mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-20 19:44:09 +01:00
Merge branch 'master' of https://github.com/Miniature/Baystation12 into Miniature-master
Conflicts: code/modules/mob/living/carbon/alien/humanoid/life.dm code/modules/mob/living/carbon/alien/larva/life.dm
This commit is contained in:
@@ -2,8 +2,8 @@ var/const
|
||||
MIN_IMPREGNATION_TIME = 100 //time it takes to impregnate someone
|
||||
MAX_IMPREGNATION_TIME = 150
|
||||
|
||||
MIN_ACTIVE_TIME = 30 //time between being dropped and going idle
|
||||
MAX_ACTIVE_TIME = 50
|
||||
MIN_ACTIVE_TIME = 300 //time between being dropped and going idle
|
||||
MAX_ACTIVE_TIME = 600
|
||||
|
||||
/obj/item/clothing/mask/facehugger
|
||||
name = "alien"
|
||||
@@ -13,7 +13,7 @@ var/const
|
||||
w_class = 1 //note: can be picked up by aliens unlike most other items of w_class below 4
|
||||
flags = FPRINT|TABLEPASS|MASKCOVERSMOUTH|MASKCOVERSEYES
|
||||
|
||||
var/stat = CONSCIOUS //UNCONSCIOUS is the idle state in this case
|
||||
var/stat = UNCONSCIOUS //UNCONSCIOUS is the idle state in this case
|
||||
|
||||
var/sterile = 0
|
||||
|
||||
@@ -177,6 +177,11 @@ var/const
|
||||
|
||||
stat = CONSCIOUS
|
||||
|
||||
for(var/mob/living/carbon/alien/alien in world)
|
||||
var/image/activeIndicator = image('alien.dmi', loc = src, icon_state = "facehugger_active")
|
||||
activeIndicator.override = 1
|
||||
alien.client.images += activeIndicator
|
||||
|
||||
spawn(rand(MIN_ACTIVE_TIME,MAX_ACTIVE_TIME))
|
||||
GoIdle()
|
||||
|
||||
@@ -186,6 +191,8 @@ var/const
|
||||
if(stat == DEAD || stat == UNCONSCIOUS)
|
||||
return
|
||||
|
||||
RemoveActiveIndicators()
|
||||
|
||||
stat = UNCONSCIOUS
|
||||
|
||||
return
|
||||
@@ -194,6 +201,8 @@ var/const
|
||||
if(stat == DEAD)
|
||||
return
|
||||
|
||||
RemoveActiveIndicators()
|
||||
|
||||
icon_state = "facehugger_dead"
|
||||
stat = DEAD
|
||||
|
||||
@@ -202,7 +211,13 @@ var/const
|
||||
|
||||
return
|
||||
|
||||
proc/RemoveActiveIndicators() //removes the "active" facehugger indicator from all aliens in the world for this hugger
|
||||
for(var/mob/living/carbon/alien/alien in world)
|
||||
for(var/image/image in alien.client.images)
|
||||
if(image.icon_state == "facehugger_active" && image.loc == src)
|
||||
del(image)
|
||||
|
||||
return
|
||||
|
||||
/* NOPE.png -- Urist
|
||||
|
||||
|
||||
@@ -4,6 +4,12 @@
|
||||
return 0
|
||||
return 1
|
||||
|
||||
/obj/structure/closet/secure_closet/close()
|
||||
..()
|
||||
if(broken)
|
||||
icon_state = src.icon_off
|
||||
return 1
|
||||
|
||||
/obj/structure/closet/secure_closet/emp_act(severity)
|
||||
for(var/obj/O in src)
|
||||
O.emp_act(severity)
|
||||
@@ -35,7 +41,8 @@
|
||||
broken = 1
|
||||
locked = 0
|
||||
desc = "It appears to be broken."
|
||||
icon_state = src.icon_broken
|
||||
icon_state = icon_off
|
||||
flick(icon_broken, src)
|
||||
if(istype(W, /obj/item/weapon/melee/energy/blade))
|
||||
var/datum/effect/effect/system/spark_spread/spark_system = new /datum/effect/effect/system/spark_spread()
|
||||
spark_system.set_up(5, 0, src.loc)
|
||||
|
||||
@@ -100,6 +100,7 @@
|
||||
new /obj/item/device/radio/headset/headset_sec(src)
|
||||
new /obj/item/weapon/storage/belt/security(src)
|
||||
new /obj/item/weapon/flashbang(src)
|
||||
new /obj/item/weapon/pepperspray(src)
|
||||
new /obj/item/device/flash(src)
|
||||
new /obj/item/weapon/melee/baton(src)
|
||||
new /obj/item/weapon/gun/energy/taser(src)
|
||||
|
||||
@@ -162,6 +162,10 @@
|
||||
user << "\red Sticking a dead brain into the frame would sort of defeat the purpose."
|
||||
return
|
||||
|
||||
if(M.brainmob.mind in ticker.mode.head_revolutionaries)
|
||||
user << "\red The frame's firmware lets out a shrill sound, and flashes 'Abnormal Memory Engram'. It refuses to accept the MMI."
|
||||
return
|
||||
|
||||
if(jobban_isbanned(M.brainmob, "Cyborg"))
|
||||
user << "\red This MMI does not seem to fit."
|
||||
return
|
||||
@@ -183,6 +187,10 @@
|
||||
G.corpse.mind.transfer_to(O)
|
||||
del(G)
|
||||
break
|
||||
|
||||
if(O.mind in ticker.mode:revolutionaries)
|
||||
ticker.mode:remove_revolutionary(O.mind , 1)
|
||||
|
||||
if(O.mind && O.mind.special_role)
|
||||
O.mind.store_memory("In case you look at this after being borged, the objectives are only here until I find a way to make them not show up for you, as I can't simply delete them without screwing up round-end reporting. --NeoFite")
|
||||
|
||||
|
||||
@@ -130,18 +130,7 @@ RCD
|
||||
user << "The RCD now holds [matter]/30 matter-units."
|
||||
desc = "A RCD. It currently holds [matter]/30 matter-units."
|
||||
return
|
||||
if(istype(A, /turf/simulated/wall/r_wall) && matter >= 8)
|
||||
user << "Deconstructing RWall (8)..."
|
||||
playsound(src.loc, 'click.ogg', 50, 1)
|
||||
if(do_after(user, 60))
|
||||
if(!disabled && matter >= 8)
|
||||
spark_system.set_up(5, 0, src)
|
||||
src.spark_system.start()
|
||||
A:ReplaceWithWall()
|
||||
playsound(src.loc, 'Deconstruct.ogg', 50, 1)
|
||||
matter -= 8
|
||||
user << "The RCD now holds [matter]/30 matter-units."
|
||||
desc = "A RCD. It currently holds [matter]/30 matter-units."
|
||||
if(istype(A, /turf/simulated/wall/r_wall))
|
||||
return
|
||||
if(istype(A, /turf/simulated/floor) && matter >= 5)
|
||||
user << "Deconstructing Floor (5)..."
|
||||
|
||||
@@ -26,6 +26,7 @@ FLASHBANG
|
||||
|
||||
afterattack(atom/target as mob|obj|turf|area, mob/user as mob)
|
||||
if (istype(target, /obj/item/weapon/storage)) return ..() // Trying to put it in a full container
|
||||
if (istype(target, /obj/item/weapon/gun/grenadelauncher)) return ..()
|
||||
if((user.equipped() == src)&&(!active)&&(clown_check(user)))
|
||||
user << "\red You prime the emp grenade! [det_time/10] seconds!"
|
||||
src.active = 1
|
||||
@@ -93,6 +94,7 @@ FLASHBANG
|
||||
active = 0
|
||||
det_time = 30
|
||||
proc
|
||||
bang(var/turf/T , var/mob/living/carbon/M)
|
||||
prime()
|
||||
clown_check(var/mob/living/user)
|
||||
|
||||
@@ -119,6 +121,7 @@ FLASHBANG
|
||||
|
||||
afterattack(atom/target as mob|obj|turf|area, mob/user as mob)
|
||||
if (istype(target, /obj/item/weapon/storage)) return ..() // Trying to put it in a full container
|
||||
if (istype(target, /obj/item/weapon/gun/grenadelauncher)) return ..()
|
||||
if((user.equipped() == src)&&(!active)&&(clown_check(user)))
|
||||
user << "\red You prime the flashbang! [det_time/10] seconds!"
|
||||
src.active = 1
|
||||
@@ -143,81 +146,92 @@ FLASHBANG
|
||||
..()
|
||||
return
|
||||
|
||||
bang(var/turf/T , var/mob/living/carbon/M) // Added a new proc called 'bang' that takes a location and a person to be banged.
|
||||
if (locate(/obj/item/weapon/cloaking_device, M)) // Called during the loop that bangs people in lockers/containers and when banging
|
||||
for(var/obj/item/weapon/cloaking_device/S in M) // people in normal view. Could theroetically be called during other explosions.
|
||||
S.active = 0 // -- Polymorph
|
||||
S.icon_state = "shield0"
|
||||
|
||||
prime()
|
||||
M << "\red <B>BANG</B>"
|
||||
playsound(src.loc, 'bang.ogg', 25, 1)
|
||||
|
||||
//Checking for protections
|
||||
var/eye_safety = 0
|
||||
var/ear_safety = 0
|
||||
if(iscarbon(M))
|
||||
eye_safety = M.eyecheck()
|
||||
if(ishuman(M))
|
||||
if(istype(M:ears, /obj/item/clothing/ears/earmuffs))
|
||||
ear_safety += 2
|
||||
if(M.mutations & HULK)
|
||||
ear_safety += 1
|
||||
if(istype(M:head, /obj/item/clothing/head/helmet))
|
||||
ear_safety += 1
|
||||
|
||||
//Flashing everyone
|
||||
if(eye_safety < 1)
|
||||
flick("e_flash", M.flash)
|
||||
M.eye_stat += rand(1, 3)
|
||||
M.stunned = max(M.stunned,2)
|
||||
M.weakened = max(M.weakened,10)
|
||||
|
||||
|
||||
|
||||
//Now applying sound
|
||||
if((get_dist(M, T) <= 2 || src.loc == M.loc || src.loc == M))
|
||||
if(ear_safety > 0)
|
||||
M.stunned = max(M.stunned,2)
|
||||
M.weakened = max(M.weakened,1)
|
||||
else
|
||||
M.stunned = max(M.stunned,10)
|
||||
M.weakened = max(M.weakened,3)
|
||||
if ((prob(14) || (M == src.loc && prob(70))))
|
||||
M.ear_damage += rand(1, 10)
|
||||
else
|
||||
M.ear_damage += rand(0, 5)
|
||||
M.ear_deaf = max(M.ear_deaf,15)
|
||||
|
||||
else if(get_dist(M, T) <= 5)
|
||||
if(!ear_safety)
|
||||
M.stunned = max(M.stunned,8)
|
||||
M.ear_damage += rand(0, 3)
|
||||
M.ear_deaf = max(M.ear_deaf,10)
|
||||
|
||||
else if(!ear_safety)
|
||||
M.stunned = max(M.stunned,4)
|
||||
M.ear_damage += rand(0, 1)
|
||||
M.ear_deaf = max(M.ear_deaf,5)
|
||||
|
||||
//This really should be in mob not every check
|
||||
if (M.eye_stat >= 20)
|
||||
M << "\red Your eyes start to burn badly!"
|
||||
M.disabilities |= 1
|
||||
if (prob(M.eye_stat - 20 + 1))
|
||||
M << "\red You can't see anything!"
|
||||
M.sdisabilities |= 1
|
||||
if (M.ear_damage >= 15)
|
||||
M << "\red Your ears start to ring badly!"
|
||||
if (prob(M.ear_damage - 10 + 5))
|
||||
M << "\red You can't hear anything!"
|
||||
M.sdisabilities |= 4
|
||||
else
|
||||
if (M.ear_damage >= 5)
|
||||
M << "\red Your ears start to ring!"
|
||||
|
||||
prime() // Prime now just handles the two loops that query for people in lockers and people who can see it.
|
||||
var/turf/T = get_turf(src)
|
||||
if(T)
|
||||
T.hotspot_expose(700,125)
|
||||
|
||||
for(var/obj/structure/closet/L in view(T, null))
|
||||
if(locate(/mob/living/carbon/, L))
|
||||
for(var/mob/living/carbon/M in L)
|
||||
bang(T, M)
|
||||
|
||||
|
||||
for(var/mob/living/carbon/M in viewers(T, null))
|
||||
if (locate(/obj/item/weapon/cloaking_device, M))
|
||||
for(var/obj/item/weapon/cloaking_device/S in M)
|
||||
S.active = 0
|
||||
S.icon_state = "shield0"
|
||||
bang(T, M)
|
||||
|
||||
M << "\red <B>BANG</B>"
|
||||
|
||||
//Checking for protections
|
||||
var/eye_safety = 0
|
||||
var/ear_safety = 0
|
||||
if(iscarbon(M))
|
||||
eye_safety = M.eyecheck()
|
||||
if(ishuman(M))
|
||||
if(istype(M:ears, /obj/item/clothing/ears/earmuffs))
|
||||
ear_safety += 2
|
||||
if(M.mutations & HULK)
|
||||
ear_safety += 1
|
||||
if(istype(M:head, /obj/item/clothing/head/helmet))
|
||||
ear_safety += 1
|
||||
|
||||
//Flashing everyone
|
||||
if(eye_safety < 1)
|
||||
flick("e_flash", M.flash)
|
||||
M.eye_stat += rand(1, 3)
|
||||
M.stunned = max(M.stunned,2)
|
||||
M.weakened = max(M.weakened,10)
|
||||
|
||||
//Now applying sound
|
||||
if((get_dist(M, T) <= 2 || src.loc == M.loc || src.loc == M))
|
||||
if(ear_safety > 0)
|
||||
M.stunned = max(M.stunned,2)
|
||||
M.weakened = max(M.weakened,1)
|
||||
else
|
||||
M.stunned = max(M.stunned,10)
|
||||
M.weakened = max(M.weakened,3)
|
||||
if ((prob(14) || (M == src.loc && prob(70))))
|
||||
M.ear_damage += rand(1, 10)
|
||||
else
|
||||
M.ear_damage += rand(0, 5)
|
||||
M.ear_deaf = max(M.ear_deaf,15)
|
||||
|
||||
else if(get_dist(M, T) <= 5)
|
||||
if(!ear_safety)
|
||||
M.stunned = max(M.stunned,8)
|
||||
M.ear_damage += rand(0, 3)
|
||||
M.ear_deaf = max(M.ear_deaf,10)
|
||||
|
||||
else if(!ear_safety)
|
||||
M.stunned = max(M.stunned,4)
|
||||
M.ear_damage += rand(0, 1)
|
||||
M.ear_deaf = max(M.ear_deaf,5)
|
||||
|
||||
//This really should be in mob not every check
|
||||
if (M.eye_stat >= 20)
|
||||
M << "\red Your eyes start to burn badly!"
|
||||
M.disabilities |= 1
|
||||
if (prob(M.eye_stat - 20 + 1))
|
||||
M << "\red You can't see anything!"
|
||||
M.sdisabilities |= 1
|
||||
if (M.ear_damage >= 15)
|
||||
M << "\red Your ears start to ring badly!"
|
||||
if (prob(M.ear_damage - 10 + 5))
|
||||
M << "\red You can't hear anything!"
|
||||
M.sdisabilities |= 4
|
||||
else
|
||||
if (M.ear_damage >= 5)
|
||||
M << "\red Your ears start to ring!"
|
||||
|
||||
//Blob damage here
|
||||
for(var/obj/effect/blob/B in view(8,T))
|
||||
@@ -251,3 +265,16 @@ FLASHBANG
|
||||
prime()
|
||||
return 0
|
||||
return 1
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@ MOP
|
||||
return
|
||||
|
||||
/obj/item/weapon/cleaner/afterattack(atom/A as mob|obj, mob/user as mob)
|
||||
if (istype(A, /obj/item/weapon/storage/backpack ))
|
||||
if (istype(A, /obj/item/weapon/storage ))
|
||||
return
|
||||
if (istype(A, /obj/effect/proc_holder/spell ))
|
||||
return
|
||||
@@ -91,7 +91,7 @@ MOP
|
||||
return
|
||||
|
||||
/obj/item/weapon/chemsprayer/afterattack(atom/A as mob|obj, mob/user as mob)
|
||||
if (istype(A, /obj/item/weapon/storage/backpack ))
|
||||
if (istype(A, /obj/item/weapon/storage ))
|
||||
return
|
||||
if (istype(A, /obj/effect/proc_holder/spell ))
|
||||
return
|
||||
@@ -165,7 +165,95 @@ MOP
|
||||
|
||||
return
|
||||
|
||||
/obj/item/weapon/chemsprayer/examine()
|
||||
/obj/item/weapon/pepperspray/New()
|
||||
var/datum/reagents/R = new/datum/reagents(45)
|
||||
reagents = R
|
||||
R.my_atom = src
|
||||
R.add_reagent("condensedcapsaicin", 45)
|
||||
|
||||
/obj/item/weapon/pepperspray/attack(mob/living/carbon/human/M as mob, mob/user as mob)
|
||||
return
|
||||
|
||||
/obj/item/weapon/pepperspray/afterattack(atom/A as mob|obj, mob/user as mob)
|
||||
if (istype(A, /obj/item/weapon/storage ))
|
||||
return
|
||||
if (istype(A, /obj/effect/proc_holder/spell ))
|
||||
return
|
||||
else if (istype(A, /obj/structure/reagent_dispensers/peppertank) && get_dist(src,A) <= 1)
|
||||
A.reagents.trans_to(src, 45)
|
||||
user << "\blue Pepper spray refilled"
|
||||
playsound(src.loc, 'refill.ogg', 50, 1, -6)
|
||||
return
|
||||
else if (src.reagents.total_volume < 1)
|
||||
user << "\blue [src] is empty!"
|
||||
return
|
||||
playsound(src.loc, 'spray2.ogg', 50, 1, -6)
|
||||
|
||||
var/Sprays[3]
|
||||
for(var/i=1, i<=3, i++) // intialize sprays
|
||||
if(src.reagents.total_volume < 1) break
|
||||
var/obj/effect/decal/D = new/obj/effect/decal(get_turf(src))
|
||||
D.name = "chemicals"
|
||||
D.icon = 'chempuff.dmi'
|
||||
D.create_reagents(15)
|
||||
src.reagents.trans_to(D, 15)
|
||||
|
||||
var/rgbcolor[3]
|
||||
var/finalcolor
|
||||
for(var/datum/reagent/re in D.reagents.reagent_list)
|
||||
if(!finalcolor)
|
||||
rgbcolor = GetColors(re.color)
|
||||
finalcolor = re.color
|
||||
else
|
||||
var/newcolor[3]
|
||||
var/prergbcolor[3]
|
||||
prergbcolor = rgbcolor
|
||||
newcolor = GetColors(re.color)
|
||||
|
||||
rgbcolor[1] = (prergbcolor[1]+newcolor[1])/2
|
||||
rgbcolor[2] = (prergbcolor[2]+newcolor[2])/2
|
||||
rgbcolor[3] = (prergbcolor[3]+newcolor[3])/2
|
||||
|
||||
finalcolor = rgb(rgbcolor[1], rgbcolor[2], rgbcolor[3])
|
||||
|
||||
D.icon += finalcolor
|
||||
|
||||
Sprays[i] = D
|
||||
|
||||
var/direction = get_dir(src, A)
|
||||
var/turf/T = get_turf(A)
|
||||
var/turf/T1 = get_step(T,turn(direction, 90))
|
||||
var/turf/T2 = get_step(T,turn(direction, -90))
|
||||
var/list/the_targets = list(T,T1,T2)
|
||||
|
||||
for(var/i=1, i<=Sprays.len, i++)
|
||||
spawn()
|
||||
var/obj/effect/decal/D = Sprays[i]
|
||||
if(!D) continue
|
||||
|
||||
// Spreads the sprays a little bit
|
||||
var/turf/my_target = pick(the_targets)
|
||||
the_targets -= my_target
|
||||
|
||||
for(var/j=1, j<=rand(6,8), j++)
|
||||
step_towards(D, my_target)
|
||||
D.reagents.reaction(get_turf(D))
|
||||
for(var/atom/t in get_turf(D))
|
||||
D.reagents.reaction(t)
|
||||
sleep(2)
|
||||
del(D)
|
||||
sleep(1)
|
||||
|
||||
if(isrobot(user)) //Cyborgs can clean forever if they keep charged
|
||||
var/mob/living/silicon/robot/janitor = user
|
||||
janitor.cell.charge -= 20
|
||||
var/refill = src.reagents.get_master_reagent_id()
|
||||
spawn(600)
|
||||
src.reagents.add_reagent(refill, 10)
|
||||
|
||||
return
|
||||
|
||||
/obj/item/weapon/pepperspray/examine()
|
||||
set src in usr
|
||||
usr << text("\icon[] [] units of cleaner left!", src, src.reagents.total_volume)
|
||||
..()
|
||||
|
||||
@@ -21,12 +21,6 @@ WELDINGTOOOL
|
||||
origin_tech = "materials=1;engineering=1"
|
||||
|
||||
|
||||
New()
|
||||
if (prob(75))
|
||||
src.pixel_x = rand(0, 16)
|
||||
return
|
||||
|
||||
|
||||
|
||||
// SCREWDRIVER
|
||||
/obj/item/weapon/screwdriver/New()
|
||||
|
||||
@@ -68,7 +68,6 @@ var/global/list/datum/stack_recipe/metal_recipes = list ( \
|
||||
null, \
|
||||
new/datum/stack_recipe("floor tile", /obj/item/stack/tile/steel, 1, 4, 10), \
|
||||
new/datum/stack_recipe("metal rod", /obj/item/stack/rods, 1, 2, 60), \
|
||||
new/datum/stack_recipe("reinforced sheet", /obj/item/stack/sheet/r_metal, 2, 1, 50), \
|
||||
null, \
|
||||
new/datum/stack_recipe("computer frame", /obj/structure/computerframe, 5, one_per_turf = 1), \
|
||||
new/datum/stack_recipe("wall girders", /obj/structure/girder, 2, time = 50, one_per_turf = 1, on_floor = 1), \
|
||||
@@ -92,7 +91,6 @@ var/global/list/datum/stack_recipe/metal_recipes = list ( \
|
||||
// /datum/stack_recipe/New(title, result_type, req_amount, res_amount, max_res_amount, time, one_per_turf, on_floor = 0)
|
||||
var/global/list/datum/stack_recipe/r_metal_recipes = list ( \
|
||||
new/datum/stack_recipe("table parts", /obj/item/weapon/table_parts/reinforced, 2), \
|
||||
new/datum/stack_recipe("metal sheet", /obj/item/stack/sheet/metal, 1, 2, 50), \
|
||||
new/datum/stack_recipe("AI core", /obj/structure/AIcore, 4, one_per_turf = 1), \
|
||||
)
|
||||
|
||||
|
||||
@@ -191,7 +191,8 @@
|
||||
return
|
||||
if (src.amount < R.req_amount*multiplier)
|
||||
return
|
||||
var/O = new R.result_type( usr.loc )
|
||||
var/atom/O = new R.result_type( usr.loc )
|
||||
O.dir = usr.dir
|
||||
if (R.max_res_amount>1)
|
||||
var/obj/item/stack/new_item = O
|
||||
new_item.amount = R.res_amount*multiplier
|
||||
|
||||
@@ -108,6 +108,7 @@
|
||||
//storage_slots = 6
|
||||
can_hold = list(
|
||||
"/obj/item/weapon/flashbang",
|
||||
"/obj/item/weapon/pepperspray",
|
||||
"/obj/item/weapon/handcuffs",
|
||||
"/obj/item/device/flash",
|
||||
"/obj/item/clothing/glasses",
|
||||
|
||||
Reference in New Issue
Block a user