Cult stuff (#249)

* - tweak: Change sounds.

* - tweak: Update stun desc.

* - add: Add hint.

* - tweak: Change juggernaut ability.

* - add: Constructs can't harm allies.

* - add: Name identifier for constructs.

* - add: Pylon now produces oxygen.

* - tweak: Change sledgehammer sound.

* - tweak: Increase conceal presence audio max distance.
This commit is contained in:
Aviu00
2024-03-29 21:05:44 +09:00
committed by GitHub
parent 62a00000bf
commit ae221391bf
25 changed files with 124 additions and 19 deletions

View File

@@ -79,6 +79,7 @@ public sealed class CultRuleSystem : GameRuleSystem<CultRuleComponent>
private void OnGetBriefing(Entity<CultistRoleComponent> ent, ref GetBriefingEvent args) private void OnGetBriefing(Entity<CultistRoleComponent> ent, ref GetBriefingEvent args)
{ {
args.Append(Loc.GetString("cult-role-briefing-short")); args.Append(Loc.GetString("cult-role-briefing-short"));
args.Append(Loc.GetString("cult-role-briefing-hint"));
} }
private void OnCultistsStateChanged(EntityUid uid, CultistComponent component, MobStateChangedEvent ev) private void OnCultistsStateChanged(EntityUid uid, CultistComponent component, MobStateChangedEvent ev)

View File

@@ -1,8 +1,8 @@
using System.Linq; using System.Linq;
using System.Numerics; using System.Numerics;
using Content.Server.Atmos.Piping.Other.Components;
using Content.Server.Body.Components; using Content.Server.Body.Components;
using Content.Server.Body.Systems; using Content.Server.Body.Systems;
using Content.Server.Maps;
using Content.Shared.Damage; using Content.Shared.Damage;
using Content.Shared.Doors.Components; using Content.Shared.Doors.Components;
using Content.Shared.Interaction; using Content.Shared.Interaction;
@@ -11,7 +11,6 @@ using Content.Shared.Mobs.Systems;
using Content.Shared.Physics; using Content.Shared.Physics;
using Content.Shared.Popups; using Content.Shared.Popups;
using Content.Shared.Tag; using Content.Shared.Tag;
using Content.Shared._White.Cult;
using Content.Shared._White.Cult.Pylon; using Content.Shared._White.Cult.Pylon;
using Content.Shared._White.Cult.Systems; using Content.Shared._White.Cult.Systems;
using Robust.Server.GameObjects; using Robust.Server.GameObjects;
@@ -55,9 +54,7 @@ public sealed class PylonSystem : EntitySystem
private void OnConceal(Entity<SharedPylonComponent> ent, ref ConcealEvent args) private void OnConceal(Entity<SharedPylonComponent> ent, ref ConcealEvent args)
{ {
ent.Comp.Activated = !args.Conceal; SetActivated(ent, ent.Comp, !args.Conceal);
UpdateAppearance(ent, ent.Comp);
_pointLight.SetEnabled(ent, !args.Conceal);
_physics.SetCanCollide(ent, !args.Conceal); _physics.SetCanCollide(ent, !args.Conceal);
} }
@@ -229,12 +226,7 @@ public sealed class PylonSystem : EntitySystem
if (HasComp<CultistComponent>(user)) if (HasComp<CultistComponent>(user))
{ {
comp.Activated = !comp.Activated; SetActivated(uid, comp, !comp.Activated);
UpdateAppearance(uid, comp);
_pointLight.SetEnabled(uid, comp.Activated);
var toggleMsg = Loc.GetString(comp.Activated ? "pylon-toggle-on" : "pylon-toggle-off"); var toggleMsg = Loc.GetString(comp.Activated ? "pylon-toggle-on" : "pylon-toggle-off");
_popupSystem.PopupEntity(toggleMsg, uid); _popupSystem.PopupEntity(toggleMsg, uid);
return; return;
@@ -272,4 +264,16 @@ public sealed class PylonSystem : EntitySystem
_appearance.SetData(uid, PylonVisuals.Activated, comp.Activated, appearance); _appearance.SetData(uid, PylonVisuals.Activated, comp.Activated, appearance);
} }
private void SetActivated(EntityUid uid, SharedPylonComponent comp, bool activated)
{
comp.Activated = activated;
if (TryComp(uid, out GasMinerComponent? miner))
miner.Enabled = activated;
UpdateAppearance(uid, comp);
_pointLight.SetEnabled(uid, activated);
}
} }

View File

@@ -332,7 +332,7 @@ public partial class CultSystem
if (success) if (success)
{ {
_audio.PlayPvs(conceal ? "/Audio/White/Cult/smoke.ogg" : "/Audio/White/Cult/enter_blood.ogg", uid, _audio.PlayPvs(conceal ? "/Audio/White/Cult/smoke.ogg" : "/Audio/White/Cult/enter_blood.ogg", uid,
AudioParams.Default.WithMaxDistance(2f)); AudioParams.Default.WithMaxDistance(5f));
_bloodstreamSystem.TryModifyBloodLevel(uid, -2, bloodstream, createPuddle: false); _bloodstreamSystem.TryModifyBloodLevel(uid, -2, bloodstream, createPuddle: false);
args.Handled = true; args.Handled = true;
} }

