ID:267673
 
hi

how can i use whole words like 'north' for the mob to move north?

thanks
I am going to assume you mean that you want to use text instead of the regular bit-flags and/or numbers to represent directions.

Make yourself a variable to keep track of your text directions like so:

var/global/list/text_dir=list("north"=1,"south"=2,"east"=4," west"=8)

After that, if you want to move a movable object in a specific direction, just call the appropriate procedure with your text_dir variable as an argument.

Examples:

Move(get_step(src,text_dir("north")))//This will move you one step north.

walk(src,text_dir("east"))//This will make you continually walk to the east.

[edit]
I just woke up this morning thinking about this for some reason: I realised that I made a mistake here.

Fixed Examples:

Move(get_step(src,text_dir["north"]))//This will move you one step north.

walk(src,text_dir["east"])//This will make you continually walk to the east.