ID:155091
 
hi im trying to make a game sort of like AOE, im having problems with movement, i want the usr to be able to only click on the mob they want to move and then click on the turf they want to move it to. this is my current code:
turf
grass
icon = 'grass.dmi'
Click()
src.move(/mob/mob1)
proc
move(mob/M)
if(M.selected == "yes")
walk_to(M,src,0,5)
mob
var
selected in list("yes","no")
Click()
if(selected == "no")
selected = "yes"
else
selected = "no"
mob1
icon = '1.dmi'
selected = "no"
Click()
if(selected == "no")
src.selected = "yes"
icon = '1s.dmi'
else
src.selected = "no"
icon = '1.dmi'
this code checks out when I compile but when I try to use it in the game it gives me a bunch of error messages, Please help!
Translation:
OMG THIS CODE DOESNT COMPILE!!!1!1!11!! HALP
1. This belongs in code problems.
2. Use DM and /DM tags for posting long code snippets.
3. Post your errors as well as your code, we're not mind readers.
4. I suggest you read the guide and do some tutorials. There are several obvious mistakes here that could be fixed by having a basic understanding of DM.
5. Don't post the exact same topic twice in 2 hours.