Skip to content
This repository was archived by the owner on May 22, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
446 changes: 446 additions & 0 deletions _maps/RandomRuins/LavaRuins/lavaland_surface_worldanvil.dmm

Large diffs are not rendered by default.

617 changes: 510 additions & 107 deletions _maps/RandomRuins/LavaRuins/miningbase.dmm

Large diffs are not rendered by default.

223 changes: 65 additions & 158 deletions _maps/map_files/mining/Lavaland.dmm

Large diffs are not rendered by default.

9 changes: 9 additions & 0 deletions code/datums/ruins/lavaland.dm
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,15 @@
suffix = "lavaland_surface_puzzle.dmm"
cost = 5

/datum/map_template/ruin/lavaland/worldanvil //Plasma magmite upgrading area... always place.
name = "World Anvil"
id = "worldanvil"
description = "An ancient anvil, standing untainted for millennia. Wonders were once forged here."
suffix = "lavaland_surface_worldanvil.dmm"
always_place = TRUE
unpickable = TRUE
cost = 0

/datum/map_template/ruin/lavaland/miningbase //THIS IS THE MINING BASE. DO NOT FUCK WITH THIS UNLESS YOU ARE 100% CERTAIN YOU KNOW WHAT YOU'RE DOING, OR THE MINING BASE WILL DISAPPEAR
name = "Mining Base"
id = "miningbase"
Expand Down
19 changes: 18 additions & 1 deletion code/modules/mining/equipment/mining_charges.dm
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
/obj/item/grenade/plastic/miningcharge
name = "mining charge"
desc = "Used to make big holes in rocks. Only works on rocks!"
icon_state = "mining-charge"
icon = 'icons/obj/mining.dmi'
icon_state = "mining-charge-2"
det_time = 5 //uses real world seconds cause screw you i guess
boom_sizes = list(1,3,5)
alert_admins = FALSE
Expand Down Expand Up @@ -43,3 +44,19 @@
/obj/item/grenade/plastic/miningcharge/deconstruct(disassembled = TRUE) //no gibbing a miner with pda bombs
if(!QDELETED(src))
qdel(src)

/obj/item/grenade/plastic/miningcharge/lesser
name = "lesser mining charge"
desc = "A mining charge. This one seems less powerful than normal. Only works on rocks!"
icon_state = "mining-charge-1"
boom_sizes = list(1,1,1)

/obj/item/grenade/plastic/miningcharge/mega
name = "mega mining charge"
desc = "A mining charge. This one seems much more powerful than normal!"
icon_state = "mining-charge-3"
boom_sizes = list(2,4,7)

/obj/item/storage/backpack/duffelbag/miningcharges/PopulateContents()
for(var/i in 1 to 3)
new /obj/item/grenade/plastic/miningcharge/lesser(src)
72 changes: 72 additions & 0 deletions code/modules/mining/equipment/upgrades.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
//plasma magmite is exclusively used to upgrade mining equipment, by using it on a heated world anvil to make upgradeparts.
/obj/item/magmite
name = "plasma magmite"
desc = "A chunk of plasma magmite, crystallized deep under the planet's surface. It seems to lose strength as it gets further from the planet!"
icon = 'icons/obj/mining.dmi'
icon_state = "Magmite ore"
w_class = WEIGHT_CLASS_NORMAL

/obj/item/magmite_parts
name = "plasma magmite upgrade parts"
desc = "Forged on the legendary World Anvil, these parts can be used to upgrade many kinds of mining equipment."
icon = 'icons/obj/mining.dmi'
icon_state = "upgrade_parts"
w_class = WEIGHT_CLASS_NORMAL
var/inert = FALSE

/obj/item/magmite_parts/Initialize()
. = ..()
addtimer(CALLBACK(src, .proc/go_inert), 10 MINUTES)

/obj/item/magmite_parts/proc/go_inert()
if(inert)
return
visible_message(span_warning("The [src] loses it's glow!"))
inert = TRUE
name = "inert plasma magmite upgrade parts"
icon_state = "upgrade_parts_inert"
desc += "It appears to have lost its magma-like glow."

/obj/item/magmite_parts/proc/restore()
if(!inert)
return
inert = FALSE
name = initial(name)
icon_state = initial(icon_state)
desc = initial(desc)
addtimer(CALLBACK(src, .proc/go_inert), 10 MINUTES)

