Skip to content

Commit

Permalink
alters pricing and ports a tg pr
Browse files Browse the repository at this point in the history
  • Loading branch information
Erikafox committed Oct 11, 2024
1 parent e04d138 commit 40b02b6
Show file tree
Hide file tree
Showing 15 changed files with 34 additions and 36 deletions.
20 changes: 9 additions & 11 deletions code/modules/vending/_vending.dm
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@ IF YOU MODIFY THE PRODUCTS LIST OF A MACHINE, MAKE SURE TO UPDATE ITS RESUPPLY C
integrity_failure = 0.33
armor = list("melee" = 20, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 50, "acid" = 70)
circuit = /obj/item/circuitboard/machine/vendor
var/datum/weakref/payment_account_ref
light_power = 0.5
light_range = MINIMUM_USEFUL_LIGHT_RANGE
clicksound = 'sound/machines/pda_button1.ogg'
Expand Down Expand Up @@ -139,9 +138,9 @@ IF YOU MODIFY THE PRODUCTS LIST OF A MACHINE, MAKE SURE TO UPDATE ITS RESUPPLY C
///Does this machine accept mining points?
var/mining_point_vendor = FALSE
///Default price of items if not overridden
var/default_price = 25
var/default_price = 15
///Default price of premium items if not overridden
var/extra_price = 50
var/extra_price = 30
///Whether our age check is currently functional
var/age_restrictions = TRUE

Expand Down Expand Up @@ -194,7 +193,7 @@ IF YOU MODIFY THE PRODUCTS LIST OF A MACHINE, MAKE SURE TO UPDATE ITS RESUPPLY C

Radio = new /obj/item/radio(src)
Radio.listening = 0
if(istype(get_area(src.loc), /area/outpost))
if(istype(get_area(src.loc), /area/outpost) || istype(get_area(src.loc), /area/ruin))
all_items_free = FALSE

/obj/machinery/vending/Destroy()
Expand Down Expand Up @@ -797,12 +796,7 @@ IF YOU MODIFY THE PRODUCTS LIST OF A MACHINE, MAKE SURE TO UPDATE ITS RESUPPLY C
flick(icon_deny,src)
vend_ready = TRUE
return

var/datum/bank_account/payment_account = payment_account_ref.resolve()
if(payment_account)
payment_account.transfer_money(account, price_to_use)
else
account.adjust_money(-price_to_use, "vendor_purchase")
account.adjust_money(-price_to_use, "vendor_purchase")
SSblackbox.record_feedback("amount", "vending_spent", price_to_use)
log_econ("[price_to_use] credits were inserted into [src] by [H] to buy [R].")
if(last_shopper != REF(usr) || purchase_message_cooldown < world.time)
Expand All @@ -813,9 +807,13 @@ IF YOU MODIFY THE PRODUCTS LIST OF A MACHINE, MAKE SURE TO UPDATE ITS RESUPPLY C
if(icon_vend) //Show the vending animation if needed
flick(icon_vend,src)
playsound(src, 'sound/machines/machine_vend.ogg', 50, TRUE, extrarange = -3)
new R.product_path(get_turf(src))
var/obj/item/vended_item = new R.product_path(get_turf(src))
if(R.max_amount >= 0)
R.amount--
if(usr.CanReach(src) && usr.put_in_hands(vended_item))
to_chat(usr, span_notice("You take [R.name] out of the slot."))
else
to_chat(usr, span_warning("[capitalize(R.name)] falls onto the floor!"))
SSblackbox.record_feedback("nested tally", "vending_machine_usage", 1, list("[type]", "[R.product_path]"))
vend_ready = TRUE

Expand Down
2 changes: 1 addition & 1 deletion code/modules/vending/assist.dm
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
/obj/item/circuitboard/machine/vendor = 3)
refill_canister = /obj/item/vending_refill/assist
product_ads = "Only the finest!;Have some tools.;The most robust equipment.;The finest gear in space!"
default_price = 125
default_price = 50
extra_price = 100
light_mask = "generic-light-mask"

Expand Down
4 changes: 2 additions & 2 deletions code/modules/vending/autodrobe.dm
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,8 @@
/obj/item/shield/riot/roman/fake = 1,
/obj/item/skub = 1)
refill_canister = /obj/item/vending_refill/autodrobe
default_price = 180
extra_price = 360
default_price = 90
extra_price = 180
light_mask="theater-light-mask"

/obj/machinery/vending/autodrobe/canLoadItem(obj/item/I,mob/user)
Expand Down
4 changes: 2 additions & 2 deletions code/modules/vending/boozeomat.dm
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@
product_ads = "Drink up!;Booze is good for you!;Alcohol is everyone's best friend.;Quite delighted to serve you!;Care for a nice, cold beer?;Nothing cures you like booze!;Have a sip!;Have a drink!;Have a beer!;Beer is good for you!;Only the finest alcohol!;Best quality booze since 53 FSC!;Award-winning wine!;Maximum alcohol!;Everyone loves beer.;A toast for progress!"
req_access = list(ACCESS_BAR)
refill_canister = /obj/item/vending_refill/boozeomat
default_price = 120
extra_price = 200
default_price = 60
extra_price = 150
light_mask = "boozeomat-light-mask"

