User Tools

Site Tools


xg:examples

Line Type examples

Restore sector light color & luminance

Line Type {
   ID = 6101
   Flags2 = when_deact | when_act | any
   Class = sector_light
   Type = flip
   Count = -1
   Ip0 = "lpref_line_tagged_floors"
   Ip2 = 1
   Ip3 = 1
   Ip4 = "lightref_original"
   Ip6 = "lightref_original"
}

Restores the light level and color of the sectors that have the same tag number as the line to their original values, when the line is activated or deactivated. The line can only be activated with Chain events (no activation method is specified). Game mode and skill level have no effect. The line can be activated an infinite number of times (count is –1). Note that a line-plane reference is used to refer to whole sectors. This can be done because lpref_line_tagged_floors is actually the same as lsref_line_tagged.

Change wall material

Line Type {
   ID = 5070
   Flags = player_use
   Flags2 = when_act | any
   Class = wall_texture
   Type = timed_off
   Count = 1
   Time = 1
   Act sound = "swtchn"
   Ip0 = "lref_all"
   Ip3 = "SP_FACE1"
   Ip4 = "SP_FACE1"
   Ip5 = "SP_FACE1"
}

The line can be activated with player Use events. Game mode and skill level have no effect. The line is initially inactive and once activated it stays active for one second after which it deactivates itself. When activated, the upper, lower and middle textures of the front side of all lines in the map are changed to SP_FACE1. The standard Doom switch sound swtchn is played upon activation. The line can only be activated once.

Lower sector floor

Line Type {
   ID = 5006
   Comment = "Lower when Poss gone"
   Flags = mobj_gone | ticker
   Flags2 = when_act | any
   Class = plane_move
   Type = timed_off
   Count = 1
   Time = 1
   Thing type = "POSSESSED"
   Ticker tics = 5
   Texmove angle = 90
   Texmove speed = 1
   Ip0 = "lpref_my_floor"
   Ip2 = "spref_lowest_floor"
   Ip3 = "pmf_follow pmf_crush"
   Ip4 = "bdopn"
   Ip5 = "bdcls"
   Ip6 = "punch"
   Ip10 = "HCSKULL1"
   Fp0 = 3
   Fp1 = 0.2
   Fp3 = 0.2
   Fp4 = 0.4
}

The line is activated by the game ticker. Activation will only succeed if all the things whose type is POSSESSED have died or been removed from the map. Game mode and skill level have no effect. When activated, the line begins moving the floor plane of its sector. The destination height is the lowest floor height of the adjacent sectors. The ceiling of the sector will follow at a fixed distance from the floor, so the height of the sector won't change. The sector would crush things if they got in the way. The sound bdopn is played when the move is begun, and bdcls is played when the destination height has been reached. The punch sound is played at random intervals while the plane is moving (min: 0.2 seconds, max: 0.4 seconds). The planes will be moved 3 units per game tic, which means they move 105 units per second. In the end of the move the texture HCSKULL1 is applied to the floor.

xg/examples.txt · Last modified: 2018-10-20 07:34 by skyjake