Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Port] Port Nanotrasen Representative (NTR) and Blueshield Officer (BSO) #20

Closed
wants to merge 49 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
a1171af
Add blueshield and ntr
Aidenkrz Jun 3, 2024
1c90b1c
Change to CharacterDepart... to fit the role creation.
CerberusWolfie Jan 3, 2025
365971c
Add more flavor comment.
CerberusWolfie Jan 3, 2025
60b9564
Fix blueshield and ntr backpacks
Aidenkrz Jun 5, 2024
ea35a10
Cherry-Pick the commit 3989974 (3989974647) from Goob LRP and fix con…
Aidenkrz Jun 13, 2024
7e06c74
Update nanotrasen_representative.yml
Teapug Jun 14, 2024
275f903
give ntr cc access
Piras314 Jun 14, 2024
d81bf84
Merge pull request #272 from Teapug/master
Aidenkrz Jun 15, 2024
811d5e2
NTR spawns with nanotrasen representative satchel now
Teapug Jun 17, 2024
56e0ed6
Had to forcefully commit 1870a312be006dce8baae36f14dec877a8acb177 man…
CerberusWolfie Jan 3, 2025
528c92b
Cherry-Picking 1b79de9 (1b79de95dd) from GoobLRP, had to manually fix…
Teapug Jun 19, 2024
a8b9eff
Cherry-Pick Commit 8a03dfb (8a03dfb911) and accept a character change.
Verbalase Jul 31, 2024
0f50efd
Change the Department time to CharacterDepartm... as needed.
CerberusWolfie Jan 3, 2025
b6a2e19
Fix NTR access bug (#455)
Piras314 Aug 2, 2024
6a042e7
Cherry-Pick 97e8824 (97e8824a2f) and fix conflicts.
Aidenkrz Aug 12, 2024
b6b7600
Fix jobIcon -> statusIcon for EE.
CerberusWolfie Jan 3, 2025
2b4cd06
Fix the merge conflict on techAssist and secCadet and comment out loa…
CerberusWolfie Jan 3, 2025
47f6c28
Rename all the files to follow the rename in PR (on Goob LRP GH) #689…
CerberusWolfie Jan 3, 2025
df25100
Fix naming schema for entitites prior to testing.
CerberusWolfie Jan 3, 2025
8bd96e3
Cherry-Pick 1f37558 (1f3755809d) from Goob LRP. Will fix in later com…
BombasterDS Sep 26, 2024
36df507
Temp rename to grab older resources.
CerberusWolfie Jan 3, 2025
6e53044
Cherry-Pick b66ae2f (b66ae2fcb4) from Goob LRP. Fixing changes and th…
BombasterDS Sep 24, 2024
beb78c3
Rename the directories.
CerberusWolfie Jan 3, 2025
cb284ea
Renamed all the dependencies to match the name change. Deleted artifa…
CerberusWolfie Jan 4, 2025
be9b0d4
Rename for the umpteenth time to cherry-pick an older commit that I m…
CerberusWolfie Jan 4, 2025
68cb287
Cherry-Pick f412ad2 (f412ad2c61) from Goob LRP for the remaining BSO …
Icepicked Sep 15, 2024
aace1bc
Rename back to _Goobstation. PLEASE LET THIS BE THE LAST TIME!
CerberusWolfie Jan 4, 2025
97609d5
This adds the component for the MedSec glasses (it doesn't work). Thi…
CerberusWolfie Jan 4, 2025
2bacf62
Fixed the Jumpskirt for BSO.
CerberusWolfie Jan 4, 2025
fcd922f
Made BSO uniform more blue (#667)
InfinityPandaRed Sep 23, 2024
1461440
Rename for a cherry-pick.
CerberusWolfie Jan 4, 2025
95efa5b
NTR Skirt Change (#500)
Aidenkrz Aug 13, 2024
c27370e
Rename back.
CerberusWolfie Jan 4, 2025
6d44a09
Security Status partial PR.
CerberusWolfie Jan 4, 2025
4042f2c
Cherry-Pick b19945c (b19945c394) and fix merge conflict.
starch70 Oct 23, 2024
f94f5cf
Rename for EG-4 cherry-pick.
CerberusWolfie Jan 4, 2025
401f720
Cherry-Pick 64d84d2 (64d84d2127) and add the gun to pocket.
Icepicked Sep 18, 2024
6041c65
Rename back.
CerberusWolfie Jan 4, 2025
6f09149
Cherry-Pick 49d5a9f (49d5a9fd03) and solve merge conflict.
Icepicked Sep 28, 2024
d935160
Remove the gun that isn't in my files.
CerberusWolfie Jan 4, 2025
dee8ead
Cherry-Pick f1cff42 (f1cff42058) but remove the extra doors (I don't …
starch70 Nov 11, 2024
5a25c9d
Cherry-Pick 348757d (348757d7c7) and comment out loadouts (for EE rem…
DarkenedSynergy Dec 1, 2024
402d012
Remove Contraband tags, they're not in EE.
CerberusWolfie Jan 4, 2025
a849aab
Rename to fix the NTR Satchel with the most elite cherry-pick.
CerberusWolfie Jan 4, 2025
d25d01f
Cherry-Pick fe29176 (fe291765f5) to fix the Satchels for NTR.
Aidenkrz Jun 18, 2024
0ea621e
Rename back and test.
CerberusWolfie Jan 4, 2025
798763e
Fix the base texture of the gun.
CerberusWolfie Jan 4, 2025
71fffef
Fix the unique_teleporters.yml to use the previous version of it. The…
CerberusWolfie Jan 4, 2025
2ad123c
Fix the jumpskirt (once again) because it undid my earlier change?!
CerberusWolfie Jan 4, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions Content.Server/Explosion/EntitySystems/TriggerSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,14 @@ private void HandleFlashTrigger(EntityUid uid, FlashOnTriggerComponent component

private void HandleDeleteTrigger(EntityUid uid, DeleteOnTriggerComponent component, TriggerEvent args)
{
//Goobstation - bluespace lifeline implanter
if (TryComp(uid, out TransformComponent? xform) && xform.ParentUid != null)
{
EntityManager.QueueDeleteEntity(xform.ParentUid);
args.Handled = true;
return;
}

EntityManager.QueueDeleteEntity(uid);
args.Handled = true;
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
namespace Content.Server._Goobstation.Interaction.Components;

/// <summary>
/// Allows use item with component on stations only
/// </summary>
[RegisterComponent]
public sealed partial class UseOnStationOnlyComponent : Component
{
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
using Content.Server._Goobstation.Interaction.Components;
using Content.Server.Popups;
using Content.Server.Station.Systems;
using Content.Shared._Goobstation.Interaction;

namespace Content.Server._Goobstation.Interaction.Systems;

public sealed partial class UseOnStationOnlySystem : EntitySystem
{
[Dependency] private readonly StationSystem _station = default!;
[Dependency] private readonly PopupSystem _popup = default!;

public override void Initialize()
{
base.Initialize();

SubscribeLocalEvent<UseOnStationOnlyComponent, UseInHandAttemptEvent>(OnUseAttempt);
}

private void OnUseAttempt(Entity<UseOnStationOnlyComponent> item, ref UseInHandAttemptEvent args)
{
if (_station.GetOwningStation(args.User) is not null)
return;

_popup.PopupEntity(Loc.GetString("use-on-station-only-not-on-station"), args.User, args.User);
args.Cancel();
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
namespace Content.Server._Goobstation.Spawn.Components;

/// <summary>
/// Ensures that related entity will be on station (like NTR or BSO lockers) and will be not duplicate.
/// If station have unique entity - item with this component will be deleted.
/// </summary>
[RegisterComponent]
public sealed partial class UniqueEntityCheckerComponent : Component
{
/// <summary>
/// Name of marker in UniqueEntityMarker
/// </summary>
[DataField]
public string? MarkerName;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
namespace Content.Server._Goobstation.Spawn.Components;

/// <summary>
/// Component-marker for unique entity
/// </summary>
[RegisterComponent]
public sealed partial class UniqueEntityMarkerComponent : Component
{
/// <summary>
/// Marker name that would be used in check
/// </summary>
[DataField]
public string? MarkerName;

/// <summary>
/// If true - marker will work on grids with StationDataComponent
/// If false - marker will work globally
/// </summary>
[DataField]
public bool StationOnly = true;
}
43 changes: 43 additions & 0 deletions Content.Server/_Goobstation/Spawn/Systems/UniqueEntitySystem.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
using Content.Server._Goobstation.Spawn.Components;
using Content.Server.Station.Components;
using Content.Server.Station.Systems;

namespace Content.Server._Goobstation.Spawn.Systems;

public sealed partial class UniqueEntitySystem : EntitySystem
{
[Dependency] private readonly StationSystem _station = default!;

public override void Initialize()
{
base.Initialize();

SubscribeLocalEvent<UniqueEntityCheckerComponent, ComponentInit>(OnComponentInit);
}

public void OnComponentInit(Entity<UniqueEntityCheckerComponent> checker, ref ComponentInit args)
{
var comp = checker.Comp;

if (string.IsNullOrEmpty(comp.MarkerName))
return;

var query = EntityQueryEnumerator<UniqueEntityMarkerComponent, TransformComponent>();

while (query.MoveNext(out var uid, out var marker, out var xform))
{
if (string.IsNullOrEmpty(marker.MarkerName)
|| marker.MarkerName != comp.MarkerName
|| uid == checker.Owner)
continue;

// Check if marker on station
if (marker.StationOnly && _station.GetOwningStation(uid, xform) is null)
continue;

// Delete it if found unique entity
QueueDel(checker);
return;
}
}
}
9 changes: 9 additions & 0 deletions Content.Shared/Interaction/SharedInteractionSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
using Content.Shared.CombatMode;
using Content.Shared.Database;
using Content.Shared.Ghost;
using Content.Shared._Goobstation.Interaction;
using Content.Shared.Hands;
using Content.Shared.Hands.Components;
using Content.Shared.Input;
Expand Down Expand Up @@ -1132,6 +1133,14 @@ public bool UseInHandInteraction(
if (checkCanUse && !_actionBlockerSystem.CanUseHeldEntity(user, used))
return false;

// Goobstation [
var useAttemptEv = new UseInHandAttemptEvent(user);
RaiseLocalEvent(used, useAttemptEv);

if (useAttemptEv.Cancelled)
return false;
// ] Goobstation

var useMsg = new UseInHandEvent(user);
RaiseLocalEvent(used, useMsg, true);
if (useMsg.Handled)
Expand Down
9 changes: 9 additions & 0 deletions Content.Shared/_Goobstation/Interaction/InteractionEvents.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
namespace Content.Shared._Goobstation.Interaction;

/// <summary>
/// UseAttempt, but for item.
/// </summary>
public sealed class UseInHandAttemptEvent(EntityUid user) : CancellableEntityEventArgs
{
public EntityUid User { get; } = user;
}
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
use-on-station-only-not-on-station = You need to be on station to use this.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
job-supervisors-ntr-centcom = the Nanotrasen Representative and Central Command
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
stamp-component-stamped-name-nanorep = Nanotrasen Representative
14 changes: 14 additions & 0 deletions Resources/Locale/en-US/_Goobstation/preferences/loadout-groups.ftl
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
loadout-group-ntr-head = Nanotrasen Representative head
loadout-group-ntr-backpack = Nanotrasen Representative backpack
loadout-group-ntr-jumpsuit = Nanotrasen Representative jumpsuit
loadout-group-ntr-belt = Nanotrasen Representative belt
loadout-group-ntr-shoes = Nanotrasen Representative shoes

loadout-group-bso-head = Blueshield Officer head
loadout-group-bso-backpack = Blueshield Officer backpack
loadout-group-bso-jumpsuit = Blueshield Officer jumpsuit
loadout-group-bso-outer = Blueshield Officer armor
loadout-group-bso-neck = Blueshield Officer neck

loadout-group-reporter-outerclothing = Reporter outer clothing

Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
id-card-access-level-ntr = Nanotrasen Representative
id-card-access-level-bso = Blueshield Officer
2 changes: 2 additions & 0 deletions Resources/Locale/en-US/_Goobstation/weapons/gun.ftl
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# EnergyGunComponent
energygun-examine-fire-mode = Set to {$mode} bolt.
Original file line number Diff line number Diff line change
@@ -0,0 +1,117 @@
- type: entity #DeltaV, modified by Goobstation to work in this folder.
name: energy bolt
id: BulletEnergyGunLaser
parent: BaseBullet
categories: [ HideSpawnMenu ]
components:
- type: Reflective
reflective:
- Energy
- type: FlyBySound
sound:
collection: EnergyMiss
params:
volume: 5
- type: Sprite
sprite: Objects/Weapons/Guns/Projectiles/projectiles_tg.rsi
layers:
- state: heavylaser
shader: unshaded
- type: Ammo
- type: Physics
- type: Fixtures
fixtures:
projectile:
shape:
!type:PhysShapeAabb
bounds: "-0.2,-0.2,0.2,0.2"
hard: false
mask:
- Opaque
- type: Projectile
impactEffect: BulletImpactEffectRedDisabler
damage:
types:
Heat: 15 # Slightly more damage than the 17heat from the Captain's Hitscan lasgun - Goobstation: Nerfed to 15 damage, to keep it less powerful than caps Lasgun
soundHit:
collection: MeatLaserImpact

- type: entity #Goobstation, put here so the X-01 stuff isnt spread everywhere.
name: ion bolt
id: BulletEnergyGunIon
parent: BaseBullet
categories: [ HideSpawnMenu ]
components:
- type: Reflective
reflective:
- Energy
- type: FlyBySound
sound:
collection: EnergyMiss
params:
volume: 5
- type: Sprite
sprite: Objects/Weapons/Guns/Projectiles/projectiles_tg.rsi
layers:
- state: omnilaser_greyscale
shader: unshaded
color: blue
- type: Ammo
- type: Physics
- type: Fixtures
fixtures:
projectile:
shape:
!type:PhysShapeAabb
bounds: "-0.2,-0.2,0.2,0.2"
hard: false
mask:
- Opaque
- type: Projectile
impactEffect: BulletImpactEffectBlueDisabler
damage:
types:
Cold: 7.5
Heat: 5
soundHit:
collection: MeatLaserImpact

- type: entity #Goobstation, put here so the X-01 stuff isnt spread everywhere.
name: magnum bolt
id: BulletEnergyGunMagnum
parent: BaseBullet
categories: [ HideSpawnMenu ]
components:
- type: Reflective
reflective:
- Energy
- type: FlyBySound
sound:
collection: EnergyMiss
params:
volume: 5
- type: Sprite
sprite: Objects/Weapons/Guns/Projectiles/projectiles_tg.rsi
layers:
- state: heavylaser
shader: unshaded
- type: Ammo
- type: Physics
- type: Fixtures
fixtures:
projectile:
shape:
!type:PhysShapeAabb
bounds: "-0.2,-0.2,0.2,0.2"
hard: false
mask:
- Opaque
- type: Projectile
impactEffect: BulletImpactEffectRedDisabler
damage:
types:
Blunt: 3
Heat: 15
soundHit:
collection: MeatLaserImpact

9 changes: 8 additions & 1 deletion Resources/Prototypes/Entities/Clothing/Eyes/hud.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,13 @@
- type: ShowMindShieldIcons
- type: ShowCriminalRecordIcons

- type: entity
id: ShowMedicalIcons
abstract: true
categories: [ HideSpawnMenu ]
components:
- type: ShowHealthBars
- type: ShowHealthIcons

- type: entity
parent: ClothingEyesBase
Expand Down Expand Up @@ -163,7 +170,7 @@
damageContainers:
- Biological
- type: ShowHealthIcons
damageContainers:
damageContainers:
- Biological

- type: entity
Expand Down
2 changes: 2 additions & 0 deletions Resources/Prototypes/Maps/debug.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@
- Captain
availableJobs:
Captain: [ -1, -1 ]
NanotrasenRepresentative: [ -1, -1 ] # Goob - remove it after test
BlueshieldOfficer: [ -1, -1 ] # Remove this too

- type: gameMap
id: TestTeg
Expand Down
2 changes: 2 additions & 0 deletions Resources/Prototypes/Roles/Jobs/departments.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@
- HeadOfSecurity
- ResearchDirector
- Quartermaster
- BlueshieldOfficer # Goobstation - BlueshieldOfficer, see Resources/Prototypes/_Goobstation/Roles/Jobs/Command/blueshieldofficer.yml
- NanotrasenRepresentative # Goobstation - NanotrasenRep, see Resources/Prototypes/_Goobstation/Roles/Jobs/Command/nanotrasen_representative.yml
primary: false
weight: 100

Expand Down
7 changes: 7 additions & 0 deletions Resources/Prototypes/_Goobstation/Access/centcomm.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
- type: accessLevel
id: NanotrasenRepresentative
name: id-card-access-level-ntr

- type: accessLevel
id: BlueshieldOfficer
name: id-card-access-level-bso
15 changes: 15 additions & 0 deletions Resources/Prototypes/_Goobstation/Actions/types.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
- type: entity
parent: BaseSuicideAction
id: ActionActivateBluespaceLifeline
name: Activate Bluespace Lifeline
description: Activates your bluespace lifeline implant, teleporting you far-far away from this station. You won't be able to come back.
components:
- type: InstantAction
checkCanInteract: false
checkConsciousness: false
itemIconStyle: BigAction
priority: -20
icon:
sprite: _Goobstation/Effects/bluespace_lifeline.rsi
state: bluespace_lifeline
event: !type:ActivateImplantEvent
Loading
Loading