/obj/item/magmite_parts/afterattack(atom/target, mob/user, proximity_flag, click_parameters)
if(inert)
to_chat(span_warning("[src] appears inert! Perhaps the World Anvil can restore it!"))
switch(target.type)
if(/obj/item/gun/energy/kinetic_accelerator) //basic kinetic accelerator
var/obj/item/gun/energy/kinetic_accelerator/gun = target
if(gun.bayonet)
gun.remove_gun_attachment(item_to_remove = gun.bayonet)
if(gun.gun_light)
gun.remove_gun_attachment(item_to_remove = gun.gun_light)
for(var/obj/item/borg/upgrade/modkit/kit in gun.modkits)
kit.uninstall(gun)
qdel(gun)
var/obj/item/gun/energy/kinetic_accelerator/mega/newgun = new(get_turf(user))
user.put_in_hand(newgun)
to_chat(user,"Harsh tendrils wrap around the kinetic accelerator, merging the parts and kinetic accelerator to form a mega kinetic accelerator.")
qdel(src)
if(/obj/item/gun/energy/plasmacutter/adv)
var/obj/item/gun/energy/plasmacutter/adv/gun = target
qdel(gun)
var/obj/item/gun/energy/plasmacutter/adv/mega/newgun = new(get_turf(user))
user.put_in_hand(newgun)
to_chat(user,"Harsh tendrils wrap around the plasma cutter, merging the parts and cutter to form a mega plasma cutter.")
qdel(src)
if(/obj/item/gun/energy/plasmacutter/scatter) //holy fuck make a new system bro do a /datum/worldanvilrecipe DAMN
var/obj/item/gun/energy/plasmacutter/scatter/gun = target
qdel(gun)
var/obj/item/gun/energy/plasmacutter/scatter/mega/newgun = new(get_turf(user))
user.put_in_hand(newgun)
to_chat(user,"Harsh tendrils wrap around the plasma cutter shotgun, merging the parts and cutter to form a mega plasma cutter shotgun.")
qdel(src)



118 changes: 44 additions & 74 deletions code/modules/mining/lavaland/world_anvil.dm
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,21 @@
resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | UNACIDABLE | ACID_PROOF

var/forge_charges = 0
var/list/placed_objects = list()
var/obj/item/gps/internal //so we can find it!

/obj/item/gps/internal/world_anvil
icon_state = null
gpstag = "Tempered Signal"
desc = "An ancient anvil rests at this location."
invisibility = 100

/obj/structure/world_anvil/Initialize()
. = ..()
internal = new /obj/item/gps/internal/world_anvil(src)

/obj/structure/world_anvil/Destroy()
QDEL_NULL(internal)
. = ..()

/obj/structure/world_anvil/update_icon()
icon_state = forge_charges > 0 ? "anvil_a" : "anvil"
Expand All @@ -28,79 +42,35 @@
if(istype(I,/obj/item/twohanded/required/gibtonite))
var/obj/item/twohanded/required/gibtonite/placed_ore = I
forge_charges = forge_charges + placed_ore.quality
to_chat(user,"You place down the gibtonite on the world anvil, and watch as the gibtonite melts into it. The world anvil is now heated enough for [forge_charges] forge[forge_charges > 1 ? "s" : ""].")
to_chat(user,"You place down the gibtonite on the World Anvil, and watch as the gibtonite melts into it. The World Anvil is now heated enough for [forge_charges] forge[forge_charges > 1 ? "s" : ""].")
qdel(placed_ore)
update_icon()
else //put everything else except gibtonite on the forge
if(user.transferItemToLoc(I, src))
vis_contents += I
placed_objects += I
RegisterSignal(I, COMSIG_MOVABLE_MOVED, .proc/ItemMoved,TRUE)

/obj/structure/world_anvil/proc/ItemMoved(obj/item/I, atom/OldLoc, Dir, Forced)
vis_contents -= I
placed_objects -= I
UnregisterSignal(I, COMSIG_MOVABLE_MOVED)

