Railing climb animation and fixes

This commit is contained in:
quotefox
2022-04-28 01:57:53 +01:00
parent 7aced82a0e
commit 11b6f77142
2 changed files with 14 additions and 3 deletions
+4 -1
View File
@@ -151,15 +151,18 @@
usr.visible_message("<span class='warning'>[user] starts climbing onto \the [src]!</span>")
if(!do_after(user, 20))
if(!do_after(user, 15, src))
return
if(get_turf(user) == get_turf(src))
usr.dir = get_dir(usr.loc, get_step(src, src.dir))//turn and face railing
usr.forceMove(get_step(src, src.dir))
else
usr.dir = get_dir(usr.loc, loc)//turn and face railing
usr.forceMove(get_turf(src))
usr.visible_message("<span class='warning'>[user] climbed over \the [src]!</span>")
usr.do_twist(targetangle = 45, timer = 8)
/obj/structure/railing/handrail
name = "handrail"