mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-26 18:13:35 +00:00
Merge branch 'master' of https://github.com/Zuhayr/Baystation12
This commit is contained in:
@@ -50,7 +50,7 @@ datum/controller/game_controller/New()
|
||||
if(!syndicate_code_response) syndicate_code_response = generate_code_phrase()
|
||||
if(!ticker) ticker = new /datum/controller/gameticker()
|
||||
if(!emergency_shuttle) emergency_shuttle = new /datum/shuttle_controller/emergency_shuttle()
|
||||
|
||||
if(artifact_spawn) artifact_spawning_turfs = artifact_spawn
|
||||
|
||||
datum/controller/game_controller/proc/setup()
|
||||
world.tick_lag = config.Ticklag
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
#define ARTIFACT_SPAWN_CHANCE 20
|
||||
|
||||
/datum/controller/game_controller/var/list/artifact_spawning_turfs = list()
|
||||
/var/global/list/artifact_spawn = list() // Runtime fix for geometry loading before controller is instantiated.
|
||||
|
||||
/turf/simulated/mineral //wall piece
|
||||
name = "Rock"
|
||||
@@ -129,7 +130,7 @@
|
||||
//dont create artifact machinery in animal or plant digsites, or if we already have one
|
||||
if(!artifact_find && digsite != 1 && digsite != 2 && prob(ARTIFACT_SPAWN_CHANCE))
|
||||
artifact_find = new()
|
||||
master_controller.artifact_spawning_turfs.Add(src)
|
||||
artifact_spawn.Add(src)
|
||||
|
||||
if(!src.geological_data)
|
||||
src.geological_data = new/datum/geosample(src)
|
||||
|
||||
@@ -126,6 +126,7 @@
|
||||
artifact_distance = rand()
|
||||
artifact_id = container.artifact_find.artifact_id
|
||||
else
|
||||
if(master_controller) //Sanity check due to runtimes ~Z
|
||||
for(var/turf/simulated/mineral/T in master_controller.artifact_spawning_turfs)
|
||||
if(T.artifact_find)
|
||||
var/cur_dist = get_dist(container, T) * 2
|
||||
|
||||
@@ -36,6 +36,7 @@
|
||||
last_scan_time = world.time
|
||||
nearest_artifact_distance = -1
|
||||
var/turf/cur_turf = get_turf(src)
|
||||
if(master_controller) //Sanity check due to runtimes ~Z
|
||||
for(var/turf/simulated/mineral/T in master_controller.artifact_spawning_turfs)
|
||||
if(T.artifact_find)
|
||||
if(T.z == cur_turf.z)
|
||||
|
||||
Reference in New Issue
Block a user