Quote:
Originally Posted by DustyPorViva
However, I have been told using sleep is bad before, so this may get some resistance.
|
Could use waitfor instead, that function is pretty cool i.e:
PHP Code:
function onWeaponFired() {
while (keydown(4) && !this.jammed) {
FireGun();
waitfor(this, "Jammed", this.firerate);
}
}
function onJammed() {
this.jammed = true;
player.chat = "$#!&ing gun jammed.";
}
and have some sort of script behind the scenes throw out random jammed events to guns.