move all nuke core stuff to _DV (#2902)

* move store-objective stuff to _DV

* radiation fix

* move SealingCabinet to _DV

* move textures to _DV

* move yml stuff to _DV

---------

Co-authored-by: deltanedas <@deltanedas:kde.org>
This commit is contained in:
deltanedas 2025-02-06 13:22:28 +00:00 committed by GitHub
parent 22fb3c50e0
commit e5e82f0de5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
47 changed files with 205 additions and 203 deletions

View File

@ -278,7 +278,7 @@ public partial class RadiationSystem
continue;
}
if (_blockerQuery.TryComp(xform.ParentUid, out var blocker))
if (_blockerQuery.TryComp(xform.ParentUid, out var blocker) && _openable.IsClosed(xform.ParentUid)) // DeltaV - Add IsClosed check
{
rads -= blocker.RadResistance;
if (rads < 0)

View File

@ -1,4 +1,5 @@
using Content.Server.Radiation.Components;
using Content.Shared.Nutrition.EntitySystems; // DeltaV
using Content.Shared.Radiation.Components;
using Content.Shared.Radiation.Events;
using Content.Shared.Stacks;
@ -14,6 +15,7 @@ public sealed partial class RadiationSystem : EntitySystem
[Dependency] private readonly IConfigurationManager _cfg = default!;
[Dependency] private readonly SharedTransformSystem _transform = default!;
[Dependency] private readonly SharedStackSystem _stack = default!;
[Dependency] private readonly OpenableSystem _openable = default!; // DeltaV
private EntityQuery<RadiationBlockingContainerComponent> _blockerQuery;
private EntityQuery<RadiationGridResistanceComponent> _resistanceQuery;

View File

@ -1,12 +1,13 @@
using Content.Server._DV.Objectives.Systems;
using Content.Shared.Store;
using Robust.Shared.Prototypes;
namespace Content.Server.Objectives.Components;
namespace Content.Server._DV.Objectives.Components;
/// <summary>
/// Unlocks store listings that use <see cref="ObjectiveUnlockCondition"/>.
/// </summary>
[RegisterComponent]
[RegisterComponent, Access(typeof(StoreUnlockerSystem))]
public sealed partial class StoreUnlockerComponent : Component
{
[DataField(required: true)]

View File

@ -1,7 +1,7 @@
using Content.Server.Objectives.Components;
using Content.Server._DV.Objectives.Components;
using Content.Shared.Mind;
namespace Content.Server.Objectives.Systems;
namespace Content.Server._DV.Objectives.Systems;
/// <summary>
/// Provides api for listings with <c>ObjectiveUnlockRequirement</c> to use.

View File

@ -1,8 +1,8 @@
using Content.Shared.Mind;
using Content.Shared.Store;
using Content.Server.Objectives.Systems;
using Content.Server._DV.Objectives.Systems;
namespace Content.Server.Store.Conditions;
namespace Content.Server._DV.Store.Conditions;
/// <summary>
/// Requires that the buyer have an objective that unlocks this listing.

View File

@ -16,16 +16,16 @@ public sealed class ItemCabinetSystem : EntitySystem
[Dependency] private readonly OpenableSystem _openable = default!;
[Dependency] private readonly SharedAppearanceSystem _appearance = default!;
private EntityQuery<ItemCabinetComponent> _cabinetQuery = default!;
private EntityQuery<ItemSlotsComponent> _slotsQuery = default!;
private EntityQuery<ItemCabinetComponent> _cabinetQuery = default!; // DeltaV
private EntityQuery<ItemSlotsComponent> _slotsQuery = default!; // DeltaV
/// <inheritdoc/>
public override void Initialize()
{
base.Initialize();
_cabinetQuery = GetEntityQuery<ItemCabinetComponent>();
_slotsQuery = GetEntityQuery<ItemSlotsComponent>();
_cabinetQuery = GetEntityQuery<ItemCabinetComponent>(); // DeltaV
_slotsQuery = GetEntityQuery<ItemSlotsComponent>(); // DeltaV
SubscribeLocalEvent<ItemCabinetComponent, ComponentStartup>(OnStartup);
SubscribeLocalEvent<ItemCabinetComponent, MapInitEvent>(OnMapInit);
@ -43,7 +43,7 @@ public sealed class ItemCabinetSystem : EntitySystem
private void OnMapInit(Entity<ItemCabinetComponent> ent, ref MapInitEvent args)
{
// update at mapinit to avoid copy pasting locked: true and locked: false for each closed/open prototype
SetSlotLock((ent, ent.Comp), !_openable.IsOpen(ent));
SetSlotLock(ent, !_openable.IsOpen(ent));
}
private void UpdateAppearance(Entity<ItemCabinetComponent> ent)
@ -59,25 +59,27 @@ public sealed class ItemCabinetSystem : EntitySystem
private void OnOpened(Entity<ItemCabinetComponent> ent, ref OpenableOpenedEvent args)
{
SetSlotLock((ent, ent.Comp), false);
SetSlotLock(ent, false);
}
private void OnClosed(Entity<ItemCabinetComponent> ent, ref OpenableClosedEvent args)
{
SetSlotLock((ent, ent.Comp), true);
SetSlotLock(ent, true);
}
/// <summary>
/// Tries to get the cabinet's item slot.
/// </summary>
public bool TryGetSlot(Entity<ItemCabinetComponent?> ent, [NotNullWhen(true)] out ItemSlot? slot)
public bool TryGetSlot(Entity<ItemCabinetComponent?> ent, [NotNullWhen(true)] out ItemSlot? slot) // DeltaV - made component optional
{
slot = null;
// Begin DeltaV Changes: Use queries instead of TryComp
if (!_cabinetQuery.Resolve(ent, ref ent.Comp))
return false;
if (!_slotsQuery.TryComp(ent, out var slots))
return false;
// End DeltaV Changes
return _slots.TryGetSlot(ent, ent.Comp.Slot, out slot, slots);
}
@ -85,7 +87,7 @@ public sealed class ItemCabinetSystem : EntitySystem
/// <summary>
/// Returns true if the cabinet contains an item.
/// </summary>
public bool HasItem(Entity<ItemCabinetComponent?> ent)
public bool HasItem(Entity<ItemCabinetComponent?> ent) // DeltaV - made component optional
{
return TryGetSlot(ent, out var slot) && slot.HasItem;
}
@ -95,7 +97,7 @@ public sealed class ItemCabinetSystem : EntitySystem
/// </summary>
public void SetSlotLock(Entity<ItemCabinetComponent> ent, bool closed)
{
if (!_slotsQuery.TryComp(ent, out var slots))
if (!_slotsQuery.TryComp(ent, out var slots)) // DeltaV - use query
return;
if (_slots.TryGetSlot(ent, ent.Comp.Slot, out var slot, slots))

View File

@ -1,12 +1,12 @@
using Robust.Shared.GameStates;
namespace Content.Shared.Cabinet;
namespace Content.Shared._DV.Cabinet;
/// <summary>
/// Item cabinet that cannot be opened if it has an item inside.
/// The only way to open it after that is to emag it.
/// </summary>
[RegisterComponent, NetworkedComponent]
[RegisterComponent, NetworkedComponent, Access(typeof(SealingCabinetSystem))]
public sealed partial class SealingCabinetComponent : Component
{
/// <summary>

View File

@ -1,9 +1,10 @@
using Content.Shared.Cabinet;
using Content.Shared.Emag.Systems;
using Content.Shared.Nutrition.Components;
using Content.Shared.Nutrition.EntitySystems;
using Content.Shared.Popups;
namespace Content.Shared.Cabinet;
namespace Content.Shared._DV.Cabinet;
public sealed class SealingCabinetSystem : EntitySystem
{

View File

@ -0,0 +1 @@
objective-condition-steal-nuclear-bomb = nuclear bomb

View File

@ -0,0 +1 @@
store-category-objectives = Objectives

View File

@ -1,3 +1,5 @@
tool-quality-axing-name = Axing
tool-quality-axing-tool-name = Fireaxe
tool-quality-fine-screwing = Fine Screwing
tool-quality-fine-screwing-name = Fine Screwing
tool-quality-fine-screwing-tool-name = Thin-Tipped Screwdriver

View File

@ -4,7 +4,6 @@ objective-condition-steal-title = Steal the {$owner}'s {$itemName}.
objective-condition-steal-description = We need you to steal {$itemName}. Don't get caught.
objective-condition-steal-station = station
objective-condition-steal-nuclear-bomb = nuclear bomb
objective-condition-steal-Ian = head of personnel's corgi
objective-condition-thief-description = The {$itemName} would be a great addition to my collection!

View File

@ -13,8 +13,6 @@ store-category-job = Job
store-category-wearables = Wearables
store-category-pointless = Pointless
store-discounted-items = Discounts
# DeltaV, removed upstream
store-category-objectives = Objectives
# Revenant
store-category-abilities = Abilities

View File

@ -32,7 +32,4 @@ tool-quality-rolling-name = Rolling
tool-quality-rolling-tool-name = Rolling Pin
tool-quality-digging-name = Digging
tool-quality-digging-tool-name = Shovel
tool-quality-fine-screwing-name = Fine Screwing
tool-quality-fine-screwing-tool-name = Thin-Tipped Screwdriver
tool-quality-digging-tool-name = Shovel

View File

@ -123,19 +123,6 @@
- id: ClothingHandsGlovesCombat
- id: ClothingMaskGasSyndicate
- type: entity
parent: ToolboxSyndicate
id: ToolboxSyndicateFilledCoreExtraction
suffix: Filled, Core Extraction
components:
- type: StorageFill
contents:
- id: Crowbar
- id: Welder
- id: Wrench
- id: ThinTippedScrewdriver
- id: NukeCoreContainer
- type: entity
id: ToolboxGoldFilled
name: golden toolbox

View File

@ -2118,23 +2118,3 @@
whitelist:
- Chef
- Mime
# Objective-specific # DeltaV, reverted upstream
- type: listing
id: UplinkCoreExtractionToolbox
name: uplink-core-extraction-toolbox-name
description: uplink-core-extraction-toolbox-desc
icon:
sprite: Objects/Misc/nuke_core_container.rsi
state: closed
productEntity: ToolboxSyndicateFilledCoreExtraction
categories:
- UplinkObjectives
conditions:
- !type:ObjectiveUnlockCondition
- !type:ListingLimitedStockCondition
stock: 1
- !type:BuyerWhitelistCondition
blacklist:
components:
- SurplusBundle

View File

@ -1,3 +1,4 @@
# DeltaV note: these are completely reorganized for nuke core extraction
- type: entity
abstract: true
parent: [BaseStructure, StructureWheeled, BaseMajorContraband]
@ -138,17 +139,6 @@
- type: Physics
bodyType: Dynamic
- type: entity
parent: BaseNuclearBomb
id: NuclearBombDisarmed
suffix: Disarmed
description: "You can clearly see that this can't be armed, given its lack of nuclear material."
components:
- type: StaticPrice
price: 1000 # fancy paperweight
- type: Construction
node: disarmed
- type: entity
parent: StorageTank
id: NuclearBombKeg

View File

@ -15,6 +15,8 @@
CMOHyposprayStealObjective: 1
CMOCrewMonitorStealObjective: 1
RDHardsuitStealObjective: 1
NukeDiskStealObjective: 0.25 # DeltaV - was 1
PlutoniumCoreStealObjective: 0.5 # DeltaV
MagbootsStealObjective: 1
# CorgiMeatStealObjective: 1 # DeltaV - Disable the horrible murder of Ian as an objective
MantisKnifeStealObjective: 1 # Nyanotrasen - ForensicMantis steal objective, see Resources/Prototypes/Nyanotrasen/Objectives/traitor.yml
@ -28,8 +30,6 @@
LOLuckyBillStealObjective: 0.5 # DeltaV - LO steal objective, see Resources/Prototypes/_DV/Objectives/traitor.yml
HoPBookIanDossierStealObjective: 1 # DeltaV - HoP steal objective, see Resources/Prototypes/_DV/Objectives/traitor.yml
HoSGunStealObjective: 0.5 # DeltaV
PlutoniumCoreStealObjective: 0.5 # DeltaV, was reverted upstream
NukeDiskStealObjective: 0.25
- type: weightedRandom
id: TraitorObjectiveGroupKill

View File

@ -77,13 +77,6 @@
sprite: Objects/Misc/nukedisk.rsi
state: icon
- type: stealTargetGroup # DeltaV, upstream reverted
id: PlutoniumCore
name: steal-target-groups-plutonium-core
sprite:
sprite: Objects/Misc/plutonium_core.rsi
state: icon
- type: stealTargetGroup
id: WeaponEnergyShotgun
name: steal-target-groups-weapon-energy-shot-gun

View File

@ -297,20 +297,3 @@
- type: StealCondition
stealGroup: NukeDisk
owner: objective-condition-steal-station
# Station
- type: entity
parent: BaseTraitorStealObjective
id: PlutoniumCoreStealObjective
components:
- type: Objective
# its hard to steal and leaves evidence, but you can get away with it.
difficulty: 3.5
- type: NotCommandRequirement
- type: StealCondition
stealGroup: PlutoniumCore
owner: objective-condition-steal-nuclear-bomb
- type: StoreUnlocker
listings:
- UplinkCoreExtractionToolbox

View File

@ -89,11 +89,6 @@
name: store-category-pointless
priority: 10
- type: storeCategory
id: UplinkObjectives
name: store-category-objectives
priority: 11
#revenant
- type: storeCategory
id: RevenantAbilities

View File

@ -16,7 +16,7 @@
- UplinkWearables
- UplinkJob
- UplinkPointless
- UplinkObjectives
- UplinkObjectives # DeltaV
currencyWhitelist:
- Telecrystal
balance:

View File

@ -0,0 +1,12 @@
- type: entity
parent: ToolboxSyndicate
id: ToolboxSyndicateFilledCoreExtraction
suffix: Filled, Core Extraction
components:
- type: StorageFill
contents:
- id: Crowbar
- id: Welder
- id: Wrench
- id: ThinTippedScrewdriver
- id: NukeCoreContainer

View File

@ -148,6 +148,39 @@
whitelist:
- Logistics
- type: listing
id: UplinkDeadMansSignaller
name: uplink-dead-mans-signaller-name
description: uplink-dead-mans-signaller-desc
productEntity: DeadMansSignaler
discountCategory: rareDiscounts
discountDownTo:
Telecrystal: 1
cost:
Telecrystal: 2
categories:
- UplinkDisruption
# Objective-specific
- type: listing
id: UplinkCoreExtractionToolbox
name: uplink-core-extraction-toolbox-name
description: uplink-core-extraction-toolbox-desc
icon:
sprite: _DV/Objects/Misc/nuke_core_container.rsi
state: closed
productEntity: ToolboxSyndicateFilledCoreExtraction
categories:
- UplinkObjectives
conditions:
- !type:ObjectiveUnlockCondition
- !type:ListingLimitedStockCondition
stock: 1
- !type:BuyerWhitelistCondition
blacklist:
components:
- SurplusBundle
- type: listing
id: UplinkAntimovObjectiveBoard
name: uplink-objective-syndicate-board-name
@ -167,19 +200,6 @@
components:
- SurplusBundle
- type: listing
id: UplinkDeadMansSignaller
name: uplink-dead-mans-signaller-name
description: uplink-dead-mans-signaller-desc
productEntity: DeadMansSignaler
discountCategory: rareDiscounts
discountDownTo:
Telecrystal: 1
cost:
Telecrystal: 2
categories:
- UplinkDisruption
- type: listing
id: UplinkHostageImplanter
name: uplink-syndicate-hostage-implanter-bundle-name

View File

@ -5,7 +5,7 @@
description: Extremely radioactive, even looking at this with the naked eye is dangerous.
components:
- type: Sprite
sprite: Objects/Misc/plutonium_core.rsi
sprite: _DV/Objects/Misc/plutonium_core.rsi
state: icon
- type: StealTarget
stealGroup: PlutoniumCore
@ -25,7 +25,7 @@
description: Solid container for radioactive objects.
components:
- type: Sprite
sprite: Objects/Misc/nuke_core_container.rsi
sprite: _DV/Objects/Misc/nuke_core_container.rsi
layers:
- state: closed
map: [ "enum.OpenableVisuals.Layer" ]

View File

@ -0,0 +1,10 @@
- type: entity
parent: BaseNuclearBomb
id: NuclearBombDisarmed
suffix: Disarmed
description: "You can clearly see that this can't be armed, given its lack of nuclear material."
components:
- type: StaticPrice
price: 1000 # fancy paperweight
- type: Construction
node: disarmed

View File

@ -18,7 +18,7 @@
sprite:
sprite: _DV/Objects/Weapons/Guns/Battery/multiphase_energygun.rsi
state: base
- type: stealTargetGroup
id: BoxFolderRdClipboard
name: steal-target-groups-box-folder-rd-clipboard
@ -40,6 +40,13 @@
sprite: _DV/Mobs/Pets/silvia.rsi
state: silvia
- type: stealTargetGroup
id: PlutoniumCore
name: steal-target-groups-plutonium-core
sprite:
sprite: _DV/Objects/Misc/plutonium_core.rsi
state: icon
# Ninja
- type: stealTargetGroup

View File

@ -127,3 +127,20 @@
lawset: SyndicateLawset
- type: ObjectiveLimit
limit: 1
# Station
- type: entity
parent: BaseTraitorStealObjective
id: PlutoniumCoreStealObjective
components:
- type: Objective
# its hard to steal and leaves evidence, but you can get away with it.
difficulty: 3.5
- type: NotCommandRequirement
- type: StealCondition
stealGroup: PlutoniumCore
owner: objective-condition-steal-nuclear-bomb
- type: StoreUnlocker
listings:
- UplinkCoreExtractionToolbox

View File

@ -10,7 +10,7 @@
- tag: PlutoniumCore
name: "a plutonium core"
icon:
sprite: Objects/Misc/plutonium_core.rsi
sprite: _DV/Objects/Misc/plutonium_core.rsi
state: icon
doAfter: 1

View File

@ -0,0 +1,4 @@
- type: storeCategory
id: UplinkObjectives
name: store-category-objectives
priority: 11

View File

@ -68,7 +68,7 @@
- type: Tag
id: HidesHarpyWings
- type: Tag
id: HudMedicalSecurity #Craftable Corpsman Glasses
@ -84,6 +84,9 @@
- type: Tag
id: PaperSlip
- type: Tag
id: PlutoniumCore
- type: Tag
id: PreventLabel

View File

@ -4,3 +4,11 @@
toolName: tool-quality-axing-tool-name
spawn: FireAxe
icon: { sprite: Objects/Weapons/Melee/fireaxe.rsi, state: icon }
# do not give this to normal tools, it's for nuke deconstruction
- type: tool
id: FineScrewing
name: tool-quality-fine-screwing-name
toolName: tool-quality-fine-screwing-tool-name
spawn: ThinTippedScrewdriver
icon: { sprite: Objects/Tools/screwdriver.rsi, state: screwdriver-map }

View File

@ -1005,9 +1005,6 @@
- type: Tag
id: PlushieSharkPink
- type: Tag
id: PlutoniumCore
- type: Tag
id: Potato

View File

@ -67,11 +67,3 @@
toolName: tool-quality-rolling-tool-name
spawn: RollingPin
icon: { sprite: Objects/Tools/rolling_pin.rsi, state: icon }
# do not give this to normal tools, its for nuke deconstruction
- type: tool
id: FineScrewing
name: tool-quality-fine-screwing
toolName: tool-quality-fine-screwing-tool-name
spawn: ThinTippedScrewdriver
icon: { sprite: Objects/Tools/screwdriver.rsi, state: screwdriver-map }

View File

@ -1,47 +0,0 @@
{
"version": 1,
"license": "CC-BY-SA-3.0",
"copyright": "Taken from tgstation at https://github.com/tgstation/tgstation/blob/c34d56a45b0461f5e0fad3cc75e81580c3357119/icons/obj/antags/syndicate_tools.dmi",
"size": {
"x": 32,
"y": 32
},
"states": [
{
"name": "open"
},
{
"name": "closed"
},
{
"name": "core_open",
"delays": [
[
2.3,
0.3,
0.3,
0.3
]
]
},
{
"name": "core_closed",
"delays": [
[
2.3,
0.3,
0.3,
0.3
]
]
},
{
"name": "inhand-left",
"directions": 4
},
{
"name": "inhand-right",
"directions": 4
}
]
}

View File

@ -1,23 +0,0 @@
{
"version": 1,
"license": "CC-BY-SA-3.0",
"copyright": "Taken from tgstation at https://github.com/tgstation/tgstation/blob/c34d56a45b0461f5e0fad3cc75e81580c3357119/icons/obj/antags/syndicate_tools.dmi",
"size": {
"x": 32,
"y": 32
},
"states": [
{
"name": "icon",
"delays": [
[
2,
0.3,
0.3,
0.3,
0.3
]
]
}
]
}

View File

@ -0,0 +1,47 @@
{
"version": 1,
"license": "CC-BY-SA-3.0",
"copyright": "Taken from tgstation at https://github.com/tgstation/tgstation/blob/c34d56a45b0461f5e0fad3cc75e81580c3357119/icons/obj/antags/syndicate_tools.dmi",
"size": {
"x": 32,
"y": 32
},
"states": [
{
"name": "open"
},
{
"name": "closed"
},
{
"name": "core_open",
"delays": [
[
2.3,
0.3,
0.3,
0.3
]
]
},
{
"name": "core_closed",
"delays": [
[
2.3,
0.3,
0.3,
0.3
]
]
},
{
"name": "inhand-left",
"directions": 4
},
{
"name": "inhand-right",
"directions": 4
}
]
}

View File

Before

Width:  |  Height:  |  Size: 330 B

After

Width:  |  Height:  |  Size: 330 B

View File

Before

Width:  |  Height:  |  Size: 386 B

After

Width:  |  Height:  |  Size: 386 B

View File

@ -0,0 +1,23 @@
{
"version": 1,
"license": "CC-BY-SA-3.0",
"copyright": "Taken from tgstation at https://github.com/tgstation/tgstation/blob/c34d56a45b0461f5e0fad3cc75e81580c3357119/icons/obj/antags/syndicate_tools.dmi",
"size": {
"x": 32,
"y": 32
},
"states": [
{
"name": "icon",
"delays": [
[
2,
0.3,
0.3,
0.3,
0.3
]
]
}
]
}