Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Breeder

Scroll Floor/Thing According to Sector Height DOOMinHexen

Recommended Posts

I am working on a map for Odamex and am editing in DOOM in Hexen mode.

I would like to use the feature shown in the BOOMEDIT.WAD here:

http://doomedsda.us/wad1706.html

That allows you to scroll a floor and the items on in, in accord with a sector height change. If you load up the WAD and head to the opposite end of the starting room, you will see an example in DOOM mode.

Share this post


Link to post

I guess you would have to employ a script to simulate the BOOM effect, for example

#include "zcommon.acs"

script 1 (void)

{
    Floor_LowerByValueTimes8 ( 15, 32, 45 );
    Scroll_Floor ( 10,  384,  0, 2 );
    tagwait (15);

    if
       ( GetSectorFloorZ ( 15, 0, 0 ) == 26.0 )
            Print (s:"This platform is 26 mu above the floor");
            Scroll_Floor ( 10,  0,  0, 2 );   
}
Example pwad

[edit]
I'm not sure if Odamex is up to it, I only tested in ZDOOM and affiliates.

Share this post


Link to post

You don't need a script. All the Boom specials have a corresponding translation in Hexen mode.

Boomedit illustrates effects 214--218 and 245--254. So you look in zdoom.pk3 how they are translated to the Hexen line system

214 = 0,		Scroll_Ceiling (tag, 6, 0, 0, 0)
215 = 0,		Scroll_Floor (tag, 6, 0, 0, 0)
216 = 0,		Scroll_Floor (tag, 6, 1, 0, 0)
217 = 0,		Scroll_Floor (tag, 6, 2, 0, 0)
218 = 0,		Scroll_Texture_Model (lineid, 2)
245 = 0,		Scroll_Ceiling (tag, 5, 0, 0, 0)
246 = 0,		Scroll_Floor (tag, 5, 0, 0, 0)
247 = 0,		Scroll_Floor (tag, 5, 1, 0, 0)
248 = 0,		Scroll_Floor (tag, 5, 2, 0, 0)
249 = 0,		Scroll_Texture_Model (lineid, 1)
250 = 0,		Scroll_Ceiling (tag, 4, 0, 0, 0)
251 = 0,		Scroll_Floor (tag, 4, 0, 0, 0)
252 = 0,		Scroll_Floor (tag, 4, 1, 0, 0)
253 = 0,		Scroll_Floor (tag, 4, 2, 0, 0)
254 = 0,		Scroll_Texture_Model (lineid, 0)
http://zdoom.org/wiki/Scroll_Ceiling
http://zdoom.org/wiki/Scroll_Floor
http://zdoom.org/wiki/Scroll_Texture_Model

Share this post


Link to post
Gez said:

You don't need a script. All the Boom specials have a corresponding translation in Hexen mode.

Boomedit illustrates effects 214--218 and 245--254. So you look in zdoom.pk3 how they are translated to the Hexen line system

214 = 0,		Scroll_Ceiling (tag, 6, 0, 0, 0)
215 = 0,		Scroll_Floor (tag, 6, 0, 0, 0)
216 = 0,		Scroll_Floor (tag, 6, 1, 0, 0)
217 = 0,		Scroll_Floor (tag, 6, 2, 0, 0)
218 = 0,		Scroll_Texture_Model (lineid, 2)
245 = 0,		Scroll_Ceiling (tag, 5, 0, 0, 0)
246 = 0,		Scroll_Floor (tag, 5, 0, 0, 0)
247 = 0,		Scroll_Floor (tag, 5, 1, 0, 0)
248 = 0,		Scroll_Floor (tag, 5, 2, 0, 0)
249 = 0,		Scroll_Texture_Model (lineid, 1)
250 = 0,		Scroll_Ceiling (tag, 4, 0, 0, 0)
251 = 0,		Scroll_Floor (tag, 4, 0, 0, 0)
252 = 0,		Scroll_Floor (tag, 4, 1, 0, 0)
253 = 0,		Scroll_Floor (tag, 4, 2, 0, 0)
254 = 0,		Scroll_Texture_Model (lineid, 0)
http://zdoom.org/wiki/Scroll_Ceiling
http://zdoom.org/wiki/Scroll_Floor
http://zdoom.org/wiki/Scroll_Texture_Model


I had no idea where to look intside the zdoom.pk3, though I do see that I need special 223.

