Sets the position of a gag in a level.
Scope
This command should be called between calls to GagBegin and GagEnd in a level's load script.
Syntax
Using a Locator (1 Argument)
GagSetPosition( locator_name );Game.GagSetPosition( locator_name )- locator_name: The name of a locator.
Using a Position (3 Arguments)
GagSetPosition( x, y, z );Game.GagSetPosition( x, y, z )- x: The X position.
- y: The Y position.
- z: The Z position.
Examples
Using a Locator (1 Argument)
GagBegin("gag_sqsh.p3d");
// ...
GagSetPosition("Squish");
// ...
GagEnd();Game.GagBegin("gag_sqsh.p3d")
-- ...
Game.GagSetPosition("Squish")
-- ...
Game.GagEnd()Using a Position (3 Arguments)
GagBegin("gag_bbq.p3d");
// ...
GagSetPosition(10, 10, 10);
// ...
GagEnd();Game.GagBegin("gag_bbq.p3d")
-- ...
Game.GagSetPosition(10, 10, 10)
-- ...
Game.GagEnd()Notes
If the gag is added to an interior via GagSetInterior, a locator must be used or the gag's position will be ignored and set to the position of the interior's InteriorOrigin locator.