ID:150582
 
/turf/buyzone/
icon = 'buy.dmi'
if(icon == 'blue.dmi')
verb/pumps()

rest of my code

I get these errors,
buysys.dm:3:error:icon:duplicate definition
buysys.dm:3:error:'blue.dmi':duplicate definition
buysys.dm:3:error:== :instruction not allowed here

What I am trying to do here is allow a new tab to pop-up when u enter the area for buying weapons when you are the icon 'blue.dmi'.

Thanx for any help :)
turf/buyzone
icon = 'buy.dmi'
verb/pumps()
if(icon == 'blue.dmi')
instruction here


you cannot have a floating if statement
In response to FIREking
FIREking wrote:
> turf/buyzone
> icon = 'buy.dmi'
> verb/pumps()
> if(icon == 'blue.dmi')
> instruction here
>
>

you cannot have a floating if statement

yuck, I have alot of code under that, with around 50 verbs.. So I have to do this to each one :(
In response to Oblivian
b_flag
icon = 'flags.dmi'
icon_state = "bflag"
verb
if(icon == 'ctfred.dmi')
get()
set category = "Commands"
set src in oview(0)
usr << "You get [src]"
Move(usr)

drop()
set category = "Commands"
usr << "You drop [src]"
Move(usr.loc)

This is really annoying, and I am probably just overlooking something but I get this error:
flags.dm:6:error:if :missing ()'s or invalid return type
flags.dm:7:error::missing ()'s or invalid return type
flags.dm:22:error:if :missing ()'s or invalid return type
flags.dm:23:error::missing ()'s or invalid return type

do I need to add in a ..() or something somewhere?
In response to Oblivian
Oblivian wrote:
b_flag
icon = 'flags.dmi'
icon_state = "bflag"
verb
if(icon == 'ctfred.dmi')
get()
set category = "Commands"
set src in oview(0)
usr << "You get [src]"
Move(usr)

drop()
set category = "Commands"
usr << "You drop [src]"
Move(usr.loc)

This is really annoying, and I am probably just overlooking something but I get this error:
flags.dm:6:error:if :missing ()'s or invalid return type
flags.dm:7:error::missing ()'s or invalid return type
flags.dm:22:error:if :missing ()'s or invalid return type
flags.dm:23:error::missing ()'s or invalid return type

do I need to add in a ..() or something somewhere?

As I said I am overlooking something, duh..

fixed it :)

In response to Oblivian
Oblivian wrote:
Oblivian wrote:
b_flag
icon = 'flags.dmi'
icon_state = "bflag"
verb
if(icon == 'ctfred.dmi')
get()
set category = "Commands"
set src in oview(0)
usr << "You get [src]"
Move(usr)

drop()
set category = "Commands"
usr << "You drop [src]"
Move(usr.loc)

This is really annoying, and I am probably just overlooking something but I get this error:
flags.dm:6:error:if :missing ()'s or invalid return type
flags.dm:7:error::missing ()'s or invalid return type
flags.dm:22:error:if :missing ()'s or invalid return type
flags.dm:23:error::missing ()'s or invalid return type

do I need to add in a ..() or something somewhere?

As I said I am overlooking something, duh..

fixed it :)


once again, you cant have floating if statments

if statments can only be under a proc or verb