/obj/structure/world_anvil/attack_hand(mob/user)
if(!LAZYLEN(placed_objects))
to_chat(user,"You must place a piece of plasma magmite and either a kinetic accelerator or advanced plasma cutter on the anvil!")
return ..()
return
if(forge_charges <= 0)
to_chat(user,"The World Anvil is not hot enough to be usable!")
return
var/success = FALSE
switch(I.type)
if(/obj/item/magmite)
if(do_after(user,10 SECONDS, target = src))
new /obj/item/magmite_parts(get_turf(src))
qdel(I)
to_chat(user, "You carefully forge the rough plasma magmite into plasma magmite upgrade parts.")
success = TRUE
if(/obj/item/magmite_parts)
var/obj/item/magmite_parts/parts = I
if(!parts.inert)
to_chat(user,"The magmite upgrade parts are already glowing and usable!")
return
if(do_after(user,5 SECONDS, target = src))
parts.restore()
to_chat(user, "You successfully reheat the magmite upgrade parts. They are now glowing and usable again.")
if(!success)
return
forge_charges--
if(forge_charges <= 0)
to_chat(user,"The anvil is not heated enough to be usable!")
return ..()
var/magmite_amount = 0
var/used_magmite = 0
for(var/obj/item/magmite/placed_magmite in placed_objects)
magmite_amount++
if(magmite_amount <= 0)
to_chat(user,"The anvil does not have any plasma magmite on it!")
return ..()
for(var/obj/item/I in placed_objects)
if(istype(I,/obj/item/gun/energy/kinetic_accelerator) && forge_charges && used_magmite < magmite_amount)
var/obj/item/gun/energy/kinetic_accelerator/gun = I
if(gun.max_mod_capacity != 100)
to_chat(user,"This is not a base kinetic accelerator!")
break
if(gun.bayonet)
gun.remove_gun_attachment(item_to_remove = gun.bayonet)
if(gun.gun_light)
gun.remove_gun_attachment(item_to_remove = gun.gun_light)
for(var/obj/item/borg/upgrade/modkit/kit in gun.modkits)
kit.uninstall(gun)
var/obj/item/gun/energy/kinetic_accelerator/mega/newgun = new(src)
if(user.transferItemToLoc(newgun, src))
vis_contents += newgun
placed_objects += newgun
RegisterSignal(newgun, COMSIG_MOVABLE_MOVED, .proc/ItemMoved,TRUE)
ItemMoved(gun)
qdel(gun)
forge_charges--
used_magmite++
to_chat(user,"Harsh tendrils wrap around the kinetic accelerator, consuming the plasma magmite to form a mega kinetic accelerator.")
if(istype(I,/obj/item/gun/energy/plasmacutter/adv) && forge_charges && used_magmite < magmite_amount)
var/obj/item/gun/energy/plasmacutter/adv/gun = I
if(gun.name != "advanced plasma cutter")
to_chat(user,"This is not an advanced plasma cutter!")
break
var/obj/item/gun/energy/plasmacutter/adv/mega/newgun = new(src)
if(user.transferItemToLoc(newgun, src))
vis_contents += newgun
placed_objects += newgun
RegisterSignal(newgun, COMSIG_MOVABLE_MOVED, .proc/ItemMoved,TRUE)
ItemMoved(gun)
qdel(gun)
forge_charges--
used_magmite++
to_chat(user,"Harsh tendrils wrap around the plasma cutter, consuming the plasma magmite to form a mega plasma cutter.")
//time to clean up all the magmite we used
for(var/obj/item/magmite in placed_objects)
if(used_magmite)
used_magmite--
ItemMoved(magmite)
qdel(magmite)
update_icon()
if(!forge_charges)
to_chat(user,"The world anvil cools down.")


visible_message("The World Anvil cools down.")
update_icon()



