ID:271654
 
obj
Interactive_Scenery
Shinigami_Gate_Guard
icon = 'Shinigami.dmi'
icon_state = "captain-blue"
density = 1
verb/Talk()
set src in oview(1)
switch(alert("Before i let you into soul society, you must defeat me.","Alrighty","I'm good","Cancel",))
if("Alrighty")
if(Shinigami)
set src in oview(1)
switch(alert("You are already a Shinigami, what are you doing out here?","I don't know",))
usr.loc = locate (60,65,2)
return
else
usr.Human = 0
set src in oview(1)
switch(alert("Do you think you have what it takes to become a Shinigami?","Yes","No","Cancel",))
if("Yes")
(alert("Lets see if you can defeat me.","Ok",))
usr.loc = locate (43,106,8)
if("No")
(alert("Get out of my sight"))
if("Cancel")
return




Whenever I try to include this code file, which seems pretty simple to me, I get around 48 errors saying that every else clause i have, doesn't have a statement after it. Please tell me what I'm doing wrong.
You missed a closing bracket on the second alert(). DM hates it when you miss out brackets and likes to freak out with lots of errors =P.
In response to Abhishake
I was actually about to edit it and say i fixed the bracket but now it's all indented wrong. I think it looks fine, but once again can someone help me. Also, how would i make it so that when you defeat the guard, you get automatically teleported back.
In response to Blagh Nabbit
You're not meant to indent return. You don't even need to use it if that's your entire code, by the way. return isn't meant to be added at the end of every block of code.
Here
obj
Interactive_Scenery
Shinigami_Gate_Guard
icon = 'Shinigami.dmi'
icon_state = "captain-blue"
density = 1
verb/Talk()
set src in oview(1)
switch(alert("Before I let you into soul society, you must defeat me.","Alrighty","I'm good","Cancel",))
if("Alrighty")
if(Shinigami)
set src in oview(1)
switch(alert("You are already a Shinigami, what are you doing out here?","I don't know",))
if("I don't know")
usr.loc = locate (60,65,2)
return
else
set src in oview(1)
usr.Human = 0
switch(alert("Do you think you have what it takes to become a Shinigami?","Yes","No","Cancel",))
if("Yes")
switch(alert("Lets see if you can defeat me.","Ok",))
if("Ok")
usr.loc = locate (43,106,8)
if("No")
alert("Get out of my sight")
if("Cancel")return