mob
NPC
OldLady
icon = 'Oldlady.dmi'
name = "Old Woman"
verb
talk()
set src in oview(1)
usr << "Old Woman: Hello there young man. <br>Old Woman: Would you be interested in doing a little job for me?"
usr.icon_state = input("There will be a small reward.") in list ("Yes","No")
if("Yes")
usr << "Old Woman: Good, all I need you to do is pick 15 pieces of corn and bring them to me. <br>And make sure you wash them off. I don't want to be getting sick."
if("No")
usr << "Old Woman: Sorry to here that."
<dm/>
ERRORS:
Old Lady.dm:10:error:list:undefined proc
Old Lady.dm:11:error::invalid expression
ID:261415
Feb 28 2002, 8:15 pm
|
|
Im not sure why im getting these errors please help :P
|
In response to Creek
|
|
Ok I kinda under stand but if I was going to pick the var as choice where and what would i describe it as?
|
In response to Little Sally
|
|
input() doesn't automatically put you into some kind of pseudo-switch() statement environment. You must use if() or switch() after the input.
Alathon |
In response to Alathon
|
|
Try this
mob/npc/Oldlady icon='oldlady.dmi' verb Talk() set src in oview(1) usr<<"Pick some corn" switch(input("DO you wish to do a quest for me?") in list ("Yes","No")) if("Yes") usr<<"Pick 15 pieces of corn that are clean." if("No") usr<<"Sorry to hear that." |
Little Sally wrote: