diff --git a/code/modules/client/preference_setup/loadout/loadout_smoking_ch.dm b/code/modules/client/preference_setup/loadout/loadout_smoking_ch.dm index c8818f5016..1cbfb42cf2 100644 --- a/code/modules/client/preference_setup/loadout/loadout_smoking_ch.dm +++ b/code/modules/client/preference_setup/loadout/loadout_smoking_ch.dm @@ -8,4 +8,29 @@ for(var/cigar in (typesof(/obj/item/weapon/storage/fancy/cigar))) var/obj/item/weapon/storage/fancy/cigar/cigar_brand = cigar cigars[initial(cigar_brand.name)] = cigar_brand - gear_tweaks += new/datum/gear_tweak/path(sortAssoc(cigars)) \ No newline at end of file + gear_tweaks += new/datum/gear_tweak/path(sortAssoc(cigars)) +/* // The two below here are the versions outside of a tgui selection prompt. +/datum/gear/sm_lighter/safesmzippo + display_name = "Supermatter Lighter, Hardlight" // Base Supermatter zippo + description = "A State of the Art Lighter holding an active supermatter shard in a containment field, this one is contained with a hardlight barrier." + path = /obj/item/weapon/flame/lighter/safesmzippo + +/datum/gear/sm_lighter/syndismzippo + display_name = "Supermatter Lighter, Phoron" // Syndicate Supermatter zippo + description = "A State of the Art Lighter holding an active supermatter shard in a containment field, this one is contained with a phoron shield." + path = /obj/item/weapon/flame/lighter/syndismzippo +*/ +/datum/gear/sm_lighter + display_name = "Supermatter Lighter Selection" + path = /obj/item/weapon/flame/lighter/supermatter + description = "State of the Art Supermatter Lighters." + +/datum/gear/sm_lighter/New() + ..() + var/list/sm_lighters = list() + for(var/sm_lighter in typesof(/obj/item/weapon/flame/lighter/supermatter)) + if(sm_lighter in typesof(/obj/item/weapon/flame/lighter/supermatter/expsmzippo)) // Removes the experimental/weapon variant of the SM Lighter + continue + var/obj/item/weapon/flame/lighter/supermatter/sm_lighter_type = sm_lighter + sm_lighters[initial(sm_lighter_type.name)] = sm_lighter_type + gear_tweaks += new/datum/gear_tweak/path(sortAssoc(sm_lighters)) diff --git a/icons/obj/zippo_ch.dmi b/icons/obj/zippo_ch.dmi index 98a028f4b2..0f1b9b3f75 100644 Binary files a/icons/obj/zippo_ch.dmi and b/icons/obj/zippo_ch.dmi differ diff --git a/modular_chomp/code/game/objects/items/weapons/cigs_lighters.dm b/modular_chomp/code/game/objects/items/weapons/cigs_lighters.dm index c4d485e14f..f55aebe798 100644 --- a/modular_chomp/code/game/objects/items/weapons/cigs_lighters.dm +++ b/modular_chomp/code/game/objects/items/weapons/cigs_lighters.dm @@ -1,5 +1,5 @@ -/obj/item/weapon/flame/lighter/safesmzippo - name = "Supermatter Zippo" +/obj/item/weapon/flame/lighter/supermatter + name = "Hardlight Supermatter Zippo" desc = "State of the Art Supermatter Lighter." description_fluff = "A zippo style lighter with a tiny supermatter sliver held by a hardlight shield. When lighting a cigar, make sure to hover the tip near the sliver, not against it!" icon = 'icons/obj/zippo_ch.dmi' @@ -8,8 +8,8 @@ activation_sound = 'modular_chomp/sound/items/open.ogg' deactivation_sound = 'sound/items/zippo_off.ogg' -/obj/item/weapon/flame/lighter/syndismzippo - name = "Syndicate SM Zippo" +/obj/item/weapon/flame/lighter/supermatter/syndismzippo + name = "Phoron Supermatter Zippo" // Syndicate SM Lighter desc = "State of the Art Supermatter Lighter." description_fluff = "A red zippo style lighter with a tiny supermatter sliver held by a phoron field." icon = 'icons/obj/zippo_ch.dmi' @@ -18,8 +18,18 @@ activation_sound = 'modular_chomp/sound/items/open.ogg' deactivation_sound = 'sound/items/zippo_off.ogg' +/obj/item/weapon/flame/lighter/supermatter/expsmzippo + name = "Experimental SM Lighter" + desc = "State of the Art Supermatter Lighter" + description_fluff = "A unique take originating from the zippo design, a shard of supermatter placed within lead-lined walls. Cautious, VERY DANGEROUS do NOT touch!" + icon = 'icons/obj/zippo_ch.dmi' + icon_state = "ExpSMzippo" + item_state = "ExpSMzippo" + activation_sound = 'modular_chomp/sound/items/button-open.ogg' + deactivation_sound = 'modular_chomp/sound/items/button-close.ogg' + // safe smzippo -/obj/item/weapon/flame/lighter/safesmzippo/attack_self(mob/living/user) +/obj/item/weapon/flame/lighter/supermatter/attack_self(mob/living/user) if(!base_state) base_state = icon_state if(!lit) @@ -40,10 +50,10 @@ user.apply_damage(3,CLONE,"l_hand") user.apply_damage(4,ELECTROMAG,"l_hand") else - user.apply_damage(1,SEARING,"l_hand") + user.apply_damage(1,SEARING,"r_hand") user.apply_damage(2,ELECTROCUTE,"r_hand") user.apply_damage(3,CLONE,"r_hand") - user.apply_damage(4,ELECTROMAG,"l_hand") + user.apply_damage(4,ELECTROMAG,"r_hand") user.visible_message("After a few attempts, [user] manages to activate the [src], they however sting themselves on the shielding!") set_light(2) @@ -53,7 +63,7 @@ icon_state = "[base_state]" item_state = "[base_state]" playsound(src, deactivation_sound, 75, 1) - if(istype(src, /obj/item/weapon/flame/lighter/safesmzippo) ) + if(istype(src, /obj/item/weapon/flame/lighter/supermatter) ) user.visible_message("You hear a quiet click, as [user] shuts the [src] without even looking at what they're doing.") else user.visible_message("[user] quietly shuts the [src].") @@ -63,7 +73,7 @@ return -/obj/item/weapon/flame/lighter/safesmzippo/attack(mob/living/carbon/M as mob, mob/living/carbon/user as mob) +/obj/item/weapon/flame/lighter/supermatter/attack(mob/living/carbon/M as mob, mob/living/carbon/user as mob) if(!istype(M, /mob)) return @@ -76,21 +86,21 @@ if(M == user) cig.attackby(src, user) else - if(istype(src, /obj/item/weapon/flame/lighter/zippo)) + if(istype(src, /obj/item/weapon/flame/lighter/supermatter)) cig.light("[user] whips the [name] out and holds it for [M].") else cig.light("[user] holds the [name] out for [M], and lights the [cig.name].") else ..() -/obj/item/weapon/flame/lighter/safesmzippo/process() +/obj/item/weapon/flame/lighter/supermatter/process() var/turf/location = get_turf(src) if(location) location.hotspot_expose(700, 5) return // syndicate smzippo -/obj/item/weapon/flame/lighter/syndismzippo/attack_self(mob/living/user) +/obj/item/weapon/flame/lighter/supermatter/syndismzippo/attack_self(mob/living/user) if(!base_state) base_state = icon_state if(!lit) @@ -101,7 +111,7 @@ if(prob(50)) user.visible_message("[user] safely activates the [src] with a push of a button!") else - if(prob(99)) + if(prob(95)) user.visible_message("After a few attempts, [user] manages to excite the supermatter within the [src].") else to_chat(user, "You singe yourself on the phoron shielding the excited supermatter!") @@ -124,7 +134,7 @@ icon_state = "[base_state]" item_state = "[base_state]" playsound(src, deactivation_sound, 75, 1) - if(istype(src, /obj/item/weapon/flame/lighter/syndismzippo) ) + if(istype(src, /obj/item/weapon/flame/lighter/supermatter/syndismzippo) ) user.visible_message("You hear a quiet click, as [user] shuts the [src] without even looking at what they're doing.") else user.visible_message("[user] quietly shuts the [src].") @@ -134,7 +144,7 @@ return -/obj/item/weapon/flame/lighter/syndismzippo/attack(mob/living/carbon/M as mob, mob/living/carbon/user as mob) +/obj/item/weapon/flame/lighter/supermatter/syndismzippo/attack(mob/living/carbon/M as mob, mob/living/carbon/user as mob) if(!istype(M, /mob)) return @@ -147,7 +157,7 @@ if(M == user) cig.attackby(src, user) else - if(istype(src, /obj/item/weapon/flame/lighter/syndismzippo)) + if(istype(src, /obj/item/weapon/flame/lighter/supermatter/syndismzippo)) cig.light("[user] whips the [name] out and holds it for [M].") else cig.light("[user] holds the [name] out for [M], and lights the [cig.name].") @@ -159,3 +169,169 @@ if(location) location.hotspot_expose(700, 5) return + +// Experimental smzippo +/obj/item/weapon/flame/lighter/supermatter/expsmzippo/attack_self(mob/living/user) + if (!base_state) + base_state = icon_state + if (!lit) + lit = 1 + icon_state = "[base_state]on" + item_state = "[base_state]on" + playsound(src, activation_sound, 75, 1) + var/i = rand(1, 100) + switch(i) + if(1 to 22) + to_chat("[user] safely reveals the supermatter shard within the [src]!") + user.visible_message("You safely revealed the supermatter shard within the [src]!") + if (user.get_left_hand() == src) + user.apply_damage(1, IRRADIATE, "l_hand") + else + user.apply_damage(1, IRRADIATE, "r_hand") + if(23 to 33) + to_chat(user, "[user]'s hand slipped and they brush against the supermatter within [src]!") + user.visible_message("You accidentally grazed your hand across the supermatter!") + if (user.get_left_hand() == src) + user.apply_damage(10, IRRADIATE, "l_hand") + user.apply_damage(20, BURN, "l_hand") + user.apply_damage(20, ELECTROCUTE, "l_hand") + user.apply_damage(50, AGONY, "l_hand") + else + user.apply_damage(10, IRRADIATE, "r_hand") + user.apply_damage(20, BURN, "r_hand") + user.apply_damage(20, ELECTROCUTE, "r_hand") + user.apply_damage(50, AGONY, "r_hand") + if(34 to 44) + to_chat(user, "[user] burned themselves on the [src]!") + user.visible_message("You accidentally burn yourself on the [src]!") + if (user.get_left_hand() == src) + user.apply_damage(30, IRRADIATE, "l_hand") + user.apply_damage(20, SEARING, "l_hand") + user.apply_damage(15, BURN, "l_hand") + else + user.apply_damage(30, IRRADIATE, "r_hand") + user.apply_damage(20, SEARING, "r_hand") + user.apply_damage(15, BURN, "r_hand") + if(45 to 55) + to_chat(user, "[user] fumbled the [src] and the supermatter let out sparks!") + user.visible_message("You fumble the [src], letting the supermatter spark as the case opens!") + if (user.get_left_hand() == src) + user.apply_damage(1, ELECTROCUTE, "l_hand") + user.apply_damage(100, ELECTROMAG, "l_hand") + else + user.apply_damage(1, ELECTROCUTE, "r_hand") + user.apply_damage(100, ELECTROMAG, "r_hand") + if(56 to 66) + to_chat(user, "[user] struggles to open their [src], but when they do they get burned by the extreme heat within!") + user.visible_message("You struggle to get the case to open, and when it does the heat that pours out of the [src] burns!") + if (user.get_left_hand() == src) + user.apply_damage(1, IRRADIATE, "l_hand") + user.apply_damage(1, BRUISE, "l_hand") + user.apply_damage(200, BURN, "l_hand") + user.drop_l_hand() + else + user.apply_damage(1, IRRADIATE, "r_hand") + user.apply_damage(1, BRUISE, "r_hand") + user.apply_damage(200, BURN, "r_hand") + user.drop_r_hand() + if(67 to 77) + to_chat(user, "Ouch! While pushing on the release to open the [src], [user]'s finger slipped right as the case opened, pressing their finger firm against the supermatter!") + user.visible_message("You accidentally pushed your finger against the supermatter!") + if (user.get_left_hand() == src) + user.apply_damage(50, HALLOSS, "l_hand") + user.apply_damage(40, IRRADIATE, "l_hand") + user.apply_damage(30, BURN, "l_hand") + user.apply_damage(20, TOX, "l_hand") + user.apply_damage(10, ELECTROCUTE, "l_hand") + user.apply_effect(25, STUTTER) + user.apply_effect(15, SLUR) + user.apply_effect(5, STUN) + else + user.apply_damage(50, HALLOSS, "r_hand") + user.apply_damage(40, IRRADIATE, "r_hand") + user.apply_damage(30, BURN, "r_hand") + user.apply_damage(20, TOX, "r_hand") + user.apply_damage(10, ELECTROCUTE, "r_hand") + user.apply_effect(25, STUTTER) + user.apply_effect(15, SLUR) + user.apply_effect(5, STUN) + if(78 to 88) + to_chat(user, "[user] managed to pinch themselves on the case of their [src]... it could have been worse.") + user.visible_message("You manage to pinch yourself on the case!") + if (user.get_left_hand() == src) + user.apply_damage(1, CLONE, "l_hand") + user.apply_damage(1, HALLOSS, "l_hand") + else + user.apply_damage(1, CLONE, "r_hand") + user.apply_damage(1, HALLOSS, "r_hand") + if(89 to 99) + to_chat(user, "[user] opened the [src] but forgot that you aren't supposed to look at supermatter!") + user.visible_message("You find yourself looking at the supermatter for longer than you should...") + if (user.get_left_hand() == src) + user.apply_damage(15, HALLOSS, "l_hand") + user.apply_effect(5, WEAKEN) + user.apply_damage(15, IRRADIATE, "l_hand") + user.apply_effect(100, EYE_BLUR) + user.apply_effect(505, AGONY) + user.apply_damage(5, OXY) + user.eye_blurry = 10 + else + user.apply_damage(15, HALLOSS, "r_hand") + user.apply_effect(5, WEAKEN) + user.apply_damage(15, IRRADIATE, "l_hand") + user.apply_effect(100, EYE_BLUR) + user.apply_effect(50, AGONY) + user.apply_damage(15, OXY) + user.eye_blurry = 10 + if(100) + to_chat(user, "OH NO! [user] almost dropped their live [src]! Thank goodness they caught it... by the glowing yellow crystal... oh.") + user.visible_message("You almost dropped your [src], thank goodness you caught it! By the glowing crystal within. You find your ears filled with unearthly ringing and your last thought is \"Oh, fuck.\"") + user.drop_r_hand() // To ensure the lighter is dropped <3 + user.drop_l_hand() // To ensure the lighter is dropped <3 + for(var/obj/item/e in user) + user.drop_from_inventory(e) + log_and_message_admins("[user] dusted themselves and caused massive radiation with [src]!",user) + user.dust() + var/rads = 500 + SSradiation.radiate(src, rads) + + set_light(5) + START_PROCESSING(SSobj, src) + else + lit = 0 + icon_state = "[base_state]" + item_state = "[base_state]" + playsound(src, deactivation_sound, 75, 1) + if (istype(src, /obj/item/weapon/flame/lighter/supermatter/expsmzippo)) + user.visible_message("You hear a quiet click, as [user] closes the [src].") + else + user.visible_message("[user] quietly shuts the [src].") + + set_light(0) + STOP_PROCESSING(SSobj, src) + +/obj/item/weapon/flame/lighter/supermatter/expsmzippo/attack(mob/living/carbon/M as mob, mob/living/carbon/user as mob) + if (!istype(M, /mob)) + return + + if (lit == 1) + M.IgniteMob() + add_attack_logs(user, M, "Lit on fire with [src]") + + if (istype(M.wear_mask, /obj/item/clothing/mask/smokable/cigarette) && user.zone_sel.selecting == O_MOUTH && lit) + var/obj/item/clothing/mask/smokable/cigarette/cig = M.wear_mask + if (M == user) + cig.attackby(src, user) + else + if (istype(src, /obj/item/weapon/flame/lighter/supermatter/expsmzippo)) + cig.light("[user] whips the [name] out and holds it for [M].") + else + cig.light("[user] holds the [name] out for [M], and lights the [cig.name].") + else + ..() + +/obj/item/weapon/flame/lighter/supermatter/expsmzippo/process() + var/turf/location = get_turf(src) + if (location) + location.hotspot_expose(700, 5) + return diff --git a/modular_chomp/sound/items/button-close.ogg b/modular_chomp/sound/items/button-close.ogg new file mode 100644 index 0000000000..4139ac6e84 Binary files /dev/null and b/modular_chomp/sound/items/button-close.ogg differ diff --git a/modular_chomp/sound/items/button-open.ogg b/modular_chomp/sound/items/button-open.ogg new file mode 100644 index 0000000000..83bedcdd36 Binary files /dev/null and b/modular_chomp/sound/items/button-open.ogg differ