/obj/machinery/vending/boozeomat/all_access
Expand Down
4 changes: 2 additions & 2 deletions code/modules/vending/cartridge.dm
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
/obj/item/cartridge/captain = 3,
/obj/item/cartridge/quartermaster = 10)
refill_canister = /obj/item/vending_refill/cart
default_price = 250
extra_price = 500
default_price = 200
extra_price = 300
light_mask="cart-light-mask"

/obj/item/vending_refill/cart
Expand Down
4 changes: 2 additions & 2 deletions code/modules/vending/cigarette.dm
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@
/obj/item/storage/fancy/cigarettes/cigars/cohiba = 1,
/obj/item/clothing/mask/vape/cigar = 3)
refill_canister = /obj/item/vending_refill/cigarette
default_price = 75
extra_price = 250
default_price = 50
extra_price = 150
light_mask = "cigs-light-mask"

/obj/machinery/vending/cigarette/syndicate
Expand Down
4 changes: 2 additions & 2 deletions code/modules/vending/coffee.dm
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
/obj/item/reagent_containers/food/drinks/cafelatte = 3,
/obj/item/reagent_containers/food/drinks/soylatte = 3)
refill_canister = /obj/item/vending_refill/coffee
default_price = 45
extra_price = 150
default_price = 25
extra_price = 40
light_mask = "coffee-light-mask"
light_color = COLOR_DARK_MODERATE_ORANGE

Expand Down
4 changes: 2 additions & 2 deletions code/modules/vending/cola.dm
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@
/obj/item/reagent_containers/food/drinks/soda_cans/xeno_energy = 1,
/obj/item/reagent_containers/food/drinks/soda_cans/crosstalk = 1)
refill_canister = /obj/item/vending_refill/cola
default_price = 45
extra_price = 200
default_price = 20
extra_price = 50


/obj/item/vending_refill/cola
Expand Down
4 changes: 2 additions & 2 deletions code/modules/vending/engineering.dm
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@
/obj/item/stock_parts/matter_bin = 5,
/obj/item/stock_parts/manipulator = 5)
refill_canister = /obj/item/vending_refill/engineering
default_price = 450
extra_price = 500
default_price = 200
extra_price = 400
light_mask = "engi-light-mask"

/obj/item/vending_refill/engineering
Expand Down
2 changes: 1 addition & 1 deletion code/modules/vending/engivend.dm
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
/obj/item/construction/rcd/loaded = 2,
/obj/item/storage/box/smart_metal_foam = 1)
refill_canister = /obj/item/vending_refill/engivend
default_price = 450
default_price = 250
extra_price = 500
light_mask = "engivend-light-mask"

Expand Down
4 changes: 2 additions & 2 deletions code/modules/vending/medical.dm
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@
armor = list("melee" = 100, "bullet" = 100, "laser" = 100, "energy" = 100, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 100, "acid" = 50)
resistance_flags = FIRE_PROOF
refill_canister = /obj/item/vending_refill/medical
default_price = 250
extra_price = 500
default_price = 150
extra_price = 400
light_mask = "med-light-mask"

/obj/item/vending_refill/medical
Expand Down
4 changes: 2 additions & 2 deletions code/modules/vending/medical_wall.dm
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@
armor = list("melee" = 100, "bullet" = 100, "laser" = 100, "energy" = 100, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 100, "acid" = 50)
resistance_flags = FIRE_PROOF
refill_canister = /obj/item/vending_refill/wallmed
default_price = 250
extra_price = 500
default_price = 200
extra_price = 400
tiltable = FALSE
light_mask = "wallmed-light-mask"

Expand Down
2 changes: 1 addition & 1 deletion code/modules/vending/toys.dm
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
armor = list("melee" = 100, "bullet" = 100, "laser" = 100, "energy" = 100, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 100, "acid" = 50)
resistance_flags = FIRE_PROOF
refill_canister = /obj/item/vending_refill/donksoft
default_price = 150
default_price = 100
extra_price = 300

/obj/item/vending_refill/donksoft
Expand Down
4 changes: 2 additions & 2 deletions code/modules/vending/wardrobes.dm
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
icon_state = "refill_clothes"

/obj/machinery/vending/wardrobe
default_price = 350
extra_price = 450
default_price = 200
extra_price = 500
input_display_header = "Returned Clothing"
light_mask = "wardrobe-light-mask"

Expand Down
4 changes: 2 additions & 2 deletions code/modules/vending/youtool.dm
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,5 @@
/obj/item/clothing/gloves/color/yellow = 1)
armor = list("melee" = 100, "bullet" = 100, "laser" = 100, "energy" = 100, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 100, "acid" = 70)
resistance_flags = FIRE_PROOF
default_price = 125
extra_price = 350
default_price = 75
extra_price = 250

0 comments on commit 40b02b6

Please sign in to comment.