Graal Forums  

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

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 10-22-2001, 06:03 AM
nyghtGT nyghtGT is offline
Banned
nyghtGT's Avatar
Join Date: Jun 2001
Posts: 3,993
nyghtGT is on a distinguished road
Send a message via AIM to nyghtGT
::need help::

How can i get this to show the players # of darts ?
NPC Code:

// NPC made by Nyght *Asst* (LAT Admin)
hide;
if (playerenters && !hasstats) {
toweapons -stats;
set hasstats;
}
if (created) {
showstats 1;
showstats 2;
showstats 4;
showstats 8;
showstats 16;
showstats 32;
showstats 64;
showstats 128;
showstats 256;
showstats 512;
showstats 1024;
showimg 521,norin_stats.gif,440,5;
changeimgvis 521,4;
changeimgpart 521,0,0,193,94;
}
// Setting Max Quantities
if (!maxarrows=50 || !maxarrows=99) {
setstring maxarrows,25;
}
if (strcontains(25,#s(maxarrows))) {
showimg 523,@verdana@<Players Dart Count>/25,486,65;
changeimgvis 523,4;
changeimgzoom 523,0.85;
changeimgcolors 523,0,0,0,1;
}

// Arrows
if (playerdarts>=26 && strcontains(25,#s(maxarrows))) {
playerdarts = 25;
}


Any help would be awesome !
Reply With Quote
  #2  
Old 10-22-2001, 06:14 AM
TDO2000 TDO2000 is offline
Registered User
TDO2000's Avatar
Join Date: Jul 2001
Location: Germany
Posts: 655
TDO2000 is on a distinguished road
showimg 523,@verdana@#v(playerdarts/25),486,65;


or what do u mean?
__________________
No Webhost at the moment
Reply With Quote
  #3  
Old 10-22-2001, 06:24 AM
KJS KJS is offline
The one, The only -
KJS's Avatar
Join Date: Apr 2001
Location: USA, Minnesota
Posts: 1,012
KJS is on a distinguished road
Send a message via AIM to KJS
Re: ::need help::

Quote:
Originally posted by nyghtGT
How can i get this to show the players # of darts ?
NPC Code:

// NPC made by Nyght *Asst* (LAT Admin)
hide;
if (playerenters && !hasstats) {
toweapons -stats;
set hasstats;
}
if (created) {
showstats 1;
showstats 2;
showstats 4;
showstats 8;
showstats 16;
showstats 32;
showstats 64;
showstats 128;
showstats 256;
showstats 512;
showstats 1024;
showimg 521,norin_stats.gif,440,5;
changeimgvis 521,4;
changeimgpart 521,0,0,193,94;
}
// Setting Max Quantities
if (!maxarrows=50 || !maxarrows=99) {
setstring maxarrows,25;
}
if (strcontains(25,#s(maxarrows))) {
showimg 523,@verdana@<Players Dart Count>/25,486,65;
changeimgvis 523,4;
changeimgzoom 523,0.85;
changeimgcolors 523,0,0,0,1;
}

// Arrows
if (playerdarts>=26 && strcontains(25,#s(maxarrows))) {
playerdarts = 25;
}


Any help would be awesome !
just going though it quickly I fixed a few bugs...

NPC Code:

if (playerenters && !isweapon) {
toweapons -stats;
hide;
}
if (created && isweapond) {
showstats 1+2+4+8+16+32+64+128+256+512+1024;
showimg 521,norin_stats.gif,440,5;
changeimgvis 521,4;
changeimgpart 521,0,0,193,94;
timeout=0.1;
}
if(timeout){
// Setting Max Quantities
if (!maxarrows==50 || !maxarrows==99)
setstring maxarrows,25;
if (strcontains(25,#s(maxarrows))) {
showimg 523,@verdana@<Players Dart Count>/25,486,65;
changeimgvis 523,4;
changeimgzoom 523,0.85;
changeimgcolors 523,0,0,0,1;
}
// Arrows
if (playerdarts>=26 && strcontains(25,#s(maxarrows)))
playerdarts = 25;
timeout=0.1;
}

__________________
Thanks,
-KJL
Reply With Quote
  #4  
Old 10-22-2001, 06:33 AM
ownerofbabylon ownerofbabylon is offline
Lord Helmut
ownerofbabylon's Avatar
Join Date: Jun 2001
Location: Gainesville FL
Posts: 1,763
ownerofbabylon is on a distinguished road
Send a message via ICQ to ownerofbabylon Send a message via AIM to ownerofbabylon
on showimg is there a reason its 521? why not just do like 5?
__________________


Warrior of Light

WWW.BABYLONSERVER.COM
Reply With Quote
  #5  
Old 10-22-2001, 06:41 AM
nyghtGT nyghtGT is offline
Banned
nyghtGT's Avatar
Join Date: Jun 2001
Posts: 3,993
nyghtGT is on a distinguished road
Send a message via AIM to nyghtGT
Quote:
Originally posted by ownerofbabylon
on showimg is there a reason its 521? why not just do like 5?
yeah ... 500 shows it locally for the player and if a playerenters a new level it is still there ...
Reply With Quote
  #6  
Old 10-23-2001, 03:35 AM
btedji btedji is offline
bryan986
btedji's Avatar
Join Date: Apr 2001
Location: Force 10
Posts: 1,153
btedji is on a distinguished road
Send a message via ICQ to btedji Send a message via AIM to btedji Send a message via Yahoo to btedji
you need to use #s and strtofloat when calling strings
Reply With Quote
Reply


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 11:04 PM.


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