Removes Weapons (#7415)

* Adds icon and hitsound where needed.

* Moves alt_attack to /obj/item and deletes weapons.dm

* Replaced /obj/item/weapon with /obj/item

* Fixes merge issues.

* Fix merge issues.
This commit is contained in:
Werner
2019-11-16 18:36:13 +01:00
committed by GitHub
parent 128ca2235b
commit af16a489a6
1123 changed files with 27193 additions and 27175 deletions

View File

@@ -24,29 +24,29 @@
var/loot = rand(1, 100)
switch(loot)
if(1 to 5) // Common things go, 5%
new/obj/item/weapon/reagent_containers/food/drinks/bottle/rum(src)
new/obj/item/weapon/reagent_containers/food/drinks/bottle/whiskey(src)
new/obj/item/weapon/reagent_containers/food/snacks/grown/ambrosiadeus(src)
new/obj/item/weapon/flame/lighter/zippo(src)
new/obj/item/reagent_containers/food/drinks/bottle/rum(src)
new/obj/item/reagent_containers/food/drinks/bottle/whiskey(src)
new/obj/item/reagent_containers/food/snacks/grown/ambrosiadeus(src)
new/obj/item/flame/lighter/zippo(src)
if(6 to 10)
new/obj/random/custom_ka(src)
new/obj/random/custom_ka(src)
new/obj/random/custom_ka(src)
if(11 to 15)
new/obj/item/weapon/reagent_containers/glass/beaker/bluespace(src)
new/obj/item/reagent_containers/glass/beaker/bluespace(src)
if(16 to 20)
for(var/i = 0, i < 10, i++)
new/obj/item/weapon/ore/diamond(src)
new/obj/item/ore/diamond(src)
if(21 to 25)
for(var/i = 0, i < 3, i++)
new/obj/machinery/portable_atmospherics/hydroponics(src)
if(26 to 30)
for(var/i = 0, i < 3, i++)
new/obj/item/weapon/reagent_containers/glass/beaker/noreact(src)
new/obj/item/reagent_containers/glass/beaker/noreact(src)
if(31 to 35)
spawn_money(rand(300,800), src)
if(36 to 40)
new/obj/item/weapon/melee/baton(src)
new/obj/item/melee/baton(src)
if(41 to 45)
new/obj/item/clothing/under/shorts/red(src)
new/obj/item/clothing/under/shorts/blue(src)
@@ -55,7 +55,7 @@
for(var/i = 0, i < 7, i++)
new/obj/item/clothing/accessory/horrible(src)
if(51 to 52) // Uncommon, 2% each
new/obj/item/weapon/melee/classic_baton(src)
new/obj/item/melee/classic_baton(src)
if(53 to 54)
new/obj/item/latexballon(src)
if(55 to 56)
@@ -64,36 +64,36 @@
if(57 to 58)
new/obj/item/toy/syndicateballoon(src)
if(59 to 60)
new/obj/item/weapon/rig/eva(src)
new/obj/item/rig/eva(src)
if(61 to 62)
for(var/i = 0, i < 12, ++i)
new/obj/item/clothing/head/kitty(src)
if(63 to 64)
var/t = rand(4,7)
for(var/i = 0, i < t, ++i)
var/newcoin = pick(/obj/item/weapon/coin/silver, /obj/item/weapon/coin/silver, /obj/item/weapon/coin/silver, /obj/item/weapon/coin/iron, /obj/item/weapon/coin/iron, /obj/item/weapon/coin/iron, /obj/item/weapon/coin/gold, /obj/item/weapon/coin/diamond, /obj/item/weapon/coin/phoron, /obj/item/weapon/coin/uranium, /obj/item/weapon/coin/platinum)
var/newcoin = pick(/obj/item/coin/silver, /obj/item/coin/silver, /obj/item/coin/silver, /obj/item/coin/iron, /obj/item/coin/iron, /obj/item/coin/iron, /obj/item/coin/gold, /obj/item/coin/diamond, /obj/item/coin/phoron, /obj/item/coin/uranium, /obj/item/coin/platinum)
new newcoin(src)
if(65 to 66)
new/obj/item/clothing/suit/ianshirt(src)
if(67 to 68)
var/t = rand(4,7)
for(var/i = 0, i < t, ++i)
var/newitem = pick(typesof(/obj/item/weapon/stock_parts) - /obj/item/weapon/stock_parts - /obj/item/weapon/stock_parts/subspace)
var/newitem = pick(typesof(/obj/item/stock_parts) - /obj/item/stock_parts - /obj/item/stock_parts/subspace)
new newitem(src)
if(69 to 70)
new/obj/item/weapon/pickaxe/silver(src)
new/obj/item/pickaxe/silver(src)
if(71 to 72)
new/obj/item/weapon/pickaxe/drill(src)
new/obj/item/pickaxe/drill(src)
if(73 to 74)
new/obj/item/weapon/pickaxe/jackhammer(src)
new/obj/item/pickaxe/jackhammer(src)
if(75 to 76)
new/obj/item/weapon/pickaxe/diamond(src)
new/obj/item/pickaxe/diamond(src)
if(77 to 78)
new/obj/item/weapon/pickaxe/diamonddrill(src)
new/obj/item/pickaxe/diamonddrill(src)
if(79 to 80)
new/obj/item/weapon/pickaxe/gold(src)
new/obj/item/pickaxe/gold(src)
if(81 to 82)
new/obj/item/weapon/gun/energy/plasmacutter(src)
new/obj/item/gun/energy/plasmacutter(src)
if(83) // Rarest things, some are unobtainble otherwise, some are just robust, 1% each
new/obj/random/prebuilt_ka(src)
if(84)
@@ -105,7 +105,7 @@
if(87)
new/obj/item/xenos_claw(src)
if(88)
new/obj/item/weapon/gun/projectile/shotgun/pump/rifle(src)
new/obj/item/gun/projectile/shotgun/pump/rifle(src)
new/obj/item/ammo_magazine/boltaction(src)
new/obj/item/clothing/under/soviet(src)
new/obj/item/clothing/head/ushanka/grey(src)
@@ -116,18 +116,18 @@
if(91)
new/obj/item/poppet(src)
if(92)
new/obj/item/weapon/material/sword/katana(src)
new/obj/item/material/sword/katana(src)
if(93)
new/obj/item/weapon/dnainjector/xraymut(src) // Probably the least OP
new/obj/item/dnainjector/xraymut(src) // Probably the least OP
if(94) // Why the hell not
new/obj/item/weapon/storage/backpack/clown(src)
new/obj/item/storage/backpack/clown(src)
new/obj/item/clothing/under/rank/clown(src)
new/obj/item/clothing/shoes/clown_shoes(src)
new/obj/item/device/pda/clown(src)
new/obj/item/clothing/mask/gas/clown_hat(src)
new/obj/item/weapon/bikehorn(src)
//new/obj/item/weapon/stamp/clown(src) I'd add it, but only clowns can use it
new/obj/item/weapon/pen/crayon/rainbow(src)
new/obj/item/bikehorn(src)
//new/obj/item/stamp/clown(src) I'd add it, but only clowns can use it
new/obj/item/pen/crayon/rainbow(src)
new/obj/item/toy/waterflower(src)
if(95)
new/obj/item/clothing/under/mime(src)
@@ -137,19 +137,19 @@
new/obj/item/clothing/mask/gas/mime(src)
new/obj/item/clothing/head/beret(src)
new/obj/item/clothing/accessory/suspenders(src)
new/obj/item/weapon/pen/crayon/mime(src)
new/obj/item/weapon/reagent_containers/food/drinks/bottle/bottleofnothing(src)
new/obj/item/pen/crayon/mime(src)
new/obj/item/reagent_containers/food/drinks/bottle/bottleofnothing(src)
if(96)
new/obj/item/weapon/vampiric(src)
new/obj/item/vampiric(src)
if(97)
new/obj/item/weapon/archaeological_find(src)
new/obj/item/archaeological_find(src)
if(98)
new/obj/item/weapon/melee/energy/sword(src)
new/obj/item/melee/energy/sword(src)
if(99)
new/obj/item/weapon/storage/belt/champion(src)
new/obj/item/storage/belt/champion(src)
new/obj/item/clothing/mask/luchador(src)
if(100)
new/obj/item/weapon/gun/projectile/tanto(src)
new/obj/item/gun/projectile/tanto(src)
new/obj/item/ammo_magazine/mc10mm(src)
new/obj/item/ammo_magazine/mc10mm(src)
new/obj/item/ammo_magazine/mc10mm/rubber(src)
@@ -198,7 +198,7 @@
if(guesschar != code[i])
. = 0
/obj/structure/closet/crate/secure/loot/attackby(obj/item/weapon/W as obj, mob/user as mob)
/obj/structure/closet/crate/secure/loot/attackby(obj/item/W as obj, mob/user as mob)
if(locked)
if (W.ismultitool()) // Greetings Urist McProfessor, how about a nice game of cows and bulls?
to_chat(user, "<span class='notice'>DECA-CODE LOCK ANALYSIS:</span>")

View File

@@ -1,6 +1,6 @@
/*****************************Coin********************************/
/obj/item/weapon/coin
/obj/item/coin
icon = 'icons/obj/coins.dmi'
name = "Coin"
icon_state = "coin"
@@ -16,55 +16,55 @@
var/cmineral = null
drop_sound = 'sound/items/drop/ring.ogg'
/obj/item/weapon/coin/New()
/obj/item/coin/New()
randpixel_xy()
/obj/item/weapon/coin/gold
/obj/item/coin/gold
name = "gold coin"
icon_state = "coin_gold_heads"
cmineral = "gold"
/obj/item/weapon/coin/silver
/obj/item/coin/silver
name = "silver coin"
icon_state = "coin_silver_heads"
cmineral = "silver"
/obj/item/weapon/coin/diamond
/obj/item/coin/diamond
name = "diamond coin"
icon_state = "coin_diamond_heads"
cmineral = "diamond"
/obj/item/weapon/coin/iron
/obj/item/coin/iron
name = "iron coin"
icon_state = "coin_iron_heads"
cmineral = "iron"
/obj/item/weapon/coin/phoron
/obj/item/coin/phoron
name = "solid phoron coin"
icon_state = "coin_phoron_heads"
cmineral = "phoron"
/obj/item/weapon/coin/uranium
/obj/item/coin/uranium
name = "uranium coin"
icon_state = "coin_uranium_heads"
cmineral = "uranium"
/obj/item/weapon/coin/platinum
/obj/item/coin/platinum
name = "platinum coin"
icon_state = "coin_platinum_heads"
cmineral = "platinum"
/obj/item/weapon/coin/platinum
/obj/item/coin/platinum
name = "mythril coin"
icon_state = "coin_mythril_heads"
cmineral = "mythril"
/obj/item/weapon/coin/battlemonsters
/obj/item/coin/battlemonsters
name = "battlemonsters coin"
icon_state = "coin_battlemonsters_heads"
cmineral = "battlemonsters"
/obj/item/weapon/coin/attackby(obj/item/weapon/W as obj, mob/user as mob)
/obj/item/coin/attackby(obj/item/W as obj, mob/user as mob)
if(W.iscoil())
var/obj/item/stack/cable_coil/CC = W
if(string_attached)
@@ -90,7 +90,7 @@
to_chat(user, "<span class='notice'>You detach the string from the coin.</span>")
else ..()
/obj/item/weapon/coin/attack_self(mob/user as mob)
/obj/item/coin/attack_self(mob/user as mob)
var/result = rand(1, sides)
var/comment = ""
if(result == 1)

View File

@@ -16,23 +16,23 @@
var/list/resource_field = list()
var/ore_types = list(
"iron" = /obj/item/weapon/ore/iron,
"uranium" = /obj/item/weapon/ore/uranium,
"gold" = /obj/item/weapon/ore/gold,
"silver" = /obj/item/weapon/ore/silver,
"diamond" = /obj/item/weapon/ore/diamond,
"phoron" = /obj/item/weapon/ore/phoron,
"osmium" = /obj/item/weapon/ore/osmium,
"hydrogen" = /obj/item/weapon/ore/hydrogen,
"silicates" = /obj/item/weapon/ore/glass,
"carbonaceous rock" = /obj/item/weapon/ore/coal
"iron" = /obj/item/ore/iron,
"uranium" = /obj/item/ore/uranium,
"gold" = /obj/item/ore/gold,
"silver" = /obj/item/ore/silver,
"diamond" = /obj/item/ore/diamond,
"phoron" = /obj/item/ore/phoron,
"osmium" = /obj/item/ore/osmium,
"hydrogen" = /obj/item/ore/hydrogen,
"silicates" = /obj/item/ore/glass,
"carbonaceous rock" = /obj/item/ore/coal
)
//Upgrades
var/harvest_speed
var/capacity
var/charge_use
var/obj/item/weapon/cell/cell = null
var/obj/item/cell/cell = null
//Flags
var/need_update_field = 0
@@ -41,11 +41,11 @@
var/datum/effect_system/sparks/spark_system
component_types = list(
/obj/item/weapon/circuitboard/miningdrill,
/obj/item/weapon/stock_parts/matter_bin,
/obj/item/weapon/stock_parts/capacitor,
/obj/item/weapon/stock_parts/micro_laser,
/obj/item/weapon/cell/high
/obj/item/circuitboard/miningdrill,
/obj/item/stock_parts/matter_bin,
/obj/item/stock_parts/capacitor,
/obj/item/stock_parts/micro_laser,
/obj/item/cell/high
)
/obj/machinery/mining/drill/Initialize()
@@ -164,7 +164,7 @@
cell = null
return
if(istype(O, /obj/item/weapon/cell))
if(istype(O, /obj/item/cell))
if(cell)
to_chat(user, "The drill already has a cell installed.")
else
@@ -246,14 +246,14 @@
capacity = 0
charge_use = 50
for(var/obj/item/weapon/stock_parts/P in component_parts)
for(var/obj/item/stock_parts/P in component_parts)
if(ismicrolaser(P))
harvest_speed = P.rating
else if(ismatterbin(P))
capacity = 200 * P.rating
else if(iscapacitor(P))
charge_use -= 10 * P.rating
cell = locate(/obj/item/weapon/cell) in component_parts
cell = locate(/obj/item/cell) in component_parts
/obj/machinery/mining/drill/proc/check_supports()
@@ -316,11 +316,11 @@
var/obj/structure/ore_box/B = locate() in orange(1)
if(B)
for(var/obj/item/weapon/ore/O in contents)
for(var/obj/item/ore/O in contents)
O.forceMove(B)
to_chat(usr, "<span class='notice'>You unload the drill's storage cache into the ore box.</span>")
else
for(var/obj/item/weapon/ore/O in contents)
for(var/obj/item/ore/O in contents)
O.forceMove(src.loc)
to_chat(usr, "<span class='notice'>You spill the content's of the drill's storage box all over the ground. Idiot.</span>")
@@ -332,10 +332,10 @@
var/obj/machinery/mining/drill/connected
component_types = list(
/obj/item/weapon/circuitboard/miningdrillbrace
/obj/item/circuitboard/miningdrillbrace
)
/obj/machinery/mining/brace/attackby(obj/item/weapon/W as obj, mob/user as mob)
/obj/machinery/mining/brace/attackby(obj/item/W as obj, mob/user as mob)
if(connected && connected.active)
to_chat(user, "<span class='notice'>You know you ought not work with the brace of a <i>running</i> drill, but you do anyways.</span>")
sleep(5)

View File

@@ -1,4 +1,4 @@
/obj/item/weapon/mining_scanner
/obj/item/mining_scanner
name = "ore detector"
desc = "A complex device used to locate ore deep underground."
icon = 'icons/obj/device.dmi'
@@ -7,7 +7,7 @@
origin_tech = list(TECH_MAGNET = 1, TECH_ENGINEERING = 1)
matter = list(DEFAULT_WALL_MATERIAL = 150)
/obj/item/weapon/mining_scanner/attack_self(mob/user as mob)
/obj/item/mining_scanner/attack_self(mob/user as mob)
to_chat(user, "You begin sweeping \the [src] about, scanning for metal deposits.")
if(!do_after(user, 50))

View File

@@ -13,7 +13,7 @@
var/obj/machinery/mineral/processing_unit/machine = null
var/show_all_ores = 0
var/points = 0
var/obj/item/weapon/card/id/inserted_id
var/obj/item/card/id/inserted_id
var/ore/list/input_mats = list()
var/material/list/output_mats = list()
@@ -41,8 +41,8 @@
interact(user)
/obj/machinery/mineral/processing_unit_console/attackby(obj/item/I, mob/user)
if(istype(I,/obj/item/weapon/card/id))
var/obj/item/weapon/card/id/C = user.get_active_hand()
if(istype(I,/obj/item/card/id))
var/obj/item/card/id/C = user.get_active_hand()
if(istype(C) && !istype(inserted_id))
user.drop_from_inventory(C,src)
inserted_id = C
@@ -135,7 +135,7 @@
to_chat(usr, "<span class='warning'>Required access not found.</span>")
else if(href_list["choice"] == "insert")
var/obj/item/weapon/card/id/I = usr.get_active_hand()
var/obj/item/card/id/I = usr.get_active_hand()
if(istype(I))
usr.drop_from_inventory(I,src)
inserted_id = I
@@ -181,7 +181,7 @@
printing = TRUE
var/obj/item/weapon/paper/P = new /obj/item/weapon/paper(user.loc)
var/obj/item/paper/P = new /obj/item/paper(user.loc)
var/date_string = worlddate2text()
idx++
@@ -245,7 +245,7 @@
P.offset_x += 0
P.offset_y += 0
P.ico += "paper_stamp-cent"
P.stamped += /obj/item/weapon/stamp
P.stamped += /obj/item/stamp
P.add_overlay(stampoverlay)
P.stamps += "<HR><i>This paper has been stamped by the NT Ore Processing System.</i>"
@@ -286,11 +286,11 @@
active_power_usage = 150
component_types = list(
/obj/item/weapon/circuitboard/refiner,
/obj/item/weapon/stock_parts/capacitor = 2,
/obj/item/weapon/stock_parts/scanning_module,
/obj/item/weapon/stock_parts/micro_laser = 2,
/obj/item/weapon/stock_parts/matter_bin
/obj/item/circuitboard/refiner,
/obj/item/stock_parts/capacitor = 2,
/obj/item/stock_parts/scanning_module,
/obj/item/stock_parts/micro_laser = 2,
/obj/item/stock_parts/matter_bin
)
/obj/machinery/mineral/processing_unit/Initialize()
@@ -323,7 +323,7 @@
//Grab some more ore to process this tick.
for(var/i = 0,i<sheets_per_tick,i++)
var/obj/item/weapon/ore/O = locate() in input.loc
var/obj/item/ore/O = locate() in input.loc
if(!O) break
if(!isnull(ores_stored[O.material]))
ores_stored[O.material]++
@@ -428,13 +428,13 @@
sheets++
console.input_mats[O]++
console.waste++
new /obj/item/weapon/ore/slag(output.loc)
new /obj/item/ore/slag(output.loc)
else
continue
console.updateUsrDialog()
/obj/machinery/mineral/processing_unit/attackby(obj/item/weapon/W as obj, mob/user as mob)
/obj/machinery/mineral/processing_unit/attackby(obj/item/W as obj, mob/user as mob)
if(default_deconstruction_screwdriver(user, W))
return
else if(default_part_replacement(user, W))
@@ -446,7 +446,7 @@
var/cap_rating = 0
var/laser_rating = 0
for(var/obj/item/weapon/stock_parts/P in component_parts)
for(var/obj/item/stock_parts/P in component_parts)
if(isscanner(P))
scan_rating += P.rating
else if(iscapacitor(P))

View File

@@ -23,22 +23,22 @@
if(istype(W, /obj/item/clothing/glasses/material) || istype (W,/obj/item/clothing/glasses/meson))
outcome_path = /obj/item/rig_module/vision/meson
if(istype(W, /obj/item/weapon/tank/jetpack))
if(istype(W, /obj/item/tank/jetpack))
outcome_path = /obj/item/rig_module/maneuvering_jets
if(istype(W, /obj/item/weapon/mining_scanner))
if(istype(W, /obj/item/mining_scanner))
outcome_path = /obj/item/rig_module/device/orescanner
if(istype(W, /obj/item/weapon/pickaxe/drill))
if(istype(W, /obj/item/pickaxe/drill))
outcome_path = /obj/item/rig_module/device/basicdrill
if(istype(W, /obj/item/weapon/gun/energy/plasmacutter))
if(istype(W, /obj/item/gun/energy/plasmacutter))
outcome_path = /obj/item/rig_module/mounted/plasmacutter
if(istype(W, /obj/item/weapon/pickaxe/diamond))
if(istype(W, /obj/item/pickaxe/diamond))
outcome_path = /obj/item/rig_module/device/drill
if(istype(W, /obj/item/weapon/gun/energy/vaurca/thermaldrill))
if(istype(W, /obj/item/gun/energy/vaurca/thermaldrill))
outcome_path = /obj/item/rig_module/mounted/thermalldrill
if(!outcome_path)

View File

@@ -29,7 +29,7 @@
if (locate(/obj/structure/ore_box, input.loc))
var/obj/structure/ore_box/BOX = locate(/obj/structure/ore_box, input.loc)
var/i = 0
for (var/obj/item/weapon/ore/O in BOX.contents)
for (var/obj/item/ore/O in BOX.contents)
BOX.contents -= O
O.forceMove(output.loc)
i++

View File

@@ -5,58 +5,58 @@
//Think up of lots of items. Not everything needs to be unique or even mining-special, but it should be neat. Convert most of /tg/'s items. 25% of this at least
// should be bling. Things that shorten the distance between base and mining. Instant-teleporters should be one use.
var/global/list/minevendor_list = list( //keep in order of price
new /datum/data/mining_equipment("Food Ration", /obj/item/weapon/reagent_containers/food/snacks/liquidfood, 10, 5),
new /datum/data/mining_equipment("Poster", /obj/item/weapon/contraband/poster, 10, 20),
new /datum/data/mining_equipment("Ore Scanner Pad", /obj/item/weapon/ore_radar, 10, 50),
new /datum/data/mining_equipment("Food Ration", /obj/item/reagent_containers/food/snacks/liquidfood, 10, 5),
new /datum/data/mining_equipment("Poster", /obj/item/contraband/poster, 10, 20),
new /datum/data/mining_equipment("Ore Scanner Pad", /obj/item/ore_radar, 10, 50),
new /datum/data/mining_equipment("5 Red Flags", /obj/item/stack/flag/red, 10, 50),
new /datum/data/mining_equipment("5 Green Flags", /obj/item/stack/flag/green, 10, 50),
new /datum/data/mining_equipment("5 Yellow Flags", /obj/item/stack/flag/yellow, 10, 50),
new /datum/data/mining_equipment("5 Purple Flags", /obj/item/stack/flag/purple, 10, 50),
new /datum/data/mining_equipment("Ore-bag", /obj/item/weapon/storage/bag/ore, 25, 50),
new /datum/data/mining_equipment("Ore-bag", /obj/item/storage/bag/ore, 25, 50),
new /datum/data/mining_equipment("Meat Pizza", /obj/item/pizzabox/meat, 25, 50),
new /datum/data/mining_equipment("Lantern", /obj/item/device/flashlight/lantern, 10, 75),
new /datum/data/mining_equipment("Shovel", /obj/item/weapon/shovel, 15, 100),
new /datum/data/mining_equipment("Pickaxe", /obj/item/weapon/pickaxe, 10, 100),
new /datum/data/mining_equipment("Compressed matter cartridge", /obj/item/weapon/rfd_ammo, 50, 100),
new /datum/data/mining_equipment("Class E Kinetic Accelerator", /obj/item/weapon/gun/custom_ka/frame01/prebuilt, 12, 200),
new /datum/data/mining_equipment("Shovel", /obj/item/shovel, 15, 100),
new /datum/data/mining_equipment("Pickaxe", /obj/item/pickaxe, 10, 100),
new /datum/data/mining_equipment("Compressed matter cartridge", /obj/item/rfd_ammo, 50, 100),
new /datum/data/mining_equipment("Class E Kinetic Accelerator", /obj/item/gun/custom_ka/frame01/prebuilt, 12, 200),
new /datum/data/mining_equipment("Ore Box", /obj/structure/ore_box, -1, 150, 1),
new /datum/data/mining_equipment("Emergency Floodlight", /obj/item/weapon/floodlight_diy, -1, 150, 1),
new /datum/data/mining_equipment("Emergency Floodlight", /obj/item/floodlight_diy, -1, 150, 1),
new /datum/data/mining_equipment("Premium Cigar", /obj/item/clothing/mask/smokable/cigarette/cigar/havana, 30, 150),
new /datum/data/mining_equipment("Seismic Charge", /obj/item/weapon/plastique/seismic, 25, 150),
new /datum/data/mining_equipment("Deployable Ladder", /obj/item/weapon/ladder_mobile, 5, 200),
new /datum/data/mining_equipment("Seismic Charge", /obj/item/plastique/seismic, 25, 150),
new /datum/data/mining_equipment("Deployable Ladder", /obj/item/ladder_mobile, 5, 200),
new /datum/data/mining_equipment("Deployable Hoist Kit", /obj/item/hoist_kit, 5, 200),
new /datum/data/mining_equipment("Ripley Paint Kit", /obj/item/device/kit/paint/ripley/random, 15, 200),
new /datum/data/mining_equipment("Material Scanners", /obj/item/clothing/glasses/material, 15, 200),
new /datum/data/mining_equipment("Mining Drill", /obj/item/weapon/pickaxe/drill, 10, 200),
new /datum/data/mining_equipment("Deep Ore Scanner", /obj/item/weapon/mining_scanner, 10, 250),
new /datum/data/mining_equipment("Mining Drill", /obj/item/pickaxe/drill, 10, 200),
new /datum/data/mining_equipment("Deep Ore Scanner", /obj/item/mining_scanner, 10, 250),
new /datum/data/mining_equipment("Magboots", /obj/item/clothing/shoes/magboots, 10, 300),
new /datum/data/mining_equipment("Class D Kinetic Accelerator", /obj/item/weapon/gun/custom_ka/frame02/prebuilt, 12, 400),
new /datum/data/mining_equipment("Autochisel", /obj/item/weapon/autochisel, 10, 400),
new /datum/data/mining_equipment("Jetpack", /obj/item/weapon/tank/jetpack, 10, 400),
new /datum/data/mining_equipment("Class D Kinetic Accelerator", /obj/item/gun/custom_ka/frame02/prebuilt, 12, 400),
new /datum/data/mining_equipment("Autochisel", /obj/item/autochisel, 10, 400),
new /datum/data/mining_equipment("Jetpack", /obj/item/tank/jetpack, 10, 400),
new /datum/data/mining_equipment("Drone Drill Upgrade", /obj/item/device/mine_bot_ugprade, 10, 400),
new /datum/data/mining_equipment("Industrial Drill Brace", /obj/machinery/mining/brace, -1, 500, 1),
new /datum/data/mining_equipment("Point Transfer Card", /obj/item/weapon/card/mining_point_card, -1, 500),
new /datum/data/mining_equipment("Explorer's Belt", /obj/item/weapon/storage/belt/mining, 10, 500),
new /datum/data/mining_equipment("Point Transfer Card", /obj/item/card/mining_point_card, -1, 500),
new /datum/data/mining_equipment("Explorer's Belt", /obj/item/storage/belt/mining, 10, 500),
new /datum/data/mining_equipment("Item-Warp Beacon", /obj/item/warp_core, 25, 500),
new /datum/data/mining_equipment("Item-Warp Pack", /obj/item/weapon/extraction_pack, 25, 600),
new /datum/data/mining_equipment("Item-Warp Pack", /obj/item/extraction_pack, 25, 600),
new /datum/data/mining_equipment("Drone Health Upgrade", /obj/item/device/mine_bot_ugprade/health, 20, 600),
new /datum/data/mining_equipment("RFD M-Class", /obj/item/weapon/rfd/mining, 10, 600),
new /datum/data/mining_equipment("Brute First-Aid Kit", /obj/item/weapon/storage/firstaid/brute, 30, 600),
new /datum/data/mining_equipment("Ore Magnet", /obj/item/weapon/oremagnet, 10, 600),
new /datum/data/mining_equipment("RFD M-Class", /obj/item/rfd/mining, 10, 600),
new /datum/data/mining_equipment("Brute First-Aid Kit", /obj/item/storage/firstaid/brute, 30, 600),
new /datum/data/mining_equipment("Ore Magnet", /obj/item/oremagnet, 10, 600),
new /datum/data/mining_equipment("Minecart", /obj/vehicle/train/cargo/trolley/mining, -1, 600, 1),
new /datum/data/mining_equipment("Resonator", /obj/item/weapon/resonator, 10, 700),
new /datum/data/mining_equipment("Resonator", /obj/item/resonator, 10, 700),
new /datum/data/mining_equipment("Jaunter", /obj/item/device/wormhole_jaunter, 20, 750),
new /datum/data/mining_equipment("Mining RIG", /obj/item/weapon/rig/industrial, 5, 1000),
new /datum/data/mining_equipment("Mass Driver", /obj/item/weapon/mass_driver_diy, 5, 800),
new /datum/data/mining_equipment("Mining RIG", /obj/item/rig/industrial, 5, 1000),
new /datum/data/mining_equipment("Mass Driver", /obj/item/mass_driver_diy, 5, 800),
new /datum/data/mining_equipment("Mining Drone", /mob/living/silicon/robot/drone/mining, 15, 800),
new /datum/data/mining_equipment("Minecart Engine", /obj/vehicle/train/cargo/engine/mining, -1, 800, 1),
new /datum/data/mining_equipment("Drone KA Upgrade", /obj/item/device/mine_bot_ugprade/ka, 10, 800),
new /datum/data/mining_equipment("Ore Summoner", /obj/item/weapon/oreportal, 35, 800),
new /datum/data/mining_equipment("Lazarus Injector", /obj/item/weapon/lazarus_injector, 25, 1000),
new /datum/data/mining_equipment("Ore Summoner", /obj/item/oreportal, 35, 800),
new /datum/data/mining_equipment("Lazarus Injector", /obj/item/lazarus_injector, 25, 1000),
new /datum/data/mining_equipment("Industrial Drill Head", /obj/machinery/mining/drill, -1, 1000, 1),
new /datum/data/mining_equipment("Super Resonator", /obj/item/weapon/resonator/upgraded, 10, 1250),
new /datum/data/mining_equipment("Diamond Pickaxe", /obj/item/weapon/pickaxe/diamond, 10, 1500),
new /datum/data/mining_equipment("Thermal Drill", /obj/item/weapon/gun/energy/vaurca/thermaldrill, 5, 3750)
new /datum/data/mining_equipment("Super Resonator", /obj/item/resonator/upgraded, 10, 1250),
new /datum/data/mining_equipment("Diamond Pickaxe", /obj/item/pickaxe/diamond, 10, 1500),
new /datum/data/mining_equipment("Thermal Drill", /obj/item/gun/energy/vaurca/thermaldrill, 5, 3750)
)
/obj/machinery/mineral/equipment_vendor
@@ -66,7 +66,7 @@ var/global/list/minevendor_list = list( //keep in order of price
icon_state = "mining"
density = 1
anchored = 1
var/obj/item/weapon/card/id/inserted_id
var/obj/item/card/id/inserted_id
/datum/data/mining_equipment
var/equipment_name = "generic"
@@ -82,13 +82,13 @@ var/global/list/minevendor_list = list( //keep in order of price
src.cost = cost
src.shuttle = shuttle
/obj/item/weapon/circuitboard/machine/mining_equipment_vendor
/obj/item/circuitboard/machine/mining_equipment_vendor
name = "circuit board (Mining Equipment Vendor)"
build_path = /obj/machinery/mineral/equipment_vendor
origin_tech = list(TECH_DATA = 1, TECH_ENGINEERING = 1)
req_components = list(
/obj/item/weapon/stock_parts/console_screen = 1,
/obj/item/weapon/stock_parts/matter_bin = 3)
/obj/item/stock_parts/console_screen = 1,
/obj/item/stock_parts/matter_bin = 3)
/obj/machinery/mineral/equipment_vendor/power_change()
..()
@@ -143,7 +143,7 @@ var/global/list/minevendor_list = list( //keep in order of price
inserted_id.forceMove(get_turf(src))
inserted_id = null
else if(href_list["choice"] == "insert")
var/obj/item/weapon/card/id/I = usr.get_active_hand()
var/obj/item/card/id/I = usr.get_active_hand()
if(istype(I))
usr.drop_from_inventory(I,src)
inserted_id = I
@@ -206,8 +206,8 @@ var/global/list/minevendor_list = list( //keep in order of price
return
/obj/machinery/mineral/equipment_vendor/attackby(obj/item/I, mob/user, params)
if(istype(I,/obj/item/weapon/card/id))
var/obj/item/weapon/card/id/C = usr.get_active_hand()
if(istype(I,/obj/item/card/id))
var/obj/item/card/id/C = usr.get_active_hand()
if(istype(C) && !istype(inserted_id))
usr.drop_from_inventory(C,src)
inserted_id = C

View File

@@ -13,22 +13,22 @@
/obj/structure/closet/secure_closet/miner/fill()
..()
if(prob(50))
new /obj/item/weapon/storage/backpack/industrial(src)
new /obj/item/storage/backpack/industrial(src)
else
new /obj/item/weapon/storage/backpack/satchel_eng(src)
new /obj/item/storage/backpack/satchel_eng(src)
new /obj/item/device/radio/headset/headset_cargo(src)
new /obj/item/clothing/under/rank/miner(src)
new /obj/item/clothing/gloves/black(src)
new /obj/item/clothing/shoes/black(src)
new /obj/item/device/analyzer(src)
new /obj/item/weapon/storage/bag/ore(src)
new /obj/item/weapon/shovel(src)
new /obj/item/weapon/pickaxe(src)
new /obj/item/weapon/gun/custom_ka/frame01/prebuilt(src)
new /obj/item/weapon/ore_radar(src)
new /obj/item/weapon/key/minecarts(src)
new /obj/item/storage/bag/ore(src)
new /obj/item/shovel(src)
new /obj/item/pickaxe(src)
new /obj/item/gun/custom_ka/frame01/prebuilt(src)
new /obj/item/ore_radar(src)
new /obj/item/key/minecarts(src)
new /obj/item/device/gps/mining(src)
new /obj/item/weapon/book/manual/ka_custom(src)
new /obj/item/book/manual/ka_custom(src)
new /obj/item/clothing/accessory/storage/overalls/mining(src)
/******************************Lantern*******************************/
@@ -45,7 +45,7 @@
/*****************************Pickaxe********************************/
/obj/item/weapon/pickaxe
/obj/item/pickaxe
name = "pickaxe"
desc = "The most basic of mining implements. Surely this is a joke?"
icon = 'icons/obj/tools.dmi'
@@ -77,21 +77,21 @@
action_button_name = "Wield pick/drill"
/obj/item/weapon/pickaxe/proc/unwield()
/obj/item/pickaxe/proc/unwield()
wielded = 0
force = force_unwielded
digspeed = digspeed_unwielded
name = initial(name)
update_icon()
/obj/item/weapon/pickaxe/proc/wield()
/obj/item/pickaxe/proc/wield()
wielded = 1
force = force_wielded
digspeed = digspeed_wielded
name = "[name] (Wielded)"
update_icon()
/obj/item/weapon/pickaxe/update_icon()
/obj/item/pickaxe/update_icon()
..()
if(wielded)
item_state = "[initial(icon_state)]-wielded"
@@ -99,7 +99,7 @@
item_state = initial(item_state)
update_held_icon()
/obj/item/weapon/pickaxe/mob_can_equip(M as mob, slot)
/obj/item/pickaxe/mob_can_equip(M as mob, slot)
//Cannot equip wielded items.
if(wielded)
to_chat(M, "<span class='warning'>Unwield the [initial(name)] first!</span>")
@@ -107,19 +107,19 @@
return ..()
/obj/item/weapon/pickaxe/dropped(mob/user as mob)
/obj/item/pickaxe/dropped(mob/user as mob)
//handles unwielding a twohanded weapon when dropped as well as clearing up the offhand
if(user)
var/obj/item/weapon/pickaxe/O = user.get_inactive_hand()
var/obj/item/pickaxe/O = user.get_inactive_hand()
if(istype(O))
O.unwield()
return unwield()
/obj/item/weapon/pickaxe/pickup(mob/user)
/obj/item/pickaxe/pickup(mob/user)
..()
unwield()
/obj/item/weapon/pickaxe/attack_self(mob/user as mob)
/obj/item/pickaxe/attack_self(mob/user as mob)
..()
@@ -142,7 +142,7 @@
unwield()
to_chat(user, "<span class='notice'>You are now carrying the [initial(name)] with one hand.</span>")
var/obj/item/weapon/pickaxe/offhand/O = user.get_inactive_hand()
var/obj/item/pickaxe/offhand/O = user.get_inactive_hand()
if(O && istype(O))
O.unwield()
@@ -153,7 +153,7 @@
wield()
to_chat(user, "<span class='notice'>You grab the [initial(name)] with both hands.</span>")
var/obj/item/weapon/pickaxe/offhand/O = new(user) ////Let's reserve his other hand~
var/obj/item/pickaxe/offhand/O = new(user) ////Let's reserve his other hand~
O.name = "[initial(name)] - offhand"
O.desc = "Your second grip on the [initial(name)]."
user.put_in_inactive_hand(O)
@@ -165,11 +165,11 @@
return
/obj/item/weapon/pickaxe/ui_action_click()
/obj/item/pickaxe/ui_action_click()
if(src in usr)
attack_self(usr)
/obj/item/weapon/pickaxe/verb/wield_pick()
/obj/item/pickaxe/verb/wield_pick()
if(can_wield)
set name = "Wield pick/drill"
set category = "Object"
@@ -177,7 +177,7 @@
attack_self(usr)
/obj/item/weapon/pickaxe/offhand
/obj/item/pickaxe/offhand
w_class = 5
icon = 'icons/obj/weapons.dmi'
icon_state = "offhand"
@@ -187,31 +187,33 @@
action_button_name = null
/obj/item/weapon/pickaxe/proc/copy_stats(obj/item/weapon/pickaxe/parent)
/obj/item/pickaxe/proc/copy_stats(obj/item/pickaxe/parent)
digspeed_wielded = parent.digspeed_wielded
excavation_amount = parent.excavation_amount
force = parent.force_wielded
/obj/item/weapon/pickaxe/offhand/unwield()
/obj/item/pickaxe/offhand/unwield()
if (ismob(loc))
var/mob/living/our_mob = loc
our_mob.remove_from_mob(src)
qdel(src)
/obj/item/weapon/pickaxe/offhand/wield()
/obj/item/pickaxe/offhand/wield()
if (ismob(loc))
var/mob/living/our_mob = loc
our_mob.remove_from_mob(src)
qdel(src)
/obj/item/weapon/pickaxe/hammer
/obj/item/pickaxe/hammer
name = "sledgehammer"
//icon_state = "sledgehammer" Waiting on sprite
desc = "A mining hammer made of reinforced metal. You feel like smashing your boss in the face with this."
icon_state = "sledgehammer"
icon = 'icons/obj/weapons.dmi'
hitsound = "swing_hit"
/obj/item/weapon/pickaxe/silver
/obj/item/pickaxe/silver
name = "silver pickaxe"
icon_state = "spickaxe"
item_state = "spickaxe"
@@ -222,7 +224,7 @@
digspeed_unwielded = 30
digspeed_wielded = 5
/obj/item/weapon/pickaxe/drill
/obj/item/pickaxe/drill
name = "mining drill" // Can dig sand as well!
icon_state = "handdrill"
item_state = "jackhammer"
@@ -241,7 +243,7 @@
action_button_name = null
/obj/item/weapon/pickaxe/jackhammer
/obj/item/pickaxe/jackhammer
name = "sonic jackhammer"
icon_state = "jackhammer"
item_state = "jackhammer"
@@ -260,7 +262,7 @@
action_button_name = null
/obj/item/weapon/pickaxe/gold
/obj/item/pickaxe/gold
name = "golden pickaxe"
icon_state = "gpickaxe"
item_state = "gpickaxe"
@@ -272,7 +274,7 @@
digspeed_unwielded = 30
digspeed_wielded = 5
/obj/item/weapon/pickaxe/diamond
/obj/item/pickaxe/diamond
name = "diamond pickaxe"
icon_state = "dpickaxe"
item_state = "dpickaxe"
@@ -284,7 +286,7 @@
digspeed_wielded = 1
force_wielded = 25.0
/obj/item/weapon/pickaxe/diamonddrill //When people ask about the badass leader of the mining tools, they are talking about ME!
/obj/item/pickaxe/diamonddrill //When people ask about the badass leader of the mining tools, they are talking about ME!
name = "diamond mining drill"
icon_state = "diamonddrill"
item_state = "jackhammer"
@@ -304,7 +306,7 @@
action_button_name = null
/obj/item/weapon/pickaxe/borgdrill
/obj/item/pickaxe/borgdrill
name = "cyborg mining drill"
icon_state = "diamonddrill"
item_state = "jackhammer"
@@ -323,7 +325,7 @@
/*****************************Shovel********************************/
/obj/item/weapon/shovel
/obj/item/shovel
name = "shovel"
desc = "A large tool for digging and moving dirt."
icon = 'icons/obj/tools.dmi'
@@ -340,7 +342,7 @@
sharp = 0
edge = 1
/obj/item/weapon/shovel/spade
/obj/item/shovel/spade
name = "spade"
desc = "A small tool for digging and moving dirt."
icon_state = "spade"
@@ -480,7 +482,7 @@
T.attackby(C, user)
return
if (C.iswelder())
var/obj/item/weapon/weldingtool/WT = C
var/obj/item/weldingtool/WT = C
if(WT.remove_fuel(0, user))
to_chat(user, "<span class='notice'>Slicing apart connectors ...</span>")
new /obj/item/stack/rods(src.loc)
@@ -522,14 +524,14 @@
/obj/vehicle/train/cargo/engine/mining/Initialize()
. = ..()
cell = new /obj/item/weapon/cell/high(src)
cell = new /obj/item/cell/high(src)
key = null
var/image/I = new(icon = 'icons/obj/cart.dmi', icon_state = "[icon_state]_overlay", layer = src.layer + 0.2) //over mobs
add_overlay(I)
turn_off() //so engine verbs are correctly set
/obj/vehicle/train/cargo/engine/mining/attackby(obj/item/weapon/W as obj, mob/user as mob)
if(istype(W, /obj/item/weapon/key/minecarts))
/obj/vehicle/train/cargo/engine/mining/attackby(obj/item/W as obj, mob/user as mob)
if(istype(W, /obj/item/key/minecarts))
if(!key)
user.drop_from_inventory(W,src)
key = W
@@ -565,7 +567,7 @@
/obj/vehicle/train/cargo/trolley/mining/Move(var/turf/destination)
return ((locate(/obj/structure/track) in destination)) ? ..() : FALSE
/obj/item/weapon/key/minecarts
/obj/item/key/minecarts
name = "key"
desc = "A keyring with a small steel key, and a pickaxe shaped fob."
icon = 'icons/obj/vehicles.dmi'
@@ -574,7 +576,7 @@
/**********************Pinpointer**********************/
/obj/item/weapon/ore_radar
/obj/item/ore_radar
name = "scanner pad"
desc = "An antiquated device that can detect ore in a wide radius around the user."
icon = 'icons/obj/device.dmi'
@@ -590,7 +592,7 @@
var/active = 0
/obj/item/weapon/ore_radar/attack_self(mob/user)
/obj/item/ore_radar/attack_self(mob/user)
if(!active)
active = 1
to_chat(usr, "<span class='notice'>You activate the pinpointer</span>")
@@ -601,13 +603,13 @@
to_chat(usr, "<span>You deactivate the pinpointer</span>")
STOP_PROCESSING(SSfast_process, src)
/obj/item/weapon/ore_radar/process()
/obj/item/ore_radar/process()
if (active)
workdisk()
else
STOP_PROCESSING(SSfast_process, src)
/obj/item/weapon/ore_radar/proc/workdisk()
/obj/item/ore_radar/proc/workdisk()
if(!src.loc)
active = 0
@@ -725,7 +727,7 @@
/**********************Lazarus Injector**********************/
/obj/item/weapon/lazarus_injector
/obj/item/lazarus_injector
name = "lazarus injector"
desc = "An injector with a cocktail of nanomachines and chemicals, this device can seemingly raise animals from the dead. If no effect in 3 days please call customer support."
icon = 'icons/obj/syringe.dmi'
@@ -740,7 +742,7 @@
var/revive_type = TYPE_ORGANIC //So you can't revive boss monsters or robots with it
origin_tech = list(TECH_BIO = 7, TECH_MATERIAL = 4)
/obj/item/weapon/lazarus_injector/afterattack(atom/target, mob/user, proximity_flag)
/obj/item/lazarus_injector/afterattack(atom/target, mob/user, proximity_flag)
if(!loaded)
return
if(isliving(target) && proximity_flag)
@@ -766,11 +768,11 @@
to_chat(user, "<span class='info'>[src] is only effective on lesser beings.</span>")
return
/obj/item/weapon/lazarus_injector/emp_act()
/obj/item/lazarus_injector/emp_act()
if(!malfunctioning)
malfunctioning = 1
/obj/item/weapon/lazarus_injector/examine(mob/user)
/obj/item/lazarus_injector/examine(mob/user)
..()
if(!loaded)
to_chat(user, "<span class='info'>[src] is empty.</span>")
@@ -779,16 +781,16 @@
/**********************Point Transfer Card**********************/
/obj/item/weapon/card/mining_point_card
/obj/item/card/mining_point_card
name = "mining points card"
desc = "A small card preloaded with mining points. Swipe your ID card over it to transfer the points, then discard."
icon_state = "data"
var/points = 500
/obj/item/weapon/card/mining_point_card/attackby(obj/item/I, mob/user, params)
if(istype(I, /obj/item/weapon/card/id))
/obj/item/card/mining_point_card/attackby(obj/item/I, mob/user, params)
if(istype(I, /obj/item/card/id))
if(points)
var/obj/item/weapon/card/id/C = I
var/obj/item/card/id/C = I
C.mining_points += points
to_chat(user, "<span class='info'>You transfer [points] points to [C].</span>")
points = 0
@@ -796,7 +798,7 @@
to_chat(user, "<span class='info'>There's no points left on [src].</span>")
..()
/obj/item/weapon/card/mining_point_card/examine(mob/user)
/obj/item/card/mining_point_card/examine(mob/user)
..()
to_chat(user, "There's [points] point\s on the card.")
@@ -804,7 +806,7 @@
var/list/total_extraction_beacons = list()
/obj/item/weapon/extraction_pack
/obj/item/extraction_pack
name = "warp extraction pack"
desc = "A complex device that warps nonliving matter to nearby locations."
contained_sprite = 1
@@ -816,11 +818,11 @@ var/list/total_extraction_beacons = list()
var/uses_left = 3
origin_tech = list(TECH_BLUESPACE = 3, TECH_PHORON = 4, TECH_ENGINEERING = 4)
/obj/item/weapon/extraction_pack/examine()
/obj/item/extraction_pack/examine()
. = ..()
usr.show_message("It has [uses_left] uses remaining.", 1)
/obj/item/weapon/extraction_pack/attack_self(mob/user)
/obj/item/extraction_pack/attack_self(mob/user)
var/list/possible_beacons = list()
for(var/B in total_extraction_beacons)
var/obj/structure/extraction_point/EP = B
@@ -840,7 +842,7 @@ var/list/total_extraction_beacons = list()
return
beacon = A
/obj/item/weapon/extraction_pack/afterattack(atom/movable/A, mob/living/carbon/human/user)
/obj/item/extraction_pack/afterattack(atom/movable/A, mob/living/carbon/human/user)
if(!beacon)
to_chat(user, "[src] is not linked to a beacon, and cannot be used.")
return
@@ -905,7 +907,7 @@ var/list/total_extraction_beacons = list()
/**********************Resonator**********************/
/obj/item/weapon/resonator
/obj/item/resonator
name = "resonator"
contained_sprite = 1
icon = 'icons/obj/mining_contained.dmi'
@@ -921,7 +923,7 @@ var/list/total_extraction_beacons = list()
var/quick_burst_mod = 0.8
origin_tech = list(TECH_MAGNET = 3, TECH_ENGINEERING = 3)
/obj/item/weapon/resonator/upgraded
/obj/item/resonator/upgraded
name = "upgraded resonator"
desc = "An upgraded version of the resonator that can produce more fields at once."
icon_state = "resonatoru"
@@ -931,7 +933,7 @@ var/list/total_extraction_beacons = list()
quick_burst_mod = 1
burst_time = 15
/obj/item/weapon/resonator/proc/CreateResonance(target, creator)
/obj/item/resonator/proc/CreateResonance(target, creator)
var/turf/T = get_turf(target)
var/obj/effect/resonance/R = locate(/obj/effect/resonance) in T
if(R)
@@ -943,7 +945,7 @@ var/list/total_extraction_beacons = list()
var/obj/effect/resonance/RE = new /obj/effect/resonance(T, creator, burst_time, src)
fields += RE
/obj/item/weapon/resonator/attack_self(mob/user)
/obj/item/resonator/attack_self(mob/user)
if(burst_time == 50)
burst_time = 30
to_chat(user, "<span class='info'>You set the resonator's fields to detonate after 3 seconds.</span>")
@@ -951,7 +953,7 @@ var/list/total_extraction_beacons = list()
burst_time = 50
to_chat(user, "<span class='info'>You set the resonator's fields to detonate after 5 seconds.</span>")
/obj/item/weapon/resonator/afterattack(atom/target, mob/user, proximity_flag)
/obj/item/resonator/afterattack(atom/target, mob/user, proximity_flag)
..()
if(user.Adjacent(target))
if(isturf(target))
@@ -967,7 +969,7 @@ var/list/total_extraction_beacons = list()
mouse_opacity = 0
var/resonance_damage = 20
var/creator
var/obj/item/weapon/resonator/res
var/obj/item/resonator/res
/obj/effect/resonance/New(loc, set_creator, timetoburst, set_resonator)
..()
@@ -1003,7 +1005,7 @@ var/list/total_extraction_beacons = list()
/******************************Ore Magnet*******************************/
/obj/item/weapon/oremagnet
/obj/item/oremagnet
name = "ore magnet"
contained_sprite = 1
icon = 'icons/obj/mining_contained.dmi'
@@ -1015,21 +1017,21 @@ var/list/total_extraction_beacons = list()
throwforce = 5
origin_tech = list(TECH_MAGNET = 4, TECH_ENGINEERING = 3)
/obj/item/weapon/oremagnet/attack_self(mob/user)
/obj/item/oremagnet/attack_self(mob/user)
if (use_check_and_message(user))
return
toggle_on(user)
/obj/item/weapon/oremagnet/process()
for(var/obj/item/weapon/ore/O in oview(7, loc))
/obj/item/oremagnet/process()
for(var/obj/item/ore/O in oview(7, loc))
if(prob(80))
step_to(O, src.loc, 0)
if (TICK_CHECK)
return
/obj/item/weapon/oremagnet/proc/toggle_on(mob/user)
/obj/item/oremagnet/proc/toggle_on(mob/user)
if (!isprocessing)
START_PROCESSING(SSprocessing, src)
else
@@ -1038,13 +1040,13 @@ var/list/total_extraction_beacons = list()
if (user)
to_chat(user, "<span class='[isprocessing ? "notice" : "warning"]'>You switch [isprocessing ? "on" : "off"] [src].</span>")
/obj/item/weapon/oremagnet/Destroy()
/obj/item/oremagnet/Destroy()
STOP_PROCESSING(SSprocessing, src)
return ..()
/******************************Ore Summoner*******************************/
/obj/item/weapon/oreportal
/obj/item/oreportal
name = "ore summoner"
contained_sprite = 1
icon = 'icons/obj/mining_contained.dmi'
@@ -1057,12 +1059,12 @@ var/list/total_extraction_beacons = list()
origin_tech = list(TECH_BLUESPACE = 4, TECH_ENGINEERING = 3)
var/last_oresummon_time = 0
/obj/item/weapon/oreportal/attack_self(mob/user)
/obj/item/oreportal/attack_self(mob/user)
if(world.time - last_oresummon_time >= 25)
to_chat(user, "<span class='notice'>You pulse the ore summoner.</span>")
last_oresummon_time = world.time
var/limit = 50
for(var/obj/item/weapon/ore/O in orange(7,user))
for(var/obj/item/ore/O in orange(7,user))
if(limit <= 0)
break
single_spark(O.loc)
@@ -1074,7 +1076,7 @@ var/list/total_extraction_beacons = list()
return 0
/******************************Sculpting*******************************/
/obj/item/weapon/autochisel
/obj/item/autochisel
name = "auto-chisel"
icon = 'icons/obj/tools.dmi'
icon_state = "jackhammer"
@@ -1113,7 +1115,7 @@ var/list/total_extraction_beacons = list()
to_chat(user, "<span class='notice'>You [anchored ? "un" : ""]anchor the [name].</span>")
anchored = !anchored
if (istype(C, /obj/item/weapon/autochisel))
if (istype(C, /obj/item/autochisel))
if(!sculpted)
if(last_struck)
return
@@ -1252,13 +1254,13 @@ var/list/total_extraction_beacons = list()
/******************************Seismic Charge*******************************/
/obj/item/weapon/plastique/seismic
/obj/item/plastique/seismic
name = "seismic charge"
desc = "A complex mining device that utilizes a seismic detonation to eliminate weak asteroid turf in a wide radius."
origin_tech = list(TECH_MAGNET = 2, TECH_MATERIAL = 4, TECH_PHORON = 2)
timer = 15
/obj/item/weapon/plastique/seismic/explode(var/turf/location)
/obj/item/plastique/seismic/explode(var/turf/location)
if(!target)
target = get_atom_on_turf(src)
if(!target)
@@ -1291,7 +1293,7 @@ var/list/total_extraction_beacons = list()
qdel(src)
/obj/item/weapon/plastique/seismic/proc/drill(var/turf/drill_loc)
/obj/item/plastique/seismic/proc/drill(var/turf/drill_loc)
for(var/turf/simulated/mineral/M in range(7,drill_loc))
if(prob(75))
M.GetDrilled(1)

View File

@@ -47,7 +47,7 @@ var/list/mineral_can_smooth_with = list(
var/excavation_level = 0
var/list/finds
var/archaeo_overlay = ""
var/obj/item/weapon/last_find
var/obj/item/last_find
var/datum/artifact_find/artifact_find
var/obj/effect/mineral/my_mineral
@@ -146,19 +146,19 @@ var/list/mineral_can_smooth_with = list(
. = ..()
if(istype(AM,/mob/living/carbon/human))
var/mob/living/carbon/human/H = AM
if((istype(H.l_hand,/obj/item/weapon/pickaxe)) && (!H.hand))
var/obj/item/weapon/pickaxe/P = H.l_hand
if((istype(H.l_hand,/obj/item/pickaxe)) && (!H.hand))
var/obj/item/pickaxe/P = H.l_hand
if(P.autodrill)
attackby(H.l_hand,H)
else if((istype(H.r_hand,/obj/item/weapon/pickaxe)) && H.hand)
var/obj/item/weapon/pickaxe/P = H.r_hand
else if((istype(H.r_hand,/obj/item/pickaxe)) && H.hand)
var/obj/item/pickaxe/P = H.r_hand
if(P.autodrill)
attackby(H.r_hand,H)
else if(istype(AM,/mob/living/silicon/robot))
var/mob/living/silicon/robot/R = AM
if(istype(R.module_active,/obj/item/weapon/pickaxe))
if(istype(R.module_active,/obj/item/pickaxe))
attackby(R.module_active,R)
else if(istype(AM,/obj/mecha))
@@ -240,7 +240,7 @@ var/list/mineral_can_smooth_with = list(
new /obj/effect/mineral(src, mineral)
//Not even going to touch this pile of spaghetti
/turf/simulated/mineral/attackby(obj/item/weapon/W as obj, mob/user as mob)
/turf/simulated/mineral/attackby(obj/item/W as obj, mob/user as mob)
if (!usr.IsAdvancedToolUser())
to_chat(usr, "<span class='warning'>You don't have the dexterity to do this!</span>")
@@ -267,12 +267,12 @@ var/list/mineral_can_smooth_with = list(
to_chat(user, "<span class='notice'>\icon[P] [src] has been excavated to a depth of [2*excavation_level]cm.</span>")
return
if (istype(W, /obj/item/weapon/pickaxe) && W.simulated) // Pickaxe offhand is not simulated.
if (istype(W, /obj/item/pickaxe) && W.simulated) // Pickaxe offhand is not simulated.
var/turf/T = user.loc
if (!( istype(T, /turf) ))
return
var/obj/item/weapon/pickaxe/P = W
var/obj/item/pickaxe/P = W
if(last_act + P.digspeed > world.time)//prevents message spam
return
@@ -310,11 +310,11 @@ var/list/mineral_can_smooth_with = list(
P.drilling = 0
if(prob(50))
var/obj/item/weapon/ore/O
var/obj/item/ore/O
if(prob(25) && (mineral) && (P.excavation_amount >= 30))
O = new mineral.ore (src)
else
O = new /obj/item/weapon/ore(src)
O = new /obj/item/ore(src)
if(istype(O))
geologic_data.UpdateNearbyArtifactInfo(src)
O.geologic_data = geologic_data
@@ -368,7 +368,7 @@ var/list/mineral_can_smooth_with = list(
to_chat(user, "<span class='notice'> You stop [P.drill_verb] [src].</span>")
P.drilling = 0
if (istype(W, /obj/item/weapon/autochisel))
if (istype(W, /obj/item/autochisel))
if(last_act + 80 > world.time)//prevents message spam
return
@@ -395,7 +395,7 @@ var/list/mineral_can_smooth_with = list(
return
clear_ore_effects()
var/obj/item/weapon/ore/O = new mineral.ore (src)
var/obj/item/ore/O = new mineral.ore (src)
if(istype(O))
geologic_data.UpdateNearbyArtifactInfo(src)
O.geologic_data = geologic_data
@@ -440,15 +440,15 @@ var/list/mineral_can_smooth_with = list(
/turf/simulated/mineral/proc/excavate_find(var/prob_clean = 0, var/datum/find/F)
//with skill and luck, players can cleanly extract finds
//otherwise, they come out inside a chunk of rock
var/obj/item/weapon/X
var/obj/item/X
if(prob_clean)
X = new /obj/item/weapon/archaeological_find(src, new_item_type = F.find_type)
X = new /obj/item/archaeological_find(src, new_item_type = F.find_type)
else
X = new /obj/item/weapon/ore/strangerock(src, inside_item_type = F.find_type)
X = new /obj/item/ore/strangerock(src, inside_item_type = F.find_type)
geologic_data.UpdateNearbyArtifactInfo(src)
X:geologic_data = geologic_data
//some find types delete the /obj/item/weapon/archaeological_find and replace it with something else, this handles when that happens
//some find types delete the /obj/item/archaeological_find and replace it with something else, this handles when that happens
//yuck
var/display_name = "something"
if(!X)
@@ -493,12 +493,12 @@ var/list/mineral_can_smooth_with = list(
if(5)
var/quantity = rand(1,3)
for(var/i=0, i<quantity, i++)
new /obj/item/weapon/material/shard(src)
new /obj/item/material/shard(src)
if(6)
var/quantity = rand(1,3)
for(var/i=0, i<quantity, i++)
new /obj/item/weapon/material/shard/phoron(src)
new /obj/item/material/shard/phoron(src)
if(7)
var/obj/item/stack/material/uranium/R = new(src)
@@ -660,7 +660,7 @@ var/list/asteroid_floor_smooth = list(
/turf/unsimulated/floor/asteroid/is_plating()
return 0
/turf/unsimulated/floor/asteroid/attackby(obj/item/weapon/W as obj, mob/user as mob)
/turf/unsimulated/floor/asteroid/attackby(obj/item/W as obj, mob/user as mob)
if(!W || !user)
return 0
@@ -692,10 +692,10 @@ var/list/asteroid_floor_smooth = list(
return
var/static/list/usable_tools = typecacheof(list(
/obj/item/weapon/shovel,
/obj/item/weapon/pickaxe/diamonddrill,
/obj/item/weapon/pickaxe/drill,
/obj/item/weapon/pickaxe/borgdrill
/obj/item/shovel,
/obj/item/pickaxe/diamonddrill,
/obj/item/pickaxe/drill,
/obj/item/pickaxe/borgdrill
))
if(is_type_in_typecache(W, usable_tools))
@@ -774,16 +774,16 @@ var/list/asteroid_floor_smooth = list(
gets_dug(user)
else if(istype(W,/obj/item/weapon/storage/bag/ore))
var/obj/item/weapon/storage/bag/ore/S = W
else if(istype(W,/obj/item/storage/bag/ore))
var/obj/item/storage/bag/ore/S = W
if(S.collection_mode)
for(var/obj/item/weapon/ore/O in contents)
for(var/obj/item/ore/O in contents)
O.attackby(W,user)
return
else if(istype(W,/obj/item/weapon/storage/bag/fossils))
var/obj/item/weapon/storage/bag/fossils/S = W
else if(istype(W,/obj/item/storage/bag/fossils))
var/obj/item/storage/bag/fossils/S = W
if(S.collection_mode)
for(var/obj/item/weapon/fossil/F in contents)
for(var/obj/item/fossil/F in contents)
F.attackby(W,user)
return
@@ -796,32 +796,32 @@ var/list/asteroid_floor_smooth = list(
add_overlay("asteroid_dug", TRUE)
if(prob(75))
new /obj/item/weapon/ore/glass(src)
new /obj/item/ore/glass(src)
if(prob(25) && has_resources)
var/list/ore = list()
for(var/metal in resources)
switch(metal)
if("silicates")
ore += /obj/item/weapon/ore/glass
ore += /obj/item/ore/glass
if("carbonaceous rock")
ore += /obj/item/weapon/ore/coal
ore += /obj/item/ore/coal
if("iron")
ore += /obj/item/weapon/ore/iron
ore += /obj/item/ore/iron
if("gold")
ore += /obj/item/weapon/ore/gold
ore += /obj/item/ore/gold
if("silver")
ore += /obj/item/weapon/ore/silver
ore += /obj/item/ore/silver
if("diamond")
ore += /obj/item/weapon/ore/diamond
ore += /obj/item/ore/diamond
if("uranium")
ore += /obj/item/weapon/ore/uranium
ore += /obj/item/ore/uranium
if("phoron")
ore += /obj/item/weapon/ore/phoron
ore += /obj/item/ore/phoron
if("osmium")
ore += /obj/item/weapon/ore/osmium
ore += /obj/item/ore/osmium
if("hydrogen")
ore += /obj/item/weapon/ore/hydrogen
ore += /obj/item/ore/hydrogen
else
if(prob(25))
switch(rand(1,5))
@@ -834,9 +834,9 @@ var/list/asteroid_floor_smooth = list(
if(4)
ore += /obj/random/loot
if(5)
ore += /obj/item/weapon/ore/glass
ore += /obj/item/ore/glass
else
ore += /obj/item/weapon/ore/glass
ore += /obj/item/ore/glass
if (ore.len)
var/ore_path = pick(ore)
if(ore)
@@ -861,11 +861,11 @@ var/list/asteroid_floor_smooth = list(
if(istype(M,/mob/living/silicon/robot))
var/mob/living/silicon/robot/R = M
if(R.module)
if(istype(R.module_state_1,/obj/item/weapon/storage/bag/ore))
if(istype(R.module_state_1,/obj/item/storage/bag/ore))
attackby(R.module_state_1,R)
else if(istype(R.module_state_2,/obj/item/weapon/storage/bag/ore))
else if(istype(R.module_state_2,/obj/item/storage/bag/ore))
attackby(R.module_state_2,R)
else if(istype(R.module_state_3,/obj/item/weapon/storage/bag/ore))
else if(istype(R.module_state_3,/obj/item/storage/bag/ore))
attackby(R.module_state_3,R)
else
return

View File

@@ -1,13 +1,13 @@
/mob/living/silicon/robot/drone/mining
icon_state = "miningdrone"
law_type = /datum/ai_laws/mining_drone
module_type = /obj/item/weapon/robot_module/mining_drone/basic
holder_type = /obj/item/weapon/holder/drone/mining
module_type = /obj/item/robot_module/mining_drone/basic
holder_type = /obj/item/holder/drone/mining
maxHealth = 45
health = 45
pass_flags = PASSTABLE
req_access = list(access_mining, access_robotics)
idcard_type = /obj/item/weapon/card/id/minedrone
idcard_type = /obj/item/card/id/minedrone
speed = -1
var/health_upgrade
var/ranged_upgrade
@@ -48,7 +48,7 @@
if(!laws) laws = new law_type
if(!module) module = new module_type(src)
if(!jetpack)
jetpack = new /obj/item/weapon/tank/jetpack/carbondioxide/synthetic(src)
jetpack = new /obj/item/tank/jetpack/carbondioxide/synthetic(src)
flavor_text = "It's a tiny little mining drone. The casing is stamped with an corporate logo and the subscript: '[current_map.company_name] Automated Pickaxe!'"
playsound(src.loc, 'sound/machines/twobeep.ogg', 50, 0)
@@ -65,13 +65,13 @@
to_chat(src, "Remember, <b>you DO NOT take orders from the AI.</b>")
to_chat(src, "Use <b>say ;Hello</b> to talk to other drones and <b>say Hello</b> to speak silently to your nearby fellows.")
/mob/living/silicon/robot/drone/mining/attackby(var/obj/item/weapon/W, var/mob/user)
/mob/living/silicon/robot/drone/mining/attackby(var/obj/item/W, var/mob/user)
if(istype(W, /obj/item/borg/upgrade/))
to_chat(user, "<span class='danger'>\The [src] is not compatible with \the [W].</span>")
return
else if (istype(W, /obj/item/weapon/card/id)||istype(W, /obj/item/device/pda))
else if (istype(W, /obj/item/card/id)||istype(W, /obj/item/device/pda))
var/choice = input("Select your choice.") in list("Reboot","Recycle")
if(choice=="Reboot")
@@ -89,7 +89,7 @@
return
else
var/obj/item/weapon/card/id/ID = W
var/obj/item/card/id/ID = W
if(!allowed(usr))
to_chat(user, "<span class='danger'>Access denied.</span>")
return
@@ -141,7 +141,7 @@
// Create the reply message
to_chat(usr, "<span class='warning'>You begin printing the message.</span>")
if(do_after(src,20))
var/obj/item/weapon/paper/P = new /obj/item/weapon/paper(src.loc)
var/obj/item/paper/P = new /obj/item/paper(src.loc)
P.name = "mining report - [customname]"
P.info = {"<center><img src = ntlogo.png></center>
<center><b><i>NanoTrasen Mining Drone Report</b></i><br>
@@ -186,13 +186,13 @@
qdel(M.module)
M.module = null
if(M.ranged_upgrade)
new /obj/item/weapon/robot_module/mining_drone/drillandka(M)
new /obj/item/robot_module/mining_drone/drillandka(M)
else
new /obj/item/weapon/robot_module/mining_drone/drill(M)
new /obj/item/robot_module/mining_drone/drill(M)
M.module.rebuild()
M.recalculate_synth_capacities()
if(!M.jetpack)
M.jetpack = new /obj/item/weapon/tank/jetpack/carbondioxide/synthetic(src)
M.jetpack = new /obj/item/tank/jetpack/carbondioxide/synthetic(src)
qdel(src)
/obj/item/device/mine_bot_ugprade/health
@@ -222,12 +222,12 @@
qdel(M.module)
M.module = null
if(M.melee_upgrade)
new /obj/item/weapon/robot_module/mining_drone/drillandka(M)
new /obj/item/robot_module/mining_drone/drillandka(M)
else
new /obj/item/weapon/robot_module/mining_drone/ka(M)
new /obj/item/robot_module/mining_drone/ka(M)
M.ranged_upgrade = 1
M.module.rebuild()
M.recalculate_synth_capacities()
if(!M.jetpack)
M.jetpack = new /obj/item/weapon/tank/jetpack/carbondioxide/synthetic(src)
M.jetpack = new /obj/item/tank/jetpack/carbondioxide/synthetic(src)
qdel(src)

View File

@@ -126,15 +126,15 @@
if (src.output)
processing = 1;
icon_state = "coinpress1"
var/obj/item/weapon/moneybag/M
var/obj/item/moneybag/M
switch(chosen)
if(DEFAULT_WALL_MATERIAL)
while(amt_iron > 0 && coinsToProduce > 0)
if (locate(/obj/item/weapon/moneybag,output.loc))
M = locate(/obj/item/weapon/moneybag,output.loc)
if (locate(/obj/item/moneybag,output.loc))
M = locate(/obj/item/moneybag,output.loc)
else
M = new/obj/item/weapon/moneybag(output.loc)
new/obj/item/weapon/coin/iron(M)
M = new/obj/item/moneybag(output.loc)
new/obj/item/coin/iron(M)
amt_iron -= 20
coinsToProduce--
newCoins++
@@ -142,11 +142,11 @@
sleep(5);
if("gold")
while(amt_gold > 0 && coinsToProduce > 0)
if (locate(/obj/item/weapon/moneybag,output.loc))
M = locate(/obj/item/weapon/moneybag,output.loc)
if (locate(/obj/item/moneybag,output.loc))
M = locate(/obj/item/moneybag,output.loc)
else
M = new/obj/item/weapon/moneybag(output.loc)
new /obj/item/weapon/coin/gold(M)
M = new/obj/item/moneybag(output.loc)
new /obj/item/coin/gold(M)
amt_gold -= 20
coinsToProduce--
newCoins++
@@ -154,11 +154,11 @@
sleep(5);
if("silver")
while(amt_silver > 0 && coinsToProduce > 0)
if (locate(/obj/item/weapon/moneybag,output.loc))
M = locate(/obj/item/weapon/moneybag,output.loc)
if (locate(/obj/item/moneybag,output.loc))
M = locate(/obj/item/moneybag,output.loc)
else
M = new/obj/item/weapon/moneybag(output.loc)
new /obj/item/weapon/coin/silver(M)
M = new/obj/item/moneybag(output.loc)
new /obj/item/coin/silver(M)
amt_silver -= 20
coinsToProduce--
newCoins++
@@ -166,11 +166,11 @@
sleep(5);
if("diamond")
while(amt_diamond > 0 && coinsToProduce > 0)
if (locate(/obj/item/weapon/moneybag,output.loc))
M = locate(/obj/item/weapon/moneybag,output.loc)
if (locate(/obj/item/moneybag,output.loc))
M = locate(/obj/item/moneybag,output.loc)
else
M = new/obj/item/weapon/moneybag(output.loc)
new /obj/item/weapon/coin/diamond(M)
M = new/obj/item/moneybag(output.loc)
new /obj/item/coin/diamond(M)
amt_diamond -= 20
coinsToProduce--
newCoins++
@@ -178,11 +178,11 @@
sleep(5);
if("phoron")
while(amt_phoron > 0 && coinsToProduce > 0)
if (locate(/obj/item/weapon/moneybag,output.loc))
M = locate(/obj/item/weapon/moneybag,output.loc)
if (locate(/obj/item/moneybag,output.loc))
M = locate(/obj/item/moneybag,output.loc)
else
M = new/obj/item/weapon/moneybag(output.loc)
new /obj/item/weapon/coin/phoron(M)
M = new/obj/item/moneybag(output.loc)
new /obj/item/coin/phoron(M)
amt_phoron -= 20
coinsToProduce--
newCoins++
@@ -190,11 +190,11 @@
sleep(5);
if("uranium")
while(amt_uranium > 0 && coinsToProduce > 0)
if (locate(/obj/item/weapon/moneybag,output.loc))
M = locate(/obj/item/weapon/moneybag,output.loc)
if (locate(/obj/item/moneybag,output.loc))
M = locate(/obj/item/moneybag,output.loc)
else
M = new/obj/item/weapon/moneybag(output.loc)
new /obj/item/weapon/coin/uranium(M)
M = new/obj/item/moneybag(output.loc)
new /obj/item/coin/uranium(M)
amt_uranium -= 20
coinsToProduce--
newCoins++

View File

@@ -1,6 +1,6 @@
/*****************************Money bag********************************/
/obj/item/weapon/moneybag
/obj/item/moneybag
icon = 'icons/obj/storage.dmi'
name = "Money bag"
icon_state = "moneybag"
@@ -9,7 +9,7 @@
throwforce = 2.0
w_class = 4.0
/obj/item/weapon/moneybag/attack_hand(user as mob)
/obj/item/moneybag/attack_hand(user as mob)
var/amt_gold = 0
var/amt_silver = 0
var/amt_diamond = 0
@@ -17,18 +17,18 @@
var/amt_phoron = 0
var/amt_uranium = 0
for (var/obj/item/weapon/coin/C in contents)
if (istype(C,/obj/item/weapon/coin/diamond))
for (var/obj/item/coin/C in contents)
if (istype(C,/obj/item/coin/diamond))
amt_diamond++;
if (istype(C,/obj/item/weapon/coin/phoron))
if (istype(C,/obj/item/coin/phoron))
amt_phoron++;
if (istype(C,/obj/item/weapon/coin/iron))
if (istype(C,/obj/item/coin/iron))
amt_iron++;
if (istype(C,/obj/item/weapon/coin/silver))
if (istype(C,/obj/item/coin/silver))
amt_silver++;
if (istype(C,/obj/item/weapon/coin/gold))
if (istype(C,/obj/item/coin/gold))
amt_gold++;
if (istype(C,/obj/item/weapon/coin/uranium))
if (istype(C,/obj/item/coin/uranium))
amt_uranium++;
var/dat = text("<b>The contents of the moneybag reveal...</b><br>")
@@ -46,41 +46,41 @@
dat += text("Uranium coins: [amt_uranium] <A href='?src=\ref[src];remove=uranium'>Remove one</A><br>")
user << browse("[dat]", "window=moneybag")
/obj/item/weapon/moneybag/attackby(obj/item/weapon/W as obj, mob/user as mob)
/obj/item/moneybag/attackby(obj/item/W as obj, mob/user as mob)
..()
//TODO: Check this code
if (istype(W, /obj/item/weapon/coin))
var/obj/item/weapon/coin/C = W
if (istype(W, /obj/item/coin))
var/obj/item/coin/C = W
to_chat(user, "<span class='notice'>You add the [C.name] into the bag.</span>")
usr.drop_item()
contents += C
if (istype(W, /obj/item/weapon/moneybag))
var/obj/item/weapon/moneybag/C = W
if (istype(W, /obj/item/moneybag))
var/obj/item/moneybag/C = W
for (var/obj/O in C.contents)
contents += O;
to_chat(user, "<span class='notice'>You empty the [C.name] into the bag.</span>")
return
/obj/item/weapon/moneybag/Topic(href, href_list)
/obj/item/moneybag/Topic(href, href_list)
if(..())
return 1
usr.set_machine(src)
src.add_fingerprint(usr)
if(href_list["remove"])
var/obj/item/weapon/coin/COIN
var/obj/item/coin/COIN
switch(href_list["remove"])
if("gold")
COIN = locate(/obj/item/weapon/coin/gold,src.contents)
COIN = locate(/obj/item/coin/gold,src.contents)
if("silver")
COIN = locate(/obj/item/weapon/coin/silver,src.contents)
COIN = locate(/obj/item/coin/silver,src.contents)
if("iron")
COIN = locate(/obj/item/weapon/coin/iron,src.contents)
COIN = locate(/obj/item/coin/iron,src.contents)
if("diamond")
COIN = locate(/obj/item/weapon/coin/diamond,src.contents)
COIN = locate(/obj/item/coin/diamond,src.contents)
if("phoron")
COIN = locate(/obj/item/weapon/coin/phoron,src.contents)
COIN = locate(/obj/item/coin/phoron,src.contents)
if("uranium")
COIN = locate(/obj/item/weapon/coin/uranium,src.contents)
COIN = locate(/obj/item/coin/uranium,src.contents)
if(!COIN)
return
COIN.forceMove(src.loc)
@@ -88,13 +88,13 @@
/obj/item/weapon/moneybag/vault
/obj/item/moneybag/vault
/obj/item/weapon/moneybag/vault/New()
/obj/item/moneybag/vault/New()
..()
new /obj/item/weapon/coin/silver(src)
new /obj/item/weapon/coin/silver(src)
new /obj/item/weapon/coin/silver(src)
new /obj/item/weapon/coin/silver(src)
new /obj/item/weapon/coin/gold(src)
new /obj/item/weapon/coin/gold(src)
new /obj/item/coin/silver(src)
new /obj/item/coin/silver(src)
new /obj/item/coin/silver(src)
new /obj/item/coin/silver(src)
new /obj/item/coin/gold(src)
new /obj/item/coin/gold(src)

View File

@@ -1,4 +1,4 @@
/obj/item/weapon/ore
/obj/item/ore
name = "rock"
icon = 'icons/obj/mining.dmi'
icon_state = "ore1"
@@ -8,25 +8,25 @@
var/datum/geosample/geologic_data
var/material
/obj/item/weapon/ore/uranium
/obj/item/ore/uranium
name = "pitchblende"
icon_state = "ore_uranium"
origin_tech = list(TECH_MATERIAL = 5)
material = ORE_URANIUM
/obj/item/weapon/ore/iron
/obj/item/ore/iron
name = "hematite"
icon_state = "ore_iron"
origin_tech = list(TECH_MATERIAL = 1)
material = ORE_IRON
/obj/item/weapon/ore/coal
/obj/item/ore/coal
name = "raw carbon"
icon_state = "ore_coal"
origin_tech = list(TECH_MATERIAL = 1)
material = ORE_COAL
/obj/item/weapon/ore/glass
/obj/item/ore/glass
name = "sand"
icon_state = "ore_glass"
origin_tech = list(TECH_MATERIAL = 1)
@@ -34,7 +34,7 @@
slot_flags = SLOT_HOLSTER
// POCKET SAND!
/obj/item/weapon/ore/glass/throw_impact(atom/hit_atom)
/obj/item/ore/glass/throw_impact(atom/hit_atom)
..()
var/mob/living/carbon/human/H = hit_atom
if(istype(H) && H.has_eyes() && prob(85))
@@ -45,51 +45,51 @@
if(istype(loc, /turf/)) qdel(src)
/obj/item/weapon/ore/phoron
/obj/item/ore/phoron
name = "phoron crystals"
icon_state = "ore_phoron"
origin_tech = list(TECH_MATERIAL = 2, TECH_PHORON = 2)
material = ORE_PHORON
/obj/item/weapon/ore/silver
/obj/item/ore/silver
name = "native silver ore"
icon_state = "ore_silver"
origin_tech = list(TECH_MATERIAL = 3)
material = ORE_SILVER
/obj/item/weapon/ore/gold
/obj/item/ore/gold
name = "native gold ore"
icon_state = "ore_gold"
origin_tech = list(TECH_MATERIAL = 4)
material = ORE_GOLD
/obj/item/weapon/ore/diamond
/obj/item/ore/diamond
name = "diamonds"
icon_state = "ore_diamond"
origin_tech = list(TECH_MATERIAL = 6)
material = ORE_DIAMOND
/obj/item/weapon/ore/osmium
/obj/item/ore/osmium
name = "raw platinum"
icon_state = "ore_platinum"
material = ORE_PLATINUM
/obj/item/weapon/ore/hydrogen
/obj/item/ore/hydrogen
name = "raw hydrogen"
icon_state = "ore_hydrogen"
material = ORE_HYDROGEN
/obj/item/weapon/ore/slag
/obj/item/ore/slag
name = "Slag"
desc = "Someone screwed up..."
icon_state = "slag"
material = null
/obj/item/weapon/ore/New()
/obj/item/ore/New()
if((randpixel_xy()) && icon_state == "ore1")
icon_state = "ore[pick(1,2,3)]"
/obj/item/weapon/ore/attackby(obj/item/weapon/W as obj, mob/user as mob)
/obj/item/ore/attackby(obj/item/W as obj, mob/user as mob)
if(istype(W,/obj/item/device/core_sampler))
var/obj/item/device/core_sampler/C = W
C.sample_item(src, user)

View File

@@ -30,7 +30,7 @@ var/global/list/ore_data = list()
smelts_to = "uranium"
result_amount = 5
spread_chance = 15
ore = /obj/item/weapon/ore/uranium
ore = /obj/item/ore/uranium
scan_icon = "mineral_uncommon"
xarch_ages = list(
"thousand" = 999,
@@ -46,7 +46,7 @@ var/global/list/ore_data = list()
alloy = 1
result_amount = 5
spread_chance = 30
ore = /obj/item/weapon/ore/iron
ore = /obj/item/ore/iron
scan_icon = "mineral_common"
worth = 4
@@ -57,7 +57,7 @@ var/global/list/ore_data = list()
alloy = 1
result_amount = 5
spread_chance = 35
ore = /obj/item/weapon/ore/coal
ore = /obj/item/ore/coal
scan_icon = "mineral_common"
worth = 2
@@ -74,7 +74,7 @@ var/global/list/ore_data = list()
compresses_to = "phoron"
result_amount = 5
spread_chance = 25
ore = /obj/item/weapon/ore/phoron
ore = /obj/item/ore/phoron
scan_icon = "mineral_uncommon"
xarch_ages = list(
"thousand" = 999,
@@ -91,7 +91,7 @@ var/global/list/ore_data = list()
smelts_to = "silver"
result_amount = 5
spread_chance = 15
ore = /obj/item/weapon/ore/silver
ore = /obj/item/ore/silver
scan_icon = "mineral_uncommon"
worth = 20
@@ -101,7 +101,7 @@ var/global/list/ore_data = list()
display_name = "native gold"
result_amount = 5
spread_chance = 10
ore = /obj/item/weapon/ore/gold
ore = /obj/item/ore/gold
scan_icon = "mineral_uncommon"
xarch_ages = list(
"thousand" = 999,
@@ -117,7 +117,7 @@ var/global/list/ore_data = list()
compresses_to = "diamond"
result_amount = 5
spread_chance = 5
ore = /obj/item/weapon/ore/diamond
ore = /obj/item/ore/diamond
scan_icon = "mineral_rare"
xarch_source_mineral = "nitrogen"
worth = 50
@@ -130,7 +130,7 @@ var/global/list/ore_data = list()
alloy = 1
result_amount = 5
spread_chance = 15
ore = /obj/item/weapon/ore/osmium
ore = /obj/item/ore/osmium
scan_icon = "mineral_rare"
worth = 15

View File

@@ -10,14 +10,14 @@
var/last_update = 0
var/list/stored_ore = list()
/obj/structure/ore_box/attackby(obj/item/weapon/W as obj, mob/user as mob)
if (istype(W, /obj/item/weapon/ore))
/obj/structure/ore_box/attackby(obj/item/W as obj, mob/user as mob)
if (istype(W, /obj/item/ore))
user.remove_from_mob(W)
src.contents += W
if (istype(W, /obj/item/weapon/storage))
var/obj/item/weapon/storage/S = W
if (istype(W, /obj/item/storage))
var/obj/item/storage/S = W
S.hide_from(user)
for(var/obj/item/weapon/ore/O in S.contents)
for(var/obj/item/ore/O in S.contents)
S.remove_from_storage_deferred(O, src, user) //This will move the item to this item's contents
CHECK_TICK
@@ -34,7 +34,7 @@
stored_ore = list()
for(var/obj/item/weapon/ore/O in contents)
for(var/obj/item/ore/O in contents)
if(stored_ore[O.name])
stored_ore[O.name]++
@@ -90,7 +90,7 @@
to_chat(usr, "<span class='warning'>The ore box is empty</span>")
return
for (var/obj/item/weapon/ore/O in contents)
for (var/obj/item/ore/O in contents)
contents -= O
O.forceMove(src.loc)
to_chat(usr, "<span class='notice'>You empty the ore box</span>")
@@ -99,7 +99,7 @@
/obj/structure/ore_box/ex_act(severity)
if(severity == 1.0 || (severity < 3.0 && prob(50)))
for (var/obj/item/weapon/ore/O in contents)
for (var/obj/item/ore/O in contents)
O.forceMove(src.loc)
O.ex_act(severity++)