Linedef type 9

From SRB2 Wiki
(Redirected from Chain with Maces Spawnpoint)
Jump to navigation Jump to search
Player hanging on a spinning chain.

Linedef type 9, Chain Parameters, is a type of linedef special which sets the parameters for spinning or swinging chains and the various items that can be attached to them, including maces, grabbable chains, chained springs, firebars and custom Objects.

Note that in the UDMF map format, this special is not used: since all parameters for chains and maces can be found as arguments on their respective spawnpoint things, this linedef special is not necessary.

Binary setup

A chain setup consists of a control linedef with linedef type 9 and a spawnpoint Thing inside the map. The tag of the control linedef must be equal to the Angle value of the spawnpoint Thing.

Item types

A rotating or swinging chain consists of the chain itself, which in turn consists of multiple chain link items, and the item attached to the end of it. The Object type used for the chain links and the end item depend on the Thing type used for the spawnpoint:

Thing type number Name Link item type End item type Sprites Sprites (Ambush)
1104 Mace Spawnpoint Intangible chain link Mace
1105 Chain with Maces Spawnpoint Intangible chain link Mace/Grabbable chain link1
1106 Chained Spring Spawnpoint Intangible chain link Chained yellow spring
1107 Chain Spawnpoint Intangible chain link Grabbable chain link
1109 Firebar Spawnpoint Fireball Fireball
1110 Custom Mace Spawnpoint Custom2 Custom2

If the Ambush flag is set on the spawnpoint, both the link items and the end items will be made twice as large. There are two exceptions to this: For the Custom Mace Spawnpoint, the Ambush flag has no effect. For the Chained Spring Spawnpoint, setting the Ambush flag will leave the chain links small but turn the yellow spring into a red spring instead.

If Flag [7] / No Midtexture Skew / Effect 2 is set on the control linedef, all chain link items are replaced with the corresponding end item, unless it is a grabbable chain link. For the Firebar Spawnpoint, the effect is different: Fireballs are already used as both the end item and the chain link item by default. If Flag [7] / No Midtexture Skew / Effect 2 is set, the chain link items are removed altogether.

If Flag [8] / Peg Midtexture / Effect 3 is set on the control linedef, an additional chain link item is spawned in the center of rotation.

1 The Chain with Maces Spawnpoint is meant to be used with multiple spokes (see Appearance below). In this case, some spokes will use a mace as the end item and others will use a grabbable chain link.

2 For the Custom Mace Spawnpoint, the end item type is written across the front textures of the control linedef, and the link item type is written across the back textures. If the control linedef does not have a back side, the link item type defaults to MT_NULL, i.e., no link items are spawned.

Appearance

By default, the chain setup will consist of a single chain rotating around a central point. The control linedef's X distance determines the number of links in the chain link. The front texture Y offset can be used to remove inner links from the chain – a value of -x will make the x innermost links disappear. Positive values have no effect.

The chain can be multiplied in two ways: One way is to turn the single chain into a row of rotating end items, with both ends of the row supported by a chain. This can be done by giving the control linedef a back side and setting the back texture Y offset to the width of the row, i.e., the number of additional items in the row, excluding the initial item that always appears. The other way is to create multiple spokes, i.e., multiple chains that rotate around the same central point, evenly spaced out across the rotation cycle. Specifically, the Parameter value is the number of additional spokes, excluding the one chain that always appears. Both ways can be combined to create multi-spoke chain rows.

If the control linedef has a back side, the back texture X offset determines the number of spokes that are skipped and do not appear. This can be used to create setups where some spokes use different items than the rest, by creating one setup with the respective spokes missing and another with a different item type that fills in the missing spokes. The missing spokes are distributed evenly. For the Chain with Maces Spawnpoint, the back texture X offset has a slightly different meaning – it determines the number of spokes that use grabbable chain links, while the rest use maces. The default and minimum value in this case is 1.

Movement

The control linedef's Y distance determines the chain's rotating or swinging speed, with one fracunit of distance equalling one fracunit per tic of speed.

The control sector's ceiling height determines the yaw of the rotation axis in degrees, i.e., its horizontal orientation. The floor height determines the pitch of the rotation in degrees, i.e., the vertical tilt of the rotation axis. A value of 0 means the rotation axis is perfectly horizontal, while 90 is perfectly vertical.

The control linedef's front texture X offset sets the phase of the rotation in degrees, i.e., how far into the rotation cycle the chain starts on map load.

Optional parameters can be set on the control linedef's back sector if it has one. The back sector's floor height sets the pinch in degrees. The default value of 0 makes the chain rotate in a perfect circle, while both positive and negative values distort the area of rotation into a cone shape. The back sector's ceiling height sets the roll of the rotation axis – for rotating chains this is identical to the phase, but for swinging chains it rotates the section of the circle in which the chain swings around the rotation axis. If no back sector exists, both values default to 0.

If Flag [5] / Slope Skew / Effect 1 is set on the control linedef, the chain setup will swing instead of rotate. The distance to which the chain swings before turning back is defined by its speed – the higher the speed, the further it swings.

