is it possible to have bools in the function brackets?
public function(id, bool:etc )
{
}
and then you can just do this in other functions..
function(id, true)
or
function(id, false)
if so how to i make up the function with the bool ?
EDIT:
ok figured one way out
PHP Code:
public plugin_init() {
register_plugin(PLUGIN, VERSION, AUTHOR)
register_clcmd("say /true", "cmdTest", 0);
register_clcmd("say /false", "cmdTest1", 0);
}
public cmdTest(id)
{
Test(id, true)
}
public cmdTest1(id)
{
Test(id, false)
}
public Test(id, bool:hmm )
{
switch(hmm)
{
case true: client_print(id, print_center, "I AM TRUE");
case false: client_print(id, print_center, "I AM FALSE");
}
}
is there any other more effective ways ?
__________________