View File

@@ -1,6 +1,9 @@
using Content.Shared.Containers.ItemSlots; using System.Linq;
using Content.Shared._White.Cult.Components;
using Content.Shared.Containers.ItemSlots;
using Content.Shared.Mind.Components; using Content.Shared.Mind.Components;
using Content.Shared._White.Cult.UI; using Content.Shared._White.Cult.UI;
using Content.Shared.Weapons.Melee.Events;
using Robust.Shared.Containers; using Robust.Shared.Containers;
using Robust.Shared.Player; using Robust.Shared.Player;
using Robust.Shared.Prototypes; using Robust.Shared.Prototypes;
@@ -19,6 +22,13 @@ public partial class CultSystem
SubscribeLocalEvent<ConstructShellComponent, ComponentInit>(OnShellInit); SubscribeLocalEvent<ConstructShellComponent, ComponentInit>(OnShellInit);
SubscribeLocalEvent<ConstructShellComponent, ComponentRemove>(OnShellRemove); SubscribeLocalEvent<ConstructShellComponent, ComponentRemove>(OnShellRemove);
SubscribeLocalEvent<ConstructShellComponent, ConstructFormSelectedEvent>(OnShellSelected); SubscribeLocalEvent<ConstructShellComponent, ConstructFormSelectedEvent>(OnShellSelected);
SubscribeLocalEvent<ConstructComponent, MeleeHitEvent>(OnMeleeHit);
}
private void OnMeleeHit(Entity<ConstructComponent> ent, ref MeleeHitEvent args)
{
if (args.HitEntities.Any(e => HasComp<CultistComponent>(e) || HasComp<ConstructComponent>(e)))
args.BonusDamage = -args.BaseDamage;
} }
private void OnShellSelected(EntityUid uid, ConstructShellComponent component, ConstructFormSelectedEvent args) private void OnShellSelected(EntityUid uid, ConstructShellComponent component, ConstructFormSelectedEvent args)

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -6,6 +6,7 @@ cult-role-greeting =
Слава Нар`си! Слава Нар`си!
cult-role-briefing-short = Используйте '^' для связи с другими членами культа. cult-role-briefing-short = Используйте '^' для связи с другими членами культа.
cult-role-briefing-hint = Нажмите правой кнопкой мыши по своему персонажу и выберите меню 'Культ' для действий, связанных с культом.
cult-cond-cultwin = Культ одержал победу cult-cond-cultwin = Культ одержал победу
cult-cond-cultfailure = Экипаж уничтожил культ cult-cond-cultfailure = Экипаж уничтожил культ

View File

@@ -28,7 +28,7 @@ ent-InstantActionBloodRites = Кровавые Обряды
.desc = Высасывает кровь и исцеляет вас. .desc = Высасывает кровь и исцеляет вас.
ent-ActionCultStun = Оглушение ent-ActionCultStun = Оглушение
.desc = Сильное заклинание, которое оглушает и обезмолвливает жертв. .desc = Сильное заклинание, которое оглушает и обезмолвливает жертв. Не работает на священника и на экипаж с чипом защиты разума.
ent-ActionCultShadowShackles = Теневые Узы ent-ActionCultShadowShackles = Теневые Узы
.desc = Бесшумное заклинание, которое наложит на человека теневые наручники и заставит вашу жертву замолчать на 10 секунд. .desc = Бесшумное заклинание, которое наложит на человека теневые наручники и заставит вашу жертву замолчать на 10 секунд.

View File

@@ -15,6 +15,8 @@ ent-CultGirder = руническая балка
.desc = Большой конструктивный элемент, изготовленный из металла. На этом есть руна. .desc = Большой конструктивный элемент, изготовленный из металла. На этом есть руна.
ent-AirlockGlassCult = рунический шлюз ent-AirlockGlassCult = рунический шлюз
.desc = Странный стеклянный шлюз с руной. .desc = Странный стеклянный шлюз с руной.
ent-WallForceCult = светящаяся стена
.desc = Нечестивый щит, блокирующий все атаки.
cult-structure-craft-not-enough-metal = Недостаточно металла. cult-structure-craft-not-enough-metal = Недостаточно металла.
cult-structure-craft-craft-failed = Не удалось начать постройку. cult-structure-craft-craft-failed = Не удалось начать постройку.
cult-structure-craft-blocked = Что-то мешает построить. cult-structure-craft-blocked = Что-то мешает построить.

View File

@@ -12,6 +12,10 @@
types: types:
Blunt: 10 Blunt: 10
Structural: 10 Structural: 10
soundHit:
collection: HammerHit
soundSwing:
collection: HammerMiss
- type: Wieldable - type: Wieldable
- type: IncreaseDamageOnWield - type: IncreaseDamageOnWield
damage: damage:

View File

