This one's better styled (how it should be);
PHP Code:
//#CLIENTSIDE
function onWeaponFired() {
if (this.on == false) {
this.on = true;
client.gani_idle = "light-old_rifle-idle";
onTimeout();
}
else{
this.on = false;
showsword(1);
player.chat = "Gun Deactivated!";
client.gani_idle = "idle";
client.gani_walk = "walk";
}
}
function onTimeout() {
if (this.on == true) {
hidesword(1);
player.chat = "Gun Activated!";
client.gani_idle = "light-old_rifle-idle";
client.gani_walk = "light-old_rifle-walk";
}
}
function onKeyPressed(code,key) {
if (key == "s") {
hidesword(1);
setani("light-old_rifle-fire","");
freezeplayer(0.1);
setshootparams("Rifle",player.account);
shoot(player.x,player.y,0,player.dir,0,0,"utopia_bullet","0.5");
}
}
function onPlayerChats(){
if (player.chat == "Reload"){
client.gani_idle = "light-old_rifle-reload";
sleep(0.25);
client.gani_idle = "light-old_rifle-idle";
}
}
It looks like stuff from 4 different scripts though, lol.. and I personally never heard of hidesword and showsword either xD Did you just think of some commands that sound cool?