CreateFire
From Liberty Unleashed Wiki
This function creates a scripted fire at the given coordinates.
Syntax
bool CreateFire( Vector vPos, float fRadius )
bool CreateFire( float x, float y, float z, float fRadius )
Arguments
- vPos - The position of the script fire as a vector
- x, y, z - The coordinates of the fire as separate float values
- fRadius - The radius of the fire
Example
This will create a fire with a radius of 5.0 10 x co-ordinate units away from the player.
function onPlayerCommand( player, cmd, text ) { if ( cmd == "fire" ) { local pos = player.Pos; CreateFire( pos.x + 10.0, pos.y, pos.z, 5.0 ); } return 1; }
Notes
The function Player.Pos and call onPlayerCommand were used in this example. More info about them in the corresponding pages.
Related Functions
- CreateExplosion
- CreateFire
- ExtinguishFire
- ExtinguishAllFires