mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-23 20:16:55 +01:00
MAP ROTATION PART 2 (#12345)
* MAP ROTATION * Tweaks + New additions * Apply suggestions from code review Co-authored-by: dearmochi <shenesis@gmail.com> * Fixes improper naming * Fixes map vote Co-authored-by: dearmochi <shenesis@gmail.com>
This commit is contained in:
co-authored by
dearmochi
parent
122f09585e
commit
663eff7b5e
@@ -137,7 +137,8 @@ GLOBAL_LIST_INIT(admin_verbs_server, list(
|
||||
/client/proc/toggle_antagHUD_restrictions,
|
||||
/client/proc/set_ooc,
|
||||
/client/proc/reset_ooc,
|
||||
/client/proc/toggledrones
|
||||
/client/proc/toggledrones,
|
||||
/client/proc/set_next_map
|
||||
))
|
||||
GLOBAL_LIST_INIT(admin_verbs_debug, list(
|
||||
/client/proc/cmd_admin_list_open_jobs,
|
||||
|
||||
@@ -2341,7 +2341,7 @@
|
||||
P.name = "Central Command - paper"
|
||||
var/stypes = list("Handle it yourselves!","Illegible fax","Fax not signed","Not Right Now","You are wasting our time", "Keep up the good work", "ERT Instructions")
|
||||
var/stype = input(src.owner, "Which type of standard reply do you wish to send to [H]?","Choose your paperwork", "") as null|anything in stypes
|
||||
var/tmsg = "<font face='Verdana' color='black'><center><img src = 'ntlogo.png'><BR><BR><BR><font size='4'><b>Nanotrasen Science Station [GLOB.using_map.station_short]</b></font><BR><BR><BR><font size='4'>NAS Trurl Communications Department Report</font></center><BR><BR>"
|
||||
var/tmsg = "<font face='Verdana' color='black'><center><img src = 'ntlogo.png'><BR><BR><BR><font size='4'><b>[SSmapping.map_datum.fluff_name]</b></font><BR><BR><BR><font size='4'>NAS Trurl Communications Department Report</font></center><BR><BR>"
|
||||
if(stype == "Handle it yourselves!")
|
||||
tmsg += "Greetings, esteemed crewmember. Your fax has been <b><I>DECLINED</I></b> automatically by NAS Trurl Fax Registration.<BR><BR>Please proceed in accordance with Standard Operating Procedure and/or Space Law. You are fully trained to handle this situation without Central Command intervention.<BR><BR><i><small>This is an automatic message.</small>"
|
||||
else if(stype == "Illegible fax")
|
||||
|
||||
@@ -179,3 +179,28 @@ GLOBAL_VAR_INIT(intercom_range_display_status, 0)
|
||||
|
||||
to_chat(world, "There are [count] objects of type [type_path] in the game world.")
|
||||
SSblackbox.record_feedback("tally", "admin_verb", 1, "Count Objects (Global)") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
/client/proc/set_next_map()
|
||||
set category = "Server"
|
||||
set name = "Set Next Map"
|
||||
|
||||
if(!check_rights(R_SERVER))
|
||||
return
|
||||
|
||||
var/list/map_datums = list()
|
||||
for(var/x in subtypesof(/datum/map))
|
||||
var/datum/map/M = x
|
||||
map_datums["[initial(M.fluff_name)] ([initial(M.technical_name)])"] = M // Put our map in
|
||||
|
||||
var/target_map_name = input(usr, "Select target map", "Next map", null) as null|anything in map_datums
|
||||
|
||||
if(!target_map_name)
|
||||
return
|
||||
|
||||
var/datum/map/TM = map_datums[target_map_name]
|
||||
SSmapping.next_map = new TM
|
||||
var/announce_to_players = alert(usr, "Do you wish to tell the playerbase about your choice?", "Announce", "Yes", "No")
|
||||
message_admins("[key_name_admin(usr)] has set the next map to [SSmapping.next_map.fluff_name] ([SSmapping.next_map.technical_name])")
|
||||
log_admin("[key_name(usr)] has set the next map to [SSmapping.next_map.fluff_name] ([SSmapping.next_map.technical_name])")
|
||||
if(announce_to_players == "Yes")
|
||||
to_chat(world, "<span class='boldannounce'>[key] has chosen the following map for next round: <font color='cyan'>[SSmapping.next_map.fluff_name] ([SSmapping.next_map.technical_name])</font></span>")
|
||||
|
||||
@@ -301,7 +301,7 @@
|
||||
else if(!ismob(contract.target.current))
|
||||
invalidate()
|
||||
return
|
||||
U.message_holder("Extraction signal received, agent. [GLOB.using_map.full_name]'s bluespace transport jamming systems have been sabotaged. "\
|
||||
U.message_holder("Extraction signal received, agent. [SSmapping.map_datum.fluff_name]'s bluespace transport jamming systems have been sabotaged. "\
|
||||
+ "We have opened a temporary portal at your flare location - proceed to the target's extraction by inserting them into the portal.", 'sound/effects/confirmdropoff.ogg')
|
||||
// Open a portal
|
||||
var/obj/effect/portal/redspace/contractor/P = new(get_turf(F), pick(GLOB.syndieprisonwarp), null, 0)
|
||||
@@ -528,7 +528,7 @@
|
||||
var/datum/feed_message/FM = new
|
||||
FM.author = "Nyx Daily"
|
||||
FM.admin_locked = TRUE
|
||||
FM.body = "Suspected Syndicate activity was reported in the system. Rumours have surfaced about a [R?.fields["rank"] || M?.mind.assigned_role || DEFAULT_RANK] aboard the [GLOB.using_map.full_name] being the victim of a kidnapping.\n\n" +\
|
||||
FM.body = "Suspected Syndicate activity was reported in the system. Rumours have surfaced about a [R?.fields["rank"] || M?.mind.assigned_role || DEFAULT_RANK] aboard the [SSmapping.map_datum.fluff_name] being the victim of a kidnapping.\n\n" +\
|
||||
"A reliable source said the following: There was a note with the victim's initials which were \"[initials]\" and a scribble saying \"[fluff_message]\""
|
||||
GLOB.news_network.get_channel_by_name("Nyx Daily")?.add_message(FM)
|
||||
|
||||
@@ -539,7 +539,7 @@
|
||||
var/datum/feed_message/FM2 = new
|
||||
FM2.author = "Nyx Daily"
|
||||
FM2.admin_locked = TRUE
|
||||
FM2.body = "Nanotrasen's Asset Management board has resigned today after a series of kidnappings aboard the [GLOB.using_map.full_name]." +\
|
||||
FM2.body = "Nanotrasen's Asset Management board has resigned today after a series of kidnappings aboard the [SSmapping.map_datum.fluff_name]." +\
|
||||
"One former member of the board was heard saying: \"I can't do this anymore. How does a single shift on this cursed station manage to cost us over ten million Credits in ransom payments? Is there no security aboard?!\""
|
||||
GLOB.news_network.get_channel_by_name("Nyx Daily")?.add_message(FM2)
|
||||
|
||||
|
||||
@@ -237,6 +237,11 @@ GLOBAL_DATUM_INIT(_preloader, /datum/dmm_suite/preloader, new())
|
||||
full_def = copytext(full_def, variables_start + 1, length(full_def)) // removing the last '}'
|
||||
fields = readlist(full_def, ";")
|
||||
|
||||
for(var/I in fields)
|
||||
var/value = fields[I]
|
||||
if(istext(value))
|
||||
fields[I] = apply_text_macros(value)
|
||||
|
||||
// then fill the members_attributes list with the corresponding variables
|
||||
members_attributes.len++
|
||||
members_attributes[index++] = fields
|
||||
|
||||
@@ -1,10 +0,0 @@
|
||||
/datum/map/cyberiad
|
||||
name = "Cyberiad"
|
||||
full_name = "NSS Cyberiad"
|
||||
|
||||
station_name = "NSS Cyberiad"
|
||||
station_short = "Cyberiad"
|
||||
dock_name = "NAS Trurl"
|
||||
company_name = "Nanotrasen"
|
||||
company_short = "NT"
|
||||
starsys_name = "Epsilon Eridani "
|
||||
@@ -1,10 +0,0 @@
|
||||
/datum/map/delta
|
||||
name = "Delta"
|
||||
full_name = "NSS Kerberos"
|
||||
|
||||
station_name = "NSS Kerberos"
|
||||
station_short = "Kerberos"
|
||||
dock_name = "NAS Trurl"
|
||||
company_name = "Nanotrasen"
|
||||
company_short = "NT"
|
||||
starsys_name = "Epsilon Eridani "
|
||||
@@ -1,10 +0,0 @@
|
||||
/datum/map
|
||||
var/name = "Unnamed Map"
|
||||
var/full_name = "Unnamed Map"
|
||||
|
||||
var/station_name = "BAD Station"
|
||||
var/station_short = "Baddy"
|
||||
var/dock_name = "THE PirateBay"
|
||||
var/company_name = "BadMan"
|
||||
var/company_short = "BM"
|
||||
var/starsys_name = "Dull Star"
|
||||
@@ -1,10 +0,0 @@
|
||||
/datum/map/metastation
|
||||
name = "MetaStation"
|
||||
full_name = "NSS Cerebron"
|
||||
|
||||
station_name = "NSS Cerebron"
|
||||
station_short = "Cerebron"
|
||||
dock_name = "NAS Trurl"
|
||||
company_name = "Nanotrasen"
|
||||
company_short = "NT"
|
||||
starsys_name = "Epsilon Eridani "
|
||||
@@ -0,0 +1,14 @@
|
||||
/**
|
||||
* Map Datum
|
||||
*
|
||||
* Datum which holds all of the information for maps ingame
|
||||
* This is used for showing map information, as well as map loading
|
||||
*
|
||||
**/
|
||||
/datum/map
|
||||
/// Name of the map to be shown in the statpanel
|
||||
var/fluff_name
|
||||
/// Name to be used when using the map from a technical standpoint. Used in TGUI Nanomaps among other things.
|
||||
var/technical_name
|
||||
/// Path to the map file
|
||||
var/map_path
|
||||
@@ -0,0 +1,4 @@
|
||||
/datum/map/cyberiad
|
||||
fluff_name = "NSS Cyberiad"
|
||||
technical_name = "Cyberiad"
|
||||
map_path = "_maps/map_files/cyberiad/cyberiad.dmm"
|
||||
@@ -0,0 +1,4 @@
|
||||
/datum/map/delta
|
||||
fluff_name = "NSS Kerberos"
|
||||
technical_name = "Delta"
|
||||
map_path = "_maps/map_files/Delta/delta.dmm"
|
||||
@@ -0,0 +1,4 @@
|
||||
/datum/map/metastation
|
||||
fluff_name = "NSS Cerebron"
|
||||
technical_name = "MetaStation"
|
||||
map_path = "_maps/map_files/MetaStation/MetaStation.dmm"
|
||||
@@ -963,6 +963,9 @@ GLOBAL_LIST_INIT(slot_equipment_priority, list( \
|
||||
|
||||
statpanel("Status") // We only want alt-clicked turfs to come before Status
|
||||
stat(null, "Round ID: [GLOB.round_id ? GLOB.round_id : "NULL"]")
|
||||
stat(null, "Map: [SSmapping.map_datum.fluff_name]")
|
||||
if(SSmapping.next_map)
|
||||
stat(null, "Next Map: [SSmapping.next_map.fluff_name]")
|
||||
|
||||
if(mob_spell_list && mob_spell_list.len)
|
||||
for(var/obj/effect/proc_holder/spell/S in mob_spell_list)
|
||||
|
||||
@@ -269,6 +269,8 @@
|
||||
for(var/mob/M in GLOB.player_list)
|
||||
if(!isnewplayer(M) && !M.client.karma_spent && !(M.client.ckey in GLOB.karma_spenders) && !M.get_preference(PREFTOGGLE_DISABLE_KARMA_REMINDER))
|
||||
to_chat(M, "<i>You have not yet spent your karma for the round; was there a player worthy of receiving your reward? Look under Special Verbs tab, Award Karma.</i>")
|
||||
if(config.map_voting_enabled)
|
||||
SSvote.initiate_vote("map", "the server", TRUE)
|
||||
|
||||
if(SHUTTLE_ESCAPE)
|
||||
if(time_left <= 0)
|
||||
|
||||
@@ -36,7 +36,8 @@
|
||||
secure = (z == level_name_to_num(CENTCOMM))
|
||||
return secure
|
||||
|
||||
GLOBAL_LIST_INIT(default_map_traits, MAP_TRANSITION_CONFIG)
|
||||
// Only CC
|
||||
GLOBAL_LIST_INIT(default_map_traits, list(CC_TRANSITION_CONFIG))
|
||||
|
||||
/proc/check_level_trait(z, trait)
|
||||
if(!z)
|
||||
|
||||
@@ -197,7 +197,7 @@
|
||||
"fancy" = user.client.prefs.toggles2 & PREFTOGGLE_2_FANCYUI,
|
||||
"observer" = isobserver(user),
|
||||
"window" = window_id,
|
||||
"map" = (GLOB.using_map && GLOB.using_map.name) ? GLOB.using_map.name : "Unknown",
|
||||
"map" = SSmapping.map_datum.technical_name,
|
||||
"ref" = "[src.UID()]"
|
||||
)
|
||||
|
||||
|
||||
@@ -30,7 +30,7 @@
|
||||
player_count++
|
||||
status_info["players"] = player_count
|
||||
status_info["admins"] = admin_count
|
||||
status_info["map_name"] = GLOB.map_name ? GLOB.map_name : "Unknown"
|
||||
status_info["map_name"] = SSmapping.map_datum.fluff_name
|
||||
|
||||
// Add more info if we are authed
|
||||
if(key_valid)
|
||||
|
||||
Reference in New Issue
Block a user