mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-12 23:53:47 +01:00
Explosion Tweaks and Fixes
This commit is contained in:
@@ -56,6 +56,9 @@
|
||||
use_me = 1 //If it can move, let it emote
|
||||
else canmove = 0
|
||||
return canmove
|
||||
|
||||
|
||||
/mob/living/carbon/brain/ex_act() //you cant blow up brainmobs because it makes transfer_to() freak out when borgs blow up.
|
||||
return
|
||||
|
||||
/mob/living/carbon/brain/binarycheck()
|
||||
return istype(loc, /obj/item/device/mmi/posibrain)
|
||||
@@ -214,9 +214,6 @@
|
||||
stat("Spacepod Integrity", "[!S.health ? "0" : "[(S.health / initial(S.health)) * 100]"]%")
|
||||
|
||||
/mob/living/carbon/human/ex_act(severity)
|
||||
if(!blinded)
|
||||
flick("flash", flash)
|
||||
|
||||
var/shielded = 0
|
||||
var/b_loss = null
|
||||
var/f_loss = null
|
||||
@@ -235,8 +232,8 @@
|
||||
|
||||
while(limbs_affected != 0)
|
||||
processing_dismember = pick(organs)
|
||||
if(processing_dismember.name != "chest" && processing_dismember.name != "groin")
|
||||
processing_dismember.dismember_limb()
|
||||
if(processing_dismember.name != "chest" && processing_dismember.name != "groin" && processing_dismember.name != "head")
|
||||
processing_dismember.droplimb(1,1,1)
|
||||
limbs_affected -= 1
|
||||
|
||||
|
||||
@@ -260,7 +257,7 @@
|
||||
while(limbs_affected != 0)
|
||||
processing_dismember = pick(organs)
|
||||
if(processing_dismember.name != "chest" && processing_dismember.name != "groin" && processing_dismember.name != "head")
|
||||
processing_dismember.dismember_limb()
|
||||
processing_dismember.droplimb(1,1,1)
|
||||
limbs_affected -= 1
|
||||
|
||||
else
|
||||
@@ -269,8 +266,8 @@
|
||||
|
||||
while(limbs_affected != 0)
|
||||
processing_dismember = pick(organs)
|
||||
if(processing_dismember.name != "chest" && processing_dismember.name != "groin")
|
||||
processing_dismember.dismember_limb()
|
||||
if(processing_dismember.name != "chest" && processing_dismember.name != "groin" && processing_dismember.name != "head")
|
||||
processing_dismember.droplimb(1,1,1)
|
||||
limbs_affected -= 1
|
||||
|
||||
if (!istype(l_ear, /obj/item/clothing/ears/earmuffs) && !istype(r_ear, /obj/item/clothing/ears/earmuffs))
|
||||
@@ -292,7 +289,7 @@
|
||||
while(limbs_affected != 0)
|
||||
processing_dismember = pick(organs)
|
||||
if(processing_dismember.name != "chest" && processing_dismember.name != "groin" && processing_dismember.name != "head")
|
||||
processing_dismember.dismember_limb()
|
||||
processing_dismember.droplimb(1,1,1)
|
||||
limbs_affected -= 1
|
||||
|
||||
if (!istype(l_ear, /obj/item/clothing/ears/earmuffs) && !istype(r_ear, /obj/item/clothing/ears/earmuffs))
|
||||
@@ -302,23 +299,15 @@
|
||||
Paralyse(10)
|
||||
|
||||
var/update = 0
|
||||
|
||||
// focus most of the blast on one organ
|
||||
var/datum/organ/external/take_blast = pick(organs)
|
||||
update |= take_blast.take_damage(b_loss * 0.9, f_loss * 0.9, used_weapon = "Explosive blast")
|
||||
|
||||
// distribute the remaining 10% on all limbs equally
|
||||
b_loss *= 0.1
|
||||
f_loss *= 0.1
|
||||
|
||||
var/weapon_message = "Explosive Blast"
|
||||
|
||||
for(var/datum/organ/external/temp in organs)
|
||||
switch(temp.name)
|
||||
if("head")
|
||||
update |= temp.take_damage(b_loss * 0.2, f_loss * 0.2, used_weapon = weapon_message)
|
||||
if("chest")
|
||||
update |= temp.take_damage(b_loss * 0.4, f_loss * 0.4, used_weapon = weapon_message)
|
||||
if("groin")
|
||||
update |= temp.take_damage(b_loss * 0.1, f_loss * 0.1, used_weapon = weapon_message)
|
||||
if("l_arm")
|
||||
update |= temp.take_damage(b_loss * 0.05, f_loss * 0.05, used_weapon = weapon_message)
|
||||
if("r_arm")
|
||||
@@ -328,15 +317,16 @@
|
||||
if("r_leg")
|
||||
update |= temp.take_damage(b_loss * 0.05, f_loss * 0.05, used_weapon = weapon_message)
|
||||
if("r_foot")
|
||||
update |= temp.take_damage(b_loss * 0.05, f_loss * 0.05, used_weapon = weapon_message)
|
||||
update |= temp.take_damage(b_loss * 0.025, f_loss * 0.025, used_weapon = weapon_message)
|
||||
if("l_foot")
|
||||
update |= temp.take_damage(b_loss * 0.05, f_loss * 0.05, used_weapon = weapon_message)
|
||||
if("r_arm")
|
||||
update |= temp.take_damage(b_loss * 0.05, f_loss * 0.05, used_weapon = weapon_message)
|
||||
if("l_arm")
|
||||
update |= temp.take_damage(b_loss * 0.05, f_loss * 0.05, used_weapon = weapon_message)
|
||||
update |= temp.take_damage(b_loss * 0.025, f_loss * 0.025, used_weapon = weapon_message)
|
||||
if("r_hand")
|
||||
update |= temp.take_damage(b_loss * 0.025, f_loss * 0.025, used_weapon = weapon_message)
|
||||
if("l_hand")
|
||||
update |= temp.take_damage(b_loss * 0.025, f_loss * 0.025, used_weapon = weapon_message)
|
||||
if(update) UpdateDamageIcon()
|
||||
|
||||
..()
|
||||
|
||||
/mob/living/carbon/human/blob_act()
|
||||
if(stat == 2) return
|
||||
|
||||
@@ -190,7 +190,7 @@
|
||||
var/f_loss = null
|
||||
switch (severity)
|
||||
if (1.0)
|
||||
del(src)
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
if (2.0)
|
||||
@@ -255,7 +255,7 @@
|
||||
if (Victim) return // can't attack while eating!
|
||||
|
||||
if (health > -100)
|
||||
|
||||
|
||||
M.do_attack_animation(src)
|
||||
visible_message("<span class='danger'> The [M.name] has glomped [src]!</span>", \
|
||||
"<span class='userdanger'> The [M.name] has glomped [src]!</span>")
|
||||
@@ -338,7 +338,7 @@
|
||||
var/damage = rand(1, 3)
|
||||
L.amount_grown = min(L.amount_grown + damage, L.max_grown)
|
||||
adjustBruteLoss(damage)
|
||||
|
||||
|
||||
/mob/living/carbon/slime/attack_hand(mob/living/carbon/human/M as mob)
|
||||
if (!ticker)
|
||||
M << "You cannot attack people before the game has started."
|
||||
|
||||
@@ -462,26 +462,18 @@
|
||||
..()
|
||||
|
||||
/mob/living/carbon/monkey/ex_act(severity)
|
||||
if(!blinded)
|
||||
flick("flash", flash)
|
||||
|
||||
..()
|
||||
switch(severity)
|
||||
if(1.0)
|
||||
if (stat != 2)
|
||||
adjustBruteLoss(200)
|
||||
health = 100 - getOxyLoss() - getToxLoss() - getFireLoss() - getBruteLoss()
|
||||
gib()
|
||||
return
|
||||
if(2.0)
|
||||
if (stat != 2)
|
||||
adjustBruteLoss(60)
|
||||
adjustFireLoss(60)
|
||||
health = 100 - getOxyLoss() - getToxLoss() - getFireLoss() - getBruteLoss()
|
||||
adjustBruteLoss(60)
|
||||
adjustFireLoss(60)
|
||||
if(3.0)
|
||||
if (stat != 2)
|
||||
adjustBruteLoss(30)
|
||||
health = 100 - getOxyLoss() - getToxLoss() - getFireLoss() - getBruteLoss()
|
||||
adjustBruteLoss(30)
|
||||
if (prob(50))
|
||||
Paralyse(10)
|
||||
else
|
||||
return
|
||||
|
||||
/mob/living/carbon/monkey/blob_act()
|
||||
|
||||
@@ -33,6 +33,11 @@
|
||||
/mob/living/proc/InCritical()
|
||||
return (src.health < 0 && src.health > -95.0 && stat == UNCONSCIOUS)
|
||||
|
||||
/mob/living/ex_act(severity)
|
||||
..()
|
||||
if(client && !eye_blind)
|
||||
flick("flash", src.flash)
|
||||
|
||||
/mob/living/proc/updatehealth()
|
||||
if(status_flags & GODMODE)
|
||||
health = 100
|
||||
|
||||
@@ -467,14 +467,11 @@ var/list/ai_verbs_default = list(
|
||||
..()
|
||||
|
||||
/mob/living/silicon/ai/ex_act(severity)
|
||||
if(!blinded)
|
||||
flick("flash", flash)
|
||||
..()
|
||||
|
||||
switch(severity)
|
||||
if(1.0)
|
||||
if (stat != 2)
|
||||
adjustBruteLoss(100)
|
||||
adjustFireLoss(100)
|
||||
gib()
|
||||
if(2.0)
|
||||
if (stat != 2)
|
||||
adjustBruteLoss(60)
|
||||
@@ -483,7 +480,7 @@ var/list/ai_verbs_default = list(
|
||||
if (stat != 2)
|
||||
adjustBruteLoss(30)
|
||||
|
||||
updatehealth()
|
||||
return
|
||||
|
||||
|
||||
/mob/living/silicon/ai/Topic(href, href_list)
|
||||
|
||||
@@ -183,23 +183,22 @@
|
||||
src << "<font color=green>You feel an electric surge run through your circuitry and become acutely aware at how lucky you are that you can still feel at all.</font>"
|
||||
|
||||
/mob/living/silicon/pai/ex_act(severity)
|
||||
if(!blinded)
|
||||
flick("flash", src.flash)
|
||||
..()
|
||||
|
||||
switch(severity)
|
||||
if(1.0)
|
||||
if (src.stat != 2) //Let's not have two of these instantly kill you.
|
||||
adjustBruteLoss(45)
|
||||
adjustFireLoss(45)
|
||||
if (src.stat != 2)
|
||||
adjustBruteLoss(100)
|
||||
adjustFireLoss(100)
|
||||
if(2.0)
|
||||
if (src.stat != 2)
|
||||
adjustBruteLoss(30)
|
||||
adjustFireLoss(30)
|
||||
adjustBruteLoss(60)
|
||||
adjustFireLoss(60)
|
||||
if(3.0)
|
||||
if (src.stat != 2)
|
||||
adjustBruteLoss(20)
|
||||
adjustBruteLoss(30)
|
||||
|
||||
src.updatehealth()
|
||||
return
|
||||
|
||||
|
||||
// See software.dm for Topic()
|
||||
|
||||
@@ -514,16 +514,10 @@ var/list/robot_verbs_default = list(
|
||||
|
||||
|
||||
/mob/living/silicon/robot/ex_act(severity)
|
||||
if(!blinded)
|
||||
flick("flash", flash)
|
||||
|
||||
switch(severity)
|
||||
if(1.0)
|
||||
if (stat != 2)
|
||||
adjustBruteLoss(100)
|
||||
adjustFireLoss(100)
|
||||
gib()
|
||||
return
|
||||
gib()
|
||||
return
|
||||
if(2.0)
|
||||
if (stat != 2)
|
||||
adjustBruteLoss(60)
|
||||
@@ -531,8 +525,7 @@ var/list/robot_verbs_default = list(
|
||||
if(3.0)
|
||||
if (stat != 2)
|
||||
adjustBruteLoss(30)
|
||||
|
||||
updatehealth()
|
||||
return
|
||||
|
||||
|
||||
/mob/living/silicon/robot/meteorhit(obj/O as obj)
|
||||
|
||||
@@ -477,11 +477,9 @@
|
||||
return
|
||||
|
||||
/mob/living/simple_animal/ex_act(severity)
|
||||
if(!blinded)
|
||||
flick("flash", flash)
|
||||
..()
|
||||
switch (severity)
|
||||
if (1.0)
|
||||
adjustBruteLoss(500)
|
||||
gib()
|
||||
return
|
||||
|
||||
|
||||
@@ -98,7 +98,9 @@
|
||||
|
||||
bullet_act(var/obj/item/projectile/Proj)
|
||||
if(istype(Proj ,/obj/item/projectile/beam)||istype(Proj,/obj/item/projectile/bullet))
|
||||
if(!istype(Proj ,/obj/item/projectile/lasertag) && !istype(Proj ,/obj/item/projectile/practice) )
|
||||
if((Proj.damage_type == BURN) || (Proj.damage_type == BRUTE))
|
||||
message_admins("[key_name_admin(Proj.firer)] triggered a fueltank explosion.")
|
||||
log_game("[key_name(Proj.firer)] triggered a fueltank explosion.")
|
||||
explode()
|
||||
|
||||
blob_act()
|
||||
@@ -107,64 +109,8 @@
|
||||
ex_act()
|
||||
explode()
|
||||
|
||||
|
||||
/obj/structure/reagent_dispensers/fueltank/examine()
|
||||
set src in view()
|
||||
..()
|
||||
if (!(usr in view(2)) && usr!=src.loc) return
|
||||
if (modded)
|
||||
usr << "\red Fuel faucet is wrenched open, leaking the fuel!"
|
||||
if(rig)
|
||||
usr << "<span class='notice'>There is some kind of device rigged to the tank."
|
||||
|
||||
/obj/structure/reagent_dispensers/fueltank/attack_hand()
|
||||
if (rig)
|
||||
usr.visible_message("[usr] begins to detach [rig] from \the [src].", "You begin to detach [rig] from \the [src]")
|
||||
if(do_after(usr, 20))
|
||||
usr.visible_message("\blue [usr] detaches [rig] from \the [src].", "\blue You detach [rig] from \the [src]")
|
||||
rig.loc = get_turf(usr)
|
||||
rig = null
|
||||
overlays = new/list()
|
||||
|
||||
/obj/structure/reagent_dispensers/fueltank/attackby(obj/item/weapon/W as obj, mob/user as mob, params)
|
||||
if (istype(W,/obj/item/weapon/wrench))
|
||||
user.visible_message("[user] wrenches [src]'s faucet [modded ? "closed" : "open"].", \
|
||||
"You wrench [src]'s faucet [modded ? "closed" : "open"]")
|
||||
modded = modded ? 0 : 1
|
||||
if (modded)
|
||||
leak_fuel(amount_per_transfer_from_this)
|
||||
if (istype(W,/obj/item/device/assembly_holder))
|
||||
if (rig)
|
||||
user << "\red There is another device in the way."
|
||||
return ..()
|
||||
user.visible_message("[user] begins rigging [W] to \the [src].", "You begin rigging [W] to \the [src]")
|
||||
if(do_after(user, 20))
|
||||
user.visible_message("\blue [user] rigs [W] to \the [src].", "\blue You rig [W] to \the [src]")
|
||||
|
||||
var/obj/item/device/assembly_holder/H = W
|
||||
if (istype(H.a_left,/obj/item/device/assembly/igniter) || istype(H.a_right,/obj/item/device/assembly/igniter))
|
||||
msg_admin_attack("[key_name_admin(user)] rigged fueltank at ([loc.x],[loc.y],[loc.z]) for explosion.")
|
||||
log_game("[key_name(user)] rigged fueltank at ([loc.x],[loc.y],[loc.z]) for explosion.")
|
||||
|
||||
rig = W
|
||||
user.drop_item()
|
||||
W.loc = src
|
||||
|
||||
var/icon/test = getFlatIcon(W)
|
||||
test.Shift(NORTH,1)
|
||||
test.Shift(EAST,6)
|
||||
overlays += test
|
||||
|
||||
return ..()
|
||||
|
||||
|
||||
/obj/structure/reagent_dispensers/fueltank/proc/explode()
|
||||
if (reagents.total_volume > 500)
|
||||
explosion(src.loc,1,2,4)
|
||||
else if (reagents.total_volume > 100)
|
||||
explosion(src.loc,0,1,3)
|
||||
else
|
||||
explosion(src.loc,-1,1,2)
|
||||
explosion(src.loc,0,1,3)
|
||||
if(src)
|
||||
del(src)
|
||||
|
||||
@@ -173,37 +119,6 @@
|
||||
explode()
|
||||
return ..()
|
||||
|
||||
/obj/structure/reagent_dispensers/fueltank/Move()
|
||||
..()
|
||||
if(modded)
|
||||
leak_fuel(amount_per_transfer_from_this)
|
||||
if(rig)
|
||||
rig.process_movement()
|
||||
|
||||
/obj/structure/reagent_dispensers/fueltank/proc/leak_fuel(amount)
|
||||
if (reagents.total_volume == 0)
|
||||
return
|
||||
|
||||
amount = min(amount, reagents.total_volume)
|
||||
reagents.remove_reagent("fuel",amount)
|
||||
// new /obj/effect/decal/cleanable/liquid_fuel(src.loc, amount)
|
||||
|
||||
/obj/structure/reagent_dispensers/fueltank/HasProximity(atom/movable/AM)
|
||||
if(rig)
|
||||
rig.HasProximity(AM)
|
||||
|
||||
/obj/structure/reagent_dispensers/fueltank/Crossed(atom/movable/AM)
|
||||
if(rig)
|
||||
rig.Crossed(AM)
|
||||
|
||||
/obj/structure/reagent_dispensers/fueltank/hear_talk(mob/living/M, msg)
|
||||
if(rig)
|
||||
rig.hear_talk(M, msg)
|
||||
|
||||
/obj/structure/reagent_dispensers/fueltank/Bump()
|
||||
..()
|
||||
if(rig)
|
||||
rig.process_movement()
|
||||
|
||||
/obj/structure/reagent_dispensers/peppertank
|
||||
name = "Pepper Spray Refiller"
|
||||
|
||||
Reference in New Issue
Block a user