mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-26 06:29:23 +01:00
Merge pull request #12485 from xxalpha/ultrarange
Added ultra_range() proc.
This commit is contained in:
@@ -39,7 +39,7 @@ effective or pretty fucking useless.
|
||||
|
||||
add_logs(user, null, "knocked down people in the area", src)
|
||||
|
||||
for(var/mob/living/carbon/human/M in orange(10, user))
|
||||
for(var/mob/living/carbon/human/M in ultra_range(10, user, 1))
|
||||
spawn()
|
||||
if(prob(50))
|
||||
|
||||
|
||||
@@ -1107,7 +1107,7 @@
|
||||
/obj/item/toy/minimeteor/throw_impact(atom/hit_atom)
|
||||
if(!..())
|
||||
playsound(src, 'sound/effects/meteorimpact.ogg', 40, 1)
|
||||
for(var/mob/M in range(10, src))
|
||||
for(var/mob/M in ultra_range(10, src))
|
||||
if(!M.stat && !istype(M, /mob/living/silicon/ai))\
|
||||
shake_camera(M, 3, 1)
|
||||
qdel(src)
|
||||
@@ -1153,7 +1153,7 @@
|
||||
cooldown = (world.time + 300) // Sets cooldown at 30 seconds
|
||||
user.visible_message("<span class='warning'>[user] presses the big red button.</span>", "<span class='notice'>You press the button, it plays a loud noise!</span>", "<span class='italics'>The button clicks loudly.</span>")
|
||||
playsound(src, 'sound/effects/explosionfar.ogg', 50, 0, surround = 0)
|
||||
for(var/mob/M in range(10, src)) // Checks range
|
||||
for(var/mob/M in ultra_range(10, src)) // Checks range
|
||||
if(!M.stat && !istype(M, /mob/living/silicon/ai)) // Checks to make sure whoever's getting shaken is alive/not the AI
|
||||
sleep(8) // Short delay to match up with the explosion sound
|
||||
shake_camera(M, 2, 1) // Shakes player camera 2 squares for 1 second.
|
||||
|
||||
@@ -149,7 +149,7 @@ Frequency:
|
||||
else
|
||||
L["[com.id] (Inactive)"] = com.target
|
||||
var/list/turfs = list( )
|
||||
for(var/turf/T in orange(10))
|
||||
for(var/turf/T in ultra_range(10, orange=1))
|
||||
if(T.x>world.maxx-8 || T.x<8) continue //putting them at the edge is dumb
|
||||
if(T.y>world.maxy-8 || T.y<8) continue
|
||||
turfs += T
|
||||
|
||||
Reference in New Issue
Block a user