diff --git a/code/datums/supplypacks.dm b/code/datums/supplypacks.dm index eed8492ffd..1bf774c850 100644 --- a/code/datums/supplypacks.dm +++ b/code/datums/supplypacks.dm @@ -50,7 +50,6 @@ var/list/all_supply_groups = list("Operations","Security","Hospitality","Enginee /obj/item/weapon/storage/box/swabs, /obj/item/weapon/storage/box/swabs, /obj/item/weapon/storage/box/swabs, - /obj/item/weapon/storage/box/slides, /obj/item/device/uv_light, /obj/item/weapon/reagent_containers/spray/luminol) cost = 30 @@ -775,7 +774,7 @@ var/list/all_supply_groups = list("Operations","Security","Hospitality","Enginee cost = 125 containertype = /obj/structure/closet/crate/secure/weapon containername = "Experimental weapons crate" - access = access_heads + access = access_armory group = "Security" /datum/supply_packs/randomised/armor diff --git a/code/game/objects/items/weapons/storage/belt.dm b/code/game/objects/items/weapons/storage/belt.dm index f977830ef3..6f93f03df2 100644 --- a/code/game/objects/items/weapons/storage/belt.dm +++ b/code/game/objects/items/weapons/storage/belt.dm @@ -136,7 +136,6 @@ /obj/item/weapon/melee/baton, /obj/item/weapon/gun/energy/taser, /obj/item/weapon/flame/lighter, - /obj/item/clothing/glasses/hud/security, /obj/item/device/flashlight, /obj/item/device/pda, /obj/item/device/radio/headset, @@ -166,7 +165,6 @@ /obj/item/weapon/forensics/sample_kit/powder, /obj/item/weapon/forensics/swab, /obj/item/device/uv_light, - /obj/item/weapon/forensics/slide, /obj/item/weapon/forensics/sample_kit, /obj/item/weapon/photo, /obj/item/device/camera_film, diff --git a/code/modules/admin/verbs/mapping.dm b/code/modules/admin/verbs/mapping.dm index 29d2b95d88..5661097aab 100644 --- a/code/modules/admin/verbs/mapping.dm +++ b/code/modules/admin/verbs/mapping.dm @@ -140,7 +140,6 @@ var/list/debug_verbs = list ( ,/client/proc/ticklag ,/client/proc/cmd_admin_grantfullaccess ,/client/proc/kaboom - ,/client/proc/splash ,/client/proc/cmd_admin_areatest ,/client/proc/cmd_admin_rejuvenate ,/datum/admins/proc/show_traitor_panel diff --git a/code/modules/detectivework/microscope/microscope.dm b/code/modules/detectivework/microscope/microscope.dm index 5fd31a555c..3bc596fb57 100644 --- a/code/modules/detectivework/microscope/microscope.dm +++ b/code/modules/detectivework/microscope/microscope.dm @@ -16,7 +16,7 @@ user << "There is already a slide in the microscope." return - if(istype(W, /obj/item/weapon/forensics/slide) || istype(W, /obj/item/weapon/sample/print)) + if(istype(W, /obj/item/weapon/forensics/swab)|| istype(W, /obj/item/weapon/sample/fibers) || istype(W, /obj/item/weapon/sample/print)) user << "You insert \the [W] into the microscope." user.unEquip(W) W.forceMove(src) @@ -33,6 +33,7 @@ user << "The microscope whirrs as you examine \the [sample]." if(!do_after(user, 25) || !sample) + user << "You stop examining \the [sample]." return user << "Printing findings now..." @@ -41,32 +42,27 @@ report.overlays = list("paper_stamped") report_num++ - if(istype(sample, /obj/item/weapon/forensics/slide)) - var/obj/item/weapon/forensics/slide/slide = sample - if(slide.has_swab) - var/obj/item/weapon/forensics/swab/swab = slide.has_swab + if(istype(sample, /obj/item/weapon/forensics/swab)) + var/obj/item/weapon/forensics/swab/swab = sample - report.name = "GSR report #[++report_num]: [swab.name]" - report.info = "Scanned item:
[swab.name]

" + report.name = "GSR report #[++report_num]: [swab.name]" + report.info = "Scanned item:
[swab.name]

" - if(swab.gsr) - report.info += "Residue from a [swab.gsr] bullet detected." - else - report.info += "No gunpowder residue found." - - else if(slide.has_sample) - var/obj/item/weapon/sample/fibers/fibers = slide.has_sample - report.name = "Fiber report #[++report_num]: [fibers.name]" - report.info = "Scanned item:
[fibers.name]

" - if(fibers.evidence) - report.info = "Molecular analysis on provided sample has determined the presence of unique fiber strings.

" - for(var/fiber in fibers.evidence) - report.info += "Most likely match for fibers: [fiber]

" - else - report.info += "No fibers found." + if(swab.gsr) + report.info += "Residue from a [swab.gsr] bullet detected." else - report.name = "Empty slide report #[report_num]" - report.info = "Evidence suggests that there's nothing in this slide." + report.info += "No gunpowder residue found." + + else if(istype(sample, /obj/item/weapon/sample/fibers)) + var/obj/item/weapon/sample/fibers/fibers = sample + report.name = "Fiber report #[++report_num]: [fibers.name]" + report.info = "Scanned item:
[fibers.name]

" + if(fibers.evidence) + report.info = "Molecular analysis on provided sample has determined the presence of unique fiber strings.

" + for(var/fiber in fibers.evidence) + report.info += "Most likely match for fibers: [fiber]

" + else + report.info += "No fibers found." else if(istype(sample, /obj/item/weapon/sample/print)) report.name = "Fingerprint report #[report_num]: [sample.name]" report.info = "Fingerprint analysis report #[report_num]: [sample.name]
" diff --git a/code/modules/detectivework/microscope/slides.dm b/code/modules/detectivework/microscope/slides.dm deleted file mode 100644 index 8226e6a51e..0000000000 --- a/code/modules/detectivework/microscope/slides.dm +++ /dev/null @@ -1,42 +0,0 @@ -/obj/item/weapon/forensics/slide - name = "microscope slide" - desc = "A pair of thin glass panes used in the examination of samples beneath a microscope." - icon_state = "slide" - var/obj/item/weapon/forensics/swab/has_swab - var/obj/item/weapon/sample/fibers/has_sample - -/obj/item/weapon/forensics/slide/attackby(var/obj/item/weapon/W, var/mob/user) - if(has_swab || has_sample) - user << "There is already a sample in the slide." - return - if(istype (W, /obj/item/weapon/forensics/swab)) - has_swab = W - else if(istype(W, /obj/item/weapon/sample/fibers)) - has_sample = W - else - user << "You don't think this will fit." - return - user << "You insert the sample into the slide." - user.unEquip(W) - W.forceMove(src) - update_icon() - -/obj/item/weapon/forensics/slide/attack_self(var/mob/user) - if(has_swab || has_sample) - user << "You remove \the sample from \the [src]." - if(has_swab) - has_swab.loc = get_turf(src) - has_swab = null - if(has_sample) - has_sample.forceMove(get_turf(src)) - has_sample = null - update_icon() - return - -/obj/item/weapon/forensics/slide/update_icon() - if(!has_swab && !has_sample) - icon_state = "slide" - else if(has_swab) - icon_state = "slideswab" - else if(has_sample) - icon_state = "slidefiber" diff --git a/code/modules/detectivework/tools/storage.dm b/code/modules/detectivework/tools/storage.dm index 58cbcbf594..e0cdabaafd 100644 --- a/code/modules/detectivework/tools/storage.dm +++ b/code/modules/detectivework/tools/storage.dm @@ -11,16 +11,6 @@ for(var/i=0;iYou reset the machine's memory." else user.set_machine(src) interact(user) @@ -76,7 +72,12 @@ dat += "Linked account: [linked_account ? linked_account.owner_name : "None"]
" dat += "[cash_locked? "Unlock" : "Lock"] Cash Box | " dat += "Custom Order
" - for(var/i=1, i<=transaction_logs.len, i++) + + if(item_list.len) + dat += get_current_transaction() + dat += "
" + + for(var/i=transaction_logs.len, i>=1, i--) dat += "[transaction_logs[i]]
" if(transaction_logs.len) @@ -118,12 +119,46 @@ if (!t_purpose || !Adjacent(usr)) return transaction_purpose = t_purpose item_list += t_purpose - var/t_amount = input("Enter price", "New price") as num + var/t_amount = round(input("Enter price", "New price") as num) if (!t_amount || !Adjacent(usr)) return transaction_amount += t_amount price_list += t_amount playsound(src, 'sound/machines/twobeep.ogg', 25) - src.visible_message("\icon[src][transaction_purpose]: [transaction_amount] Thaler\s.") + src.visible_message("\icon[src][transaction_purpose]: [t_amount] Thaler\s.") + if("set_amount") + var/item_name = locate(href_list["item"]) + var/n_amount = round(input("Enter amount", "New amount") as num) + n_amount = Clamp(n_amount, 0, 20) + if (!item_list[item_name] || !Adjacent(usr)) return + transaction_amount += (n_amount - item_list[item_name]) * price_list[item_name] + if(!n_amount) + item_list -= item_name + price_list -= item_name + else + item_list[item_name] = n_amount + if("subtract") + var/item_name = locate(href_list["item"]) + if(item_name) + transaction_amount -= price_list[item_name] + item_list[item_name]-- + if(item_list[item_name] <= 0) + item_list -= item_name + price_list -= item_name + if("add") + var/item_name = locate(href_list["item"]) + if(item_list[item_name] >= 20) return + transaction_amount += price_list[item_name] + item_list[item_name]++ + if("clear") + var/item_name = locate(href_list["item"]) + if(item_name) + transaction_amount -= price_list[item_name] * item_list[item_name] + item_list -= item_name + price_list -= item_name + else + transaction_amount = 0 + item_list.Cut() + price_list.Cut() if("reset_log") transaction_logs.Cut() usr << "\icon[src]Transaction log reset." @@ -180,18 +215,18 @@ if (!transaction_amount) return - if(!confirm(I)) + if (cash_open) + playsound(src, 'sound/machines/buzz-sigh.ogg', 25) + usr << "\icon[src]The cash box is open." + return + + if((item_list.len > 1 || item_list[item_list[1]] > 1) && !confirm(I)) return if (!linked_account) usr.visible_message("\icon[src]Unable to connect to linked account.") return - if (cash_open) - playsound(src, 'sound/machines/buzz-sigh.ogg', 25) - usr << "\icon[src]The cash box is open." - return - // Access account for transaction if(check_account()) var/datum/money_account/D = get_account(I.associated_account_number) @@ -245,14 +280,14 @@ if (!transaction_amount) return - if(!confirm(E)) - return - if (cash_open) playsound(src, 'sound/machines/buzz-sigh.ogg', 25) usr << "\icon[src]The cash box is open." return + if((item_list.len > 1 || item_list[item_list[1]] > 1) && !confirm(E)) + return + // Access account for transaction if(check_account()) if(transaction_amount > E.worth) @@ -283,14 +318,14 @@ if (!transaction_amount) return - if(!confirm(SC)) - return - if (cash_open) playsound(src, 'sound/machines/buzz-sigh.ogg', 25) usr << "\icon[src]The cash box is open." return + if((item_list.len > 1 || item_list[item_list[1]] > 1) && !confirm(SC)) + return + if(transaction_amount > SC.worth) src.visible_message("\icon[src]Not enough money.") else @@ -313,6 +348,9 @@ /obj/machinery/cash_register/proc/scan_item_price(obj/O) if(!istype(O)) return + if(item_list.len > 10) + src.visible_message("\icon[src]Only up to ten different items allowed per purchase.") + return if (cash_open) playsound(src, 'sound/machines/buzz-sigh.ogg', 25) usr << "\icon[src]The cash box is open." @@ -330,19 +368,43 @@ transaction_purpose += "
" transaction_purpose += "[O]: [price] Thaler\s" transaction_amount += price - item_list += "[O]" - price_list += price + for(var/previously_scanned in item_list) + if(price == price_list[previously_scanned] && O.name == previously_scanned) + . = item_list[previously_scanned]++ + if(!.) + item_list[O.name] = 1 + price_list[O.name] = price + . = 1 // Animation and sound playsound(src, 'sound/machines/twobeep.ogg', 25) // Reset confirmation confirm_item = null + updateDialog() + + +/obj/machinery/cash_register/proc/get_current_transaction() + var/dat = {" + + + + "} + var/item_name + for(var/i=1, i<=item_list.len, i++) + item_name = item_list[i] + dat += "" + dat += "
New Entry
[item_list[item_name] ? "- Set + [item_list[item_name]] x " : ""][item_name] Remove[price_list[item_name] * item_list[item_name]] þ
" + dat += "" + dat += "
Clear EntryTotal Amount: [transaction_amount] þ
" + return dat /obj/machinery/cash_register/proc/add_transaction_log(var/c_name, var/p_method, var/t_amount) var/dat = {" - + + + "} + var/item_name + for(var/i=1, i<=item_list.len, i++) + item_name = item_list[i] + dat += "" + dat += "
New Entry
[item_list[item_name] ? "- Set + [item_list[item_name]] x " : ""][item_name] Remove[price_list[item_name] * item_list[item_name]] þ
" + dat += "" + dat += "
Clear EntryTotal Amount: [transaction_amount] þ
" + return dat + + /obj/item/device/retail_scanner/proc/add_transaction_log(var/c_name, var/p_method, var/t_amount) var/dat = {"