14 changes: 11 additions & 3 deletions code/modules/mining/machine_vending.dm
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
circuit = /obj/item/circuitboard/machine/mining_equipment_vendor
var/icon_deny = "mining-deny"
var/list/prize_list = list( //if you add something to this, please, for the love of god, sort it by price/type. use tabs and not spaces.
new /datum/data/mining_equipment("Mining Charge", /obj/item/grenade/plastic/miningcharge, 500, VENDING_EQUIPMENT), //only at the top for players to see it
new /datum/data/mining_equipment("Kinetic Accelerator", /obj/item/gun/energy/kinetic_accelerator, 750, VENDING_WEAPON),
new /datum/data/mining_equipment("Kinetic Crusher", /obj/item/twohanded/required/kinetic_crusher, 750, VENDING_WEAPON),
new /datum/data/mining_equipment("Resonator", /obj/item/resonator, 800, VENDING_WEAPON),
Expand Down Expand Up @@ -54,6 +53,7 @@
new /datum/data/mining_equipment("Minebot Armor Upgrade", /obj/item/mine_bot_upgrade/health, 400, VENDING_MINEBOT),
new /datum/data/mining_equipment("Minebot Cooldown Upgrade", /obj/item/borg/upgrade/modkit/cooldown/minebot, 600, VENDING_MINEBOT),
new /datum/data/mining_equipment("Minebot AI Upgrade", /obj/item/slimepotion/slime/sentience/mining, 1000, VENDING_MINEBOT),
new /datum/data/mining_equipment("Lesser Mining Charge", /obj/item/grenade/plastic/miningcharge/lesser, 300, VENDING_EQUIPMENT),
new /datum/data/mining_equipment("Explorer's Webbing", /obj/item/storage/belt/mining, 500, VENDING_EQUIPMENT),
new /datum/data/mining_equipment("Mining Conscription Kit", /obj/item/storage/backpack/duffelbag/mining_conscript, 1000, VENDING_EQUIPMENT),
new /datum/data/mining_equipment("GAR Meson Scanners", /obj/item/clothing/glasses/meson/gar, 500, VENDING_EQUIPMENT),
Expand Down Expand Up @@ -193,7 +193,8 @@
"Minebot Kit" = image(icon = 'icons/mob/aibots.dmi', icon_state = "mining_drone"),
"Extraction and Rescue Kit" = image(icon = 'icons/obj/fulton.dmi', icon_state = "extraction_pack"),
"Crusher Kit" = image(icon = 'icons/obj/mining.dmi', icon_state = "mining_hammer1"),
"Mining Conscription Kit" = image(icon = 'icons/obj/storage.dmi', icon_state = "duffel")
"Mining Conscription Kit" = image(icon = 'icons/obj/storage.dmi', icon_state = "duffel"),
"Bag of Lesser Mining Charges" = image(icon= 'icons/obj/mining.dmi',icon_state = "mining-charge-1")
)

items = sortList(items)
Expand Down Expand Up @@ -222,6 +223,8 @@
new /obj/item/twohanded/required/kinetic_crusher(drop_location)
if("Mining Conscription Kit")
new /obj/item/storage/backpack/duffelbag/mining_conscript(drop_location)
if("Bag of Lesser Mining Charges")
new /obj/item/storage/backpack/duffelbag/miningcharges(drop_location)

SSblackbox.record_feedback("tally", "mining_voucher_redeemed", 1, selection)
qdel(voucher)
Expand Down Expand Up @@ -306,6 +309,7 @@
new /datum/data/mining_equipment("Mecha Plasma Generator", /obj/item/mecha_parts/mecha_equipment/generator, 1500, VENDING_MECHA),
new /datum/data/mining_equipment("Diamond Mecha Drill", /obj/item/mecha_parts/mecha_equipment/drill/diamonddrill, 2000, VENDING_MECHA),
new /datum/data/mining_equipment("Mecha Plasma Cutter", /obj/item/mecha_parts/mecha_equipment/weapon/energy/plasma, 3000, VENDING_MECHA),
new /datum/data/mining_equipment("Lesser Mining Charge", /obj/item/grenade/plastic/miningcharge/lesser, 300, VENDING_EQUIPMENT),
new /datum/data/mining_equipment("GAR Meson Scanners", /obj/item/clothing/glasses/meson/gar, 500, VENDING_EQUIPMENT),
new /datum/data/mining_equipment("Mining Hardsuit", /obj/item/clothing/suit/space/hardsuit/mining, 2000, VENDING_EQUIPMENT),
new /datum/data/mining_equipment("Jetpack Upgrade", /obj/item/tank/jetpack/suit, 2000, VENDING_EQUIPMENT),
Expand Down Expand Up @@ -334,7 +338,8 @@
"Resonator Kit" = image(icon = 'icons/obj/mining.dmi', icon_state = "resonator"),
"Minebot Kit" = image(icon = 'icons/mob/aibots.dmi', icon_state = "mining_drone"),
"Crusher Kit" = image(icon = 'icons/obj/mining.dmi', icon_state = "mining_hammer1"),
"Advanced Scanner" = image(icon = 'icons/obj/device.dmi', icon_state = "adv_mining0")
"Advanced Scanner" = image(icon = 'icons/obj/device.dmi', icon_state = "adv_mining0"),
"Bag of Lesser Mining Charges" = image(icon= 'icons/obj/mining.dmi', icon_state = "mining-charge-1")
)

