View Single Post
  #5  
Old 09-12-2006, 06:29 PM
Luigi203 Luigi203 is offline
Hamma Time
Luigi203's Avatar
Join Date: Mar 2003
Location: North East PA
Posts: 285
Luigi203 is on a distinguished road
Send a message via AIM to Luigi203
Quote:
Originally Posted by projectigi
hrm i think selectedweapon is the id of the current weapon
you could loop through the player.weapons array and use weapon.name to get the name
like
NPC Code:

function onCreated(){
for(i=0;i<=player.weapons.size();i++){
if(player.weapons[i]=="weaponname")
selectedweapon=i;
}
}


Okay, you just did the same exact thing I did. Selectedweapon is the current weapon, its writable.
__________________


CAUTION
Reply With Quote