Other options

  • If the chain includes grabbable chain links, setting Flag [6] / Not Climbable on the control linedef will allow players who are hanging on to the grabbable chain links to control the yaw of the rotation axis with their strafe keys.
  • Normally, items in a chain are allowed to clip through solid surfaces. If Flag [9] / Solid Midtexture / Effect 4 is set, items colliding with surfaces will instead glide along the surface until they are moved away from it again.
  • Normally, the chains will stop moving if no player is nearby, in order to save processing time. If Flag [10] / Repeat Midtexture / Effect 5 is set, the distance checks are disabled and the chains will always move.
  • Normally, the chains make sounds while moving. If the Object Special flag is set on the spawnpoint, these sounds are disabled.
  • If the Object Flip flag is set on the spawnpoint, the individual items in the chain will spawn in flipped gravity, but the overall setup of the chain will remain unaffected.

Notes

  • All properties of this linedef are evaluated only upon loading the level, so you cannot change this linedef's properties during runtime.

Samples

Sample 1

Example file: ex_ld009_chainparameters_mace.wad (MAP01)
How to use
  • You may load this file into your favorite map editor, such as Zone Builder. Select MAP01 as the map to load.
  • You may also load this file in the game:
    1. Save ex_ld009_chainparameters_mace.wad into the addons folder of your SRB2 directory.
    2. Start SRB2, go to the Addons menu, and then select ex_ld009_chainparameters_mace.wad.
    3. Start the game in Single Player mode.
    4. Press the Console button (~), and type in the command MAP MAP01 to access the example map.
  • When you load this file in the game, it replaces Greenflower Zone Act 1.

Sample 2

Example file: ex_ld009_chainparameters_chain.wad (MAP01)
How to use
  • You may load this file into your favorite map editor, such as Zone Builder. Select MAP01 as the map to load.
  • You may also load this file in the game:
    1. Save ex_ld009_chainparameters_chain.wad into the addons folder of your SRB2 directory.
    2. Start SRB2, go to the Addons menu, and then select ex_ld009_chainparameters_chain.wad.
    3. Start the game in Single Player mode.
    4. Press the Console button (~), and type in the command MAP MAP01 to access the example map.
  • When you load this file in the game, it replaces Greenflower Zone Act 1.

Sample 3

Example file: ex_ld009_chainparameters_chainwithmaces.wad (MAP01)
How to use
  • You may load this file into your favorite map editor, such as Zone Builder. Select MAP01 as the map to load.
  • You may also load this file in the game:
    1. Save ex_ld009_chainparameters_chainwithmaces.wad into the addons folder of your SRB2 directory.
    2. Start SRB2, go to the Addons menu, and then select ex_ld009_chainparameters_chainwithmaces.wad.
    3. Start the game in Single Player mode.
    4. Press the Console button (~), and type in the command MAP MAP01 to access the example map.
  • When you load this file in the game, it replaces Greenflower Zone Act 1.

Sample 4

Example file: ex_ld009_chainparameters_spring.wad (MAP01)
How to use
  • You may load this file into your favorite map editor, such as Zone Builder. Select MAP01 as the map to load.
  • You may also load this file in the game:
    1. Save ex_ld009_chainparameters_spring.wad into the addons folder of your SRB2 directory.
    2. Start SRB2, go to the Addons menu, and then select ex_ld009_chainparameters_spring.wad.
    3. Start the game in Single Player mode.
    4. Press the Console button (~), and type in the command MAP MAP01 to access the example map.
  • When you load this file in the game, it replaces Greenflower Zone Act 1.

Sample 5

Example file: ex_ld009_chainparameters_firebar.wad (MAP01)
How to use
  • You may load this file into your favorite map editor, such as Zone Builder. Select MAP01 as the map to load.
  • You may also load this file in the game:
    1. Save ex_ld009_chainparameters_firebar.wad into the addons folder of your SRB2 directory.
    2. Start SRB2, go to the Addons menu, and then select ex_ld009_chainparameters_firebar.wad.
    3. Start the game in Single Player mode.
    4. Press the Console button (~), and type in the command MAP MAP01 to access the example map.
  • When you load this file in the game, it replaces Greenflower Zone Act 1.

Sample 6

Example file: ex_ld009_chainparameters_custom.wad (MAP01) 
  • Rings are used as a custom object
How to use
  • You may load this file into your favorite map editor, such as Zone Builder. Select MAP01 as the map to load.
  • You may also load this file in the game:
    1. Save ex_ld009_chainparameters_custom.wad into the addons folder of your SRB2 directory.
    2. Start SRB2, go to the Addons menu, and then select ex_ld009_chainparameters_custom.wad.
    3. Start the game in Single Player mode.
    4. Press the Console button (~), and type in the command MAP MAP01 to access the example map.
  • When you load this file in the game, it replaces Greenflower Zone Act 1.



  Linedef types – Parameters [view]
2 - Custom Exit3 - Zoom Tube Parameters4 - Speed Pad Parameters8 - Special Sector Properties / Set Camera Collision Planes9 - Chain Parameters11 - Rope Hang Parameters12 - Rock Spawner Parameters14 - Bustable Block Parameters15 - Fan Particle Spawner Parameters / Fan Particle Generator Heights16 - Minecart Parameters64 - Continuously Appearing/Disappearing FOF