Skip to content

Commit

Permalink
Any closed turf blocks aux base placement (tgstation#35308)
Browse files Browse the repository at this point in the history
* Any closed turf blocks aux base placement

* ignores rock walls and destroys them before landing

* Goes back to some more standard style
  • Loading branch information
ninjanomnom authored and duncathan committed Mar 13, 2018
1 parent b591d9d commit b8385d8
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions code/modules/mining/aux_base.dm
Original file line number Diff line number Diff line change
Expand Up @@ -144,9 +144,11 @@ interface with the mining shuttle at the landing site if a mobile beacon is also
return
if(!no_restrictions)
var/static/list/disallowed_turf_types = typecacheof(list(
/turf/closed,
/turf/open/lava,
/turf/closed/indestructible,
/turf/open/indestructible,
)) - typecacheof(list(
/turf/closed/mineral,
))

if(!is_mining_level(T.z))
Expand Down Expand Up @@ -231,7 +233,7 @@ interface with the mining shuttle at the landing site if a mobile beacon is also
if(BAD_COORDS)
to_chat(user, "<span class='warning'>Location is too close to the edge of the station's scanning range. Move several paces away and try again.</span>")
if(BAD_TURF)
to_chat(user, "<span class='warning'>The landing zone contains turfs unsuitable for a base.</span>")
to_chat(user, "<span class='warning'>The landing zone contains turfs unsuitable for a base. Make sure you've removed all walls and dangerous terrain from the landing zone.</span>")

/obj/item/device/assault_pod/mining/unrestricted
name = "omni-locational landing field designator"
Expand All @@ -248,6 +250,13 @@ interface with the mining shuttle at the landing site if a mobile beacon is also
width = 9
height = 9

/obj/docking_port/mobile/auxillary_base/takeoff(list/old_turfs, list/new_turfs, list/moved_atoms, rotation, movement_direction, old_dock, area/underlying_old_area)
for(var/i in new_turfs)
var/turf/place = i
if(istype(place, /turf/closed/mineral))
place.ScrapeAway()
return ..()

obj/docking_port/stationary/public_mining_dock
name = "public mining base dock"
id = "disabled" //The Aux Base has to leave before this can be used as a dock.
Expand Down

0 comments on commit b8385d8

Please sign in to comment.