
09-03-2001, 04:14 PM
|
|
Script Monkey
|
 |
Join Date: May 2001
Posts: 18,222
|
|
Quote:
Originally posted by Tyhm
That would make sense, I suppose, except that = denotes an integer value, and I'm fairly certain the code
for(this.i=-;this.i<weaponscount;this.i++){
if(strequals(#w(this.i),Nukeshot)) selectedweapon=this.i;
}
would fail horribly.
I might have to try setplayerprop #w,Nukeshot; though. ^_^
Amazing....while that didn't work, this did!
if(hasweapon(Fishing Rod)){
while(!strequals(#w,Fishing Rod)&&selectedweapon>0) selectedweapon--;
if(selectedweapon=0){
while(!strequals(#w,Fishing Rod)) selectedweapon++;
}
}
It's pretty much bulletproof too, or so it seems...Yup! Works if the weapon it seeks is above or below the current selected one.
|
I dunno why the original one wouldn't work. What do you mean by "except that = denotes an integer value"? |
|
|
|