mirror of
https://github.com/Resxt/Plutonium-IW5-Scripts.git
synced 2025-04-20 13:05:43 +00:00
chat_commands 1.2.1
Added DvarDoesNotExistError error Added DvarIsInitialized util function
This commit is contained in:
parent
e866fd5b26
commit
994e69632e
@ -228,6 +228,11 @@ PlayerDoesNotExistError(playerName)
|
|||||||
return ["Player " + playerName + " was not found"];
|
return ["Player " + playerName + " was not found"];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
DvarDoesNotExistError(dvarName)
|
||||||
|
{
|
||||||
|
return ["The dvar " + dvarName + " doesn't exist"];
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* Utils section */
|
/* Utils section */
|
||||||
@ -295,6 +300,12 @@ SetStatus(commandName, player, status)
|
|||||||
player.chat_commands["status"][commandName] = status;
|
player.chat_commands["status"][commandName] = status;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
DvarIsInitialized(dvarName)
|
||||||
|
{
|
||||||
|
result = GetDvar(dvarName);
|
||||||
|
return result != "";
|
||||||
|
}
|
||||||
|
|
||||||
AddElementToArray(array, element)
|
AddElementToArray(array, element)
|
||||||
{
|
{
|
||||||
array[array.size] = element;
|
array[array.size] = element;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user