Linedef type 22

From SRB2 Wiki
Jump to: navigation, search

Linedef type 22, PolyObject Parameters, is a type of linedef special which is used to set the properties of a PolyObject. This linedef is optional – if it is omitted, all properties will be set to default values. For more information on setting up PolyObjects, see the PolyObject tutorial.

Setup

To use this effect, create a control sector outside of your map, and give one of its linedefs linedef type 22. The tag of the control linedef should be set to the PolyObject's ID (which is also the tag of the corresponding linedef type 20 and the Angle of the PolyObject Spawn Point).

The control linedef's flags toggle the following settings:

  • If the Slope Skew flag is set, only the outer sides of the PolyObject will be rendered.
  • If the No Midtexture Skew flag is set, the PolyObject will be intangible.
  • If the Peg Midtexture flag is set, the PolyObject will stop any movement if it comes in contact with a pushable Object.
  • If the Solid Midtexture flag is set, the PolyObject's flats will be rendered. By default, the flats will be invisible.
  • If the Not Climbable flag is set, the PolyObject will execute any trigger linedef whose tag is set to 32000 plus the PolyObject's ID when a player lands on it (as opposed to just standing on the PolyObject, or stepping up/down onto it from elsewhere).

If the Upper Unpegged flag is set, the PolyObject's initial translucency level is set via the control linedef's front X offset, as a value between 0 (opaque) and 10 (invisible). Otherwise, it is set via the control sector's floor height, in steps of 100. The following 11 translucency levels are available:

Floor height Front X offset (Upper Unpegged) Translucency level
0–99, or below 0 0 and below 0% translucent (completely opaque)
100–199 1 10% translucent
200–299 2 20% translucent
300–399 3 30% translucent
400–499 4 40% translucent
500–599 5 50% translucent
600–699 6 60% translucent
700–799 7 70% translucent
800–899 8 80% translucent
900–999 9 90% translucent
1000 and above 10 and above 100% translucent (completely invisible)

If the Parameters linedef is omitted, the PolyObject will spawn with full opacity. The translucency of the PolyObject can be changed at runtime with linedef type 491 (Set Translucency) and linedef type 492 (Fade Translucency).

To turn the PolyObject into a child PolyObject of another, the sector special value of the control sector should be set to the parent PolyObject's ID. If this feature is not wanted, the sector special value should be set to the PolyObject's own ID; this tells the game that the PolyObject has no parent.

Sample

Example file: ex_ld022_polyobject_parameters.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_ld022_polyobject_parameters.wad into the addons folder of your SRB2 directory.
    2. Start SRB2, go to the Addons menu, and then select ex_ld022_polyobject_parameters.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 – PolyObjects [view]
First LineParametersWaving FlagDisplacement by Front SectorAngular Displacement by Front Sector