Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Today's Posts

 
 
Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 03-31-2011, 06:06 PM
PhilSmith PhilSmith is offline
Workin' on It
PhilSmith's Avatar
Join Date: Mar 2011
Location: Chicago
Posts: 38
PhilSmith is on a distinguished road
Weapon Names Problem

I've been trying to make a custom inventory and while doing so I have come across a slight problem. I want to make the inventory hide the typical "-" and "*" weapons, however my check is not working. It seems as though the weapons that are named with these starting characters, are actually not (in the mind of my script).

PHP Code:
for(i=0;i<player.weapon.size();i++){
    if(!
player.weapon[i].name.starts("-")){
      new 
GuiBitmapButtonCtrl("PhilSmith_Weapon_"@i){
        
profile=PhilSmith_HUDButtons;
        
PhilSmith_Inventory.x+(i*40);
        
PhilSmith_Inventory.y+15;
        
normalbitmap temp.imgs[i];
        
mouseoverbitmap temp.imgs[i];
        
pressedbitmap temp.imgs[i];
        
width 32;
        
height=32;
        
text=player.weapon[i].name;
      }
    }
  } 
Thanks for taking the time to look this over to help me.
__________________
Nothing to say...
Reply With Quote
 


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 01:18 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.