Thread: carrying
View Single Post
  #3  
Old 03-02-2011, 01:17 PM
callimuc callimuc is offline
ジ
callimuc's Avatar
Join Date: Nov 2010
Location: Germany
Posts: 1,015
callimuc is a splendid one to beholdcallimuc is a splendid one to beholdcallimuc is a splendid one to beholdcallimuc is a splendid one to beholdcallimuc is a splendid one to behold
Quote:
Originally Posted by oo_jazz_oo View Post
I believe the player attribute for the carry image is player.attr[3].

So, if you did something like:
PHP Code:
//#CLIENTSIDE
function onCreated() {
  
player.attr[3] = "bomb.png";
  
replaceani("idle", "carrystill");
  
replaceani("walk", "carry");
} 
Your player would appear to be carrying a bomb. :P
Well you won´t get out of it until you reconnect and the attribute will still be the bomb.png i guess
I think you should do something like:
PHP Code:
//#CLIENTSIDE
function onWeaponFired(){
  if(
this.on = false){
    
this.on = true;
    
player.attr[3] = "bomb.png";
    
replaceani("idle", "carrystill");
    
replaceani("walk", "carry");
  }else{
    
this.on = false;
    
player.attr[3] = "";
    
replaceani("idle","idle");
    
replaceani("walk","walk");
  }
} 
Just got Trial again so I can´t test it
Reply With Quote