@@ -1,4 +1,4 @@
- type: entity - type: entity
id: InstantActionArtificerCreateSoulStone id: InstantActionArtificerCreateSoulStone
name: artificer-create-soul-stone-action-name name: artificer-create-soul-stone-action-name
description: artificer-create-soul-stone-action-description description: artificer-create-soul-stone-action-description
@@ -98,5 +98,10 @@
icon: icon:
sprite: /Textures/White/Cult/actions_cult.rsi sprite: /Textures/White/Cult/actions_cult.rsi
state: cultforcewall state: cultforcewall
useDelay: 35 sound: !type:SoundPathSpecifier
event: !type:JuggernautCreateWallActionEvent path: /Audio/Magic/forcewall.ogg
useDelay: 40
event: !type:InstantSpawnSpellEvent
prototype: WallForceCult
posData: !type:TargetInFront
preventCollide: false

View File

@@ -69,6 +69,11 @@
graph: CultPylon graph: CultPylon
node: pylon node: pylon
- type: Concealable - type: Concealable
- type: AtmosDevice
- type: GasMiner
maxExternalPressure: 100
spawnAmount: 10
spawnGas: Oxygen
- type: entity - type: entity
id: AltarTome id: AltarTome

View File

@@ -76,6 +76,8 @@
tags: tags:
- CannotSuicide - CannotSuicide
- DoorBumpOpener - DoorBumpOpener
- type: NameIdentifier
group: Construct
- type: entity - type: entity
id: JuggernautConstruct id: JuggernautConstruct
@@ -102,6 +104,10 @@
types: types:
Structural: 90 Structural: 90
Blunt: 25 Blunt: 25
soundHit:
collection: HammerHit
soundSwing:
collection: HammerMiss
- type: entity - type: entity
id: ArtificerConstruct id: ArtificerConstruct
@@ -170,9 +176,11 @@
attackRate: 1 attackRate: 1
damage: damage:
types: types:
Blunt: 10 Piercing: 10
Slash: 10 Slash: 10
Structural: 40 Structural: 40
soundHit:
path: /Audio/Weapons/bladeslice.ogg
- type: entity - type: entity
id: ReaperConstruct id: ReaperConstruct
@@ -200,9 +208,11 @@
attackRate: 1 attackRate: 1
damage: damage:
types: types:
Blunt: 20 Piercing: 20
Slash: 20 Slash: 20
Structural: 80 Structural: 80
soundHit:
path: /Audio/Weapons/bladeslice.ogg
- type: entity - type: entity
id: ConstructShell id: ConstructShell
@@ -229,3 +239,7 @@
containers: containers:
Shard: !type:ContainerSlot Shard: !type:ContainerSlot
- type: CultItem - type: CultItem
- type: nameIdentifierGroup
id: Construct
prefix: CO

View File

@@ -128,3 +128,16 @@
concealedDesc: Большой металлический каркас; Необходимо покрыть листами металла, чтобы он считался стеной. concealedDesc: Большой металлический каркас; Необходимо покрыть листами металла, чтобы он считался стеной.
revealedName: руническая балка revealedName: руническая балка
revealedDesc: Большой конструктивный элемент, изготовленный из металла. На этом есть руна. revealedDesc: Большой конструктивный элемент, изготовленный из металла. На этом есть руна.
- type: entity
id: WallForceCult
parent: WallForce
name: glowing wall
description: An unholy shield that blocks all attacks.
components:
- type: Sprite
sprite: White/Cult/Structures/cult_shield.rsi
state: icon
- type: Icon
sprite: White/Cult/Structures/cult_shield.rsi
state: icon

View File

@@ -413,6 +413,10 @@
types: types:
Blunt: 24 Blunt: 24
Structural: 80 Structural: 80
soundHit:
collection: HammerHit
soundSwing:
collection: HammerMiss
- type: Item - type: Item
size: Huge size: Huge
sprite: White/Objects/Weapons/Chaplain/hammer.rsi sprite: White/Objects/Weapons/Chaplain/hammer.rsi

View File

@@ -0,0 +1,16 @@
- type: soundCollection
id: HammerHit
files:
- /Audio/White/Cult/Hammer/plspnch1.ogg
- /Audio/White/Cult/Hammer/plspnch2.ogg
- /Audio/White/Cult/Hammer/plspnch3.ogg
- /Audio/White/Cult/Hammer/plspnch4.ogg
- /Audio/White/Cult/Hammer/plspnch5.ogg
- /Audio/White/Cult/Hammer/plspnch6.ogg
- type: soundCollection
id: HammerMiss
files:
- /Audio/White/Cult/Hammer/fstatk1.ogg
- /Audio/White/Cult/Hammer/fstatk2.ogg
- /Audio/White/Cult/Hammer/fstatk3.ogg

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

View File

@@ -0,0 +1,26 @@
{
"version": 1,
"license": "CC-BY-SA-3.0",
"copyright": "https://github.com/frosty-dev/white",
"size": {
"x": 32,
"y": 32
},
"states": [
{
"name": "icon",
"delays": [
[
0.1,
0.1,
0.1,
0.1,
0.1,
0.1,
0.1,
1
]
]
}
]
}