mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-22 19:47:22 +01:00
Makes anomalies deadlier (#18836)
* Makes anomalies deadlier * Apply suggestions from code review Co-authored-by: Sirryan2002 <80364400+Sirryan2002@users.noreply.github.com> * undodgeable to dodgeable * requested changes Co-authored-by: Sirryan2002 <80364400+Sirryan2002@users.noreply.github.com>
This commit is contained in:
co-authored by
Sirryan2002
parent
d6e24aa850
commit
afbae8af1b
@@ -67,6 +67,8 @@ SUBSYSTEM_DEF(throwing)
|
||||
var/paused = FALSE
|
||||
var/delayed_time = 0
|
||||
var/last_move = 0
|
||||
///When this variable is false, non dense mobs will be hit by a thrown item. useful for things that you dont want to be cheesed by crawling, EG. gravitational anomalies
|
||||
var/dodgeable = TRUE
|
||||
|
||||
/datum/thrownthing/proc/tick()
|
||||
var/atom/movable/AM = thrownthing
|
||||
@@ -90,6 +92,7 @@ SUBSYSTEM_DEF(throwing)
|
||||
var/tilestomove = CEILING(min(((((world.time + world.tick_lag) - start_time + delayed_time) * speed) - (dist_travelled ? dist_travelled : -1)), speed * MAX_TICKS_TO_MAKE_UP) * (world.tick_lag * SSthrowing.wait), 1)
|
||||
while(tilestomove-- > 0)
|
||||
if((dist_travelled >= maxrange || AM.loc == target_turf) && has_gravity(AM, AM.loc))
|
||||
hitcheck() //Just to be sure
|
||||
finalize()
|
||||
return
|
||||
|
||||
@@ -148,6 +151,6 @@ SUBSYSTEM_DEF(throwing)
|
||||
var/atom/movable/AM = thing
|
||||
if(AM == thrownthing || AM == thrower)
|
||||
continue
|
||||
if(AM.density && !(AM.pass_flags & LETPASSTHROW) && !(AM.flags & ON_BORDER))
|
||||
if((AM.density || isliving(AM) && !dodgeable) && !(AM.pass_flags & LETPASSTHROW) && !(AM.flags & ON_BORDER))
|
||||
finalize(hit = TRUE, target = AM)
|
||||
return TRUE
|
||||
|
||||
Reference in New Issue
Block a user