Quote:
Originally Posted by Fysez
PHP Code:
//#CLIENTSIDE
function onWeaponFired() {
if (this.on == false) {
this.on == true;
setani("Gani", null);
replaceani("idle", "Gani");
} else if (this.on == true) {
this.on == false;
setani("idle", null);
replaceani("idle", "idle");
}
}
Cujo's method did not work at all, But rather made it so I could not equip it at all. CBK, your's did the same. So I tried this and it seemed to work for Equipping, But then again, Not un-equipping. Not only am I back to where i started, But you all just confused me x.x lol
|
Use the == only in the if statement. While setting the value just use = . So this should work
PHP Code:
//#CLIENTSIDE
function onWeaponFired() {
if (this.wearing == false) {
this.wearing = true;
replaceani("idle", "gani");
replaceani("walk", "gani2");
}
else if (this.wearing == true) {
this.wearing = false;
replaceani("gani", "idle");
replaceani("gani2", "walk");
}
}