I didn't know how to get this to work with a for or while loop, as when playerdir == 3 the action is different, how do i make it work with a for loop?
PHP Code:
//#CLIENTSIDE
function onWeaponFired()
{
if(this.lol == 0)
{
this.lol = 1;
settimer(.5);
}
else if (this.lol == 1)
{
settimer(0);
this.lol = 0;
}
}
function onTimeOut()
{
if (player.dir <3)
{
player.dir++;
settimer(0.05);
}
else
{
player.dir -= 3;
settimer(0.05);
}
}
edit: i now see i forgot some spaces here and there, please don't mention those.