mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-28 14:37:04 +01:00
Merge remote-tracking branch 'upstream/master' into tesla-tweaks
This commit is contained in:
@@ -877,21 +877,22 @@ steam.start() -- spawns the effect
|
||||
// Similar to smoke, but spreads out more
|
||||
// metal foams leave behind a foamed metal wall
|
||||
|
||||
/obj/effect/effect/foam
|
||||
/obj/structure/foam
|
||||
name = "foam"
|
||||
icon = 'icons/effects/effects.dmi'
|
||||
icon_state = "foam"
|
||||
opacity = 0
|
||||
anchored = 1
|
||||
density = 0
|
||||
layer = OBJ_LAYER + 0.9
|
||||
mouse_opacity = 0
|
||||
animate_movement = 0
|
||||
var/amount = 3
|
||||
var/expand = 1
|
||||
animate_movement = 0
|
||||
var/metal = 0
|
||||
|
||||
|
||||
/obj/effect/effect/foam/New(loc, var/ismetal=0)
|
||||
/obj/structure/foam/New(loc, var/ismetal=0)
|
||||
..(loc)
|
||||
icon_state = "[ismetal ? "m":""]foam"
|
||||
if(!ismetal && reagents)
|
||||
@@ -918,11 +919,11 @@ steam.start() -- spawns the effect
|
||||
|
||||
flick("[icon_state]-disolve", src)
|
||||
sleep(5)
|
||||
delete()
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
// on delete, transfer any reagents to the floor
|
||||
/obj/effect/effect/foam/Destroy()
|
||||
/obj/structure/foam/Destroy()
|
||||
if(!metal && reagents)
|
||||
reagents.handle_reactions()
|
||||
for(var/atom/A in oview(1, src))
|
||||
@@ -933,7 +934,7 @@ steam.start() -- spawns the effect
|
||||
reagents.reaction(A, TOUCH, fraction)
|
||||
return ..()
|
||||
|
||||
/obj/effect/effect/foam/process()
|
||||
/obj/structure/foam/process()
|
||||
if(--amount < 0)
|
||||
return
|
||||
|
||||
@@ -948,11 +949,11 @@ steam.start() -- spawns the effect
|
||||
if(!T.Enter(src))
|
||||
continue
|
||||
|
||||
var/obj/effect/effect/foam/F = locate() in T
|
||||
var/obj/structure/foam/F = locate() in T
|
||||
if(F)
|
||||
continue
|
||||
|
||||
F = new /obj/effect/effect/foam(T, metal)
|
||||
F = new /obj/structure/foam(T, metal)
|
||||
F.amount = amount
|
||||
if(!metal)
|
||||
F.create_reagents(15)
|
||||
@@ -963,15 +964,15 @@ steam.start() -- spawns the effect
|
||||
|
||||
// foam disolves when heated
|
||||
// except metal foams
|
||||
/obj/effect/effect/foam/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume)
|
||||
/obj/structure/foam/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume)
|
||||
if(!metal && prob(max(0, exposed_temperature - 475)))
|
||||
flick("[icon_state]-disolve", src)
|
||||
|
||||
spawn(5)
|
||||
delete()
|
||||
qdel(src)
|
||||
|
||||
|
||||
/obj/effect/effect/foam/Crossed(var/atom/movable/AM)
|
||||
/obj/structure/foam/Crossed(var/atom/movable/AM)
|
||||
if(metal)
|
||||
return
|
||||
|
||||
@@ -1016,13 +1017,13 @@ steam.start() -- spawns the effect
|
||||
|
||||
/datum/effect/system/foam_spread/start()
|
||||
spawn(0)
|
||||
var/obj/effect/effect/foam/F = locate() in location
|
||||
var/obj/structure/foam/F = locate() in location
|
||||
if(F)
|
||||
F.amount += amount
|
||||
F.amount = min(F.amount, 27)
|
||||
return
|
||||
|
||||
F = new /obj/effect/effect/foam(location, metal)
|
||||
F = new /obj/structure/foam(location, metal)
|
||||
F.amount = amount
|
||||
|
||||
if(!metal) // don't carry other chemicals if a metal foam
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
//separate dm since hydro is getting bloated already
|
||||
|
||||
/obj/effect/glowshroom
|
||||
/obj/structure/glowshroom
|
||||
name = "glowshroom"
|
||||
desc = "Mycena Bregprox, a species of mushroom that glows in the dark."
|
||||
anchored = 1
|
||||
@@ -16,32 +16,32 @@
|
||||
var/spreadIntoAdjacentChance = 60
|
||||
var/obj/item/seeds/myseed = /obj/item/seeds/glowshroom
|
||||
|
||||
/obj/effect/glowshroom/glowcap
|
||||
/obj/structure/glowshroom/glowcap
|
||||
name = "glowcap"
|
||||
desc = "Mycena Ruthenia, a species of mushroom that, while it does glow in the dark, is not actually bioluminescent."
|
||||
icon_state = "glowcap"
|
||||
myseed = /obj/item/seeds/glowshroom/glowcap
|
||||
|
||||
/obj/effect/glowshroom/shadowshroom
|
||||
/obj/structure/glowshroom/shadowshroom
|
||||
name = "shadowshroom"
|
||||
desc = "Mycena Umbra, a species of mushroom that emits shadow instead of light."
|
||||
icon_state = "shadowshroom"
|
||||
myseed = /obj/item/seeds/glowshroom/shadowshroom
|
||||
|
||||
/obj/effect/glowshroom/single/Spread()
|
||||
/obj/structure/glowshroom/single/Spread()
|
||||
return
|
||||
|
||||
/obj/effect/glowshroom/examine(mob/user)
|
||||
/obj/structure/glowshroom/examine(mob/user)
|
||||
. = ..()
|
||||
to_chat(user, "This is a [generation]\th generation [name]!")
|
||||
|
||||
/obj/effect/glowshroom/Destroy()
|
||||
/obj/structure/glowshroom/Destroy()
|
||||
if(myseed)
|
||||
qdel(myseed)
|
||||
myseed = null
|
||||
return ..()
|
||||
|
||||
/obj/effect/glowshroom/New(loc, obj/item/seeds/newseed, mutate_stats)
|
||||
/obj/structure/glowshroom/New(loc, obj/item/seeds/newseed, mutate_stats)
|
||||
..()
|
||||
if(newseed)
|
||||
myseed = newseed.Copy()
|
||||
@@ -76,7 +76,7 @@
|
||||
|
||||
addtimer(src, "Spread", delay, FALSE)
|
||||
|
||||
/obj/effect/glowshroom/proc/Spread()
|
||||
/obj/structure/glowshroom/proc/Spread()
|
||||
var/turf/ownturf = get_turf(src)
|
||||
var/shrooms_planted = 0
|
||||
for(var/i in 1 to myseed.yield)
|
||||
@@ -90,7 +90,7 @@
|
||||
for(var/turf/simulated/floor/earth in view(3,src))
|
||||
if(!ownturf.CanAtmosPass(earth))
|
||||
continue
|
||||
if(spreadsIntoAdjacent || !locate(/obj/effect/glowshroom) in view(1,earth))
|
||||
if(spreadsIntoAdjacent || !locate(/obj/structure/glowshroom) in view(1,earth))
|
||||
possibleLocs += earth
|
||||
CHECK_TICK
|
||||
|
||||
@@ -101,7 +101,7 @@
|
||||
|
||||
var/shroomCount = 0 //hacky
|
||||
var/placeCount = 1
|
||||
for(var/obj/effect/glowshroom/shroom in newLoc)
|
||||
for(var/obj/structure/glowshroom/shroom in newLoc)
|
||||
shroomCount++
|
||||
for(var/wallDir in cardinal)
|
||||
var/turf/isWall = get_step(newLoc,wallDir)
|
||||
@@ -110,7 +110,7 @@
|
||||
if(shroomCount >= placeCount)
|
||||
continue
|
||||
|
||||
var/obj/effect/glowshroom/child = new type(newLoc, myseed, TRUE)
|
||||
var/obj/structure/glowshroom/child = new type(newLoc, myseed, TRUE)
|
||||
child.generation = generation + 1
|
||||
shrooms_planted++
|
||||
|
||||
@@ -121,7 +121,7 @@
|
||||
myseed.yield -= shrooms_planted
|
||||
addtimer(src, "Spread", delay, FALSE)
|
||||
|
||||
/obj/effect/glowshroom/proc/CalcDir(turf/location = loc)
|
||||
/obj/structure/glowshroom/proc/CalcDir(turf/location = loc)
|
||||
var/direction = 16
|
||||
|
||||
for(var/wallDir in cardinal)
|
||||
@@ -129,7 +129,7 @@
|
||||
if(newTurf.density)
|
||||
direction |= wallDir
|
||||
|
||||
for(var/obj/effect/glowshroom/shroom in location)
|
||||
for(var/obj/structure/glowshroom/shroom in location)
|
||||
if(shroom == src)
|
||||
continue
|
||||
if(shroom.floor) //special
|
||||
@@ -153,13 +153,13 @@
|
||||
floor = 1
|
||||
return 1
|
||||
|
||||
/obj/effect/glowshroom/attackby(obj/item/I, mob/user)
|
||||
/obj/structure/glowshroom/attackby(obj/item/I, mob/user)
|
||||
..()
|
||||
if(I.damtype != STAMINA)
|
||||
endurance -= I.force
|
||||
CheckEndurance()
|
||||
|
||||
/obj/effect/glowshroom/ex_act(severity)
|
||||
/obj/structure/glowshroom/ex_act(severity)
|
||||
switch(severity)
|
||||
if(1)
|
||||
qdel(src)
|
||||
@@ -170,11 +170,11 @@
|
||||
if(prob(5))
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/glowshroom/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume)
|
||||
/obj/structure/glowshroom/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume)
|
||||
if(exposed_temperature > 300)
|
||||
endurance -= 5
|
||||
CheckEndurance()
|
||||
|
||||
/obj/effect/glowshroom/proc/CheckEndurance()
|
||||
/obj/structure/glowshroom/proc/CheckEndurance()
|
||||
if(endurance <= 0)
|
||||
qdel(src)
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
//generic procs copied from obj/effect/alien
|
||||
/obj/effect/spider
|
||||
/obj/structure/spider
|
||||
name = "web"
|
||||
desc = "it's stringy and sticky"
|
||||
icon = 'icons/effects/effects.dmi'
|
||||
@@ -8,7 +8,7 @@
|
||||
var/health = 15
|
||||
|
||||
//similar to weeds, but only barfed out by nurses manually
|
||||
/obj/effect/spider/ex_act(severity)
|
||||
/obj/structure/spider/ex_act(severity)
|
||||
switch(severity)
|
||||
if(1.0)
|
||||
qdel(src)
|
||||
@@ -20,7 +20,7 @@
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
/obj/effect/spider/attackby(var/obj/item/weapon/W, var/mob/user, params)
|
||||
/obj/structure/spider/attackby(var/obj/item/weapon/W, var/mob/user, params)
|
||||
if(W.attack_verb.len)
|
||||
visible_message("<span class='danger'>[user] has [pick(W.attack_verb)] \the [src] with \the [W]!</span>")
|
||||
else
|
||||
@@ -38,28 +38,28 @@
|
||||
health -= damage
|
||||
healthcheck()
|
||||
|
||||
/obj/effect/spider/bullet_act(var/obj/item/projectile/Proj)
|
||||
/obj/structure/spider/bullet_act(var/obj/item/projectile/Proj)
|
||||
..()
|
||||
health -= Proj.damage
|
||||
healthcheck()
|
||||
|
||||
/obj/effect/spider/proc/healthcheck()
|
||||
/obj/structure/spider/proc/healthcheck()
|
||||
if(health <= 0)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/spider/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume)
|
||||
/obj/structure/spider/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume)
|
||||
if(exposed_temperature > 300)
|
||||
health -= 5
|
||||
healthcheck()
|
||||
|
||||
/obj/effect/spider/stickyweb
|
||||
/obj/structure/spider/stickyweb
|
||||
icon_state = "stickyweb1"
|
||||
|
||||
/obj/effect/spider/stickyweb/New()
|
||||
/obj/structure/spider/stickyweb/New()
|
||||
if(prob(50))
|
||||
icon_state = "stickyweb2"
|
||||
|
||||
/obj/effect/spider/stickyweb/CanPass(atom/movable/mover, turf/target, height=0)
|
||||
/obj/structure/spider/stickyweb/CanPass(atom/movable/mover, turf/target, height=0)
|
||||
if(height==0) return 1
|
||||
if(istype(mover, /mob/living/simple_animal/hostile/poison/giant_spider))
|
||||
return 1
|
||||
@@ -71,7 +71,7 @@
|
||||
return prob(30)
|
||||
return 1
|
||||
|
||||
/obj/effect/spider/eggcluster
|
||||
/obj/structure/spider/eggcluster
|
||||
name = "egg cluster"
|
||||
desc = "They seem to pulse slightly with an inner life"
|
||||
icon_state = "eggs"
|
||||
@@ -80,24 +80,24 @@
|
||||
var/faction = list()
|
||||
var/master_commander = null
|
||||
|
||||
/obj/effect/spider/eggcluster/New()
|
||||
/obj/structure/spider/eggcluster/New()
|
||||
pixel_x = rand(3,-3)
|
||||
pixel_y = rand(3,-3)
|
||||
processing_objects.Add(src)
|
||||
|
||||
/obj/effect/spider/eggcluster/process()
|
||||
/obj/structure/spider/eggcluster/process()
|
||||
amount_grown += rand(0,2)
|
||||
if(amount_grown >= 100)
|
||||
var/num = rand(3,12)
|
||||
for(var/i=0, i<num, i++)
|
||||
var/obj/effect/spider/spiderling/S = new /obj/effect/spider/spiderling(src.loc)
|
||||
var/obj/structure/spider/spiderling/S = new /obj/structure/spider/spiderling(src.loc)
|
||||
S.faction = faction
|
||||
S.master_commander = master_commander
|
||||
if(player_spiders)
|
||||
S.player_spiders = 1
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/spider/spiderling
|
||||
/obj/structure/spider/spiderling
|
||||
name = "spiderling"
|
||||
desc = "It never stays still for long."
|
||||
icon_state = "spiderling"
|
||||
@@ -113,27 +113,27 @@
|
||||
var/master_commander = null
|
||||
var/selecting_player = 0
|
||||
|
||||
/obj/effect/spider/spiderling/New()
|
||||
/obj/structure/spider/spiderling/New()
|
||||
pixel_x = rand(6,-6)
|
||||
pixel_y = rand(6,-6)
|
||||
processing_objects.Add(src)
|
||||
|
||||
/obj/effect/spider/spiderling/Bump(atom/user)
|
||||
/obj/structure/spider/spiderling/Bump(atom/user)
|
||||
if(istype(user, /obj/structure/table))
|
||||
src.loc = user.loc
|
||||
else
|
||||
..()
|
||||
|
||||
/obj/effect/spider/spiderling/proc/die()
|
||||
/obj/structure/spider/spiderling/proc/die()
|
||||
visible_message("<span class='alert'>[src] dies!</span>")
|
||||
new /obj/effect/decal/cleanable/spiderling_remains(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/spider/spiderling/healthcheck()
|
||||
/obj/structure/spider/spiderling/healthcheck()
|
||||
if(health <= 0)
|
||||
die()
|
||||
|
||||
/obj/effect/spider/spiderling/process()
|
||||
/obj/structure/spider/spiderling/process()
|
||||
if(travelling_in_vent)
|
||||
if(istype(src.loc, /turf))
|
||||
travelling_in_vent = 0
|
||||
@@ -217,16 +217,16 @@
|
||||
icon_state = "greenshatter"
|
||||
anchored = 1
|
||||
|
||||
/obj/effect/spider/cocoon
|
||||
/obj/structure/spider/cocoon
|
||||
name = "cocoon"
|
||||
desc = "Something wrapped in silky spider web"
|
||||
icon_state = "cocoon1"
|
||||
health = 60
|
||||
|
||||
/obj/effect/spider/cocoon/New()
|
||||
/obj/structure/spider/cocoon/New()
|
||||
icon_state = pick("cocoon1","cocoon2","cocoon3")
|
||||
|
||||
/obj/effect/spider/cocoon/Destroy()
|
||||
/obj/structure/spider/cocoon/Destroy()
|
||||
src.visible_message("<span class='danger'>\The [src] splits open.</span>")
|
||||
for(var/atom/movable/A in contents)
|
||||
A.loc = src.loc
|
||||
|
||||
Reference in New Issue
Block a user