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 03-29-2003, 02:40 PM
mhermher mhermher is offline
galase galase!
mhermher's Avatar
Join Date: Jun 2001
Location: Sweden, Stockholm.
Posts: 2,012
mhermher is on a distinguished road
Send a message via ICQ to mhermher Send a message via AIM to mhermher Send a message via Yahoo to mhermher
How to

Hi.. i made a admin message script and i need some help..
This is not the whole script so don't delete thread..

In the npc i have this:
NPC Code:

if (playerenters) {
toweapons -adminmsg;
}
if (!strequals(#s(client.sm),)&&client.smz==0.6) {
timeout=3;
}
if (timeout&&client.smz>0) {
client.smz=client.smz-0.1;
timeout=0.1;
}
if (client.smz==0) {
setstring client.sm,;
client.smz=0.6;
}



And then in another (test npc):
NPC Code:

if (playerchats&&startswith(/msg,#c)) {
tokenize #c;
setstring client.sm,#t(1);
client.smz=0.6;
}



The test NPC's job is to change the string.. and when it's changed, 3 seconds shall pass and the text should be smaller untill it dissapears.. but now it don't even change a bit...

Help?
__________________
Donate money for my trip to Germany

Adiarde Manager
Reply With Quote
  #2  
Old 03-29-2003, 04:16 PM
mhermher mhermher is offline
galase galase!
mhermher's Avatar
Join Date: Jun 2001
Location: Sweden, Stockholm.
Posts: 2,012
mhermher is on a distinguished road
Send a message via ICQ to mhermher Send a message via AIM to mhermher Send a message via Yahoo to mhermher
Quote:
Originally posted by Kaimetsu
http://forums.graal2001.com/forums/s...threadid=43866
Yes, but it don't help my code.
__________________
Donate money for my trip to Germany

Adiarde Manager
Reply With Quote
  #3  
Old 03-29-2003, 04:30 PM
mhermher mhermher is offline
galase galase!
mhermher's Avatar
Join Date: Jun 2001
Location: Sweden, Stockholm.
Posts: 2,012
mhermher is on a distinguished road
Send a message via ICQ to mhermher Send a message via AIM to mhermher Send a message via Yahoo to mhermher
Quote:
Originally posted by Kaimetsu


I was merely stating that I'm not going to look at your code until it conforms with the KSI-GS standard.
KSI-GS?
__________________
Donate money for my trip to Germany

Adiarde Manager
Reply With Quote
  #4  
Old 03-29-2003, 05:15 PM
mhermher mhermher is offline
galase galase!
mhermher's Avatar
Join Date: Jun 2001
Location: Sweden, Stockholm.
Posts: 2,012
mhermher is on a distinguished road
Send a message via ICQ to mhermher Send a message via AIM to mhermher Send a message via Yahoo to mhermher
Quote:
Originally posted by Kaimetsu
Kaimetsu Standards Institute - Graal Script

^_^
LOL!

Well cmon Kai.. you know i'm not as good as you.. please help :P
__________________
Donate money for my trip to Germany

Adiarde Manager
Reply With Quote
  #5  
Old 03-29-2003, 07:50 PM
HoudiniMan HoudiniMan is offline
Playerworld Administrator
HoudiniMan's Avatar
Join Date: Dec 2001
Location: Calfiornia - USA
Posts: 3,512
HoudiniMan will become famous soon enough
Quote:
Originally posted by mhermher


LOL!

Well cmon Kai.. you know i'm not as good as you.. please help :P
Just hit style =\
__________________
-HoudiniMan (Chief Playerworld Administrator)
Compulsive Support Center Checker - 5 Years and Change
Graal Support Center

Reply With Quote
  #6  
Old 03-29-2003, 11:04 PM
mhermher mhermher is offline
galase galase!
mhermher's Avatar
Join Date: Jun 2001
Location: Sweden, Stockholm.
Posts: 2,012
mhermher is on a distinguished road
Send a message via ICQ to mhermher Send a message via AIM to mhermher Send a message via Yahoo to mhermher
Quote:
Originally posted by Kaimetsu


No, it's more than that. Tyrial, you don't need to be a scripting master just to follow those three rules.
Yeah, but i never understood that ya ment with KSI-GS.
But anyhow, it's fixed now.. close this thread.
__________________
Donate money for my trip to Germany

Adiarde Manager
Reply With Quote
  #7  
Old 03-30-2003, 05:35 AM
HoudiniMan HoudiniMan is offline
Playerworld Administrator
HoudiniMan's Avatar
Join Date: Dec 2001
Location: Calfiornia - USA
Posts: 3,512
HoudiniMan will become famous soon enough
Quote:
Originally posted by Kaimetsu


No, it's more than that. Tyrial, you don't need to be a scripting master just to follow those three rules.
If you mean not nesting events and such, then yeah... but it's still not rocket science
__________________
-HoudiniMan (Chief Playerworld Administrator)
Compulsive Support Center Checker - 5 Years and Change
Graal Support Center

Reply With Quote
  #8  
Old 04-21-2003, 07:42 AM
Codeboy Codeboy is offline
Registered User
Join Date: Jan 2003
Location: USA
Posts: 7
Codeboy is on a distinguished road
o.O Why even bother with making script conform to an opinionated list of rules made by a person who has their own indivitual opinions, whos don't really conform and agree to others?

Translation:

So what if people use this 'Kam-Code' formatt, people can script however they want to script. Look at Shadow Knight, for example, he never, ever used spaces to designate a command.
Reply With Quote
  #9  
Old 04-21-2003, 07:53 AM
Shiftk03- Shiftk03- is offline
I am the trap
Shiftk03-'s Avatar
Join Date: Nov 2001
Location: Dirty South
Posts: 1,688
Shiftk03- will become famous soon enough
Quote:
Originally posted by Codeboy
o.O Why even bother with making script conform to an opinionated list of rules made by a person who has their own indivitual opinions, whos don't really conform and agree to others?

Translation:

So what if people use this 'Kam-Code' formatt, people can script however they want to script. Look at Shadow Knight, for example, he never, ever used spaces to designate a command.
Its common courtesy for another scripter who will be reading the script... Now, if you like having sloppy scripts, thats your progative.
__________________
Reply With Quote
  #10  
Old 04-21-2003, 09:12 AM
adam adam is offline
http://wiki.graal.us/
adam's Avatar
Join Date: Nov 2001
Posts: 2,247
adam has a spectacular aura aboutadam has a spectacular aura about
Send a message via AIM to adam
Quote:
Originally posted by Codeboy
o.O Why even bother with making script conform to an opinionated list of rules made by a person who has their own indivitual opinions, whos don't really conform and agree to others?

Translation:

So what if people use this 'Kam-Code' formatt, people can script however they want to script. Look at Shadow Knight, for example, he never, ever used spaces to designate a command.
Yep, you may script how you wish. But I will backup Kai with his apparently Standardized Format. It's very nice.
__________________
Rogue Shadow (TCN)(NAT)(Global Development Team)

For development help, contact the patrons of the #graaldt irc channel below, I am usually there.
Click Here to Join IRC Chat Now! -- irc.freenode.net Channel: #graaldt
Quote:
<Dustyshouri> no, RogueShadow is always talking about scripts lol
<Dustyshouri> in fact, he pretty much brought Graal back as a topic single-handedly
Reply With Quote
  #11  
Old 04-22-2003, 07:53 AM
PrinceDark PrinceDark is offline
Criminal X
PrinceDark's Avatar
Join Date: Feb 2003
Location: Miami, Florida
Posts: 662
PrinceDark will become famous soon enough
Quote:
Originally posted by Codeboy
o.O Why even bother with making script conform to an opinionated list of rules made by a person who has their own indivitual opinions, whos don't really conform and agree to others?

Translation:

So what if people use this 'Kam-Code' formatt, people can script however they want to script. Look at Shadow Knight, for example, he never, ever used spaces to designate a command.
It makes things a lot easier to read and understand.

Welcome to the forums. I haven't seen you in a long time.
__________________
- Criminal X: certified nut case
Reply With Quote
  #12  
Old 04-22-2003, 08:17 AM
Knuckles Knuckles is offline
Registered User
Join Date: Sep 2002
Location: New York
Posts: 580
Knuckles is on a distinguished road
Send a message via AIM to Knuckles
He's just showing the correct syntax.
And yea, it's alot easier to understand...

FOR EXAMPLE.
IF someone decided to put a 99 line code, on 1 line... It'd be annoying for the rest of the Graal Scripters to understand or read... I know i've had to debug some other peoples codes with very messy syntax, and since it wasn't how I did it, it was really hard for me.
__________________
Knuckles
"They say 60% of the time, it works everytime!"
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:59 PM.


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