What I don't understand is how to make a floor, the items on it, and the texture it uses, to remain still until I trigger the corresponding switch. And then, when the switch is triggered, have the floor and items scroll a tiny amount (just enough to move one item ahead), and then stop, be it with the XY settings, or by associating the linetag with the sector it is connected to ala the BOOMEDIT.WAD.

Share this post


Link to post

You open zdoom.pk3 and select xlat/base.txt.
That file contains the linedef translations from Doom to Hexen types. So you look up what special is being used in boomedit.wad, see what it maps to and enter that in the editor.
Most are obvious, but if you encounter one with a constant, you can look up that constant in xlat/defines.i.

Special 223 is Sector_SetFriction, btw, which only indirectly affects what happens here.

Share this post


Link to post

Look up what args need to be set, based on the line type the Boom map uses.
That's the 5 parameters behind the special name.

Share this post


Link to post

You'll want to use a displacement or accelerative scroller, so that the scroll is dictated by the movement of something else. Then your switch moves that other thing. So like Boom linetypes 217 or 248 in the Boomedit map. That means you use line special 223, with first parameter being sector tag of the sector that must scroll, second parameter being 5 or 6, and third parameter being 2.

Then it's a question of fine-tuning the movement speed by choosing the parameters for the sector movement used. You have more flexibility than in Boom.

Share this post


Link to post
Gez said:

You'll want to use a displacement or accelerative scroller, so that the scroll is dictated by the movement of something else. Then your switch moves that other thing. So like Boom linetypes 217 or 248 in the Boomedit map. That means you use line special 223, with first parameter being sector tag of the sector that must scroll, second parameter being 5 or 6, and third parameter being 2.

Then it's a question of fine-tuning the movement speed by choosing the parameters for the sector movement used. You have more flexibility than in Boom.


I am getting close, but no cigar. What I have set up is a switch that controls a platform residing in a sector that is not accessible by the player within the map.

On one of the sides lines that make up the platform that is to be controlled by the switch I have assigned this:

http://www.tiikoni.com/tis/view/?id=8b2b54f


Now that line is associated with the sector with items that I expect to move.

What happens though when I throw the switch is that the sector and items scroll at one angle for a while, then scroll at another angle for a while, then stops.

This is close, so close, but not quite what I have in mind. I just want it to scroll in a straight line, and then stop. What I do not understand is how to define this, for as you can see in the image, the only X,Y, options I seem to have are how fast I want them to scroll, there seems to be no way to control how to tell it not to scroll X or Y, or in what direction I want it to scroll so as to avoid the angled scrolling effect.

Thanks again!

Share this post


Link to post
Breeder said:

.... a switch that controls a platform residing in a sector that is not accessible by the player within the map.


Why try to replicate the afore mentioned boom effect if you don't make the lowering sector available to the player ?

Since you did not respond to my earlier example I don't know if it was helpful or not.
As that may be, I'll give you one more, greatly simplified, example, moving a green pillar out of the way.


#include "zcommon.acs"

script 1 (void)

{
    Scroll_Floor (10,  32,  -32, 2);
    delay (35);
    Scroll_Floor (10,  0,  0, 2);
}
[edit]
Or .....
Depending on what you want to move, instead of a scrolling floor, you could also use (130) Thing_Activate
to initiate a (9074) Actor Mover thing and appropriate interpolation points.

Share this post


Link to post
Kappes Buur said:

Why try to replicate the afore mentioned boom effect if you don't make the lowering sector available to the player ?

Since you did not respond to my earlier example I don't know if it was helpful or not.
As that may be, I'll give you one more, greatly simplified, example, moving a green pillar out of the way.


#include "zcommon.acs"

script 1 (void)

{
    Scroll_Floor (10,  32,  -32, 2);
    delay (35);
    Scroll_Floor (10,  0,  0, 2);
}
[edit]
Or .....
Depending on what you want to move, instead of a scrolling floor, you could also use (130) Thing_Activate
to initiate a (9074) Actor Mover thing and appropriate interpolation points.


Sorry man, wasn't trying to be rude, I was just avoiding a scripting solution if possible. I think I may have it worked out, will test when I get back home. If not, I'll try your script.

Share this post


Link to post
Breeder said:

.... I was just avoiding a scripting solution if possible....


Out of curiosity I installed Odamex. Now I know why you don't want scripts.
Compatibility with BOOM or ZDoom (DiH) displacement scrollers seems non-existant, even as linedef triggers.

Share this post


Link to post

