Scripting/Squirrel/Functions/Checkpoint.Radius: Difference between revisions
Jump to navigation
Jump to search
This wiki is using an old backup from 2020
Some information may be old/missing
No edit summary |
No edit summary |
||
| Line 2: | Line 2: | ||
To do it, 1st of all, you need to create a checkpoint. | To do it, 1st of all, you need to create a checkpoint. | ||
== Syntax == | |||
<pre>Checkpoint.Radius = (int)Radius</pre> | |||
== Arguments == | |||
int <b>Radius</b> - The size/Radius of the checkpoint | |||
== Example == | |||
<pre>function onScriptLoad() | <pre>function onScriptLoad() | ||
{ | { | ||
cp <- CreateCheckpoint(null, 0, Vector( 132.42, 674.34, 12.6543 ), RGB( 255, 0,255 ), 2); | cp <- CreateCheckpoint(null, 0, Vector( 132.42, 674.34, 12.6543 ), RGB( 255, 0,255 ), 2); | ||
} | } | ||
function onPlayerJoin( player ) | |||
{ | |||
{ | |||
if ( GetPlayers() >=3 ) | if ( GetPlayers() >=3 ) | ||
{ | { | ||
Revision as of 08:31, 24 February 2016
Checkpoint.Radius : By using this function, You can set the radius of the checkpoint, that means how big the checkpoint will be. To do it, 1st of all, you need to create a checkpoint.
Syntax
Checkpoint.Radius = (int)Radius
Arguments
int Radius - The size/Radius of the checkpoint
Example
function onScriptLoad()
{
cp <- CreateCheckpoint(null, 0, Vector( 132.42, 674.34, 12.6543 ), RGB( 255, 0,255 ), 2);
}
function onPlayerJoin( player )
{
if ( GetPlayers() >=3 )
{
cp.Radius = 2;
}
}
By someone