mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-12 15:45:25 +01:00
everything works thanks to our tiger overlords..
This commit is contained in:
@@ -1,252 +1,252 @@
|
||||
/obj/effect/landmark
|
||||
name = "landmark"
|
||||
icon = 'icons/mob/screen_gen.dmi'
|
||||
icon_state = "x2"
|
||||
anchored = 1.0
|
||||
unacidable = 1
|
||||
/obj/effect/landmark
|
||||
name = "landmark"
|
||||
icon = 'icons/mob/screen_gen.dmi'
|
||||
icon_state = "x2"
|
||||
anchored = 1.0
|
||||
unacidable = 1
|
||||
|
||||
/obj/effect/landmark/New()
|
||||
|
||||
..()
|
||||
set_tag()
|
||||
invisibility = 101
|
||||
|
||||
switch(name) //some of these are probably obsolete
|
||||
if("start")
|
||||
newplayer_start += loc
|
||||
qdel(src)
|
||||
|
||||
if("wizard")
|
||||
wizardstart += loc
|
||||
qdel(src)
|
||||
|
||||
if("JoinLate")
|
||||
latejoin += loc
|
||||
qdel(src)
|
||||
|
||||
if("JoinLateGateway")
|
||||
latejoin_gateway += loc
|
||||
qdel(src)
|
||||
|
||||
if("JoinLateCryo")
|
||||
latejoin_cryo += loc
|
||||
qdel(src)
|
||||
|
||||
if("JoinLateCyborg")
|
||||
latejoin_cyborg += loc
|
||||
qdel(src)
|
||||
|
||||
if("prisonwarp")
|
||||
prisonwarp += loc
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/New()
|
||||
if("prisonsecuritywarp")
|
||||
prisonsecuritywarp += loc
|
||||
qdel(src)
|
||||
|
||||
..()
|
||||
set_tag()
|
||||
invisibility = 101
|
||||
if("tdome1")
|
||||
tdome1 += loc
|
||||
|
||||
switch(name) //some of these are probably obsolete
|
||||
if("start")
|
||||
newplayer_start += loc
|
||||
qdel(src)
|
||||
if("tdome2")
|
||||
tdome2 += loc
|
||||
|
||||
if("wizard")
|
||||
wizardstart += loc
|
||||
qdel(src)
|
||||
if("tdomeadmin")
|
||||
tdomeadmin += loc
|
||||
|
||||
if("JoinLate")
|
||||
latejoin += loc
|
||||
qdel(src)
|
||||
if("tdomeobserve")
|
||||
tdomeobserve += loc
|
||||
|
||||
if("JoinLateGateway")
|
||||
latejoin_gateway += loc
|
||||
qdel(src)
|
||||
if("aroomwarp")
|
||||
aroomwarp += loc
|
||||
|
||||
if("blobstart")
|
||||
blobstart += loc
|
||||
qdel(src)
|
||||
|
||||
if("xeno_spawn")
|
||||
xeno_spawn += loc
|
||||
qdel(src)
|
||||
|
||||
if("ninjastart")
|
||||
ninjastart += loc
|
||||
qdel(src)
|
||||
|
||||
if("carpspawn")
|
||||
carplist += loc
|
||||
|
||||
if("voxstart")
|
||||
raider_spawn += loc
|
||||
|
||||
if("ERT Director")
|
||||
ertdirector += loc
|
||||
qdel(src)
|
||||
|
||||
if("JoinLateCryo")
|
||||
latejoin_cryo += loc
|
||||
qdel(src)
|
||||
|
||||
if("JoinLateCyborg")
|
||||
latejoin_cyborg += loc
|
||||
qdel(src)
|
||||
|
||||
if("prisonwarp")
|
||||
prisonwarp += loc
|
||||
qdel(src)
|
||||
|
||||
if("prisonsecuritywarp")
|
||||
prisonsecuritywarp += loc
|
||||
qdel(src)
|
||||
|
||||
if("tdome1")
|
||||
tdome1 += loc
|
||||
|
||||
if("tdome2")
|
||||
tdome2 += loc
|
||||
|
||||
if("tdomeadmin")
|
||||
tdomeadmin += loc
|
||||
|
||||
if("tdomeobserve")
|
||||
tdomeobserve += loc
|
||||
|
||||
if("aroomwarp")
|
||||
aroomwarp += loc
|
||||
|
||||
if("blobstart")
|
||||
blobstart += loc
|
||||
qdel(src)
|
||||
|
||||
if("xeno_spawn")
|
||||
xeno_spawn += loc
|
||||
qdel(src)
|
||||
|
||||
if("ninjastart")
|
||||
ninjastart += loc
|
||||
qdel(src)
|
||||
|
||||
if("carpspawn")
|
||||
carplist += loc
|
||||
|
||||
if("voxstart")
|
||||
raider_spawn += loc
|
||||
|
||||
if("ERT Director")
|
||||
ertdirector += loc
|
||||
qdel(src)
|
||||
|
||||
if("Response Team")
|
||||
emergencyresponseteamspawn += loc
|
||||
qdel(src)
|
||||
|
||||
landmarks_list += src
|
||||
return 1
|
||||
|
||||
/obj/effect/landmark/Destroy()
|
||||
landmarks_list -= src
|
||||
..()
|
||||
return QDEL_HINT_HARDDEL_NOW
|
||||
|
||||
/obj/effect/landmark/proc/set_tag()
|
||||
tag = text("landmark*[]", name)
|
||||
|
||||
|
||||
/obj/effect/landmark/start
|
||||
name = "start"
|
||||
icon = 'icons/mob/screen_gen.dmi'
|
||||
icon_state = "x"
|
||||
anchored = 1.0
|
||||
|
||||
/obj/effect/landmark/start/set_tag()
|
||||
tag = "start*[name]"
|
||||
|
||||
|
||||
//Costume spawner landmarks
|
||||
|
||||
/obj/effect/landmark/costume/New() //costume spawner, selects a random subclass and disappears
|
||||
|
||||
var/list/options = typesof(/obj/effect/landmark/costume)
|
||||
var/PICK= options[rand(1,options.len)]
|
||||
new PICK(src.loc)
|
||||
qdel(src)
|
||||
|
||||
//SUBCLASSES. Spawn a bunch of items and disappear likewise
|
||||
/obj/effect/landmark/costume/chicken/New()
|
||||
new /obj/item/clothing/suit/chickensuit(src.loc)
|
||||
new /obj/item/clothing/head/chicken(src.loc)
|
||||
new /obj/item/weapon/reagent_containers/food/snacks/egg(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/gladiator/New()
|
||||
new /obj/item/clothing/under/gladiator(src.loc)
|
||||
new /obj/item/clothing/head/helmet/gladiator(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/madscientist/New()
|
||||
new /obj/item/clothing/under/gimmick/rank/captain/suit(src.loc)
|
||||
new /obj/item/clothing/head/flatcap(src.loc)
|
||||
new /obj/item/clothing/suit/storage/labcoat/mad(src.loc)
|
||||
new /obj/item/clothing/glasses/gglasses(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/elpresidente/New()
|
||||
new /obj/item/clothing/under/gimmick/rank/captain/suit(src.loc)
|
||||
new /obj/item/clothing/head/flatcap(src.loc)
|
||||
new /obj/item/clothing/mask/cigarette/cigar/havana(src.loc)
|
||||
new /obj/item/clothing/shoes/jackboots(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/nyangirl/New()
|
||||
new /obj/item/clothing/under/schoolgirl(src.loc)
|
||||
new /obj/item/clothing/head/kitty(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/maid/New()
|
||||
new /obj/item/clothing/under/blackskirt(src.loc)
|
||||
var/CHOICE = pick( /obj/item/clothing/head/beret , /obj/item/clothing/head/rabbitears )
|
||||
new CHOICE(src.loc)
|
||||
new /obj/item/clothing/glasses/sunglasses/blindfold(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/butler/New()
|
||||
new /obj/item/clothing/suit/wcoat(src.loc)
|
||||
new /obj/item/clothing/under/suit_jacket(src.loc)
|
||||
new /obj/item/clothing/head/that(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/scratch/New()
|
||||
new /obj/item/clothing/gloves/color/white(src.loc)
|
||||
new /obj/item/clothing/shoes/white(src.loc)
|
||||
new /obj/item/clothing/under/scratch(src.loc)
|
||||
if(prob(30))
|
||||
new /obj/item/clothing/head/cueball(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/highlander/New()
|
||||
new /obj/item/clothing/under/kilt(src.loc)
|
||||
new /obj/item/clothing/head/beret(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/prig/New()
|
||||
new /obj/item/clothing/suit/wcoat(src.loc)
|
||||
new /obj/item/clothing/glasses/monocle(src.loc)
|
||||
var/CHOICE= pick( /obj/item/clothing/head/bowlerhat, /obj/item/clothing/head/that)
|
||||
new CHOICE(src.loc)
|
||||
new /obj/item/clothing/shoes/black(src.loc)
|
||||
new /obj/item/weapon/cane(src.loc)
|
||||
new /obj/item/clothing/under/sl_suit(src.loc)
|
||||
new /obj/item/clothing/mask/fakemoustache(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/plaguedoctor/New()
|
||||
new /obj/item/clothing/suit/bio_suit/plaguedoctorsuit(src.loc)
|
||||
new /obj/item/clothing/head/plaguedoctorhat(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/nightowl/New()
|
||||
new /obj/item/clothing/under/owl(src.loc)
|
||||
new /obj/item/clothing/mask/gas/owl_mask(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/waiter/New()
|
||||
new /obj/item/clothing/under/waiter(src.loc)
|
||||
var/CHOICE= pick( /obj/item/clothing/head/kitty, /obj/item/clothing/head/rabbitears)
|
||||
new CHOICE(src.loc)
|
||||
new /obj/item/clothing/suit/apron(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/pirate/New()
|
||||
new /obj/item/clothing/under/pirate(src.loc)
|
||||
new /obj/item/clothing/suit/pirate_black(src.loc)
|
||||
var/CHOICE = pick( /obj/item/clothing/head/pirate , /obj/item/clothing/head/bandana )
|
||||
new CHOICE(src.loc)
|
||||
new /obj/item/clothing/glasses/eyepatch(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/commie/New()
|
||||
new /obj/item/clothing/under/soviet(src.loc)
|
||||
new /obj/item/clothing/head/ushanka(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/imperium_monk/New()
|
||||
new /obj/item/clothing/suit/imperium_monk(src.loc)
|
||||
if(prob(25))
|
||||
new /obj/item/clothing/mask/gas/cyborg(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/holiday_priest/New()
|
||||
new /obj/item/clothing/suit/holidaypriest(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/marisawizard/fake/New()
|
||||
new /obj/item/clothing/head/wizard/marisa/fake(src.loc)
|
||||
new/obj/item/clothing/suit/wizrobe/marisa/fake(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/cutewitch/New()
|
||||
new /obj/item/clothing/under/sundress(src.loc)
|
||||
new /obj/item/clothing/head/witchwig(src.loc)
|
||||
new /obj/item/weapon/twohanded/staff/broom(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/fakewizard/New()
|
||||
new /obj/item/clothing/suit/wizrobe/fake(src.loc)
|
||||
new /obj/item/clothing/head/wizard/fake(src.loc)
|
||||
new /obj/item/weapon/twohanded/staff/(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/sexyclown/New()
|
||||
new /obj/item/clothing/mask/gas/sexyclown(src.loc)
|
||||
new /obj/item/clothing/under/sexyclown(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/sexymime/New()
|
||||
new /obj/item/clothing/mask/gas/sexymime(src.loc)
|
||||
new /obj/item/clothing/under/sexymime(src.loc)
|
||||
qdel(src)
|
||||
if("Response Team")
|
||||
emergencyresponseteamspawn += loc
|
||||
qdel(src)
|
||||
|
||||
landmarks_list += src
|
||||
return 1
|
||||
|
||||
/obj/effect/landmark/Destroy()
|
||||
landmarks_list -= src
|
||||
..()
|
||||
return QDEL_HINT_HARDDEL_NOW
|
||||
|
||||
/obj/effect/landmark/proc/set_tag()
|
||||
tag = text("landmark*[]", name)
|
||||
|
||||
|
||||
/obj/effect/landmark/start
|
||||
name = "start"
|
||||
icon = 'icons/mob/screen_gen.dmi'
|
||||
icon_state = "x"
|
||||
anchored = 1.0
|
||||
|
||||
/obj/effect/landmark/start/set_tag()
|
||||
tag = "start*[name]"
|
||||
|
||||
|
||||
//Costume spawner landmarks
|
||||
|
||||
/obj/effect/landmark/costume/New() //costume spawner, selects a random subclass and disappears
|
||||
|
||||
var/list/options = typesof(/obj/effect/landmark/costume)
|
||||
var/PICK= options[rand(1,options.len)]
|
||||
new PICK(src.loc)
|
||||
qdel(src)
|
||||
|
||||
//SUBCLASSES. Spawn a bunch of items and disappear likewise
|
||||
/obj/effect/landmark/costume/chicken/New()
|
||||
new /obj/item/clothing/suit/chickensuit(src.loc)
|
||||
new /obj/item/clothing/head/chicken(src.loc)
|
||||
new /obj/item/weapon/reagent_containers/food/snacks/egg(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/gladiator/New()
|
||||
new /obj/item/clothing/under/gladiator(src.loc)
|
||||
new /obj/item/clothing/head/helmet/gladiator(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/madscientist/New()
|
||||
new /obj/item/clothing/under/gimmick/rank/captain/suit(src.loc)
|
||||
new /obj/item/clothing/head/flatcap(src.loc)
|
||||
new /obj/item/clothing/suit/storage/labcoat/mad(src.loc)
|
||||
new /obj/item/clothing/glasses/gglasses(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/elpresidente/New()
|
||||
new /obj/item/clothing/under/gimmick/rank/captain/suit(src.loc)
|
||||
new /obj/item/clothing/head/flatcap(src.loc)
|
||||
new /obj/item/clothing/mask/cigarette/cigar/havana(src.loc)
|
||||
new /obj/item/clothing/shoes/jackboots(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/nyangirl/New()
|
||||
new /obj/item/clothing/under/schoolgirl(src.loc)
|
||||
new /obj/item/clothing/head/kitty(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/maid/New()
|
||||
new /obj/item/clothing/under/blackskirt(src.loc)
|
||||
var/CHOICE = pick( /obj/item/clothing/head/beret , /obj/item/clothing/head/rabbitears )
|
||||
new CHOICE(src.loc)
|
||||
new /obj/item/clothing/glasses/sunglasses/blindfold(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/butler/New()
|
||||
new /obj/item/clothing/suit/wcoat(src.loc)
|
||||
new /obj/item/clothing/under/suit_jacket(src.loc)
|
||||
new /obj/item/clothing/head/that(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/scratch/New()
|
||||
new /obj/item/clothing/gloves/color/white(src.loc)
|
||||
new /obj/item/clothing/shoes/white(src.loc)
|
||||
new /obj/item/clothing/under/scratch(src.loc)
|
||||
if(prob(30))
|
||||
new /obj/item/clothing/head/cueball(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/highlander/New()
|
||||
new /obj/item/clothing/under/kilt(src.loc)
|
||||
new /obj/item/clothing/head/beret(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/prig/New()
|
||||
new /obj/item/clothing/suit/wcoat(src.loc)
|
||||
new /obj/item/clothing/glasses/monocle(src.loc)
|
||||
var/CHOICE= pick( /obj/item/clothing/head/bowlerhat, /obj/item/clothing/head/that)
|
||||
new CHOICE(src.loc)
|
||||
new /obj/item/clothing/shoes/black(src.loc)
|
||||
new /obj/item/weapon/cane(src.loc)
|
||||
new /obj/item/clothing/under/sl_suit(src.loc)
|
||||
new /obj/item/clothing/mask/fakemoustache(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/plaguedoctor/New()
|
||||
new /obj/item/clothing/suit/bio_suit/plaguedoctorsuit(src.loc)
|
||||
new /obj/item/clothing/head/plaguedoctorhat(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/nightowl/New()
|
||||
new /obj/item/clothing/under/owl(src.loc)
|
||||
new /obj/item/clothing/mask/gas/owl_mask(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/waiter/New()
|
||||
new /obj/item/clothing/under/waiter(src.loc)
|
||||
var/CHOICE= pick( /obj/item/clothing/head/kitty, /obj/item/clothing/head/rabbitears)
|
||||
new CHOICE(src.loc)
|
||||
new /obj/item/clothing/suit/apron(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/pirate/New()
|
||||
new /obj/item/clothing/under/pirate(src.loc)
|
||||
new /obj/item/clothing/suit/pirate_black(src.loc)
|
||||
var/CHOICE = pick( /obj/item/clothing/head/pirate , /obj/item/clothing/head/bandana )
|
||||
new CHOICE(src.loc)
|
||||
new /obj/item/clothing/glasses/eyepatch(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/commie/New()
|
||||
new /obj/item/clothing/under/soviet(src.loc)
|
||||
new /obj/item/clothing/head/ushanka(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/imperium_monk/New()
|
||||
new /obj/item/clothing/suit/imperium_monk(src.loc)
|
||||
if(prob(25))
|
||||
new /obj/item/clothing/mask/gas/cyborg(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/holiday_priest/New()
|
||||
new /obj/item/clothing/suit/holidaypriest(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/marisawizard/fake/New()
|
||||
new /obj/item/clothing/head/wizard/marisa/fake(src.loc)
|
||||
new/obj/item/clothing/suit/wizrobe/marisa/fake(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/cutewitch/New()
|
||||
new /obj/item/clothing/under/sundress(src.loc)
|
||||
new /obj/item/clothing/head/witchwig(src.loc)
|
||||
new /obj/item/weapon/twohanded/staff/broom(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/fakewizard/New()
|
||||
new /obj/item/clothing/suit/wizrobe/fake(src.loc)
|
||||
new /obj/item/clothing/head/wizard/fake(src.loc)
|
||||
new /obj/item/weapon/twohanded/staff/(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/sexyclown/New()
|
||||
new /obj/item/clothing/mask/gas/sexyclown(src.loc)
|
||||
new /obj/item/clothing/under/sexyclown(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/landmark/costume/sexymime/New()
|
||||
new /obj/item/clothing/mask/gas/sexymime(src.loc)
|
||||
new /obj/item/clothing/under/sexymime(src.loc)
|
||||
qdel(src)
|
||||
|
||||
@@ -421,3 +421,24 @@
|
||||
/turf/proc/add_blueprints_preround(atom/movable/AM)
|
||||
if(!ticker || ticker.current_state != GAME_STATE_PLAYING)
|
||||
add_blueprints(AM)
|
||||
|
||||
/turf/proc/empty(turf_type=/turf/space)
|
||||
// Remove all atoms except observers, landmarks, docking ports, and (un)`simulated` atoms (lighting overlays)
|
||||
var/turf/T0 = src
|
||||
for(var/X in T0.GetAllContents())
|
||||
var/atom/A = X
|
||||
if(istype(A, /mob/dead))
|
||||
continue
|
||||
if(istype(A, /obj/effect/landmark))
|
||||
continue
|
||||
if(istype(A, /obj/docking_port))
|
||||
continue
|
||||
if(!A.simulated)
|
||||
continue
|
||||
qdel(A, force=TRUE)
|
||||
|
||||
T0.ChangeTurf(turf_type)
|
||||
|
||||
air_master.remove_from_active(T0)
|
||||
T0.CalculateAdjacentTurfs()
|
||||
air_master.add_to_active(T0,1)
|
||||
|
||||
@@ -0,0 +1,72 @@
|
||||
// Shuttle on-movement //
|
||||
/atom/movable/proc/onShuttleMove(turf/T1, rotation)
|
||||
if(rotation)
|
||||
shuttleRotate(rotation)
|
||||
forceMove(T1)
|
||||
return 1
|
||||
|
||||
/atom/movable/lighting_overlay/onShuttleMove()
|
||||
return 0
|
||||
|
||||
/obj/onShuttleMove()
|
||||
if(invisibility >= 101)
|
||||
return 0
|
||||
. = ..()
|
||||
|
||||
/obj/machinery/door/onShuttleMove()
|
||||
. = ..()
|
||||
if(!.)
|
||||
return
|
||||
addtimer(src, "close", 0, TRUE, 0, 1)
|
||||
// Close any nearby airlocks as well
|
||||
for(var/obj/machinery/door/D in orange(1, src))
|
||||
addtimer(D, "close", 0, TRUE, 0, 1)
|
||||
|
||||
/obj/machinery/door/airlock/onShuttleMove()
|
||||
. = ..()
|
||||
if(id_tag == "s_docking_airlock")
|
||||
addtimer(src, "lock", 0, TRUE)
|
||||
|
||||
/mob/onShuttleMove()
|
||||
if(!move_on_shuttle)
|
||||
return 0
|
||||
. = ..()
|
||||
if(!.)
|
||||
return
|
||||
if(client)
|
||||
if(buckled)
|
||||
shake_camera(src, 2, 1) // turn it down a bit come on
|
||||
else
|
||||
shake_camera(src, 7, 1)
|
||||
|
||||
/mob/living/carbon/onShuttleMove()
|
||||
. = ..()
|
||||
if(!.)
|
||||
return
|
||||
if(!buckled)
|
||||
Weaken(3)
|
||||
|
||||
// After docking //
|
||||
/atom/proc/postDock(obj/docking_port/S1)
|
||||
if(smooth)
|
||||
smooth_icon(src)
|
||||
|
||||
/obj/machinery/door/airlock/postDock(obj/docking_port/stationary/S1)
|
||||
. = ..()
|
||||
if(!S1.lock_shuttle_doors && id_tag == "s_docking_airlock")
|
||||
addtimer(src, "unlock", 0, TRUE)
|
||||
|
||||
// Shuttle Rotation //
|
||||
/atom/proc/shuttleRotate(rotation)
|
||||
//rotate our direction
|
||||
dir = angle2dir(rotation+dir2angle(dir))
|
||||
|
||||
//rotate the pixel offsets too.
|
||||
if(pixel_x || pixel_y)
|
||||
if(rotation < 0)
|
||||
rotation += 360
|
||||
for(var/turntimes=rotation/90;turntimes>0;turntimes--)
|
||||
var/oldPX = pixel_x
|
||||
var/oldPY = pixel_y
|
||||
pixel_x = oldPY
|
||||
pixel_y = (oldPX*(-1))
|
||||
@@ -271,10 +271,15 @@
|
||||
if(height-dheight > S.height-S.dheight)
|
||||
return SHUTTLE_HEIGHT_TOO_LARGE
|
||||
//check the dock isn't occupied
|
||||
// by someone other than us
|
||||
if(S.get_docked())
|
||||
to_chat(world, "[S.getDockedId()]")
|
||||
return SHUTTLE_SOMEONE_ELSE_DOCKED
|
||||
var/currently_docked = S.get_docked()
|
||||
if(currently_docked)
|
||||
// by someone other than us
|
||||
if(currently_docked != src)
|
||||
return SHUTTLE_SOMEONE_ELSE_DOCKED
|
||||
else
|
||||
// This isn't an error, per se, but we can't let the shuttle code
|
||||
// attempt to move us where we currently are, it will get weird.
|
||||
return SHUTTLE_ALREADY_DOCKED
|
||||
return SHUTTLE_CAN_DOCK
|
||||
|
||||
/obj/docking_port/mobile/proc/check_dock(obj/docking_port/stationary/S)
|
||||
@@ -341,24 +346,7 @@
|
||||
else
|
||||
WARNING("shuttle \"[id]\" could not enter transit space. S0=[S0 ? S0.id : "null"] S1=[S1 ? S1.id : "null"]")
|
||||
|
||||
//default shuttleRotate
|
||||
/atom/proc/shuttleRotate(rotation)
|
||||
//rotate our direction
|
||||
dir = angle2dir(rotation+dir2angle(dir))
|
||||
|
||||
//rotate the pixel offsets too.
|
||||
if(pixel_x || pixel_y)
|
||||
if(rotation < 0)
|
||||
rotation += 360
|
||||
for(var/turntimes=rotation/90;turntimes>0;turntimes--)
|
||||
var/oldPX = pixel_x
|
||||
var/oldPY = pixel_y
|
||||
pixel_x = oldPY
|
||||
pixel_y = (oldPX*(-1))
|
||||
|
||||
/atom/proc/postDock()
|
||||
if(smooth)
|
||||
smooth_icon(src)
|
||||
|
||||
/obj/docking_port/mobile/proc/jumpToNullSpace()
|
||||
// Destroys the docking port and the shuttle contents.
|
||||
@@ -382,22 +370,11 @@
|
||||
for(var/turf/T0 in L0)
|
||||
A0.contents += T0
|
||||
|
||||
for(var/i=1, i<=L0.len, ++i)
|
||||
var/turf/T0 = L0[i]
|
||||
for(var/i in L0)
|
||||
var/turf/T0 = i
|
||||
if(!T0)
|
||||
continue
|
||||
|
||||
for(var/AM in T0.GetAllContents())
|
||||
if(istype(AM, /mob/dead))
|
||||
continue
|
||||
qdel(AM, force=TRUE)
|
||||
|
||||
T0.ChangeTurf(turf_type)
|
||||
|
||||
//T0.redraw_lighting()
|
||||
air_master.remove_from_active(T0)
|
||||
T0.CalculateAdjacentTurfs()
|
||||
air_master.add_to_active(T0,1)
|
||||
T0.empty(turf_type)
|
||||
|
||||
qdel(src, force=TRUE)
|
||||
|
||||
@@ -449,8 +426,6 @@
|
||||
//move or squish anything in the way ship at destination
|
||||
roadkill(L0, L1, S1.dir)
|
||||
|
||||
var/list/door_unlock_list = list()
|
||||
|
||||
for(var/i in 1 to L0.len)
|
||||
var/turf/T0 = L0[i]
|
||||
if(!T0)
|
||||
@@ -468,49 +443,8 @@
|
||||
Ts1.copy_air_with_tile(T0)
|
||||
|
||||
//move mobile to new location
|
||||
|
||||
|
||||
|
||||
for(var/atom/movable/AM in T0)
|
||||
if(rotation)
|
||||
AM.shuttleRotate(rotation)
|
||||
|
||||
if(istype(AM,/obj))
|
||||
var/obj/O = AM
|
||||
if(istype(O, /obj/docking_port/stationary))
|
||||
continue
|
||||
O.forceMove(T1)
|
||||
|
||||
//close open doors
|
||||
if(istype(O, /obj/machinery/door))
|
||||
var/obj/machinery/door/Door = O
|
||||
spawn(-1)
|
||||
if(Door)
|
||||
if(istype(Door, /obj/machinery/door/airlock))
|
||||
var/obj/machinery/door/airlock/A = Door
|
||||
A.close(0,1)
|
||||
if(A.id_tag == "s_docking_airlock")
|
||||
A.lock()
|
||||
door_unlock_list += A
|
||||
else
|
||||
Door.close()
|
||||
else if(istype(AM,/mob))
|
||||
var/mob/M = AM
|
||||
if(!M.move_on_shuttle)
|
||||
continue
|
||||
M.forceMove(T1)
|
||||
|
||||
//docking turbulence
|
||||
if(M.client)
|
||||
spawn(0)
|
||||
if(M.buckled)
|
||||
shake_camera(M, 2, 1) // turn it down a bit come on
|
||||
else
|
||||
shake_camera(M, 7, 1)
|
||||
if(istype(M, /mob/living/carbon))
|
||||
if(!M.buckled)
|
||||
M.Weaken(3)
|
||||
|
||||
AM.onShuttleMove(T1, rotation)
|
||||
|
||||
if(rotation)
|
||||
T1.shuttleRotate(rotation)
|
||||
@@ -528,27 +462,14 @@
|
||||
|
||||
for(var/A1 in L1)
|
||||
var/turf/T1 = A1
|
||||
T1.postDock()
|
||||
T1.postDock(S1)
|
||||
for(var/atom/movable/M in T1)
|
||||
M.postDock()
|
||||
M.postDock(S1)
|
||||
|
||||
loc = S1.loc
|
||||
dir = S1.dir
|
||||
|
||||
unlockPortDoors(S1)
|
||||
if(S1 && !S1.lock_shuttle_doors)
|
||||
for(var/obj/machinery/door/airlock/A in door_unlock_list)
|
||||
spawn(-1)
|
||||
A.unlock()
|
||||
|
||||
/*
|
||||
if(istype(S1, /obj/docking_port/stationary/transit))
|
||||
var/d = turn(dir, 180 + travelDir)
|
||||
for(var/turf/space/transit/T in S1.return_ordered_turfs())
|
||||
T.pushdirection = d
|
||||
T.update_icon()
|
||||
*/
|
||||
|
||||
|
||||
|
||||
/obj/docking_port/mobile/proc/findTransitDock()
|
||||
|
||||
@@ -1991,6 +1991,7 @@
|
||||
#include "code\modules\security_levels\security levels.dm"
|
||||
#include "code\modules\shuttle\assault_pod.dm"
|
||||
#include "code\modules\shuttle\emergency.dm"
|
||||
#include "code\modules\shuttle\on_move.dm"
|
||||
#include "code\modules\shuttle\shuttle.dm"
|
||||
#include "code\modules\shuttle\shuttle_manipulator.dm"
|
||||
#include "code\modules\shuttle\supply.dm"
|
||||
|
||||
Reference in New Issue
Block a user