Odamex is based upon ZDOOM 1.23, though the scripting elements needed for this should still be present. Though as I said, the non-script method also seems to work, all I need now is to figure out how to control the direction under which it scrolls.

Share this post


Link to post

Aghh ha! I got the dang thing! Turns out that the direction the line associated with the sector is facing, also determines the direction of the scroll. Closer, closer, closer!!! :)

Still ain't perfect, but now I know at least it can be done!

OK, gonna shut up now and finish my work!

Thanks again everyone!


EDIT: I take that back, the direction of the line does not determine the direction of the scroll...
...what in the world did I do to change it then?!

Share this post


Link to post

It depends on the scrollbits parameters. If the value is 4, 5, or 6, the linedef will determine the scrolling. If it is 0, 1, or 2, then the scrolling is determined by x-move and y-move parameters.

Share this post


Link to post
Kappes Buur said:


Yes, this script works in Odamex (the one above it did not), what it does is create and infinite spawn point for the Health packs.

What my goal is, without scripts, though I'll happily use them if needed, is to in the end (and I know how to do the rest of this) is to have a switch on the wall, with an opening of the sealing above. What I intend to do is make the sprites for the health pack invisible. Then have up to 5 health packs sitting on a motionless conveyor belt along side the hole in the ceiling. Each time the switch is pressed, a pack will fall, and the player will get health, and will of course be able to use this up to 5 times.

The idea, is that in the end the illusion of a health station will be created, ala Chronicles of Riddick, and there will be no non-seniscal random health packs laying about the level....

...I mean who just leaves guns, bullets, amour, health packs and the like laying around anyhow?! :)

Share this post


Link to post
Kappes Buur said:

Why did you choose Odamex as your mapping port ?


It's a fan tribute for the Alien Breed series. When I started it, Odamex was the most powerful DOOM engine that could be ported to next generations Amiga platforms, and that was the platform I was targeting, as I wanted to create a game from Amiga history for modern Amiga OS' and what better than Alien Breed on a DOOM engine? A game series who's sequels grew into DOOM clones them selves.

Had I known ZDOOM was going to be available, I'd have opted for that.

That being said, since I started, I got to know some of the devs behind Odamex a bit on IRC, and I took a liking to them and their source port. It's kind of like a flash back to when DOOM Legacy and ZDOOM 1.x were the kings of the hill and still slowly expanding the features of DOOM.

With ZDOOM, GzDOOM, Zandronum and the like, you can do pretty much what ever you can imagine, which is AWESOME, though I still find it interesting to see what one can push out of a more limited play space. So taking all that into consideration, though my project will be somewhat amateur, I hope to create a worth while Total Conversion for the Odamex engine. After all, aside of this and the DOOM III TC that is supposed to release for it, I am not aware of any other project being developed strictly with it in mind.

On a side note, Odamex also runs on the classic XBOX...
...it's kind of cool making a game that will run on one of my game consoles. :)

Share this post


Link to post
Gez said:

It depends on the scrollbits parameters. If the value is 4, 5, or 6, the linedef will determine the scrolling. If it is 0, 1, or 2, then the scrolling is determined by x-move and y-move parameters.


When you say "scrollbits parametere" are you referring to the "options" where it lets you select between Displacement, Accelerative, and X/Y?

Choosing between Displacement and Accelerative change the direction the floor scrolls, but gives me absolutely no control in regards as to what direction it scrolls. The only option that does present itself is the ability to control the speed of the scroll, and I am editing GzDOOM in Hexen format.

Share this post


Link to post
Gez said:

I'm referring to what is called scrollbits in this article that is linked here: http://zdoom.org/wiki/Scroll_Floor

This is the link you have to click: http://zdoom.org/wiki/Scroll_Floor

Also, read this article if you need help: http://zdoom.org/wiki/Scroll_Floor

And just for reference: http://zdoom.org/wiki/Scroll_Floor


I found what I needed here:

http://zdoom.org/ref2/specials/scroll_floor.html

Turns out the X and Y, though not correctly marked in GzDOOM Builder, do in fact control the direction of the scroll. Though as it turns out, it is Odamex that is the source of the problem as it can scroll East and North, but not West and South. This works under ZDOOM 1.23 beta, though not ZDOOM 1.22, so maybe that is why. Some things from 1.23 did not make it into Odamex.

Sorry for wasting so much time, but now I at least know I can submit a bug report and I guess move on to using a script to resolve this. That or place my med stations on a side of a wall where scrolling the items N or E will benefit me. :)

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×