mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 10:12:45 +00:00
Fixes explosions
At least worked fine on local in all tests and types of explosions i tested out (admin and weldertank) in wilderness and on station. I suppose it had been a byond change after all that hadn't been quite as lenient with fucked up unindented archaic shapes of code. Probably gonna shove it upstreams as well if it happens to do the trick on live as well.
This commit is contained in:
@@ -78,16 +78,21 @@
|
||||
for(var/turf/T in trange(max_range, epicenter))
|
||||
var/dist = sqrt((T.x - x0)**2 + (T.y - y0)**2)
|
||||
|
||||
if(dist < devastation_range) dist = 1
|
||||
else if(dist < heavy_impact_range) dist = 2
|
||||
else if(dist < light_impact_range) dist = 3
|
||||
else continue
|
||||
if(dist < devastation_range)
|
||||
dist = 1
|
||||
else if(dist < heavy_impact_range)
|
||||
dist = 2
|
||||
else if(dist < light_impact_range)
|
||||
dist = 3
|
||||
else
|
||||
continue
|
||||
|
||||
if(!T)
|
||||
T = locate(x0,y0,z0)
|
||||
for(var/atom_movable in T.contents) //bypass type checking since only atom/movable can be contained by turfs anyway
|
||||
var/atom/movable/AM = atom_movable
|
||||
if(AM && AM.simulated) AM.ex_act(dist)
|
||||
if(AM && AM.simulated)
|
||||
AM.ex_act(dist)
|
||||
|
||||
T.ex_act(dist)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user