Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Scripting (https://forums.graalonline.com/forums/forumdisplay.php?f=8)
-   -   Commands (https://forums.graalonline.com/forums/showthread.php?t=53445)

Orbit45244 06-28-2004 07:05 PM

Commands
 
How do you make it so that when a specific person says something, somthing in the level happens?

Polo 06-28-2004 07:07 PM

NPC Code:
if (playerchats && strequals(#a,Account name of specific person) && strequals(#c,when they say this)) {
do this stuff;
}



I guess thats understandable... and I presume by specific person yo meant a specific account.

osrs 06-28-2004 07:09 PM

Read commands.rtf to see the available commands.

Polo 06-28-2004 07:11 PM

Im mine you should 'probably' split the 2 strequals into a seperat nested if statement, but unless your doing multiple chat based stuff its not going to make a difference, just thought i'd mention it to please the pedants amongst us.

Crono 06-28-2004 07:20 PM

Err I would prefer you didnt use &&.

1) It goes against the scripting standards or whatever kai posted for posting scripts on the board

2) It's ugly and debugging it is a pain

Polo 06-28-2004 07:24 PM

Yes, but's Kai's standards arn't necessarily the 'DO THIS OR DIE' correct method. There are things in it which, as a coder, I strongly disagree with. Im not saying that Kai's standards are wrong, I'm just saying that trying to impose restrictions on how people write scripts is stupid, as every seasoned scripter has thier own individual, yet still tidy format.

Trevor 06-28-2004 08:06 PM

Quote:

Originally Posted by Gerami
Err I would prefer you didnt use &&.

1) It goes against the scripting standards or whatever kai posted for posting scripts on the board

2) It's ugly and debugging it is a pain

You're crazy.

Dach 06-28-2004 08:36 PM

doesn't matter if that is all that is going on in the script, otherwise nesting unlike checks for readability is rather pointless

Orbit45244 06-29-2004 04:48 PM

About toweapons: I use toweapons to give the player the item bow. The item is just something other than the weapon bow. I need help. x_x

Damix2 06-29-2004 05:17 PM

Quote:

Originally Posted by Orbit45244
About toweapons: I use toweapons to give the player the item bow. The item is just something other than the weapon bow. I need help. x_x

1. Don't use toweapons

2.What are you asking? You want to give someone a bow that is not a bow?

Xecutor 06-29-2004 06:44 PM

Quote:

Originally Posted by Orbit45244
About toweapons: I use toweapons to give the player the item bow. The item is just something other than the weapon bow. I need help. x_x

First question, are you doing this offline or online?
Second, what is name of the weapon?

Orbit45244 06-29-2004 09:49 PM

Quote:

Originally Posted by Xecutor
First question, are you doing this offline or online?
Second, what is name of the weapon?


Never Mind.

Andy0687 06-29-2004 10:12 PM

....
Quote:

Originally Posted by Gerami
Err I would prefer you didnt use &&.

....


LOL

Nappa 06-29-2004 11:58 PM

These new forums are REALLY PISSING ME OFF. I've already tried to do ~12 replies today, all which did not go through. I swear to god this is ****ing making me mad. anyway I'll just retype what I said before.

Quote:

Originally Posted by Andy0687
LOL


What's so hillarious about that ?

Trevor 06-30-2004 01:01 AM

You did read what he quoted, right?


All times are GMT +2. The time now is 05:46 PM.

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