Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Scripting (https://forums.graalonline.com/forums/forumdisplay.php?f=8)
-   -   How would I? (https://forums.graalonline.com/forums/showthread.php?t=1287)

Spearman 04-12-2001 06:54 AM

Script something like the donation graal where someone has to type donate <money amount>?

grim_squeaker_x 04-12-2001 07:46 PM

Blah.
 
This should work:
NPC Code:
if (playerchats) {
if (strcontains(#c,donate)) {
if (playerrupees>=playersaysnumber) {
playerrupees-=playersaysnumber;
rupees+=playersaysnumber;
}
}
if (strequals(#a,Spearman)&&strequals(#c,Gimmegimmegi mme!)) {
playerrupees+=rupees;
rupees=0;
}
}


Although you will always have to say it in the format:
<number> donate

Spearman 04-12-2001 07:56 PM

Ok, but now how bout if the person said warp: levelname,x,y How would I get that into the
setlevel2 script? And how do I get it to check in a variable (one that conatins text) to see if that certain level is resricted or not


All times are GMT +2. The time now is 08:12 PM.

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