[Ready] The Virtual Reality Hub (#42879)

About The Pull Request

VR sleepers now lead to the VR Hub, a place with a bunch of portals that lead you to other areas, or just has chill stuff like a bar. Includes portals to all the old vr maps, the megafauna training simulator map, a soon to be minecraft map, and my crappy game runner where you run away from falling tiles and fight to be the last person to survive. Merges murderdome and syndicate trainer into the vr hub map so they spawn every time with vr. Recall portals now can have multiple exits to support the old vr waypoint system from the hub. Also moves a lot of stuff around in the files to make it more organized. There's now also a ghost role that can access VR as well with infinite spawns.

VR NOW HAS A CONFIG OPTION SO ENABLE IT OR VR WILL NOT WORK.
Why It's Good For The Game

Being a ghost is boring for most people, it's nice to have a place for people to hang out rather than just leave the server. This is also a nice place where people can put gamemodes they're testing or other fun little minigames that can't be main gamemodes. VR currently is not used by really anyone so I don't see anyone getting bothered by this PR as well.
This commit is contained in:
Whoneedspacee
2019-04-22 12:16:11 +12:00
committed by oranges
parent e586883c8c
commit 5b89dea70f
19 changed files with 69388 additions and 31960 deletions
+19 -15
View File
@@ -200,37 +200,41 @@
/obj/effect/portal/permanent/proc/get_linked()
if(!id)
return
var/list/possible = list()
for(var/obj/effect/portal/permanent/P in GLOB.portals - src)
if(P.id && P.id == id) // gets portals with the same id, there should only be two permanent portals with the same id
return P
possible += P
return possible
/obj/effect/portal/permanent/proc/set_linked()
var/obj/effect/portal/permanent/other = get_linked()
if(!other)
var/list/possible = get_linked()
if(!possible || !possible.len)
return
other.linked = src
linked = other
for(var/obj/effect/portal/permanent/other in possible)
other.linked = src
linked = pick(possible)
/obj/effect/portal/permanent/teleport(atom/movable/M, force = FALSE)
if(!linked) // try to search for a new one if something was var edited etc
set_linked()
// try to search for a new one if something was var edited etc
set_linked()
. = ..()
/obj/effect/portal/permanent/one_way // doesn't have a return portal
name = "one-way portal"
desc = "You get the feeling that this might not be the safest thing you've ever done."
var/list/possible_exits = list()
var/keep // if this is a portal that should be kept
/obj/effect/portal/permanent/one_way/set_linked()
var/obj/effect/portal/permanent/one_way/other = get_linked()
if(!other)
if(!keep) // wait for a keep portal to set
return
hard_target = get_turf(other)
other.hard_target = get_turf(src)
if(!other.keep)
qdel(other)
if(!keep)
qdel(src)
var/list/possible_temp = get_linked()
if(possible_temp && possible_temp.len)
for(var/obj/effect/portal/permanent/other in possible_temp)
possible_exits += get_turf(other)
qdel(other)
if(possible_exits && possible_exits.len)
hard_target = pick(possible_exits)
/obj/effect/portal/permanent/one_way/keep // because its nice to be able to tell which is which on the map
keep = TRUE