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 07-07-2001, 09:03 PM
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
Scripts and strings

How do you store a string?? So like say I want to save how many times they chopped a piece of wood. I use the random script and if the number is greater than lets say 50 then they chopped the wood right and it adds one log to a string. Then if they go into a shop and say sell wood, it looks at the string and buys that many logs from them? Does anyone have any ideas?? I will pay anything for this (within reason)
__________________


Warrior of Light

WWW.BABYLONSERVER.COM
Reply With Quote
  #2  
Old 07-08-2001, 12:33 AM
Brady2 Brady2 is offline
Registered User
Brady2's Avatar
Join Date: Mar 2001
Location: Phoenix, AZ and Wichita Falls, TX
Posts: 924
Brady2 is on a distinguished road
Re: Scripts and strings

-Posted by Jadis

Quote:
Originally posted by ownerofbabylon
How do you store a string?? So like say I want to save how many times they chopped a piece of wood. I use the random script and if the number is greater than lets say 50 then they chopped the wood right and it adds one log to a string. Then if they go into a shop and say sell wood, it looks at the string and buys that many logs from them? Does anyone have any ideas?? I will pay anything for this (within reason)
Strings are automatically stored in the player's account..
Reply With Quote
  #3  
Old 07-08-2001, 05:01 AM
Er1c Er1c is offline
Registered User
Er1c's Avatar
Join Date: Mar 2001
Location: Chicago, IL
Posts: 791
Er1c is on a distinguished road
NPC Code:
setstring <stringname>,<vaule of the string (number or ASCII crap)>;

is how you set a string and
NPC Code:
#s(<stringname>)

is how you call the string for its true value and
NPC Code:
strtofloat(#s(<stringname>))

is how you use a strings numerical value (probably what you would be using it for).
__________________
Eric Kraft
Reply With Quote
  #4  
Old 07-08-2001, 11:23 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
hmmm,

could u do a basic one that has a random system between Iron, Gold, and platinum(and of course non found)...
If you could do this so it stores the amount of that type of mineral so that i could sell it buy saying sell then the item name...
I will do almost anything to learn this so i can use it for other types of situations also..
Thanks -Lord Helmut (Owner of Babylon)
-Friends with NooseKnot(my idol) and Head LAT/Admin

__________________


Warrior of Light

WWW.BABYLONSERVER.COM
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 07:19 PM.


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