Squirrel/Server/Functions/Checkpoints/Remove
From Liberty Unleashed Wiki
(Difference between revisions)
(→Example) |
m |
||
(One intermediate revision by one user not shown) | |||
Line 1: | Line 1: | ||
− | + | {{Squirrel/Title|Checkpoint.Remove}} | |
− | This function removes the | + | This function removes the checkpoint. |
== Syntax == | == Syntax == | ||
Line 10: | Line 10: | ||
== Example == | == Example == | ||
+ | |||
+ | This example will remove the checkpoint when a player enters it. | ||
<code lang="squirrel"> | <code lang="squirrel"> | ||
− | function | + | function onPlayerEnterCheckpoint( player, checkpoint ) |
{ | { | ||
− | + | checkpoint.Remove(); | |
+ | |||
+ | return 1; | ||
} | } | ||
</code> | </code> | ||
Line 20: | Line 24: | ||
=== Notes === | === Notes === | ||
− | + | The event [[Squirrel/Server/Events/Marker/onPlayerEnterCheckpoint|onPlayerEnterCheckpoint]] was used in this example. More info about it in the corresponding page. | |
== Related Functions == | == Related Functions == | ||
{{Squirrel/Server/Functions/Checkpoints}} | {{Squirrel/Server/Functions/Checkpoints}} |
Latest revision as of 17:56, 12 February 2012
This function removes the checkpoint.
[edit] Syntax
bool Checkpoint.Remove()
[edit] Arguments
- none
[edit] Example
This example will remove the checkpoint when a player enters it.
function onPlayerEnterCheckpoint( player, checkpoint ) { checkpoint.Remove(); return 1; }
[edit] Notes
The event onPlayerEnterCheckpoint was used in this example. More info about it in the corresponding page.