Trims back wilderness code that was dependent on tether map.

* Reverted random.dm back to Polaris as there is no need for the VOREStation customs.
* Fixed /obj/random/outside_mob so it will actually work (You can't set vars on a type!)
* Removed all wilderness code outside of the tether map.  It was only setting life_disabled on mobs spawning there. We can do that with a subsystem or by dynamic maploading instead.
This commit is contained in:
Leshana
2018-01-17 15:23:22 -05:00
parent 62ef3b1820
commit fe431c8e46
8 changed files with 18 additions and 92 deletions
-1
View File
@@ -196,5 +196,4 @@ It also makes it so a ghost wont know where all the goodies/mobs are.
icon_state = "alien_egg"
spawn_types = list(
/mob/living/simple_animal/hostile/alien/queen = 5,
/mob/living/simple_animal/hostile/alien/queen/large = 1
)
-9
View File
@@ -5,8 +5,6 @@
icon_state = "rup"
var/spawn_nothing_percentage = 0 // this variable determines the likelyhood that this random object will not spawn anything
var/spawned_thing //VOREStation Edit
// creates a new object and deletes itself
/obj/random/New()
@@ -30,13 +28,6 @@
A.pixel_x = pixel_x
A.pixel_y = pixel_y
//VOREStation Edit
spawned_thing = A
/obj/random/Destroy()
spawned_thing = null
return ..()
//VOREStation Edit End
/obj/random/single
name = "randomly spawned object"
+12 -23
View File
@@ -180,33 +180,22 @@
var/faction = "wild animal"
/obj/random/outside_mob/item_to_spawn() // Special version for mobs to have the same faction.
var/mob = pick(
return pick(
prob(50);/mob/living/simple_animal/retaliate/gaslamp,
// prob(50);/mob/living/simple_animal/otie/feral, // Removed until Otie code is unfucked.
prob(20);/mob/living/simple_animal/hostile/dino/virgo3b,
prob(1);/mob/living/simple_animal/hostile/dragon/virgo3b)
if (istype(mob, /mob/living)) // This is just to prevent runtime errors in case some dev is a dumbass and puts invalid items into this.
var/mob/living/simple_animal/this_mob = mob
/obj/random/outside_mob/spawn_item()
. = ..()
if(istype(., /mob/living/simple_animal))
var/mob/living/simple_animal/this_mob = .
this_mob.faction = src.faction
if (this_mob.minbodytemp > 200) // Temporary hotfix. Eventually I'll add code to change all mob vars to fit the environment they are spawned in.
this_mob.minbodytemp = 200
return this_mob
else
return mob
/obj/random/outside_mob/spawn_item()
..()
var/datum/map_z_level/z_level = get_z_level_datum(spawned_thing)
if(!istype(z_level, /datum/map_z_level/tether/wilderness))
return
if(!istype(spawned_thing, /mob/living/simple_animal))
return
var/datum/map_z_level/tether/wilderness/wilderness = z_level
if(wilderness.activated)
return
var/mob/living/simple_animal/M = spawned_thing
wilderness.frozen_mobs += M
M.life_disabled = 1
for(var/i = 1 to 20) //wander the mobs around so they aren't always in the same spots
step_rand(M)
sleep(2)
//wander the mobs around so they aren't always in the same spots
var/turf/T = null
for(var/i = 1 to 20)
T = get_step_rand(this_mob) || T
if(T)
this_mob.forceMove(T)