mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-12 03:02:54 +00:00
[MIRROR] some istype to macros (#9802)
Co-authored-by: Kashargul <144968721+Kashargul@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
73486c399b
commit
ed79946ade
@@ -138,7 +138,7 @@
|
||||
if(isturf(T))
|
||||
A.Move(T) //bump things away when hit
|
||||
|
||||
if(istype(A, /mob/living))
|
||||
if(isliving(A))
|
||||
var/mob/living/M = A
|
||||
visible_message(span_danger("[src] knocks over [M]!"))
|
||||
M.apply_effects(2, 2) // Knock people down for a short moment
|
||||
@@ -152,7 +152,7 @@
|
||||
health -= round(M.mob_size / 4) // Less damage if they actually put the point in to emag it.
|
||||
var/turf/T2 = get_step(A, pick(throw_dirs))
|
||||
M.throw_at(T2, 1, 1, src)
|
||||
if(istype(load, /mob/living/carbon/human))
|
||||
if(ishuman(load))
|
||||
var/mob/living/D = load
|
||||
to_chat(D, span_danger("You hit [M]!"))
|
||||
add_attack_logs(D,M,"Ran over with [src.name]")
|
||||
@@ -209,7 +209,7 @@
|
||||
/obj/vehicle/train/trolley/trailer/proc/update_load()
|
||||
if(load)
|
||||
var/y_offset = load_offset_y
|
||||
if(istype(load, /mob/living))
|
||||
if(isliving(load))
|
||||
y_offset = mob_offset_y
|
||||
load.pixel_x = (initial(load.pixel_x) + 16 + load_offset_x + pixel_x) //Base location for the sprite, plus 16 to center it on the 'base' sprite of the trailer, plus the x shift of the trailer, then shift it by the same pixel_x as the trailer to track it.
|
||||
load.pixel_y = (initial(load.pixel_y) + y_offset + pixel_y) //Same as the above.
|
||||
@@ -251,7 +251,7 @@
|
||||
if(isturf(T))
|
||||
A.Move(T) //bump things away when hit
|
||||
|
||||
if(istype(A, /mob/living))
|
||||
if(isliving(A))
|
||||
var/mob/living/M = A
|
||||
visible_message(span_danger("[src] knocks over [M]!"))
|
||||
M.apply_effects(1, 1)
|
||||
@@ -263,7 +263,7 @@
|
||||
throw_dirs -= dir
|
||||
var/turf/T2 = get_step(A, pick(throw_dirs))
|
||||
M.throw_at(T2, 1, 1, src)
|
||||
if(istype(load, /mob/living/carbon/human))
|
||||
if(ishuman(load))
|
||||
var/mob/living/D = load
|
||||
to_chat(D, span_danger("You hit [M]!"))
|
||||
add_attack_logs(D,M,"Ran over with [src.name]")
|
||||
|
||||
Reference in New Issue
Block a user