ID:140376
 
Code:
obj
Sakura
name = "Sakura Support"
icon = 'Sakura Support.dmi'
icon_state = ""
verb
Use(mob/M in oview(1))
src.loc=locate(usr.x-1,usr.y-0,usr.z)
M.Frozen=1
usr.Frozen=1
flick("Stance",src)
M.hp -= 100
M.loc=locate(M.x+1,usr.y-0,usr.z)
M.loc=locate(usr.x+2,usr.y,usr.z)
sleep(5)
M.loc=locate(usr.x+3,usr.y,usr.z)
sleep(5)
M.loc=locate(usr.x+4,usr.y,usr.z)
sleep(5)
M.loc=locate(usr.x+5,usr.y-0,usr.z)
sleep(5)
M.loc=locate(usr.x+6,usr.y-0,usr.z)
sleep(5)
M.loc=locate(usr.x+7)
sleep(5)
M.Frozen=0
usr.Frozen=0
M.death_check(src)
del src</b>


Problem description:i know theres somehow to make this more less messy and main problem is i want it to make them move the direction they get pucnhed not just east

plzzz help
Have you looked into step() or step_to()?
Legitz wrote:
Code:
obj
> Sakura
> name = "Sakura Support"
> icon = 'Sakura Support.dmi'
> icon_state = ""
> verb
> Use(mob/M in oview(1))
> src.loc=locate(usr.x-1,usr.y-0,usr.z)
> M.Frozen=1
> usr.Frozen=1
> flick("Stance",src)
> M.hp -= 100
> M.loc=locate(M.x+1,usr.y-0,usr.z)
> M.loc=locate(usr.x+2,usr.y,usr.z)
> sleep(5)
> M.loc=locate(usr.x+3,usr.y,usr.z)
> sleep(5)
> M.loc=locate(usr.x+4,usr.y,usr.z)
> sleep(5)
> M.loc=locate(usr.x+5,usr.y-0,usr.z)
> sleep(5)
> M.loc=locate(usr.x+6,usr.y-0,usr.z)
> sleep(5)
> M.loc=locate(usr.x+7)
> sleep(5)
> M.Frozen=0
> usr.Frozen=0
> M.death_check(src)
> del src
>
>

Problem description:i know theres somehow to make this more less messy and main problem is i want it to make them move the direction they get pucnhed not just east


Procs you may want to use:
step(), turn(), get_dir()
(The idea isn't to use them all, but they all can be used to achieve what you want)

obj //I don't get how Sakura is a obj, but w/e
> Sakura
> name = "Sakura Support"
> icon = 'Sakura Support.dmi'
> icon_state = ""
> verb
> Use(mob/M in oview(1))
> //wtf pwn him with all your codes
> //then its time to knock him back
> step(M,src.dir) //Make him step away from you (step_away may make him step diagonally in case there is something blocking the path, which is not really something you want since people don't bounce when knocked back)
> M.dir=get_dir(M,src) //Make him face you(for a more smooth effect)