Merge pull request #1876 from Darlantanis/GlobalOreFix

Webedit ore spawning fix
This commit is contained in:
Razgriz
2021-05-04 00:52:43 -07:00
committed by GitHub
3 changed files with 5 additions and 22 deletions

View File

@@ -117,7 +117,7 @@
var/total_harvest = harvest_speed //Ore harvest-per-tick.
var/found_resource = 0 //If this doesn't get set, the area is depleted and the drill errors out.
for(var/metal in GLOB.ore_types)
for(var/metal in ore_types)
if(contents.len >= capacity)
system_error("Insufficient storage space.")
@@ -145,7 +145,7 @@
harvesting.resources[metal] = 0
for(var/i=1, i <= create_ore, i++)
var/oretype = GLOB.ore_types[metal]
var/oretype = ore_types[metal]
new oretype(src)
if(!found_resource) // If a drill can't see an advanced material, it will destroy it while going through.

View File

@@ -8,13 +8,13 @@ var/list/mining_overlay_cache = list()
density = 1
opacity = 1 // YW edit. Stops all my unsimulated tiles from being seethrough.
//YW add start
/turf/unsimulated/mineral/ice
name = "Ice wall"
desc = "Frigid Ice that seems to be stronger than most manmade structures."
icon = 'icons/turf/snow_new.dmi'
icon_state = "Icerock"
//YW add end
/turf/simulated/mineral //wall piece
name = "rock"
@@ -250,7 +250,7 @@ turf/simulated/mineral/floor/light_corner
for(var/ore in resources)
var/amount_to_give = rand(CEILING(resources[ore]/2, 1), resources[ore]) // Should result in at least one piece of ore.
for(var/i=1, i <= amount_to_give, i++)
var/oretype = GLOB.ore_types[ore]
var/oretype = ore_types[ore]
new oretype(src)
resources[ore] = 0