This commit is contained in:
izac112
2023-06-21 19:03:35 +02:00
346 changed files with 5621 additions and 4174 deletions
+9 -9
View File
@@ -36,20 +36,20 @@
/obj/item/weapon/rcd/update_icon()
var/nearest_ten = round((stored_matter/max_stored_matter)*10, 1)
//Just to prevent updates every use
if(ammostate == nearest_ten)
return //No change
ammostate = nearest_ten
cut_overlays()
//Main sprite update
if(!nearest_ten)
icon_state = "[initial(icon_state)]_empty"
else
icon_state = "[initial(icon_state)]"
add_overlay("[initial(icon_state)]_charge[nearest_ten]")
/obj/item/weapon/rcd/proc/perform_effect(var/atom/A, var/time_taken)
@@ -98,12 +98,12 @@
if(user.incapacitated())
world.log << "Two"
return FALSE
var/obj/item/rig_module/device/D = loc
if(!istype(D) || !D?.holder?.wearer == user)
world.log << "Three"
return FALSE
return TRUE
/obj/item/weapon/rcd/attack_self(mob/living/user)
@@ -134,7 +134,7 @@
"Change Window Type" = image(icon = 'icons/mob/radial.dmi', icon_state = "windowtype")
)
*/
var/choice = show_radial_menu(user, user, choices, custom_check = CALLBACK(src, .proc/check_menu, user), tooltips = TRUE)
var/choice = show_radial_menu(user, user, choices, custom_check = CALLBACK(src, PROC_REF(check_menu), user), tooltips = TRUE)
if(!check_menu(user))
return
switch(choice)
@@ -206,7 +206,7 @@
status = rcd_status
delay = rcd_delay
if (status == RCD_DECONSTRUCT)
addtimer(CALLBACK(src, /atom/.proc/update_icon), 11)
addtimer(CALLBACK(src, TYPE_PROC_REF(/atom, update_icon)), 11)
delay -= 11
icon_state = "rcd_end_reverse"
else
@@ -228,7 +228,7 @@
qdel(src)
else
icon_state = "rcd_end"
addtimer(CALLBACK(src, .proc/end), 15)
addtimer(CALLBACK(src, PROC_REF(end)), 15)
/obj/effect/constructing_effect/proc/end()
qdel(src)
+1 -1
View File
@@ -221,7 +221,7 @@
"Random" = radial_image_random
)
var/choice = show_radial_menu(user, src, choices, custom_check = CALLBACK(src, .proc/check_menu, user), require_near = TRUE, tooltips = TRUE)
var/choice = show_radial_menu(user, src, choices, custom_check = CALLBACK(src, PROC_REF(check_menu), user), require_near = TRUE, tooltips = TRUE)
if(!check_menu(user))
return
switch(choice)
@@ -249,8 +249,8 @@
//Make it so the crystal knows if its mob references get deleted to make sure things get cleaned up
/obj/item/capture_crystal/proc/knowyoursignals(mob/living/M, mob/living/U)
RegisterSignal(M, COMSIG_PARENT_QDELETING, .proc/mob_was_deleted, TRUE)
RegisterSignal(U, COMSIG_PARENT_QDELETING, .proc/owner_was_deleted, TRUE)
RegisterSignal(M, COMSIG_PARENT_QDELETING, PROC_REF(mob_was_deleted), TRUE)
RegisterSignal(U, COMSIG_PARENT_QDELETING, PROC_REF(owner_was_deleted), TRUE)
//The basic capture command does most of the registration work.
/obj/item/capture_crystal/proc/capture(mob/living/M, mob/living/U)
@@ -856,4 +856,4 @@
/mob/living
var/capture_crystal = TRUE //If TRUE, the mob is capturable. Otherwise it isn't.
var/capture_caught = FALSE //If TRUE, the mob has already been caught, and so cannot be caught again.
var/capture_caught = FALSE //If TRUE, the mob has already been caught, and so cannot be caught again.
+113 -48
View File
@@ -335,7 +335,9 @@ CIGARETTE PACKETS ARE IN FANCY.DM
/obj/item/clothing/mask/smokable/cigarette/cigar
name = "premium cigar"
desc = "A brown roll of tobacco and... well, you're not quite sure. This thing's huge!"
description_fluff = "While the label does say that this is a 'premium cigar', it really cannot match other types of cigars on the market. Is it a quality cigarette? Perhaps. Was it hand-made with care? No."
description_fluff = "While the label does say that this is a 'premium cigar', it \
really cannot match other types of cigars on the market. Is it a quality \
cigarette? Perhaps. Was it hand-made with care? No."
icon_state = "cigar2"
type_butt = /obj/item/trash/cigbutt/cigarbutt
throw_speed = 0.5
@@ -353,14 +355,22 @@ CIGARETTE PACKETS ARE IN FANCY.DM
/obj/item/clothing/mask/smokable/cigarette/cigar/cohiba
name = "\improper Cohiba Robusto cigar"
desc = "There's little more you could want from a cigar."
description_fluff = "Cohiba has been a popular cigar company for centuries. They are still based out of Cuba and refuse to expand and therefore have a very limited quantity, making their cigars coveted all through known space. Robusto is one of their most popular shapes of cigars."
description_fluff = "Cohiba has been a popular cigar company for centuries. \
They are still based out of Cuba and refuse to expand and therefore have a very \
limited quantity, making their cigars coveted all through known space. Robusto \
is one of their most popular shapes of cigars."
icon_state = "cigar2"
nicotine_amt = 7
/obj/item/clothing/mask/smokable/cigarette/cigar/havana
name = "premium Havanian cigar"
desc = "A cigar fit for only the best of the best."
description_fluff = "'Havanian' is an umbrella term for any cigar made in the typical handmade style of Cuba. This particular cigar is from Gilthari's cigar manufacturers and produced galaxy-wide. While this way of making quality cigars has become slightly bastardized over the years, overall quality has remained relatively the same, even if there is a large quantity of 'Havanian' cigars."
desc = "Save these for the fancy-pantses at the next CentCom black tie reception. \
You can't blow the smoke from such majestic stogies in just anyone's face."
description_fluff = "'Havanian' is an umbrella term for any cigar made in the \
typical handmade style of Cuba. This particular cigar is from Gilthari's cigar \
manufacturers and produced galaxy-wide. While this way of making quality cigars \
has become slightly bastardized over the years, overall quality has remained \
relatively the same, even if there is a large quantity of 'Havanian' cigars."
icon_state = "cigar2"
max_smoketime = 7200
smoketime = 7200
@@ -400,7 +410,9 @@ CIGARETTE PACKETS ARE IN FANCY.DM
/obj/item/clothing/mask/smokable/pipe
name = "smoking pipe"
desc = "A pipe, for smoking. Made of fine, stained cherry wood."
description_fluff = "ClassiCo Accessories and Haberdashers, originating out of Mars, claim to produce products 'for the modern gentlefolk'. Most of their items are high-end and expensive, but they pledge to back their prices up with quality, and usually do."
description_fluff = "ClassiCo Accessories and Haberdashers, originating out of Mars, \
claim to produce products 'for the modern gentlefolk'. Most of their items are high-end \
and expensive, but they pledge to back their prices up with quality, and usually do."
icon_state = "pipe"
item_state = "pipe"
smoketime = 0
@@ -507,7 +519,8 @@ CIGARETTE PACKETS ARE IN FANCY.DM
/obj/item/weapon/reagent_containers/rollingpaper
name = "rolling paper"
desc = "A small, thin piece of easily flammable paper, commonly used for rolling and smoking various dried plants."
description_fluff = "The legalization of certain substances propelled the sale of rolling papers through the roof. Now almost every Trans-stellar produces a variety, often of questionable quality."
description_fluff = "The legalization of certain substances propelled the sale of rolling \
papers through the roof. Now almost every Trans-stellar produces a variety, often of questionable quality."
icon = 'icons/obj/cigarettes.dmi'
icon_state = "cig paper"
volume = 25
@@ -555,77 +568,85 @@ CIGARETTE PACKETS ARE IN FANCY.DM
qdel(src)
/////////
//ZIPPO//
//CHEAP//
/////////
/obj/item/weapon/flame/lighter
name = "cheap lighter"
desc = "A cheap-as-free lighter."
description_fluff = "The 'hand-made in Altair' sticker underneath is a charming way of saying 'Made with prison labour'. It's no wonder the company can sell these things so cheap."
icon = 'icons/obj/items.dmi'
icon_state = "lighter-g"
item_state = "lighter-g"
description_fluff = "The 'hand-made in Altair' sticker underneath is a charming way of \
saying 'Made with prison labour'. It's no wonder the company can sell these things so cheap."
icon = 'icons/obj/lighters.dmi'
icon_state = "lighter"
item_state = "lighter"
w_class = ITEMSIZE_TINY
throwforce = 4
slot_flags = SLOT_BELT
attack_verb = list("burnt", "singed")
var/base_state
/// Sounds
var/activation_sound = 'sound/items/lighter_on.ogg'
var/deactivation_sound = 'sound/items/lighter_off.ogg'
/// Color of the flame and how big the flame is (pulled from Welder code)
var/flame_color = "#FF9933"
var/flame_intensity = 2
/// Color List
var/random_color = FALSE
var/available_colors = list(COLOR_ASSEMBLY_BLACK,
COLOR_ASSEMBLY_BGRAY,
COLOR_ASSEMBLY_WHITE,
COLOR_ASSEMBLY_RED,
COLOR_ASSEMBLY_ORANGE,
COLOR_ASSEMBLY_BEIGE,
COLOR_ASSEMBLY_BROWN,
COLOR_ASSEMBLY_GOLD,
COLOR_ASSEMBLY_YELLOW,
COLOR_ASSEMBLY_GURKHA,
COLOR_ASSEMBLY_LGREEN,
COLOR_ASSEMBLY_GREEN,
COLOR_ASSEMBLY_LBLUE,
COLOR_ASSEMBLY_BLUE,
COLOR_ASSEMBLY_PURPLE,
COLOR_ASSEMBLY_HOT_PINK)
/obj/item/weapon/flame/lighter/zippo
name = "\improper Zippo lighter"
desc = "The zippo."
description_fluff = "Still going after all these years."
icon = 'icons/obj/zippo.dmi'
icon_state = "zippo"
item_state = "zippo"
activation_sound = 'sound/items/zippo_on.ogg'
deactivation_sound = 'sound/items/zippo_off.ogg'
// TODO: Remove this path from POIs and loose maps (it's no longer needed)
/obj/item/weapon/flame/lighter/random
/obj/item/weapon/flame/lighter/random/New()
icon_state = "lighter-[pick("r","c","y","g")]"
item_state = icon_state
base_state = icon_state
// Randomizes Cheap Lighters on Spawn
/obj/item/weapon/flame/lighter/Initialize()
. = ..()
var/image/I = image(icon, "lighter-[pick("trans","tall","matte")]")
I.color = pick(available_colors)
add_overlay(I)
/obj/item/weapon/flame/lighter/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"
icon_state = "lighteron"
playsound(src, activation_sound, 75, 1)
if(istype(src, /obj/item/weapon/flame/lighter/zippo) )
user.visible_message("<span class='rose'>Without even breaking stride, [user] flips open and lights [src] in one smooth movement.</span>")
if(prob(95))
user.visible_message("<span class='notice'>After a few attempts, [user] manages to light the [src].</span>")
else
if(prob(95))
user.visible_message("<span class='notice'>After a few attempts, [user] manages to light the [src].</span>")
to_chat(user, "<span class='warning'>You burn yourself while lighting the lighter.</span>")
if (user.get_left_hand() == src)
user.apply_damage(2,BURN,"l_hand")
else
to_chat(user, "<span class='warning'>You burn yourself while lighting the lighter.</span>")
if (user.get_left_hand() == src)
user.apply_damage(2,BURN,"l_hand")
else
user.apply_damage(2,BURN,"r_hand")
user.visible_message("<span class='notice'>After a few attempts, [user] manages to light the [src], they however burn their finger in the process.</span>")
user.apply_damage(2,BURN,"r_hand")
user.visible_message("<span class='notice'>After a few attempts, [user] manages to light the [src], they however burn their finger in the process.</span>")
set_light(2)
set_light(2, 0.5, "#FF9933")
START_PROCESSING(SSobj, src)
update_icon()
else
lit = 0
icon_state = "[base_state]"
item_state = "[base_state]"
icon_state = "lighter"
playsound(src, deactivation_sound, 75, 1)
if(istype(src, /obj/item/weapon/flame/lighter/zippo) )
user.visible_message("<span class='rose'>You hear a quiet click, as [user] shuts off [src] without even looking at what they're doing.</span>")
else
user.visible_message("<span class='notice'>[user] quietly shuts off the [src].</span>")
user.visible_message("<span class='notice'>[user] quietly shuts off the [src].</span>")
set_light(0)
STOP_PROCESSING(SSobj, src)
update_icon()
return
/obj/item/weapon/flame/lighter/attack(mob/living/carbon/M as mob, mob/living/carbon/user as mob)
if(!istype(M, /mob))
return
@@ -652,6 +673,45 @@ CIGARETTE PACKETS ARE IN FANCY.DM
location.hotspot_expose(700, 5)
return
/////////
//ZIPPO//
/////////
/obj/item/weapon/flame/lighter/zippo
name = "\improper Zippo lighter"
desc = "The zippo."
description_fluff = "Still going after all these years."
icon_state = "zippo"
item_state = "zippo"
activation_sound = 'sound/items/zippo_on.ogg'
deactivation_sound = 'sound/items/zippo_off.ogg'
/obj/item/weapon/flame/lighter/zippo/Initialize()
. = ..()
cut_overlays() //Prevents the Cheap Lighter overlay from appearing on this
/obj/item/weapon/flame/lighter/zippo/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)
user.visible_message("<span class='rose'>Without even breaking stride, [user] flips open and lights [src] in one smooth movement.</span>")
set_light(2, 0.5, "#FF9933")
START_PROCESSING(SSobj, src)
else
lit = 0
icon_state = "[base_state]"
item_state = "[base_state]"
playsound(src, deactivation_sound, 75, 1)
user.visible_message("<span class='rose'>You hear a quiet click, as [user] shuts off [src] without even looking at what they're doing.</span>")
set_light(0)
STOP_PROCESSING(SSobj, src)
return
//Here we add Zippo skins.
/obj/item/weapon/flame/lighter/zippo/black
@@ -708,4 +768,9 @@ CIGARETTE PACKETS ARE IN FANCY.DM
/obj/item/weapon/flame/lighter/zippo/rainbow
name = "\improper rainbow Zippo lighter"
icon_state = "rainbowzippo"
icon_state = "rainbowzippo"
/obj/item/weapon/flame/lighter/zippo/skull
name = "\improper badass Zippo lighter"
desc = "An absolutely badass zippo lighter. Just look at that skull!"
icon_state = "skullzippo"
@@ -33,6 +33,7 @@
var/blanket_type = CENTER
layer = HIDING_LAYER - 0.01 //Stuff shouldn't be able to hide under the blanket on the ground
var/list/attached_blankets = list()
anchored = TRUE
/obj/structure/picnic_blanket_deployed/verb/fold_up()
set name = "Fold up"
@@ -58,7 +58,7 @@
desc = "A deluxe belt with many pouches. It can hold a very wide variety of items, but less items overall than a dedicated belt. Still, it's useful for any explorer who wants to be prepared for anything they might find."
icon = 'icons/inventory/belt/item_vr.dmi'
icon_state = "pathfinder_belt"
item_state = "explorer_belt"
item_state = "pathfinder_belt"
storage_slots = 7 //two more, bringing it on par with normal belts
max_storage_space = ITEMSIZE_COST_NORMAL * 7
@@ -157,6 +157,7 @@
name = "hydroponics belt"
desc = "A belt used to hold most hydroponics supplies. Suprisingly, not green."
icon = 'icons/inventory/belt/item_vr.dmi'
icon_override = 'icons/inventory/belt/mob_vr.dmi'
icon_state = "plantbelt"
item_state = "plantbelt"
storage_slots = 5
@@ -50,7 +50,7 @@ GLOBAL_LIST_INIT(bibleitemstates, list(
var/image/bible_image = image(icon = 'icons/obj/storage.dmi', icon_state = GLOB.biblestates[i])
skins += list("[GLOB.biblenames[i]]" = bible_image)
var/choice = show_radial_menu(user, src, skins, custom_check = CALLBACK(src, .proc/check_menu, user), radius = 40, require_near = TRUE)
var/choice = show_radial_menu(user, src, skins, custom_check = CALLBACK(src, PROC_REF(check_menu), user), radius = 40, require_near = TRUE)
if(!choice)
return FALSE
var/bible_index = GLOB.biblenames.Find(choice)
@@ -112,4 +112,4 @@ GLOBAL_LIST_INIT(bibleitemstates, list(
/obj/item/weapon/storage/bible/attackby(obj/item/weapon/W as obj, mob/user as mob)
if (src.use_sound)
playsound(src, src.use_sound, 50, 1, -5)
..()
..()
@@ -385,16 +385,18 @@
/obj/item/weapon/storage/fancy/cigar
name = "cigar case"
desc = "A case for holding your cigars when you are not smoking them."
description_fluff = "The tastefully engraved palm tree tells you that these 'Palma Grande' premium cigars are only sold on the luxury cruises and resorts of Oasis, though ten separate companies produce them for that purpose galaxy-wide. The standard is however very high."
description_fluff = "The tasteful stained palm case tells you that these 'Palma Grande' premium \
cigars are only sold on the luxury cruises and resorts of Oasis, though ten separate companies \
produce them for that purpose galaxy-wide. The standard is however very high."
icon_state = "cigarcase"
icon = 'icons/obj/cigarettes.dmi'
w_class = ITEMSIZE_TINY
throwforce = 2
slot_flags = SLOT_BELT
storage_slots = 7
storage_slots = 5
can_hold = list(/obj/item/clothing/mask/smokable/cigarette/cigar, /obj/item/trash/cigbutt/cigarbutt)
icon_type = "cigar"
starts_with = list(/obj/item/clothing/mask/smokable/cigarette/cigar = 8)
starts_with = list(/obj/item/clothing/mask/smokable/cigarette/cigar = 5)
/obj/item/weapon/storage/fancy/cigar/Initialize()
. = ..()
@@ -419,7 +421,7 @@
if(open)
icon_state = open_state
if(contents.len >= 1)
add_overlay("cigarcase[contents.len]")
add_overlay("[initial(icon_state)][contents.len]")
else
icon_state = closed_state
@@ -435,6 +437,27 @@
update_icon()
..()
/obj/item/weapon/storage/fancy/cigar/choiba
name = "/improper Choiba cigar case"
desc = "A fancy case for holding your cigars when you are not smoking them."
description_fluff = "The exquisite wooden case bears the markings of the \
Choiba cigar company based out of Cuba. The perfectly humidized case keeps \
the companies signature Cigars in premium condidtion even when traveling \
long distances within a vacuume. The custom case itself can sell for quite \
a lot in some places."
icon_state = "cohibacase"
icon = 'icons/obj/cigarettes.dmi'
icon_type = "cigar"
starts_with = list(/obj/item/clothing/mask/smokable/cigarette/cigar/cohiba = 5)
/obj/item/weapon/storage/fancy/cigar/havana
name = "\improper Havana cigar case"
desc = "A fancy case for holding your cigars when you are not smoking them."
icon_state = "havanacase"
icon = 'icons/obj/cigarettes.dmi'
icon_type = "cigar"
starts_with = list(/obj/item/clothing/mask/smokable/cigarette/cigar/havana = 5)
/*
* Tobacco Bits
*/
@@ -850,12 +850,12 @@
plane = PLANE_PLAYER_HUD_ITEMS
layer = 0.1
alpha = 200
var/weakref/held_item
var/datum/weakref/held_item
/atom/movable/storage_slot/New(newloc, obj/item/held_item)
ASSERT(held_item)
name += held_item.name
src.held_item = weakref(held_item)
src.held_item = WEAKREF(held_item)
/atom/movable/storage_slot/Destroy()
held_item = null