PDA

View Full Version : Need help with this code


Krayz
06-29-2003, 02:26 PM
Ok, I can't get this code to work. What I have I done wrong. I have tried it both ways below.

EVENT_SAY {
if ($1-=~ "Hail") { say("Hello $name . welcome to the Kunark translocation area. Do you wish to journey to [kunark]?") }
if ($1-=~ "kunark") { say("Very well, watch") cast($userid,2709) }
}

EVENT_SAY {
if ($1-=~ "Hail") { say("Hello $name . welcome to the Kunark translocation area. Do you wish to journey to [kunark]?") }
if ($1-=~ "kunark") { say("Very well, watch out") castspell($userid,2709) }
}

Any suggestions?

IANumtin
06-29-2003, 02:52 PM
This should be in the quest area but anyways, you have:

cast($userid,2709)

Should be this:

castspell("$userid","2709")

Remember to put anything that's suppose to be an action by the npc in quotations. Hope this helps.

Krayz
06-29-2003, 03:29 PM
Sweet. Thanks a ton.

Krayz
06-30-2003, 06:21 PM
Someone might add this little fact to the FAQ's until I posted it here I never saw it anywhere on the boards that you needed the " " part.

Just FYI

IANumtin
06-30-2003, 10:33 PM
Oh, it's out there. Where do you think I got it :D