02.12.2015, 01:31
use bool type and when
bool antibug_state;
#define ANTIBUG_ON true
#define ANTIBUG_OFF false
cmd:toggleantibug
{
if(antibug_state==ANTIBUG_ON)
antibug_state=ANTIBUG_OFF;
else
antibug_state=ANTIBUG_ON;
}
cmd:antibugcmd
{
if(antibug_state==ANTIBUG_OFF) return 0; // return something or w/e or just do else and execute your code..
}
bool antibug_state;
#define ANTIBUG_ON true
#define ANTIBUG_OFF false
cmd:toggleantibug
{
if(antibug_state==ANTIBUG_ON)
antibug_state=ANTIBUG_OFF;
else
antibug_state=ANTIBUG_ON;
}
cmd:antibugcmd
{
if(antibug_state==ANTIBUG_OFF) return 0; // return something or w/e or just do else and execute your code..
}