items = sortList(items)
Expand All @@ -359,6 +364,9 @@
new /obj/item/twohanded/required/kinetic_crusher(drop_location)
if("Advanced Scanner")
new /obj/item/t_scanner/adv_mining_scanner(drop_location)
if("Bag of Lesser Mining Charges")
new /obj/item/storage/backpack/duffelbag/miningcharges(drop_location)


SSblackbox.record_feedback("tally", "mining_voucher_redeemed", 1, selection)
qdel(voucher)
Expand Down
9 changes: 0 additions & 9 deletions code/modules/mining/ores_coins.dm
Original file line number Diff line number Diff line change
Expand Up @@ -293,15 +293,6 @@ GLOBAL_LIST_INIT(sand_recipes, list(\
return
qdel(src)

//plasa magmite functions like an ore in the way it's mined, but we don't want to be redeeming this. Since Gibtonite is stuck with other ores it's okay to put it here.
/obj/item/magmite
name = "plasma magmite"
desc = "A chunk of plasma magmite, crystallized deep under lavaland's surface. Its strength seems to fluctuate depending on the distance to the planet."
icon = 'icons/obj/mining.dmi'
icon_state = "Magmite ore"
w_class = WEIGHT_CLASS_NORMAL


/*****************************Coin********************************/

// The coin's value is a value of it's materials.
Expand Down
3 changes: 3 additions & 0 deletions code/modules/projectiles/ammunition/energy/plasma.dm
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@
/obj/item/ammo_casing/energy/plasma/scatter/adv
projectile_type = /obj/item/projectile/plasma/scatter/adv

/obj/item/ammo_casing/energy/plasma/scatter/adv/mega
projectile_type = /obj/item/projectile/plasma/scatter/adv/mega

/obj/item/ammo_casing/energy/plasma/adv/cyborg
projectile_type = /obj/item/projectile/plasma/adv
delay = 10
Expand Down
15 changes: 14 additions & 1 deletion code/modules/projectiles/guns/energy/special.dm
Original file line number Diff line number Diff line change
Expand Up @@ -231,17 +231,26 @@
name = "plasma cutter shotgun"
icon_state = "miningshotgun"
item_state = "miningshotgun"
desc = "An industrial-grade heavy-duty mining shotgun"
desc = "An industrial-grade, heavy-duty mining shotgun."
force = 10
ammo_type = list(/obj/item/ammo_casing/energy/plasma/scatter)



/obj/item/gun/energy/plasmacutter/attackby(obj/item/I, mob/user)
. = ..()
if(try_upgrade(I))
to_chat(user, span_notice("You install [I] into [src]"))
playsound(loc, 'sound/items/screwdriver.ogg', 100, 1)
qdel(I)

/obj/item/gun/energy/plasmacutter/scatter/mega
name = "mega plasma cutter shotgun"
icon_state = "miningshotgun_mega"
item_state = "miningshotgun_mega"
desc = "An industrial-grade, heavy-duty mining shotgun. This one seems... mega!"
ammo_type = list(/obj/item/ammo_casing/energy/plasma/scatter/adv/mega)

/obj/item/gun/energy/plasmacutter/adv/cyborg
name = "cyborg advanced plasma cutter"
icon_state = "adv_plasmacutter"
Expand Down Expand Up @@ -273,6 +282,10 @@
return TRUE
return FALSE

//no upgrading this one either (for now)
/obj/item/gun/energy/plasmacutter/scatter/mega/try_upgrade(obj/item/I)
return

/obj/item/gun/energy/wormhole_projector
name = "bluespace wormhole projector"
desc = "A projector that emits high density quantum-coupled bluespace beams."
Expand Down
5 changes: 5 additions & 0 deletions code/modules/projectiles/projectile/special/plasma.dm
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,11 @@
// Same as the scatter but with automatic defusing
/obj/item/projectile/plasma/scatter/adv

//mega plasma shotgun auto defuses
/obj/item/projectile/plasma/scatter/adv/mega
range = 7
mine_range = 3

/obj/item/projectile/plasma/adv/mech
damage = 10
range = 9
Expand Down
Loading