For: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
Line 2: | Line 2: | ||
'''for''' <gamevar> <function> <value> { [...] } | '''for''' <gamevar> <function> <value> { [...] } | ||
Executes the code in the curly braces for every instance of the | Executes the code in the curly braces for every instance of the function specified, and <[[gamevar]]> stores the sprite/sector/wall/etc found in the current function. For example, setting <function> to '''allsprites''' will execute the code for every sprite in-game, and the var specified in <[[gamevar]]> will be set to the sprite number of the current sprite it's on. | ||
== Functions == | == Functions == |
Revision as of 03:56, 25 February 2020
for <gamevar> <function> { [...] }
for <gamevar> <function> <value> { [...] }
Executes the code in the curly braces for every instance of the function specified, and <gamevar> stores the sprite/sector/wall/etc found in the current function. For example, setting <function> to allsprites will execute the code for every sprite in-game, and the var specified in <gamevar> will be set to the sprite number of the current sprite it's on.
Functions
allsprites | All actors/sprites in-game. |
allsectors | All sectors in the map. |
allwalls | All walls in the map. |
activelights lights |
All active polymer lights. |
drawnsprites | Only the sprites currently being drawn. |
spritesofsector<sectnum> sprofsec<sectnum> |
All sprites in the given sector. |
spritesofstatus <statnum> sprofstat <statnum> |
All sprites with the given statnum. |
wallsofsector <sectnum> walofsec <sectnum> |
The walls of the given sector. |
loopofwall <wall num> | All walls in the same loop of the given wall. |
range <num> | A range from 0 to the number specified. |