Scripting/Squirrel/Functions/Checkpoint.Radius: Difference between revisions

From Vice City Multiplayer
Jump to navigation Jump to search
Caution icon
This wiki is using an old backup from 2020
Some information may be old/missing
No edit summary
No edit summary
Line 1: Line 1:
Checkpoint.Radius : By using this function, You can set the radius of the checkpoint, that means how big the checkpoint will be.
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, u need to give it a name
To do it, 1st of all, you need to create a checkpoint.


<pre>function onScriptLoad()
<pre>function onScriptLoad()
  {  
  {  
array <- 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);
  }</pre>
  }</pre>


Line 15: Line 15:
if ( GetPlayers() >=3 )
if ( GetPlayers() >=3 )
{
{
array.Radius = 2;  
cp.Radius = 2;  
}
}
}</pre>
}</pre>




By VCMP Team
By someone

Revision as of 08:18, 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.

function onScriptLoad()
 { 
cp <- CreateCheckpoint(null, 0, Vector( 132.42, 674.34, 12.6543 ), RGB( 255, 0,255 ), 2);
 }

Then you may set it radius to differnt types Now let's see


function onPlayerJoin( player ) 
{ 
if ( GetPlayers() >=3 )
{
cp.Radius = 2; 
}
}


By someone