mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-26 21:48:21 +01:00
ui stuff then map conflicts
This commit is contained in:
@@ -113,6 +113,7 @@
|
||||
if(!config.disable_space_ruins) // so we don't unnecessarily clutter start-up
|
||||
preloadRuinTemplates()
|
||||
preloadShelterTemplates()
|
||||
preloadShuttleTemplates()
|
||||
|
||||
/proc/preloadRuinTemplates()
|
||||
// Still supporting bans by filename
|
||||
|
||||
@@ -455,8 +455,10 @@
|
||||
|
||||
if(seclevel2num(get_security_level()) >= SEC_LEVEL_RED) // There is a serious threat we gotta move no time to give them five minutes.
|
||||
shuttle_master.emergency.request(null, 0.5, null, " Automatic Crew Transfer", 1)
|
||||
shuttle_master.emergency.canRecall = FALSE
|
||||
else
|
||||
shuttle_master.emergency.request(null, 1, null, " Automatic Crew Transfer", 0)
|
||||
shuttle_master.emergency.canRecall = FALSE
|
||||
if(user)
|
||||
log_game("[key_name(user)] has called the shuttle.")
|
||||
message_admins("[key_name_admin(user)] has called the shuttle - [formatJumpTo(user)].", 1)
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
icon_keyboard = "tech_key"
|
||||
var/auth_need = 3
|
||||
var/list/authorized = list()
|
||||
var/canrecall = TRUE
|
||||
|
||||
/obj/machinery/computer/emergency_shuttle/attackby(obj/item/weapon/card/W, mob/user, params)
|
||||
if(stat & (BROKEN|NOPOWER))
|
||||
@@ -92,6 +91,9 @@
|
||||
var/datum/announcement/priority/emergency_shuttle_called = new(0, new_sound = sound('sound/AI/shuttlecalled.ogg'))
|
||||
var/datum/announcement/priority/emergency_shuttle_recalled = new(0, new_sound = sound('sound/AI/shuttlerecalled.ogg'))
|
||||
|
||||
var/canRecall = TRUE//no bad condom, do not recall the crew transfer shuttle!
|
||||
|
||||
|
||||
/obj/docking_port/mobile/emergency/register()
|
||||
if(!..())
|
||||
return 0 //shuttle master not initialized
|
||||
@@ -146,6 +148,9 @@
|
||||
emergency_shuttle_called.Announce("The emergency shuttle has been called. [redAlert ? "Red Alert state confirmed: Dispatching priority shuttle. " : "" ]It will arrive in [timeLeft(600)] minutes.[reason][shuttle_master.emergencyLastCallLoc ? "\n\nCall signal traced. Results can be viewed on any communications console." : "" ]")
|
||||
|
||||
/obj/docking_port/mobile/emergency/cancel(area/signalOrigin)
|
||||
if(!canRecall)
|
||||
return
|
||||
|
||||
if(mode != SHUTTLE_CALL)
|
||||
return
|
||||
|
||||
|
||||
@@ -72,14 +72,16 @@
|
||||
data["templates"] = list()
|
||||
var/list/templates = data["templates"]
|
||||
data["templates_tabs"] = list()
|
||||
data["selected"] = list()
|
||||
|
||||
data["selected"] = null
|
||||
|
||||
for(var/shuttle_id in shuttle_templates)
|
||||
var/datum/map_template/shuttle/S = shuttle_templates[shuttle_id]
|
||||
|
||||
if(!templates[S.port_id])
|
||||
data["templates_tabs"] += S.port_id
|
||||
// The first found shuttle type will be our default
|
||||
if(!existing_shuttle)
|
||||
existing_shuttle = shuttle_master.getShuttle(S.port_id)
|
||||
templates[S.port_id] = list(
|
||||
"port_id" = S.port_id,
|
||||
"templates" = list())
|
||||
@@ -149,6 +151,12 @@
|
||||
selected_menu_key = href_list["selectMenuKey"]
|
||||
return 1 // return 1 forces an update to all Nano uis attached to src
|
||||
|
||||
if(href_list["select_template_category"])
|
||||
var/chosen_shuttle_id = href_list["select_template_category"]
|
||||
selected = null
|
||||
existing_shuttle = shuttle_master.getShuttle(chosen_shuttle_id)
|
||||
return 1
|
||||
|
||||
if(href_list["select_template"])
|
||||
if(S)
|
||||
existing_shuttle = shuttle_master.getShuttle(S.port_id)
|
||||
|
||||
@@ -31,53 +31,90 @@ Title: Shuttle Manipulator UI
|
||||
Shuttle Status: {{:value.status}}
|
||||
</div>
|
||||
<div class='itemContentWide'>
|
||||
{{:helper.link('Jump to', 'space-shuttle', {'jump_to' : 1, 'type' : 'mobile', 'id' : data.selected.shuttle_id}, null)}}
|
||||
{{:helper.link('Fast Travel', 'rocket', {'fast_travel' : 1}, null)}}
|
||||
{{:helper.link('Jump to', 'space-shuttle', {'jump_to' : 1, 'type' : 'mobile', 'id' : value.id}, null)}}
|
||||
{{:helper.link('Fast Travel', 'rocket', {'fast_travel' : 1, 'id' : value.id}, null)}}
|
||||
</div>
|
||||
</div>
|
||||
{{/for}}
|
||||
<!-- Shuttle template tab -->
|
||||
{{else data.selectedMenuKey == 'stemp'}}
|
||||
<div class="itemLabelNarrow">
|
||||
|
||||
{{for data.templates}}
|
||||
Name: {{:value.name}}
|
||||
{{if data.description}}
|
||||
Description: {{:value.description}}
|
||||
{{/if}}
|
||||
{{if data.admin_notes}}
|
||||
Admin Notes: {{:value.admin_notes}}
|
||||
{{/if}}
|
||||
|
||||
{{:helper.link('select template', 'space-shuttle', {'select_template' : 1, 'shuttle_id' : data.shuttle_id}, null)}}
|
||||
{{/for}}
|
||||
<div class="item">
|
||||
{{for data.templates_tabs}}
|
||||
{{:helper.link(value, 'space-shuttle', {'select_template_category' : value}, (data.existing_shuttle && data.existing_shuttle.id == value) ? 'selected' : null)}}
|
||||
{{/for}}
|
||||
</div>
|
||||
{{if data.existing_shuttle}}
|
||||
<div class="item"> </div>
|
||||
{{for data.templates[data.existing_shuttle.id].templates}}
|
||||
<div class='statusDisplay'>
|
||||
<div class='itemLabelWide'>
|
||||
Name: {{:value.name}}
|
||||
</div>
|
||||
{{if value.description}}
|
||||
<div class='itemContent'>
|
||||
Description: {{:value.description}}
|
||||
</div>
|
||||
{{/if}}
|
||||
{{if value.admin_notes}}
|
||||
<div class='itemContent'>
|
||||
Admin Notes: {{:value.admin_notes}}
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
<div class='item'>
|
||||
{{:helper.link('select template', 'space-shuttle', {'select_template' : 1, 'shuttle_id' : value.shuttle_id}, (data.existing_shuttle.shuttle_id == value.shuttle_id) ? 'selected' : null)}}
|
||||
</div>
|
||||
</div>
|
||||
{{/for}}
|
||||
{{/if}}
|
||||
<!-- Shuttle Modification tab -->
|
||||
{{else data.selectedMenuKey == 'mod'}}
|
||||
<div class="itemLabelNarrow">
|
||||
|
||||
{{if data.selected.description}}
|
||||
Description: {{:data.selected.description}}
|
||||
{{/if}}
|
||||
{{if data.selected.admin_notes}}
|
||||
Admin Notes: {{:data.selected.admin_notes}}
|
||||
{{/if}}
|
||||
|
||||
|
||||
|
||||
{{:helper.link('Jump to', 'space-shuttle', {'jump_to' : 1, 'type' : 'mobile', 'id' : data.selected.shuttle_id}, null)}}
|
||||
|
||||
|
||||
<div class="statusDisplay">
|
||||
{{if data.existing_shuttle}}
|
||||
Existing Shuttle: {{:data.existing_shuttle.name}}
|
||||
Status: {{:data.existing_shuttle.status}}
|
||||
{{if data.existing_shuttle.timer}}
|
||||
({{:data.existing_shuttle.timeleft}})
|
||||
{{/if}}
|
||||
<div class='itemGroup'>
|
||||
<div class='itemLabelWide'>
|
||||
Existing Shuttle: {{:data.existing_shuttle.name}}
|
||||
</div>
|
||||
<div class='item'>
|
||||
Status: {{:data.existing_shuttle.status}}
|
||||
</div>
|
||||
{{if data.existing_shuttle.timer}}
|
||||
<div class='item'>
|
||||
({{:data.existing_shuttle.timeleft}})
|
||||
</div>
|
||||
{{/if}}
|
||||
<div class='item'>
|
||||
{{:helper.link('Jump to', 'space-shuttle', {'jump_to' : 1, 'type' : 'mobile', 'id' : data.existing_shuttle.id}, null)}}
|
||||
</div>
|
||||
</div>
|
||||
{{else}}
|
||||
<h3>No shuttle selected</h3>
|
||||
{{/if}}
|
||||
|
||||
{{:helper.link('Preview', 'exclamation-circle', {'preview' : 1, 'shuttle_id' : data.selected.shuttle_id}, null)}}
|
||||
{{:helper.link('Load', 'exclamation-circle', {'load' : 1, 'shuttle_id' : data.selected.shuttle_id}, null)}}
|
||||
|
||||
|
||||
{{if data.selected}}
|
||||
<div class='itemGroup'>
|
||||
<div class='itemLabelWide'>
|
||||
Name: {{:data.selected.name}}
|
||||
</div>
|
||||
{{if data.selected.description}}
|
||||
<div class='itemContent'>
|
||||
Description: {{:data.selected.description}}
|
||||
</div>
|
||||
{{/if}}
|
||||
{{if data.selected.admin_notes}}
|
||||
<div class='itemContent'>
|
||||
Admin Notes: {{:data.selected.admin_notes}}
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
<div class='item'>
|
||||
{{:helper.link('Preview', 'exclamation-circle', {'preview' : 1, 'shuttle_id' : data.selected.shuttle_id}, null)}}
|
||||
{{:helper.link('Load', 'exclamation-circle', {'load' : 1, 'shuttle_id' : data.selected.shuttle_id}, null)}}
|
||||
</div>
|
||||
</div>
|
||||
{{else}}
|
||||
<h3>No template selected</h3>
|
||||
{{/if}}
|
||||
</div>
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
Reference in New Issue
Block a user