getCPULoad()

int main(){
if(getCPULoad()>50){
cancelAttack();
message(getSourceIP(),"Attack was canceled.");
}
}

It will compile but when ran it does not work. It is in attack continue. Also, this is not the original compiled script. I have already compiled the script and just saved this one as the same name as the compiled script. Can I do that?

you'll have to recompile it.

you'll have to recompile it.

getCPULoad() will get the CPU

getCPULoad() will get the CPU load (not the % CPU load)

to get the % CPU load, make something like
int CUP = getCPULoad() / getMaximumCPULoad * 100;