Squirrel/Functions/Server/GetFallEnabled
From VC-MP Wiki
Contents |
Syntax
GetFallEnabled();
Arguments
true or false.
Use
The function GetFallEnabled(true/false); is used to detect whether the almighty most hated command on VC-MP named /fall is enabled or not. There are many ways to combine this function in order to find out whether it is enabled or not without having to risk a ban by typing the command. I'll start with a simple example.
Examples of usage
function OnPlayerCommand( player, command, text )
{
if( command == "checkfall" )
{
if (GetFallEnabled(true)) Message("/fall is currently enabled on this server.");
else Message("/fall is currently disabled on this server.");
}
}
This is the simplest way to implement this helpful function into your script. Another, quite more informative way, would be to shout out a message to the player when he/she joins.
function onPlayerJoin( player )
{
if (GetFallEnabled(false)) MessagePlayer("/fall is disabled. Please do not try using it.");
else MessagePlayer("/fall is enabled on this server. We strongly advise you to not use it if you do not want to have problems later on.");
}
Thank You
For reading this. I hope this will help people. - Morphine.
