-=> Beginning Of File "_SPRITES.TXT" ....
.==============================. | | | SPECIAL SPRITES TUTORIAL | | | `~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~'
Contents: =========
Special Sprites Quick Reference
[01] SECTOR EFFECTOR [02] ACTIVATOR [03] TOUCHPLATE [04] ACTIVATORLOCKED [05] MUSICANDSFX [06] LOCATORS [07] CYCLER [08] MASTERSWITCH [09] RESPAWN [10] GPSPEED
Duke Addict --------------------------------------
This Tutorial will give you an understanding of all the special sprites involved in Duke3D Level editing, such as the ACTIVATORs or CYCLERs. In this section I will refer to _SPRITES.MAP which is similar to _SE.MAP. Teleporters will lead you to the corresponding rooms with examples of certain sprites and their usage. Each teleporter has a number and leads to the room with this number. The descriptions in this section are numbered the same way as the teleporters, so if you're looking for the ACTIVATOR example room step into teleporter number 02.
------------------------------------------------------------------------------
.=================================. | Special Sprites Quick Reference | `================================='
SECTOREFFECTOR : Sprite #1 ****************************************************************************** The SECTOREFFECTOR Sprite is used to create game effects and manipulate Sector attributes. The SE is the main tool to create effects such as Earthquakes, Explosions, and Lighting Effects. Place a Sprite with texture #1 in the sector to effect.
Lotag : Set equal to the corresponding effect number (see SE reference) Hitag : Set equal to other SE Sprites with same Lotag to activate together.
Note : In some cases the angle, the palette, the shading and the position of the SEs have a more or less important meaning. Please read the _SE.MAP Tutorial for more information on all possible SE functions. ******************************************************************************
ACTIVATOR : Sprite #2 ****************************************************************************** The ACTIVATOR sprite is used with Switchs or the TOUCHPLATE Sprite to activate the Sector Lotag function or any Sector Effectors within the Sector.
Lotag : Set equal to a corresponding switch sprite's lotag or TOUCHPLATE lotag Hitag : Not used ******************************************************************************
TOUCHPLATE : Sprite #3 ****************************************************************************** The TOUCHPLATE will activate an ACTIVATOR or a MASTERSWITCH Sprite when the player walks on the sector floor with a TOUCHPLATE sprite on it.
Lotag : Set equal to a corresponding ACTIVATOR or MASTERSWITCH lotag Hitag : If the hitag is 0 the touchplate is activated each time the player enters that sector. If the hitag is higher than 0 the touchplate will only activate this many times, if the hitag is 1 the touchplate will only activate once. ******************************************************************************
ACTIVATORLOCKED : Sprite #4 ****************************************************************************** The ACTIVATORLOCKED sprite will lock the sector's Lotag function so it can not be activated by the player until it is unlocked with a switch.
Lotag : Set equal to a switch's Lotag which is used to toggle Locked/Unlocked. Hitag : Not used ******************************************************************************
MUSICANDSFX : Sprite #5 ****************************************************************************** Activation sound: When used in a sector with a Lotag, it will play a sound when the sectors Lotag function is activated respectively stopped.
Lotag : number of sound to be played when the lotag function is activated (see sound reference) Hitag : number of sound to be played when the lotag function has stopped (see sound reference)
Ambiente sound: When used in a sector with no Lotag, it will play an ambiente sound.
Lotag : number of *ambiente* sound to be played (see sound reference) Note that not all sounds can be used as ambiente sound! Hitag : Max distance the sound can be heard. e.g. 512 equals the largest grid square in build.
Echo effect: When used in a sector with no Lotag and the MUSICANDSFX lotag is between 1000 and 1255 it will cause all sounds to have an echo effect.
Lotag : 1000 + the amount of echo (0-255) Hitag : Max distance the echo takes effect on other sounds e.g. 512 equals the largest grid square in build. ******************************************************************************
LOCATORS : Sprite #6 ****************************************************************************** LOCATORS define tracks for the subway or the PigCop Recon Car. You actually _can_ have more than one track for subways but NOT for the Recon Cars as they sometimes "change tracks". The subway and Recon Cars may share the same track though. They're also used as the two end points of the 2-way train (ST 31/SE 30).
Lotag : Set in an increasing order starting from 0 with no gaps in the count for all the LOCATOR Sprites in the map. When the Subway or PigCop Recon Car reaches the last LOCATOR Sprite, it will loop back to the LOCATOR Sprite with Lotag 0. Hitag : If set to 1, then the Subway will stop the LOCATOR Sprite location for 5 seconds, then continue to the next LOCATOR. The PigCop Recon Car is not effected. ******************************************************************************
CYCLER : Sprite #7 ****************************************************************************** The CYCLER sprite is used to make the Sector Floor, Walls, and Ceiling pulsate in brightness. It requires a GPSPEED sprite in the same sector!
Lotag : Defines offset of when it will pulsate Hitag : Set to any unused tag number or set equal to a switch's lotag Palette : Not used, change the sector's palette instead Shade : Set the CYCLER's shade to how bright the sector will get. Set the sector brightness to how dark it will get. Angle : MUST BE NORTH!!! (1536 of 2048 degrees in Duke measurement) GPSPEED Lotag: Set to how fast the light will pulsate. ******************************************************************************
MASTERSWITCH : Sprite #8 ****************************************************************************** The MASTERSWITCH sprite is used to activate a Sector Lotag or a Sector Effector Sprite after a variable time delay. This can be activated by a TOUCHPLATE Sprite or a switch.
Lotag : Set equal to a TOUCHPLATE Sprite or Switch Lotag to be activated by. Hitag : Set for time delay until activation of Sector Tag or Sector Effector Sprite. ******************************************************************************
RESPAWN : Sprite #9 ****************************************************************************** The RESPAWN sprite is used to Teleport in Actors and Items when activated by a TOUCHPLATE sprite or a switch.
Lotag : Set equal to TOUCHPLATE Sprite or Switch Lotag to be activated by. Hitag : Set equal to any Sprite Number that has a name with it in Build. ******************************************************************************
GPSPEED : Sprite #10 ****************************************************************************** The GPSPEED sprite is used to define the rate of movement for such things as Sector Tag 20 (Ceiling Door) and Sector Effector 0 (Rotate Sector), as well as many other effects. It doesn't work on the subway or 2-way train though. On the other hand it is required if you want to get the CYCLER sprite working.
Lotag : Set to speed rate, the actual speed depends on what type of ST/SE is affected. Hitag : Not used. ******************************************************************************
.=====================. | [01] SECTOREFFECTOR | `====================='
****************************************************************************** The SECTOREFFECTOR Sprite is used to create game effects and manipulate Sector attributes. The SE is the main tool to create effects such as Earthquakes, Explosions, and Lighting Effects. Place a Sprite with texture #1 in the sector to effect.
Lotag : Set equal to the corresponding effect number (see SE reference) Hitag : Set equal to other SE Sprites with same Lotag to activate together.
Note : In some cases the angle, the palette, the shading and the position of the SEs have a more or less important meaning. Please read the _SE.MAP Tutorial for more information on all possible SE functions. ******************************************************************************
This sample room explains the use of SECTOR EFFECTOR sprites. You'll also get a rough impression of some of the effects which you can create with the SEs.
Place a SECTOR EFFECTOR sprite by pressing S in either 2D or 3D mode and then give it texture number 1 by pressing V twice on it in 3D mode. The SEs are the most important thing in creating doors, earthquakes, exploding walls, conveyor belts, flashing lights and so on. The name says it all, they operate (create effects) on the sector in which they're placed (they're handled and moved around just like any other sprite). What they "effect" on that sector depends on their lotag (press ALT+T in 2D mode or '+T in 3D mode to change the lotag) which assigns a certain function to the SE sprite. See the SE reference for more information. You'll notice that each function requires a different setup. For example the random light SE (lotag of 4) requires that you shade the SE properly while other effects like the teleporter (SE lotag of 7) require that you place the SE correctly. The SE 4 to the left of the room creates randomly flashing light. The sector (floor) shade is to be set to the darkest light value and the SE sprite shade is to be set to the lightest light value. So the light will flicker between those two shade values. If you would make it the other way round there would be NO effect at all. So it is crucial to follow the instructions with care. Usually those small things will get you into the most troubles. You surely noticed that one sector has a red palette when the light is off. This is due to the SE4 which has its palette set to 2 (red). The other SE4 I've used in this example has a hitag of 20 to change the "randomness" of the light. If I would also set the other SE4's hitag to 20 they would always flash at the same time. Don't worry too much about all the SEs used in this room, they will be explained in the _SE.MAP Tutorial one for one. In some cases it matters at which height the SEs are placed, in the case of the teleporter SE (SE7) it is a normal teleporter like in these example teleport pads. But if you move the SE sprites off the ground there will be no teleport flash and sound. This is used in tubes in which you can fall down and come out at a different point of the map without noticing it. See the hole in which you can fall down and soon thereafter come out of the hole in the ceiling. Weird, ey? :) In most cases a SE needs more than just a lotag, usually the SE hitag (press ALT+H in 2D mode or '+H in 3D mode to change the hitag) connects the SE to a switch or a touchplate (or other SEs to go off at the same time) which will trigger the SE function if they also use the exact hitag number. If your're still confused as to what SEs are take a look at the _SE.MAP while reading the _SE tutorial, I hope this will give you an impression of how those SEs work. For the moment just play around with the SEs and change whatever you like to get an impression of how things work. Especially try changing the angle of the conveyor belt SEs (SE24) or the palette and shade of the light SEs (SE4).
.================. | [02] ACTIVATOR | `================'
****************************************************************************** The ACTIVATOR sprite is used with Switchs or the TOUCHPLATE Sprite to activate the Sector Lotag function or any Sector Effectors within the Sector.
Lotag : Set equal to a corresponding switch sprite's lotag or TOUCHPLATE lotag Hitag : Not used ******************************************************************************
This sample room explains the use of ACTIVATOR sprites. You'll also get information on doors, raising ceilings, certain switches and the TOUCHPLATE sprite.
You will notice two doors in front of you when you come out of the teleporter. I will start with them first as they're the mose simple effects in Duke. As you can see in the editor both door sectors are tagged with a lotag of 20, that actually makes them a door. In the game you will be able to open the left door "by hand" while the right door requires you to press one of the switches to the right of it to open and close the door. Let's take a closer look in the editor. The left door is just a door with a lotag of 20 and nothing else in it. The right door sector instead also contains an ACTIVATOR sprite with a lotag of 100. You will notice that the switches which open/close the door also have a lotag of 100. Why did I use two switches? The answer is simple, the dipswitch (the circular one) can be pressed all the time, even if you just pressed it and the door is still moving you can press it again and the door will immediately change its direction. The other switch can't be pressed again until the function connected to it is finished. In this case it can't be pressed again until the door is fully opened or closed. There you are, this ACTIVATOR is connected with the switches to the right by giving both the ACTIVATOR and the switch sprite a unique lotag, of course it needn't be 100 but that's how I made it in this example. Now we're ready to take a look at the darker shaped floor on the right half of the room. Don't worry about the setup, it's just a raising floor with an SE of 31 if you're anxious to look it up. In the contrary to the door this effect won't even work without an ACTIVATOR sprite! The switches on the small pillars trigger the raising floor because both the ACTIVATOR in the sector with the SE 31 sprite and the switches have a matching lotag of 101. So when you press the switch the floor goes up until it reaches the height of the SE31. If you press the switch again the sector will lower again to the floor. Again, I've created two switches to show you how differently they work. While the grey switch can't be triggered again until the sector reaches one of the end positions the dipswitch allows you to stop the moving sector. If you press it again the sector will continue moving. To teach you that a switch (it can be a TOUCHPLATE sprite as well, just to let you know) can also activate two or more different functions with the ACTIVATOR I've made another door, a small compartment on the left wall (which actually is just another door) and a raising floor on the left side of the room. The switches near the door on the left side of the room have a lotag of 102, thus they will activate all ACTIVATORs with this lotag. Both the door and the raising floor have an ACTIVATOR sprite in their respective sectors with a lotag of 102, so whenever you push the switch both the doors will open/close and the floor will raise or fall. And this makes the choice of switches most important, because the grey switch can't be activated again until ALL actions are finished thus they won't get "out of sync". By using the dipswitch the player is able to mess the actions up, for example it can happen that the door is closed but the small compartment is still open. In some cases while editing a level this effect is to be avoided. Last but not least I wanted to show that an ACTIVATOR can also be activated by a TOUCHPLATE sprite. By placing this sprite in a sector this sector becomes a touchplate which works like a switch but is triggered by the player itself. When you move onto a touchplate sector the corresponding will be activated. In this case the TOUCHPLATE has a lotag of 103 and activates the sector in front of it. In the game the touchplate is the raised red sector and if you step on it it will activate the function in the sector where the ACTIVATOR sprite is, in this case the floor will raise/fall. More on touchplates in the TOUCHPLATE section.
.=================. | [03] TOUCHPLATE | `================='
****************************************************************************** The TOUCHPLATE will activate an ACTIVATOR or a MASTERSWITCH Sprite when the player walks on the sector floor with a TOUCHPLATE sprite on it.
Lotag : Set equal to a corresponding ACTIVATOR or MASTERSWITCH lotag Hitag : If the hitag is 0 the touchplate is activated each time the player enters that sector. If the hitag is higher than 0 the touchplate will only activate this many times, if the hitag is 1 the touchplate will only activate once. ******************************************************************************
This sample room explains the use of TOUCHPLATE sprites. You'll also get information on the ACTIVATOR and MASTERSWITCH sprites.
The TOUCHPLATE sprite is used to activate a function connected to the TOUCHPLATE (via a unique hitag). The sector which contains the TOUCHPLATE sprite becomes the actual touchplate. When the player enters that sector the corresponding ACTIVATOR or MASTERSWITCH function will be activated. See the corresponding sections for more information on the ACTIVATOR and MASTERSWITCH sprites. The only real differences between an ACTIVATOR and a MASTERSWITCH are that the MASTERSWITCH can activate after a certain amount of time by assigning it a hitag (amount of delay) and the MASTERSWITCH can only be activated once. In this example I've created three red touchplate sectors on the left side with TOUCHPLATE sprites. Each TOUCHPLATE sprite has a different hitag (1-3) and I've put the corresponding hitag number on the floor. While playing the game you'll see that those touchplates will only raise/lower the floor that many times. Note that there's a fourth touchplate with no hitag (actually no hitag means that the hitag is 0). This touchplate will never stop activating no matter what many times you step on it. You will see though that the long touchplate on the right side will only activate the raising floors once altough its hitag is 0. This is because it works on MASTERSWITCH sprites (see above). After the timed delay of 40 the first MASTERSWITCH function is activated (SE31 - raise floor) and after 60 the next floor goes up. This can be done because all MASTERSWITCH sprites have the same lotag but only activate after the timed delay. A hitag of 18 is approximately a one second delay.
.======================. | [04] ACTIVATORLOCKED | `======================'
****************************************************************************** The ACTIVATORLOCKED sprite will lock the sector's Lotag function so it can not be activated by the player until it is unlocked with a switch.
Lotag : Set equal to a switch's Lotag which is used to toggle Locked/Unlocked. Hitag : Not used ******************************************************************************
This sample room explains the use of ACTIVATORLOCKED sprites. You'll also get little information on ACTIVATOR sprites and ACCESSSWITCHes.
The ACTIVATORLOCKED sprite is used to lock a ST or SE function until a switch has been flipped to unlock the function so that it can be triggered. The best and easiest example is a door that requires a switch to be opened. Try opening one of the two doors in front of you and you will have no luck unless you've pressed the appropriate switch. Like the ACTIVATOR the ACTIVATORLOCKED can also work on more than one function as seen to the left where you can lock and unlock two doors at once. I'm sure you tried the raising floor by now but I guess it didn't work as it's supposed to. I tried to lock the ACTIVATOR function by using an ACTIVATORLOCKED in the same sector. Although they are set up correctly it'll work only from time to time. I assume that you'll get the same problems whenever you try to put an ACTIVATOR and an ACTIVATORLOCKED in one sector. Usually the ACTIVATORLOCKED is used for doors that require a keycard. I've made one on the right side of the room. You have to use the ACCESSSWITCH sprite to work with keycards. I gave the switch sprite a palette of 21 to make it a switch requiring the red key. You can find the key behind the two doors. Only if you have the correct key card you can activate this switch thus enabling you to open the compartment besides.
.==================. | [05] MUSICANDSFX | `=================='
****************************************************************************** Activation sound: When used in a sector with a Lotag, it will play a sound when the sectors Lotag function is activated respectively stopped.
Lotag : number of sound to be played when the lotag function is activated (see sound reference) Hitag : number of sound to be played when the lotag function has stopped (see sound reference)
Ambiente sound: When used in a sector with no Lotag, it will play an ambiente sound.
Lotag : number of *ambiente* sound to be played (see sound reference) Note that not all sounds can be used as ambiente sound! Hitag : Max distance the sound can be heard. e.g. 512 equals the largest grid square in build.
Echo effect: When used in a sector with no Lotag and the MUSICANDSFX lotag is between 1000 and 1255 it will cause all sounds to have an echo effect.
Lotag : 1000 + the amount of echo (0-255) Hitag : Max distance the echo takes effect on other sounds e.g. 512 equals the largest grid square in build. ******************************************************************************
This sample room explains the use of MUSICANDSFX sprites. You'll also get little information on ACTIVATORs, TOUCHPLATEs and switch sprites.
The MUSICANDSFX sprite can be used in three ways. The first is the activation sound. You will have noticed that for example doors (ST 20) don't make any noise if there's no MUSICANDSFX sprite. This has a big advantage because you can assign one and the same door type different sound effects so you can easily create space doors, prison doors, mechanical doors, etc. All you have to do is to place a MUSICANDSFX sprite in a sector with a lotag, like the doors or the raising floors I've set up on the left side of this room. In the left door sector there's a MUSICANDSFX sprite with a lotag of 166. If you open that door it will immediately play the door sound and it will play the same sound again if you close the door. The door on the right side instead contains a MUSICANDSFX sprite with a *hitag* of 27. You won't hear any sound until the door reached the top. Assigning only a hitag to a MUSICANDSFX sprite will play that sound only when the sector's lotag function is finished, in this case after the door is fully opened or closed. Note that if you activate the door while it is moving you can mess the sound up so it'll be played when you open the door, just like the door to the left. To avoid this use an ACTIVATOR sprite and the correct switch sprite, one that can't be activated again until the function(s) are finished. I've also made some raising floors which can either be activated by a TOUCHPLATE or a switch, just for illustration. See the corresponding sections on ACTIVATORs and TOUCHPLATEs for more information. The left sector will play a lift sound (71) because the MUSICANDSFX sprite in that sector has a lotag of 71 which is a lift sound. The raising floor to the right has the same MUSICANDSFX sprite in it but this one also has a hitag of 73 which is a lift stop sound. You will notice the difference if you activate the two raising floors. The left one will play the lift sound each time it is activated. The right one will play the lift sound each time it is activated and it will play the lift stop sound each time the function stops (in other words each time the sector stops moving).
The second usage of the MUSICANDSFX sprite are the ambiente sounds, sounds that simply play all the time. Of course you don't want to hear these type of sounds in the whole level so you assign the MUSICANDSFX hitag a value of how far the sound can still be heard. Naturally the sound will fade out the farther you're away from the MUSICANDSFX sprite. A hitag of 512 means you can hear the sound from a distance of one (largest) grid square in BUILD. Usually hitags of 2000 to 6000 will give the best results. The three small sectors in the middle of the room with the light texture on the floor all contain MUSICANDSFX sprites. Note that in order to get the ambiente sound effect the sector in which the MUSICANDSFX sprite is placed must not have any lotag (in other words the lotag must be 0). The first sector, near the teleporter, has a hitag of 1000 so that you can hear it about when you enter the green sector. Note that if you stand in the middle of the sector and then crouch the sound will be a little louder. This is because the MUSICANDSFX sprite is the source of the sound which is placed on the floor. Makes sense? Ok, you'll see that better in the next sector, it's a smaller one with white lights. Stand on it and you will hear nothing. Only if you jump the player comes in range of the MUSICANDSFX sprite and you will hear a projector sound as long as you're in the air. I've added a jetpack so that you can test this out. If you have a look at it in the editor you can see that the hitag of the MUSICANDSFX sprite is pretty low (750) and the sprite itself floats in air, so you can't even hear it when you stand just right below. The last sector in that row, the blue one, has a MUSICANDSFX hitag of 2500 so you can hear it even if you didn't enter that sector. Imagine the MUSICANDSFX sprite as the centre of a sphere and the hitag defines the sphere's radius. Only if the player is within the sphere he can hear the sound, no matter if he's on a different sector or even behind a solid wall. When you move closer towards the blue sector you will hear a waterfall sound getting louder and louder.
The last effect you can create with a MUSICANDSFX sprite is the echo effect. It works just like the ambiente MUSICANDSFX and also requires a sector with no lotag to work. The hitag of the MUSICANDSFX sprite defines the radius in which all sounds will be echoed. It does not only work on player sounds (for example shooting weapons) but also on other MUSICANDSFX sprites. If you would place another MUSICANDSFX sprite in that red sector on the right side of the room to play an ambiente sound this ambiente sound would be echoed as well. The lotag of the echo MUSICANDSFX has to be a value between 1000 and 1255 to create the echo effect. The amount of echo is defined by the lotag, a value of 1000 will create no echoing, a value of 1255 will create a very high amount of echo, 1125 would create a medium echo effect. In this example room the echo is fairly strong (lotag 1200) and the range is 3000, high enough to have echo effects up to the walls to the north and south. So if you pick up that chaingun and walk around while shooting you'll hear the echo effect until you get "out of range" of the echo MUSICANDSFX sprite.
.===============. | [06] LOCATORS | `==============='
****************************************************************************** LOCATORS define tracks for the subway or the PigCop Recon Car. You actually _can_ have more than one track for subways but NOT for the Recon Cars as they sometimes "change tracks". The subway and Recon Cars may share the same track though. They're also used as the two end points of the 2-way train (ST 31/SE 30).
Lotag : Set in an increasing order starting from 0 with no gaps in the count for all the LOCATOR Sprites in the map. When the Subway or PigCop Recon Car reaches the last LOCATOR Sprite, it will loop back to the LOCATOR Sprite with Lotag 0. Hitag : If set to 1, then the Subway will stop the LOCATOR Sprite location for 5 seconds, then continue to the next LOCATOR. The PigCop Recon Car is not effected. ******************************************************************************
This sample room explains the use of LOCATORS sprites. You'll also get some information on subways and 2 way trains.
You can only use the LOCATORS for three different "effects", they are the subway (SE 6 & SE 14), the PigCop Recon Car (a flying enemy vehicle) and the 2-way train (ST 31/SE 30).
Let me begin with the 2-way train. This is simply one or more moving sectors, they move between point A (defined by the LOCATOR with lotag of 0) and point B (defined by the LOCATOR with lotag of 1). There are no other LOCATORS or LOCATOR tags involved in this. The sectors which should move must have a lotag of 31 and an SE 30 is used to define the direction of the moving sectors. Note that the SE 30's angle should point exactly to the LOCATOR with the lotag of 1. If the SE on the moving sector and the LOCATOR don't match at some point the moving sector will miss the LOCATOR and never start moving. This also happens if you set the SE 30 angle to point to the LOCATOR with a lotag of 0. To activate the 2-way train I've used two switches and an ACTIVATOR which should be pretty clear after you've hopefully read that section. Note that both LOCATORS must be in one and the same sector and the moving sector should not cross other sectors nor leave the sector with the LOCATORS in it.
The setup for the Recon PigCop car is a little more complex. You can place as many LOCATORS as you wish to define a track for the Recon car. The track begins with the LOCATOR whose lotag is 0, the next LOCATOR must have a lotag of 1, the following must have a lotag of 2 and so on until you gave every LOCATOR a unique and consecutive lotag value. If the Recon Car reaches the last LOCATOR (the one with the highest lotag) it will move on to the lotag 0 LOCATOR and close the loop. By adjusting the height of the LOCATORS you can adjust the Recon car's height while it follows the LOCATORS track. It's a good idea to avoid LOCATORS on the floor or ceiling or too close to walls or else the Recon Car might get stuck or flies like if it was driven by a drunken pigcop. :) The LOCATORS for the Recon car need not to be all in the same sector. If you teleport into this room for the first time you'll notice that the Recon Car always flies to the 0 lotag LOCATOR first, this can't be changed. Also, if there are more than one 0 lotag LOCATOR it will move to the 0 lotag LOCATOR with the highest sprite number (use ALT+TAB on a sprite to see the sprite number). Since this number will change every time you save a level it's not a good idea to make more than one track if you use Recon cars. You might see this effect if the Recon Car moves to the 2-way train LOCATORS instead of the others. Of course, if you know what you're doing you might get it working.
Finally, the subway tracks. The LOCATORS are used similarly to the Recon Car LOCATORS, in fact in my example room the Recon Car and the subway share one and the same track. Note the CONEs, I've added them to visualize the track in the game so you can see how the Recon Car and subways follow the track. Making a subway is fairly easy, you just need to make a sector in a sector and put a SE 6 on it, the angle of the SE 6 should point to the first LOCATOR, and the hitag of the SE 6 defines the first LOCATOR to move to. The subway SEs in the upper right corner have a hitag of 7 so they will start moving towards the LOCATOR with a lotag of 7 and then follow the track as usual. The SE 14 on the subway cars are very similar to the SE 6, they define the sectors as cars instead of another engine. The height of the LOCATORS doesn't matter for subways and you must make sure that all LOCATORS as well as all subways and subway cars are in one and the same sector. They should not leave this sector or cross other sectors. You will notice that two of the LOCATORS also have a hitag of 1. That makes the subways slow down and stop right after that LOCATOR. They will not stop immediately so you'll have to set the 1 hitag LOCATORS a little before your supposed train station.
.=============. | [07] CYCLER | `============='
****************************************************************************** The CYCLER sprite is used to make the Sector Floor, Walls, and Ceiling pulsate in brightness. It requires a GPSPEED sprite in the same sector!
Lotag : Defines offset of when it will pulsate Hitag : Set to any unused tag number or set equal to a switch's lotag Palette : Not used, change the sector's palette instead Shade : Set the CYCLER's shade to how bright the sector will get. Set the sector brightness to how dark it will get. Angle : MUST BE NORTH!!! (1536 of 2048 degrees in Duke measurement) GPSPEED Lotag: Set to how fast the light will pulsate. ******************************************************************************
This sample room explains the use of CYCLER sprites. You'll also get little information on switches, the palette and the GPSPEED sprite.
There are a few things you must take care of when making pulsating lights with the CYCLER sprite. First, make sure the CYCLER sprite's angle is NORTH or it won't work at all. Second the CYCLER requires a GPSPEED sprite in the same sector or it also won't work. Of course, the GPSPEED's lotag must be higher than 0 or you won't see any effect. Common lotag values for the GPSPEED sprite range from 32 (very slow) to 256 (very fast). Higher values make the pulsating light look like a flashing light. The third thing you have to pay attention to is the CYCLER's hitag which must be set to any unused tag number. If you wish to turn it on/off with a sprite then assign the sprite's lotag the same tag number as the CYCLER's hitag. In my example the lights to the left can't be switched, the CYCLER's hitags are simply unused tags. To the right I've made three switches which correspond with the CYCLER's hitags to turn the light "sequences" on and off. You'll notice that two of the lights on the left side are colored (blue/red), this is because the sector's floor and ceiling have a different palette number of 1 respectively 2. Use ALT+P in 3D mode to change the palette number. Just for illustration I've changed the palette of the third CYCLER sprite to red but in the game the light appears white as usual, so the CYCLER palette has no meaning. I've also rotated the GPSPEED sprites to show that their angle and relative position doesn't matter whatsoever. Now to the right side, you surely noticed that the lights pulsate in sequence. This effect can be created by cleverly changing the speed (GPSPEED lotag) and the initial offset (CYCLER's lotag). I will try to explain this referring to the south row (the one near to the teleporter). All the CYCLER sprites have a hitag of 151 so they can be switched on/off with the corresponding switch. Note that they all do not need to have the same hitag in order to work in a sequence but it makes sense because that way you spare some tags and of course you can only switch them off all at once if they all have the same hitag. The GPSPEED sprite has a lotag of 32 so that the light pulsates very slow. In order to create any sequence all GPSPEED's in that sequence must have the same lotag, no matter what but it must be the same to all, or the sequence will get out of sync(hronisation). Finally, to make the sequence work, all CYCLER lotags must follow the same interval, that means if you start with a lotag of 0 at the first CYCLER and give the next CYCLER a lotag of 500, the third CYCLER's lotag should be 1000, the fourth's lotag should be 1500 and so on. I guess you got the trick now? :) Try experimenting with the different offsets and the GPSPEED sprite now and see how it affects the sequences.
.===================. | [08] MASTERSWITCH | `==================='
****************************************************************************** The MASTERSWITCH sprite is used to activate a Sector Lotag or a Sector Effector Sprite after a variable time delay. This can be activated by a TOUCHPLATE Sprite or a switch.
Lotag : Set equal to a TOUCHPLATE Sprite or Switch Lotag to be activated by. Hitag : Set for time delay until activation of Sector Tag or Sector Effector Sprite. ******************************************************************************
This sample room explains the use of MASTERSWITCH sprites. You'll also get little information on the SEENINE and TOUCHPLATE sprites as well as switches and raising floors.
In general the MASTERSWITCH sprite is the same as an ACTIVATOR with two differences: it can have a time delay (MASTERSWITCH hitag) and it only works once. The left of the two doors opens immediately because the MASTERSWITCH's hitag is left at 0. So it works just like an ACTIVATOR with the exception that you can't close the door again once it has opened. The same goes for the right door which opens after a time delay of 35 (that's about two seconds). You can also trigger other things like the SEENINE sprite (exploding barrel, usually used for exploding walls). The MASTERSWITCH is in the same sector as the SEENINE sprites and their hitag is the same as the MASTERSWITCH's lotag to connect them together. Again the MASTERSWITCH has a hitag so the cans won't go off immediately. You can also assign more than one MASTERSWITCH to a TOUCHPLATE or switch. On the right side of the is the well-known raising staircase, made out of raising floor SEs. All the MASTERSWITCHes will be activated by the TOUCHPLATE with the lotag of 163, but all MASTERSWITCHes have different hitags so they won't activate all at the same time. The first MASTERSWITCH activates the raise floor function (SE 31) after a delay of 100, the next after a delay of 115 (in other words 15 time units later than the first). Although the original BUILDHLP.EXE docs say that a MASTERSWITCH can only be activated by a TOUCHPLATE it works perfectly in my example room. See the compartment on the left side, it is triggered by a switch. The switch's lotag connects it to the MASTERSWITCH in the small door sector and the MASTERSWITCH will activate the door after 30 time units. Isn't that great? ;)
.==============. | [09] RESPAWN | `=============='
****************************************************************************** The RESPAWN sprite is used to Teleport in Actors and Items when activated by a TOUCHPLATE sprite or a switch.
Lotag : Set equal to TOUCHPLATE Sprite or Switch Lotag to be activated by. Hitag : Set equal to any Sprite Number that has a name with it in Build. ******************************************************************************
This sample room explains the use of RESPAWN sprites. You'll also get little information on TOUCHPLATEs and switches.
Just like with the MASTERSWITCH the original BUILD docs are in error, the RESPAWN sprite can also be activated by a switch. The RESPAWN sprite is quite self-explanatory, the RESPAWN's lotag connects it to a switch or TOUCHPLATE with the same lotag number, and the RESPAWN's hitag is the number of the Item/Actor to teleport in the game. But not all numbers that have a name in BUILD's texture list work, for example the SEENINE sprite 1247 can't be spawned. You'll have to find out by try and error as to which things can be spawned and which not, I don't have any "spawnable things" list (yet). If you play this example room and press one of the switches or step on one of the TOUCHPLATEs a thing or enemy will be teleported in the game, just in front of you. Of course, some things just "happen". ;) Note that by changing the RESPAWN sprite's height you could also spawn enemies or other things right in the air. But there's no easy way to avoid the flash when things respawn.
.==============. | [10] GPSPEED | `=============='
****************************************************************************** The GPSPEED sprite is used to define the rate of movement for such things as Sector Tag 20 (Ceiling Door) and Sector Effector 0 (Rotate Sector), as well as many other effects. It doesn't work on the subway or 2-way train though. On the other hand it is required if you want to get the CYCLER sprite working.
Lotag : Set to speed rate, the actual speed depends on what type of ST/SE is affected. Hitag : Not used. ******************************************************************************
This sample room explains the use of GPSPEED sprites. You'll also get little information on TOUCHPLATEs.
The GPSPEED sprite can be placed in a sector which either has a sector lotag function or a SECTOR EFFECTOR. Note that not all STs/SEs are affected by the GPSPEED sprite, one of them is the subway which will always run at the same speed. If you play this room you'll see the three raising floors, triggered by three touchplates as seen in the TOUCHPLATE section. I simply added a GPSPEED sprite to each sector. The lotag of the GPSPEED defines how fast (or slow) the floor raises, 50 is very slow, 500 is just appropriate and 2000 is very fast. You'll probably notice that the raising floor on the right side with the GPSPEED sprite with a lotag of 2000 will not always reach the desired heigt. This is because higher lotag values make the raising floors more inaccurate, so be careful when using high GPSPEED values. But note that this does not affect all types of moving sectors, floors or whatever. As you can see, the right door in front of you has a GPSPEED sprite in the door sector with a lotag of 2048 and still behaves correctly. You could even set this to 4000 or higher although it wouldn't make much difference. Just to show you which GPSPEED lotag value will produce which speed I've made two other doors. You'll notice that since the doors normally move faster (without a GPSPEED sprite that is) than the raising floors, they will also move faster if both the door and raising floor have a GPSPEED sprite lotag of, say 500. The "engines" on the right side of the room will teach you that the height of the GPSPEED sprite doesn't matter, it just has to be in the same sector. And they show that although one of them has a GPSPEED sprite lotag of 800 it moves relatively fast compared to the door and the raising floor with GPSPEED sprite lotags of 2000 and above. The same goes for the engine with the GPSPEED lotag of 2, it's very slow but still relatively fast compared to the raising floor with a GPSPEED lotag of 50. This is due to the fact that even without a GPSPEED sprite the engine moves a lot faster than doors or especially the raising floors.
-=> End Of File "_SPRITES.TXT" ....