From 64fbee982f889d6a4ca5b5bc9faa6ec6d6a5b77f Mon Sep 17 00:00:00 2001
From: NR <66198468+withoutcode333@users.noreply.github.com>
Date: Fri, 18 Apr 2025 10:36:15 +0500
Subject: [PATCH 1/2] holo fix
---
Content.Server/Guardian/GuardianComponent.cs | 2 ++
Content.Server/Guardian/GuardianSystem.cs | 4 ++++
Resources/Prototypes/Entities/Mobs/Player/guardian.yml | 9 +++++----
3 files changed, 11 insertions(+), 4 deletions(-)
diff --git a/Content.Server/Guardian/GuardianComponent.cs b/Content.Server/Guardian/GuardianComponent.cs
index f9958f08f7..66a5ff04a8 100644
--- a/Content.Server/Guardian/GuardianComponent.cs
+++ b/Content.Server/Guardian/GuardianComponent.cs
@@ -78,5 +78,7 @@ public sealed partial class GuardianComponent : Component
public EntProtoId Action = "ActionToggleGuardian";
[DataField] public EntityUid? ActionEntity;
+
+ [DataField] public TimeSpan KnockDownCharger = TimeSpan.FromSeconds(2);
}
}
diff --git a/Content.Server/Guardian/GuardianSystem.cs b/Content.Server/Guardian/GuardianSystem.cs
index 1622a45576..c05383fab3 100644
--- a/Content.Server/Guardian/GuardianSystem.cs
+++ b/Content.Server/Guardian/GuardianSystem.cs
@@ -2,6 +2,7 @@
using Content.Server.Body.Systems;
using Content.Server.Lightning;
using Content.Server.Popups;
+using Content.Server.Stunnable;
using Content.Shared._White.Guardian;
using Content.Shared.Actions;
using Content.Shared.Damage;
@@ -40,6 +41,7 @@ public sealed class GuardianSystem : EntitySystem
[Dependency] private readonly SharedUserInterfaceSystem _ui = default!;
[Dependency] private readonly LightningSystem _lightningSystem = default!;
[Dependency] private readonly DamageableSystem _damageableSystem = default!;
+ [Dependency] private readonly StunSystem _stunSystem = default!;
public override void Initialize()
{
@@ -305,6 +307,8 @@ private void OnGuardianAttackAttempt(EntityUid uid, GuardianComponent component,
_handsSystem.TryDrop(target, hand);
}
+ _stunSystem.TryKnockdown(target, component.KnockDownCharger, true);
+
component.IsCharged = false;
}
}
diff --git a/Resources/Prototypes/Entities/Mobs/Player/guardian.yml b/Resources/Prototypes/Entities/Mobs/Player/guardian.yml
index 68192a5d50..94d1c23491 100644
--- a/Resources/Prototypes/Entities/Mobs/Player/guardian.yml
+++ b/Resources/Prototypes/Entities/Mobs/Player/guardian.yml
@@ -21,6 +21,7 @@
- type: MobMover
- type: InputMover
- type: Puller
+ needsHands: false
- type: MovementSpeedModifier
baseWalkSpeed: 4
baseSprintSpeed: 5.5
@@ -99,7 +100,7 @@
# From the uplink injector
- type: entity
- name: HoloparasiteStandart
+ name: Holoparasite
id: MobHoloparasiteGuardianStandart
parent: MobGuardianBase
description: A mesmerising whirl of hard-light patterns weaves a marvelous, yet oddly familiar visage. It stands proud, tuning into its owner's life to sustain itself.
@@ -157,7 +158,7 @@
task: SimpleHumanoidHostileCompound
- type: entity
- name: HoloparasiteAssasin
+ name: Holoparasite
id: MobHoloparasiteGuardianAssasin
parent: MobGuardianBase
description: A mesmerising whirl of hard-light patterns weaves a marvelous, yet oddly familiar visage. It stands proud, tuning into its owner's life to sustain itself.
@@ -215,7 +216,7 @@
task: SimpleHumanoidHostileCompound
- type: entity
- name: HoloparasiteCharger
+ name: Holoparasite
id: MobHoloparasiteGuardianCharger
parent: MobGuardianBase
description: A mesmerising whirl of hard-light patterns weaves a marvelous, yet oddly familiar visage. It stands proud, tuning into its owner's life to sustain itself.
@@ -270,7 +271,7 @@
task: SimpleHumanoidHostileCompound
- type: entity
- name: HoloparasiteLighting
+ name: Holoparasite
id: MobHoloparasiteGuardianLighting
parent: MobGuardianBase
description: A mesmerising whirl of hard-light patterns weaves a marvelous, yet oddly familiar visage. It stands proud, tuning into its owner's life to sustain itself.
From 1b5e6725acfef7d2c095d404ed01392bfec6ba95 Mon Sep 17 00:00:00 2001
From: NR <66198468+withoutcode333@users.noreply.github.com>
Date: Sun, 20 Apr 2025 19:29:12 +0500
Subject: [PATCH 2/2] baza (govno)
---
.../_White/Contract/UI/ContractorBUI.cs | 10 ++++
.../_White/Contract/UI/ContractorWindow.xaml | 42 +++++++++++++++
.../Contract/UI/ContractorWindow.xaml.cs | 17 ++++++
.../_White/Contract/ContractEntry.cs | 51 ++++++++++++++++++
.../ContractorBoundUserInterfaceState.cs | 22 ++++++++
.../_White/Contract/contractUplink.yml | 13 +++++
.../White/Contract/contractor.rsi/icon.png | Bin 0 -> 1287 bytes
.../White/Contract/contractor.rsi/meta.json | 14 +++++
8 files changed, 169 insertions(+)
create mode 100644 Content.Client/_White/Contract/UI/ContractorBUI.cs
create mode 100644 Content.Client/_White/Contract/UI/ContractorWindow.xaml
create mode 100644 Content.Client/_White/Contract/UI/ContractorWindow.xaml.cs
create mode 100644 Content.Shared/_White/Contract/ContractEntry.cs
create mode 100644 Content.Shared/_White/Contract/ContractorBoundUserInterfaceState.cs
create mode 100644 Resources/Prototypes/_White/Contract/contractUplink.yml
create mode 100644 Resources/Textures/White/Contract/contractor.rsi/icon.png
create mode 100644 Resources/Textures/White/Contract/contractor.rsi/meta.json
diff --git a/Content.Client/_White/Contract/UI/ContractorBUI.cs b/Content.Client/_White/Contract/UI/ContractorBUI.cs
new file mode 100644
index 0000000000..041bcbc5e4
--- /dev/null
+++ b/Content.Client/_White/Contract/UI/ContractorBUI.cs
@@ -0,0 +1,10 @@
+namespace Content.Client._White.Contract.UI;
+
+public sealed class ContractorBUI : BoundUserInterface
+{
+ private ContractorWindow? _window;
+
+ public ContractorBUI(EntityUid owner, Enum uiKey) : base(owner, uiKey)
+ {
+ }
+}
diff --git a/Content.Client/_White/Contract/UI/ContractorWindow.xaml b/Content.Client/_White/Contract/UI/ContractorWindow.xaml
new file mode 100644
index 0000000000..0682bd2d87
--- /dev/null
+++ b/Content.Client/_White/Contract/UI/ContractorWindow.xaml
@@ -0,0 +1,42 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Content.Client/_White/Contract/UI/ContractorWindow.xaml.cs b/Content.Client/_White/Contract/UI/ContractorWindow.xaml.cs
new file mode 100644
index 0000000000..8316359b85
--- /dev/null
+++ b/Content.Client/_White/Contract/UI/ContractorWindow.xaml.cs
@@ -0,0 +1,17 @@
+using Content.Client.UserInterface.Controls;
+using Robust.Client.AutoGenerated;
+using Robust.Client.UserInterface.CustomControls;
+using Robust.Client.UserInterface.XAML;
+
+namespace Content.Client._White.Contract.UI;
+
+[GenerateTypedNameReferences]
+public sealed partial class ContractorWindow : DefaultWindow
+{
+ private readonly ContractorBoundUserInterface _owner;
+ public ContractorWindow()
+ {
+ RobustXamlLoader.Load(this);
+ IoCManager.InjectDependencies(this);
+ }
+}
diff --git a/Content.Shared/_White/Contract/ContractEntry.cs b/Content.Shared/_White/Contract/ContractEntry.cs
new file mode 100644
index 0000000000..b8693d85bf
--- /dev/null
+++ b/Content.Shared/_White/Contract/ContractEntry.cs
@@ -0,0 +1,51 @@
+using Robust.Shared.Serialization;
+
+namespace Content.Shared._White.Contract;
+
+[Serializable, NetSerializable]
+public sealed partial class ContractEntry
+{
+ public string Id { get; set; } = string.Empty;
+
+ public string Name { get; set; } = string.Empty;
+
+ public string Description { get; set; } = string.Empty;
+
+ public ContractDifficulty Difficulty { get; set; } = ContractDifficulty.Easy;
+
+ public int TCReward { get; set; }
+
+ public int ReputationReward { get; set; }
+
+ public ContractStatus Status { get; set; } = ContractStatus.Available;
+
+ public EntityUid Target { get; set; }
+
+ public ContractEntry(string id, string name, string description, ContractDifficulty difficulty, int tcReward, int reputationReward, ContractStatus status, EntityUid target)
+ {
+ Id = id;
+ Name = name;
+ Description = description;
+ Difficulty = difficulty;
+ TCReward = tcReward;
+ ReputationReward = reputationReward;
+ Status = status;
+ Target = target;
+ }
+}
+
+public enum ContractStatus : byte
+{
+ Available,
+ Active,
+ Completed,
+ Cancelled
+}
+
+public enum ContractDifficulty : byte
+{
+ Easy,
+ Medium,
+ Hard
+}
+
diff --git a/Content.Shared/_White/Contract/ContractorBoundUserInterfaceState.cs b/Content.Shared/_White/Contract/ContractorBoundUserInterfaceState.cs
new file mode 100644
index 0000000000..a35ae5a4c2
--- /dev/null
+++ b/Content.Shared/_White/Contract/ContractorBoundUserInterfaceState.cs
@@ -0,0 +1,22 @@
+using Robust.Shared.Serialization;
+
+namespace Content.Shared._White.Contract
+{
+ [Serializable, NetSerializable]
+ public enum ContractorUplinkUiKey
+ {
+ Key
+ }
+
+ public sealed class ContractorBoundUserInterfaceState : BoundUserInterfaceState
+ {
+ public readonly List Contracts;
+ public readonly int Reputation;
+
+ public ContractorBoundUserInterfaceState(List contracts, int reputation)
+ {
+ Contracts = contracts;
+ Reputation = reputation;
+ }
+ }
+}
diff --git a/Resources/Prototypes/_White/Contract/contractUplink.yml b/Resources/Prototypes/_White/Contract/contractUplink.yml
new file mode 100644
index 0000000000..f33ce838c0
--- /dev/null
+++ b/Resources/Prototypes/_White/Contract/contractUplink.yml
@@ -0,0 +1,13 @@
+- type: entity
+ parent: BaseItem
+ id: SyndicateContractUplink
+ name: Аплинк контрактника
+ description: Suspiciously looking...
+ components:
+ - type: Sprite
+ sprite: White/Contract/contractor.rsi
+ state: icon
+ - type: Item
+ size: Normal
+ sprite: White/Contract/contractor.rsi
+ - type: GiftIgnore
\ No newline at end of file
diff --git a/Resources/Textures/White/Contract/contractor.rsi/icon.png b/Resources/Textures/White/Contract/contractor.rsi/icon.png
new file mode 100644
index 0000000000000000000000000000000000000000..591b76510d41105881ea9a44c7e33f1fac77726a
GIT binary patch
literal 1287
zcmV+i1^D`jP)Px(!AV3xR9J=WmdlS^R}qK5s`I$rZBN<(dwM*KjR`?Gk|Xhw*nvcZvPw{-1PNFK
zW1}E1fCc{m{{#<35D0=Dk&uG21hIex3lquWkvPf3_KYX<9#8k&?mqXNVlf%ShC5bg
zkp-#MJvz5;eYdL4sULh`|L-Qpy)YOIOjXG_A3DgfE;#2XrI1o$Yiq03!MANLE-u<&
zFrbt|DFx>oW_B!q_nxL{j(}}*bMt>fv;veSQULC0~|60AxpH2q0#SkYX
zO|t{26*|+*Mw1A+;Rj!Q0)KX%I4%7C$3LTz$zikkif6BVlcsWvHZF1frI(qWm?P#6
zlG=Ml+ct}IfkM?$Vi442NJCzJ@dcb^hNY0IfRg$3^UqVpHCSSt$JBPf#1e%#JHX>#
zh$r^6ERB9M=wP_^~o*1|CI5S#~y42
zXe~jHbz)q@v?f%ZCVMK2s05z;?lm|V(&_XV701Lzgl+_lRB6Oq$LNKd|7qfxGT^EJ
z6iNcM!}A@zA}OINs25bBTZO|!=YojP4G|xpI0MS;8Q5omdXlO17I_k}<^aiEe)Gbw
z&^#fehNuGS+4qrWzIBCqGGdgBgA7Ca1f?DU!`T4-{K_h?{k`V)T4GQeaxqd0eD%s@
zvNeRU(20?$PMCzi*o?`E!ryMz?4PXI+}YqCD?77i;LDGl;q#w?mtI+>fA0iE8Vbs9
zfBF-;84`-9A$iIuIKKAWH5wd`KC;Mm+~KLm`~2nR96$fX>$3s;?vI3yP96}6pq+(<;27K6%@D0l*9g~k=U7n(dK
z`9RT#^A(~Iv-dKLrXY3zZp_dbf7smRV)XzWagZ{VMp7!6H;@_)p1-cFFscGI#)rhw
zRoI;sAZbl16|37j+$o+PUVokP>J1zTEry_^k|{2dCKFC}dRWe^>}(K2-K7O8eR_}7=>;QUQEEh}y
z2E?l_4?(XiP(8Qn|{gNW4KmjQjyt`Hk8C5v>V4vkTmf7FCH=8C@
zRYU|;Jrtv6{CCn!js}gsy9Ou-a(H?g&|`%6u>b)5exIB(&bj-NY{dWo
literal 0
HcmV?d00001
diff --git a/Resources/Textures/White/Contract/contractor.rsi/meta.json b/Resources/Textures/White/Contract/contractor.rsi/meta.json
new file mode 100644
index 0000000000..4a5e1447f6
--- /dev/null
+++ b/Resources/Textures/White/Contract/contractor.rsi/meta.json
@@ -0,0 +1,14 @@
+{
+ "version": 1,
+ "license": "CC-BY-SA-3.0",
+ "copyright": "Base sprite taken by tg station, remade by CaypenNow",
+ "size": {
+ "x": 32,
+ "y": 32
+ },
+ "states": [
+ {
+ "name": "icon"
+ }
+ ]
+}
\ No newline at end of file