Skip to content
This repository has been archived by the owner on Aug 21, 2024. It is now read-only.

Commit

Permalink
problems fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Dgeen committed Jun 24, 2024
1 parent bfcf2ca commit ee97ab8
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 8 deletions.
2 changes: 1 addition & 1 deletion modular_RUtgmc/code/game/objects/machinery/deployable.dm
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/obj/machinery/deployable/ex_act(severity)
if(CHECK_BITFIELD(resistance_flags, INDESTRUCTIBLE))
return FALSE
take_damage(severity, damage_flag = BOMB, effects = TRUE)
take_damage(severity, armor_type = BOMB, effects = TRUE)
14 changes: 7 additions & 7 deletions modular_RUtgmc/code/game/objects/obj_defense.dm
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,18 @@
return
take_damage(severity, BRUTE, BOMB, FALSE, direction)

/obj/take_damage(damage_amount, damage_type = BRUTE, damage_flag = "", effects = TRUE, attack_dir, armour_penetration = 0)
/obj/take_damage(damage_amount, damage_type = BRUTE, armor_type = null, effects = TRUE, attack_dir, armour_penetration = 0, mob/living/blame_mob)
if(QDELETED(src))
CRASH("[src] taking damage after deletion")
if(!damage_amount)
return
if(effects)
play_attack_sound(damage_amount, damage_type, damage_flag)
play_attack_sound(damage_amount, damage_type, armor_type)
if((resistance_flags & INDESTRUCTIBLE) || obj_integrity <= 0)
return

if(damage_flag)
damage_amount = round(modify_by_armor(damage_amount, damage_flag, armour_penetration), DAMAGE_PRECISION)
if(armor_type)
damage_amount = round(modify_by_armor(damage_amount, armor_type, armour_penetration, null, attack_dir), DAMAGE_PRECISION)
if(damage_amount < DAMAGE_PRECISION)
return
. = damage_amount
Expand All @@ -26,13 +26,13 @@

//BREAKING FIRST
if(integrity_failure && obj_integrity <= integrity_failure)
obj_break(damage_flag)
obj_break(armor_type)

//DESTROYING SECOND
if(obj_integrity <= 0)
if(damage_flag == BOMB)
if(armor_type == BOMB)
on_explosion_destruction(damage_amount, attack_dir)
obj_destruction(damage_amount, damage_type, damage_flag)
obj_destruction(damage_amount, damage_type, armor_type, blame_mob)

/obj/proc/on_explosion_destruction(severity, direction)
return
1 change: 1 addition & 0 deletions modular_RUtgmc/code/modules/cm_preds/yaut_items.dm
Original file line number Diff line number Diff line change
Expand Up @@ -963,6 +963,7 @@
new /obj/item/tool/surgery/healing_gel/(src)

/obj/item/storage/medicomp/update_icon()
. = ..()
if(!contents.len)
icon_state = "medicomp_open"
else
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -291,6 +291,7 @@
update_icon()

/obj/item/weapon/yautja/combistick/update_icon()
. = ..()
if(item_flags & WIELDED)
item_state = "combistick_w"
else if(!on)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -238,6 +238,7 @@
. += span_notice("This thing looks like an alien rifle of some kind. Strange.")

/obj/item/weapon/gun/energy/yautja/plasmarifle/update_icon()
. = ..()
if(last_regen < rounds + max_rounds / 5 || last_regen > rounds || rounds > max_rounds / 1.05)
var/new_icon_state = rounds <= 15 ? null : icon_state + "[round(rounds/(max_rounds / 3), 1)]"
update_special_overlay(new_icon_state)
Expand Down
1 change: 1 addition & 0 deletions modular_RUtgmc/code/modules/surgery/surgery_tools.dm
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@
var/loaded = TRUE

/obj/item/tool/surgery/healing_gun/update_icon()
. = ..()
if(loaded)
icon_state = "healing_gun"
else
Expand Down

0 comments on commit ee97ab8

Please sign in to comment.