Various improvements to job greetings. (#4777)
This commit is contained in:
committed by
GitHub
parent
eac2fd3cf0
commit
419edc710d
@@ -1,6 +1,7 @@
|
||||
using Content.Server.Chat.Managers;
|
||||
using Content.Shared.Roles;
|
||||
using Robust.Shared.IoC;
|
||||
using Robust.Shared.Localization;
|
||||
|
||||
namespace Content.Server.Roles
|
||||
{
|
||||
@@ -26,7 +27,16 @@ namespace Content.Server.Roles
|
||||
if (Mind.TryGetSession(out var session))
|
||||
{
|
||||
var chat = IoCManager.Resolve<IChatManager>();
|
||||
chat.DispatchServerMessage(session, $"You're a new {Name}. Do your best!");
|
||||
chat.DispatchServerMessage(session, Loc.GetString("job-greet-introduce-job-name", ("jobName", Name)));
|
||||
|
||||
if(Prototype.RequireAdminNotify)
|
||||
chat.DispatchServerMessage(session, Loc.GetString("job-greet-important-disconnect-admin-notify"));
|
||||
|
||||
chat.DispatchServerMessage(session, Loc.GetString("job-greet-supervisors-warning", ("jobName", Name), ("supervisors", Prototype.Supervisors)));
|
||||
|
||||
if(Prototype.JoinNotifyCrew && Mind.CharacterName != null)
|
||||
chat.DispatchStationAnnouncement(Loc.GetString("job-greet-join-notify-crew", ("jobName", Name), ("characterName", Mind.CharacterName)),
|
||||
Loc.GetString("job-greet-join-notify-crew-announcer"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -18,12 +18,21 @@ namespace Content.Shared.Roles
|
||||
[DataField("id", required: true)]
|
||||
public string ID { get; } = default!;
|
||||
|
||||
[DataField("supervisors")]
|
||||
public string Supervisors { get; } = "nobody";
|
||||
|
||||
/// <summary>
|
||||
/// The name of this job as displayed to players.
|
||||
/// </summary>
|
||||
[DataField("name")]
|
||||
public string Name { get; } = string.Empty;
|
||||
|
||||
[DataField("joinNotifyCrew")]
|
||||
public bool JoinNotifyCrew { get; } = false;
|
||||
|
||||
[DataField("requireAdminNotify")]
|
||||
public bool RequireAdminNotify { get; } = false;
|
||||
|
||||
/// <summary>
|
||||
/// Whether this job is a head.
|
||||
/// The job system will try to pick heads before other jobs on the same priority level.
|
||||
|
||||
5
Resources/Locale/en-US/job/job.ftl
Normal file
5
Resources/Locale/en-US/job/job.ftl
Normal file
@@ -0,0 +1,5 @@
|
||||
job-greet-introduce-job-name = You are the {$jobName}.
|
||||
job-greet-important-disconnect-admin-notify = You are playing a job that is important for Game Progression. If you have to disconnect, please notify the admins.
|
||||
job-greet-supervisors-warning = As the {$jobName} you answer directly to {$supervisors}. Special circumstances may change this.
|
||||
job-greet-join-notify-crew = { CAPITALIZE($jobName)} {$characterName} on deck!
|
||||
job-greet-join-notify-crew-announcer = Station
|
||||
@@ -7,6 +7,7 @@
|
||||
departments:
|
||||
- Cargo
|
||||
icon: "CargoTechnician"
|
||||
supervisors: "the head of personnel" # TODO: Change this to include the QM when it gets in.
|
||||
access:
|
||||
- Cargo
|
||||
- Maintenance
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
# departments:
|
||||
# - Cargo
|
||||
# icon: "QuarterMaster"
|
||||
# supervisors: "the head of personnel"
|
||||
# access:
|
||||
# - Cargo
|
||||
# - Quartermaster
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
departments:
|
||||
- Civilian
|
||||
icon: "Assistant"
|
||||
supervisors: "absolutely everyone"
|
||||
access:
|
||||
- Maintenance
|
||||
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
departments:
|
||||
- Civilian
|
||||
icon: "Bartender"
|
||||
supervisors: "the head of personnel"
|
||||
access:
|
||||
- Service
|
||||
- Maintenance
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
departments:
|
||||
- Civilian
|
||||
icon: "Botanist"
|
||||
supervisors: "the head of personnel"
|
||||
access:
|
||||
- Service
|
||||
- Maintenance
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
# departments:
|
||||
# - Civilian
|
||||
# icon: "Chaplain"
|
||||
# supervisors: "the head of personnel"
|
||||
# access:
|
||||
# - Chapel
|
||||
# - Maintenance
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
departments:
|
||||
- Civilian
|
||||
icon: "Chef"
|
||||
supervisors: "the head of personnel"
|
||||
access:
|
||||
- Service
|
||||
- Maintenance
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
departments:
|
||||
- Civilian
|
||||
icon: "Clown"
|
||||
supervisors: "the head of personnel"
|
||||
access:
|
||||
- Theatre
|
||||
- Maintenance
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
departments:
|
||||
- Civilian
|
||||
icon: "Janitor"
|
||||
supervisors: "the head of personnel"
|
||||
access:
|
||||
- Janitor
|
||||
- Maintenance
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
departments:
|
||||
- Civilian
|
||||
icon: "Mime"
|
||||
supervisors: "the head of personnel"
|
||||
access:
|
||||
- Theatre
|
||||
- Maintenance
|
||||
|
||||
@@ -7,6 +7,9 @@
|
||||
departments:
|
||||
- Command
|
||||
icon: "Captain"
|
||||
requireAdminNotify: true
|
||||
joinNotifyCrew: true
|
||||
supervisors: "Nanotrasen officials"
|
||||
access:
|
||||
# All of em.
|
||||
# Could probably do with some kind of wildcard or whatever to automate this.
|
||||
|
||||
@@ -7,6 +7,8 @@
|
||||
- Command
|
||||
- Civilian
|
||||
icon: "HeadOfPersonnel"
|
||||
requireAdminNotify: true
|
||||
supervisors: "the captain"
|
||||
access:
|
||||
- Command
|
||||
- HeadOfPersonnel
|
||||
|
||||
@@ -8,6 +8,8 @@
|
||||
- Command
|
||||
- Engineering
|
||||
icon: "ChiefEngineer"
|
||||
requireAdminNotify: true
|
||||
supervisors: "the captain"
|
||||
access:
|
||||
- Maintenance
|
||||
- Engineering
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
departments:
|
||||
- Engineering
|
||||
icon: "StationEngineer"
|
||||
supervisors: "the chief engineer"
|
||||
access:
|
||||
- Maintenance
|
||||
- Engineering
|
||||
|
||||
@@ -10,6 +10,8 @@
|
||||
- Command
|
||||
- Medical
|
||||
icon: "ChiefMedicalOfficer"
|
||||
requireAdminNotify: true
|
||||
supervisors: "the captain"
|
||||
access:
|
||||
- Medical
|
||||
- Command
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
departments:
|
||||
- Medical
|
||||
icon: "MedicalDoctor"
|
||||
supervisors: "the chief medical officer"
|
||||
access:
|
||||
- Medical
|
||||
- Maintenance
|
||||
|
||||
@@ -8,6 +8,8 @@
|
||||
- Command
|
||||
- Science
|
||||
icon: "ResearchDirector"
|
||||
requireAdminNotify: true
|
||||
supervisors: "the captain"
|
||||
access:
|
||||
- Research
|
||||
- Command
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
departments:
|
||||
- Science
|
||||
icon: "Scientist"
|
||||
supervisors: "the research director"
|
||||
access:
|
||||
- Research
|
||||
- Maintenance
|
||||
|
||||
@@ -8,6 +8,8 @@
|
||||
- Command
|
||||
- Security
|
||||
icon: "HeadOfSecurity"
|
||||
requireAdminNotify: true
|
||||
supervisors: "the captain"
|
||||
access:
|
||||
- Command
|
||||
- Brig
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
departments:
|
||||
- Security
|
||||
icon: "SecurityOfficer"
|
||||
supervisors: "the head of security"
|
||||
access:
|
||||
- Security
|
||||
- Maintenance
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
# departments:
|
||||
# - Security
|
||||
# icon: "Warden"
|
||||
# supervisors: "the head of security"
|
||||
# access:
|
||||
# - Security
|
||||
# - Brig
|
||||
|
||||
Reference in New Issue
Block a user