stepback(K)
fast=1
loop
if(!src||paralysed||imitated||npc||imitation)return
if(K>0)
K--
var/image=new/obj/kimage(loc)
image:dir=dir
image:icon=icon
image:overlays=overlays
image:invisibility=invisibility
moving=0
var/P=dir
if(dir==NORTH)step(src,SOUTH)
if(dir==SOUTH)step(src,NORTH)
if(dir==EAST)step(src,WEST)
if(dir==WEST)step(src,EAST)
dir=P
runstep=0
spawn(1)goto loop
fast=0
stepup(K)
fast=1
loop
if(!src||paralysed||imitated||npc||imitation)return
if(K>0)
K--
if(!istype(src,/mob/Animal))
var/image=new/obj/kimage(loc)
image:dir=dir
image:icon=icon
image:overlays=overlays
moving=0
step(src,dir)
spawn(1)goto loop
fast=0
Problem description:
This code is from my old project and was working properly last year but recently i've been restarting my project and it seems that it doesn't work anymore because in-game when one of those proc is called the player doesn't even move. So I would like to know if DM changed in some way that these code need to be fix and how to fix it? It may be an easy threat but im still a beginner coder so if you could bring explanation to Why/How/What/etc when fixing it it would really help me!
Thank you guys,
Louis53