Skip to content

Commit

Permalink
trilbysaveme
Browse files Browse the repository at this point in the history
  • Loading branch information
OliOliOnsiPree committed Feb 28, 2024
1 parent e5316c5 commit e9f4a5d
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 4 deletions.
2 changes: 1 addition & 1 deletion code/__DEFINES/jobs.dm
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
#define JOBS_CHURCH "Prime", "Vector"
#define JOBS_PROSPECTOR "Foreman","Fence","Salvager","Prospector"
#define JOBS_NONHUMAN "AI","Robot","pAI"
#define JOBS_INDEPENDENT "Outsider"
#define JOBS_LODGE "Lodge Hunt Master","Lodge Hunter","Lodge Herbalist",
#define JOBS_INDEPENDENT "Outsider"

#define JOBS_ANTI_HIVEMIND "Blackshield Commander","Warrant Officer","Supply Specialist","Ranger","Corpsman","Blackshield Trooper","Marshal Officer","Sergeant","Prime","Vector","Foreman","Fence","Salvager","Prospector","Premier","Steward","AI","Janitor","Soteria Lifeline Technician","Soteria Roboticist","Lonestar Miner"

Expand Down
20 changes: 19 additions & 1 deletion code/datums/datacore.dm
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ var/global/ManifestJSON
var/list/civ = new()
var/list/bot = new()
var/list/misc = new()
var/list/ldg = new()
var/list/isactive = new()
var/dat = {"
<head><style>
Expand Down Expand Up @@ -85,6 +86,9 @@ var/global/ManifestJSON
if(real_rank in civilian_positions)
civ[name] = rank
department = 1
if(real_rank in lodge_positions)
ldg[name] = rank
department = 1
if(!department && !(name in heads))
misc[name] = rank

Expand Down Expand Up @@ -155,6 +159,12 @@ var/global/ManifestJSON
for(name in misc)
dat += "<tr[even ? " class='alt'" : ""]><td>[name]</td><td>[misc[name]]</td><td>[isactive[name]]</td></tr>"
even = !even
if(ldg.len > 0)
dat += "<tr><th colspan=3>Lodge</th></tr>"
for(name in misc)
dat += "<tr[even ? " class='alt'" : ""]><td>[name]</td><td>[ldg[name]]</td><td>[isactive[name]]</td></tr>"
even = !even


dat += "</table>"
dat = replacetext(dat, "\n", "") // so it can be placed on paper correctly
Expand Down Expand Up @@ -388,6 +398,7 @@ var/global/ManifestJSON
var/civ[0]
var/bot[0]
var/misc[0]
var/ldg[0]
for(var/datum/data/record/t in data_core.general)
var/name = sanitize(t.fields["name"])
var/rank = sanitize(t.fields["rank"])
Expand Down Expand Up @@ -445,6 +456,12 @@ var/global/ManifestJSON
if(depthead && civ.len != 1)
civ.Swap(1, civ.len)

if(real_rank in lodge_positions)
ldg[++ldg.len] = list("name" = name, "rank" = rank, "active" = isactive)
department = 1
if(depthead && ldg.len != 1)
ldg.Swap(1, ldg.len)

if(real_rank in nonhuman_positions)
bot[++bot.len] = list("name" = name, "rank" = rank, "active" = isactive)
department = 1
Expand All @@ -463,7 +480,8 @@ var/global/ManifestJSON
"pro" = pro,
"civ" = civ,
"bot" = bot,
"misc" = misc
"misc" = misc,
"ldg" = ldg
)
ManifestJSON = json_encode(PDA_Manifest)
return
5 changes: 5 additions & 0 deletions code/datums/topic/admin.dm
Original file line number Diff line number Diff line change
Expand Up @@ -484,6 +484,11 @@
var/datum/job/temp = SSjob.GetJob(jobPos)
if(!temp) continue
joblist += temp.title
if("lodgedept")
for(var/jobPos in lodge_positions)
var/datum/job/temp = SSjob.GetJob(jobPos)
if(!temp) continue
joblist += temp.title
if("nonhumandept")
joblist += "pAI"
for(var/jobPos in nonhuman_positions)
Expand Down
1 change: 1 addition & 0 deletions code/datums/topic/world.dm
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@
"civ" = civilian_positions,
"chr" = church_positions,
"pro" = prospector_positions,
"ldg" = lodge_positions,
"bot" = nonhuman_positions
)

Expand Down
2 changes: 0 additions & 2 deletions code/game/jobs/jobs.dm
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,5 @@ var/list/offcolony_positions = list(JOBS_INDEPENDENT)

var/list/lodge_positions = list(JOBS_LODGE)



/proc/guest_jobbans(var/job)
return ((job in command_positions) || (job in nonhuman_positions) || (job in security_positions))

0 comments on commit e9f4a5d

Please sign in to comment.