mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-17 01:53:35 +01:00
Adds Supply section to manifest
This commit is contained in:
@@ -4,7 +4,6 @@ datum/game_mode/nations
|
||||
required_players_secret = 25
|
||||
var/kickoff = 0
|
||||
var/victory = 0
|
||||
var/list/cargonians = list("Quartermaster","Cargo Technician","Shaft Miner")
|
||||
var/list/servicion = list("Clown", "Mime", "Bartender", "Chef", "Botanist", "Librarian", "Chaplain", "Barber")
|
||||
|
||||
|
||||
@@ -80,7 +79,7 @@ datum/game_mode/nations
|
||||
H << "You are now part of the great sovereign nation of [H.mind.nation.default_name]!"
|
||||
continue
|
||||
|
||||
if(H.mind.assigned_role in cargonians)
|
||||
if(H.mind.assigned_role in supply_positions)
|
||||
H.mind.nation = all_nations["Cargonia"]
|
||||
update_nations_icons_added(H,"hudcargonia")
|
||||
H.mind.nation.membership += H.mind.current
|
||||
@@ -181,9 +180,8 @@ datum/game_mode/nations
|
||||
if (!mode) return 1
|
||||
|
||||
if(!mode.kickoff) return 1
|
||||
|
||||
var/list/cargonians = list("Quartermaster","Cargo Technician","Shaft Miner")
|
||||
var/list/servicion = list("Clown", "Mime", "Bartender", "Chef", "Botanist")
|
||||
|
||||
var/list/servicion = list("Clown", "Mime", "Bartender", "Chef", "Botanist", "Librarian", "Chaplain", "Barber")
|
||||
if(H.mind)
|
||||
if(H.mind.assigned_role in engineering_positions)
|
||||
H.mind.nation = all_nations["Atmosia"]
|
||||
@@ -213,7 +211,7 @@ datum/game_mode/nations
|
||||
H << "You are now part of the great sovereign nation of [H.mind.nation.current_name]!"
|
||||
return 1
|
||||
|
||||
if(H.mind.assigned_role in cargonians)
|
||||
if(H.mind.assigned_role in supply_positions)
|
||||
H.mind.nation = all_nations["Cargonia"]
|
||||
mode.update_nations_icons_added(H,"hudcargonia")
|
||||
H.mind.nation.membership += H.mind.current
|
||||
|
||||
@@ -116,6 +116,14 @@ var/list/support_positions = list(
|
||||
"Blueshield"
|
||||
)
|
||||
|
||||
var/list/supply_positions = list(
|
||||
"Quartermaster",
|
||||
"Cargo Technician",
|
||||
"Shaft Miner"
|
||||
)
|
||||
|
||||
var/list/service_positions = support_positions - supply_positions
|
||||
|
||||
|
||||
var/list/security_positions = list(
|
||||
"Head of Security",
|
||||
|
||||
@@ -18,7 +18,8 @@
|
||||
var/list/eng = new()
|
||||
var/list/med = new()
|
||||
var/list/sci = new()
|
||||
var/list/supp = new()
|
||||
var/list/ser = new()
|
||||
var/list/sup = new()
|
||||
var/list/bot = new()
|
||||
var/list/misc = new()
|
||||
var/list/isactive = new()
|
||||
@@ -67,8 +68,11 @@
|
||||
if(real_rank in science_positions)
|
||||
sci[name] = rank
|
||||
department = 1
|
||||
if(real_rank in support_positions)
|
||||
supp[name] = rank
|
||||
if(real_rank in service_positions)
|
||||
ser[name] = rank
|
||||
department = 1
|
||||
if(real_rank in supply_positions)
|
||||
sup[name] = rank
|
||||
department = 1
|
||||
if(real_rank in nonhuman_positions)
|
||||
bot[name] = rank
|
||||
@@ -100,10 +104,15 @@
|
||||
for(name in sci)
|
||||
dat += "<tr[even ? " class='alt'" : ""]><td>[name]</td><td>[sci[name]]</td><td>[isactive[name]]</td></tr>"
|
||||
even = !even
|
||||
if(supp.len > 0)
|
||||
if(ser.len > 0)
|
||||
dat += "<tr><th colspan=3>Support</th></tr>"
|
||||
for(name in supp)
|
||||
dat += "<tr[even ? " class='alt'" : ""]><td>[name]</td><td>[supp[name]]</td><td>[isactive[name]]</td></tr>"
|
||||
for(name in ser)
|
||||
dat += "<tr[even ? " class='alt'" : ""]><td>[name]</td><td>[ser[name]]</td><td>[isactive[name]]</td></tr>"
|
||||
even = !even
|
||||
if(sup.len > 0)
|
||||
dat += "<tr><th colspan=3>Supply</th></tr>"
|
||||
for(name in sup)
|
||||
dat += "<tr[even ? " class='alt'" : ""]><td>[name]</td><td>[sup[name]]</td><td>[isactive[name]]</td></tr>"
|
||||
even = !even
|
||||
// in case somebody is insane and added them to the manifest, why not
|
||||
if(bot.len > 0)
|
||||
@@ -142,7 +151,8 @@ var/global/ManifestJSON
|
||||
var/eng[0]
|
||||
var/med[0]
|
||||
var/sci[0]
|
||||
var/supp[0]
|
||||
var/ser[0]
|
||||
var/sup[0]
|
||||
var/bot[0]
|
||||
var/misc[0]
|
||||
for(var/datum/data/record/t in data_core.general)
|
||||
@@ -183,11 +193,17 @@ var/global/ManifestJSON
|
||||
if(depthead && sci.len != 1)
|
||||
sci.Swap(1,sci.len)
|
||||
|
||||
if(real_rank in support_positions)
|
||||
supp[++supp.len] = list("name" = name, "rank" = rank, "active" = isactive)
|
||||
if(real_rank in service_positions)
|
||||
ser[++ser.len] = list("name" = name, "rank" = rank, "active" = isactive)
|
||||
department = 1
|
||||
if(depthead && supp.len != 1)
|
||||
supp.Swap(1,supp.len)
|
||||
if(depthead && ser.len != 1)
|
||||
ser.Swap(1,ser.len)
|
||||
|
||||
if(real_rank in supply_positions)
|
||||
sup[++sup.len] = list("name" = name, "rank" = rank, "active" = isactive)
|
||||
department = 1
|
||||
if(depthead && sup.len != 1)
|
||||
sup.Swap(1,sup.len)
|
||||
|
||||
if(real_rank in nonhuman_positions)
|
||||
bot[++bot.len] = list("name" = name, "rank" = rank, "active" = isactive)
|
||||
@@ -203,7 +219,8 @@ var/global/ManifestJSON
|
||||
"eng" = eng,\
|
||||
"med" = med,\
|
||||
"sci" = sci,\
|
||||
"supp" = supp,\
|
||||
"ser" = ser,\
|
||||
"sup" = sup,\
|
||||
"bot" = bot,\
|
||||
"misc" = misc\
|
||||
)
|
||||
|
||||
File diff suppressed because one or more lines are too long
+20
-20
@@ -27,46 +27,46 @@ table.pmon td, table.pmon th {
|
||||
}
|
||||
|
||||
/* Table styling for the crew manifest */
|
||||
th.command {
|
||||
background: #3333FF;
|
||||
.manifest-header(@color: #666) {
|
||||
background: @color;
|
||||
font-weight: bold;
|
||||
color: #ffffff;
|
||||
}
|
||||
|
||||
th.command {
|
||||
.manifest-header(#3333FF);
|
||||
}
|
||||
|
||||
th.sec {
|
||||
background: #8e0000;
|
||||
font-weight: bold;
|
||||
color: #ffffff;
|
||||
.manifest-header(#8e0000);
|
||||
}
|
||||
|
||||
th.med {
|
||||
background: #006600;
|
||||
font-weight: bold;
|
||||
color: #ffffff;
|
||||
.manifest-header(#006600);
|
||||
}
|
||||
|
||||
th.eng {
|
||||
background: #b27300;
|
||||
font-weight: bold;
|
||||
color: #ffffff;
|
||||
.manifest-header(#b27300);
|
||||
}
|
||||
|
||||
th.sci {
|
||||
background: #a65ba6;
|
||||
font-weight: bold;
|
||||
color: #ffffff;
|
||||
.manifest-header(#a65ba6);
|
||||
}
|
||||
|
||||
th.ser {
|
||||
.manifest-header(#7100AA);
|
||||
}
|
||||
|
||||
th.sup {
|
||||
.manifest-header(#666621);
|
||||
}
|
||||
|
||||
th.civ {
|
||||
background: #a32800;
|
||||
font-weight: bold;
|
||||
color: #ffffff;
|
||||
.manifest-header(#a32800);
|
||||
}
|
||||
|
||||
th.misc {
|
||||
background: #666666;
|
||||
font-weight: bold;
|
||||
color: #ffffff;
|
||||
.manifest-header;
|
||||
}
|
||||
|
||||
/* Striped lines for tables and divs */
|
||||
|
||||
@@ -45,27 +45,37 @@ Copy-pasted from pda.tmpl
|
||||
<tr><td><span class="average">{{:value.name}}</span></td><td><span class="average">{{:value.rank}}</span></td><td><span class="average">{{:value.active}}</span></td></tr>
|
||||
{{/if}}
|
||||
{{/for}}
|
||||
{{/if}}
|
||||
{{if data.manifest.sci}}
|
||||
<tr><th colspan="3" class="sci">Science</th></tr>
|
||||
{{for data.manifest["sci"]}}
|
||||
{{if value.rank == "Research Director"}}
|
||||
<tr><td><span class="good">{{:value.name}}</span></td><td><span class="good">{{:value.rank}}</span></td><td><span class="good">{{:value.active}}</span></td></tr>
|
||||
{{else}}
|
||||
<tr><td><span class="average">{{:value.name}}</span></td><td><span class="average">{{:value.rank}}</span></td><td><span class="average">{{:value.active}}</span></td></tr>
|
||||
{{/if}}
|
||||
{{/for}}
|
||||
{{/if}}
|
||||
{{if data.manifest.supp}}
|
||||
<tr><th colspan="3" class="supp">Support</th></tr>
|
||||
{{for data.manifest["supp"]}}
|
||||
{{if value.rank == "Head of Personnel"}}
|
||||
<tr><td><span class="good">{{:value.name}}</span></td><td><span class="good">{{:value.rank}}</span></td><td><span class="good">{{:value.active}}</span></td></tr>
|
||||
{{else}}
|
||||
<tr><td><span class="average">{{:value.name}}</span></td><td><span class="average">{{:value.rank}}</span></td><td><span class="average">{{:value.active}}</span></td></tr>
|
||||
{{/if}}
|
||||
{{/for}}
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
{{if data.manifest.sci}}
|
||||
<tr><th colspan="3" class="sci">Science</th></tr>
|
||||
{{for data.manifest["sci"]}}
|
||||
{{if value.rank == "Research Director"}}
|
||||
<tr><td><span class="good">{{:value.name}}</span></td><td><span class="good">{{:value.rank}}</span></td><td><span class="good">{{:value.active}}</span></td></tr>
|
||||
{{else}}
|
||||
<tr><td><span class="average">{{:value.name}}</span></td><td><span class="average">{{:value.rank}}</span></td><td><span class="average">{{:value.active}}</span></td></tr>
|
||||
{{/if}}
|
||||
{{/for}}
|
||||
{{/if}}
|
||||
{{if data.manifest.ser}}
|
||||
<tr><th colspan="3" class="ser">Support</th></tr>
|
||||
{{for data.manifest["ser"]}}
|
||||
{{if value.rank == "Head of Personnel"}}
|
||||
<tr><td><span class="good">{{:value.name}}</span></td><td><span class="good">{{:value.rank}}</span></td><td><span class="good">{{:value.active}}</span></td></tr>
|
||||
{{else}}
|
||||
<tr><td><span class="average">{{:value.name}}</span></td><td><span class="average">{{:value.rank}}</span></td><td><span class="average">{{:value.active}}</span></td></tr>
|
||||
{{/if}}
|
||||
{{/for}}
|
||||
{{/if}}
|
||||
{{if data.manifest.sup}}
|
||||
<tr><th colspan="3" class="sup">Supply</th></tr>
|
||||
{{for data.manifest["sup"]}}
|
||||
{{if value.rank == "Quartermaster"}}
|
||||
<tr><td><span class="good">{{:value.name}}</span></td><td><span class="good">{{:value.rank}}</span></td><td><span class="good">{{:value.active}}</span></td></tr>
|
||||
{{else}}
|
||||
<tr><td><span class="average">{{:value.name}}</span></td><td><span class="average">{{:value.rank}}</span></td><td><span class="average">{{:value.active}}</span></td></tr>
|
||||
{{/if}}
|
||||
{{/for}}
|
||||
{{/if}}
|
||||
{{if data.manifest.civ}}
|
||||
<tr><th colspan="3" class="civ">Civilian</th></tr>
|
||||
{{for data.manifest["civ"]}}
|
||||
|
||||
+13
-3
@@ -428,9 +428,9 @@ Used In File(s): \code\game\objects\items\devices\PDA\PDA.dm
|
||||
{{/if}}
|
||||
{{/for}}
|
||||
{{/if}}
|
||||
{{if data.manifest.supp}}
|
||||
<tr><th colspan="3" class="supp">Support</th></tr>
|
||||
{{for data.manifest["supp"]}}
|
||||
{{if data.manifest.ser}}
|
||||
<tr><th colspan="3" class="ser">Support</th></tr>
|
||||
{{for data.manifest["ser"]}}
|
||||
{{if value.rank == "Head of Personnel"}}
|
||||
<tr><td><span class="good">{{:value.name}}</span></td><td><span class="good">{{:value.rank}}</span></td><td><span class="good">{{:value.active}}</span></td></tr>
|
||||
{{else}}
|
||||
@@ -438,6 +438,16 @@ Used In File(s): \code\game\objects\items\devices\PDA\PDA.dm
|
||||
{{/if}}
|
||||
{{/for}}
|
||||
{{/if}}
|
||||
{{if data.manifest.sup}}
|
||||
<tr><th colspan="3" class="sup">Supply</th></tr>
|
||||
{{for data.manifest["sup"]}}
|
||||
{{if value.rank == "Quartermaster"}}
|
||||
<tr><td><span class="good">{{:value.name}}</span></td><td><span class="good">{{:value.rank}}</span></td><td><span class="good">{{:value.active}}</span></td></tr>
|
||||
{{else}}
|
||||
<tr><td><span class="average">{{:value.name}}</span></td><td><span class="average">{{:value.rank}}</span></td><td><span class="average">{{:value.active}}</span></td></tr>
|
||||
{{/if}}
|
||||
{{/for}}
|
||||
{{/if}}
|
||||
{{if data.manifest.civ}}
|
||||
<tr><th colspan="3" class="civ">Civilian</th></tr>
|
||||
{{for data.manifest["civ"]}}
|
||||
|
||||
Reference in New Issue
Block a user