Random bugfixes and balance (#1088)
* shared magic energy examine * fix #1067 * fix #984 * nerf slimes * fireSpread nerf * slimes demiplane examine + remove whistler
This commit is contained in:
@@ -117,8 +117,7 @@ public sealed class CP14CommonObjectivesRule : GameRuleSystem<CP14CommonObjectiv
|
||||
{
|
||||
base.AppendRoundEndText(uid, component, gameRule, ref args);
|
||||
|
||||
if (!TryComp<MindComponent>(uid, out var stationMind))
|
||||
return;
|
||||
EnsureComp<MindComponent>(uid, out var stationMind);
|
||||
|
||||
var query = EntityQueryEnumerator<CP14StationCommonObjectivesComponent>();
|
||||
while (query.MoveNext(out var objectives))
|
||||
|
||||
@@ -1,23 +0,0 @@
|
||||
using Content.Shared._CP14.MagicEnergy.Components;
|
||||
using Content.Shared.Examine;
|
||||
|
||||
namespace Content.Server._CP14.MagicEnergy;
|
||||
|
||||
public partial class CP14MagicEnergySystem
|
||||
{
|
||||
private void InitializeScanner()
|
||||
{
|
||||
SubscribeLocalEvent<CP14MagicEnergyExaminableComponent, ExaminedEvent>(OnExamined);
|
||||
}
|
||||
|
||||
private void OnExamined(Entity<CP14MagicEnergyExaminableComponent> ent, ref ExaminedEvent args)
|
||||
{
|
||||
if (!TryComp<CP14MagicEnergyContainerComponent>(ent, out var magicContainer))
|
||||
return;
|
||||
|
||||
if (!args.IsInDetailsRange)
|
||||
return;
|
||||
|
||||
args.PushMarkup(GetEnergyExaminedText(ent, magicContainer));
|
||||
}
|
||||
}
|
||||
@@ -11,7 +11,6 @@ public sealed partial class CP14MagicEnergySystem : SharedCP14MagicEnergySystem
|
||||
public override void Initialize()
|
||||
{
|
||||
InitializeDraw();
|
||||
InitializeScanner();
|
||||
InitializePortRelay();
|
||||
}
|
||||
|
||||
|
||||
@@ -39,7 +39,7 @@ public sealed partial class CP14SellPrototypeService : CP14StoreSellService
|
||||
|
||||
foreach (var selledEnt in suitable)
|
||||
{
|
||||
entManager.QueueDeleteEntity(selledEnt);
|
||||
entManager.DeleteEntity(selledEnt);
|
||||
}
|
||||
|
||||
return true;
|
||||
|
||||
@@ -40,7 +40,7 @@ public sealed partial class CP14SellStackService : CP14StoreSellService
|
||||
if (selledEnt.Key.Comp.Count == selledEnt.Value)
|
||||
{
|
||||
entities.Remove(selledEnt.Key);
|
||||
entManager.QueueDeleteEntity(selledEnt.Key);
|
||||
entManager.DeleteEntity(selledEnt.Key);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -31,9 +31,6 @@ public sealed partial class CP14SellWhitelistService : CP14StoreSellService
|
||||
if (needCount <= 0)
|
||||
break;
|
||||
|
||||
if (!entManager.TryGetComponent<MetaDataComponent>(ent, out var metaData) || metaData.EntityPrototype is null)
|
||||
continue;
|
||||
|
||||
if (!whitelistSystem.IsValid(Whitelist, ent))
|
||||
continue;
|
||||
|
||||
@@ -52,7 +49,7 @@ public sealed partial class CP14SellWhitelistService : CP14StoreSellService
|
||||
foreach (var selledEnt in suitable)
|
||||
{
|
||||
entities.Remove(selledEnt);
|
||||
entManager.QueueDeleteEntity(selledEnt);
|
||||
entManager.DeleteEntity(selledEnt);
|
||||
}
|
||||
|
||||
return true;
|
||||
|
||||
@@ -2,8 +2,8 @@ using Content.Shared._CP14.MagicEnergy.Components;
|
||||
using Content.Shared._CP14.MagicEssence;
|
||||
using Content.Shared.Alert;
|
||||
using Content.Shared.Audio;
|
||||
using Content.Shared.Examine;
|
||||
using Content.Shared.FixedPoint;
|
||||
using Content.Shared.Inventory;
|
||||
using Content.Shared.Rounding;
|
||||
|
||||
namespace Content.Shared._CP14.MagicEnergy;
|
||||
@@ -19,6 +19,8 @@ public partial class SharedCP14MagicEnergySystem : EntitySystem
|
||||
|
||||
SubscribeLocalEvent<CP14MagicEnergyContainerComponent, ComponentStartup>(OnComponentStartup);
|
||||
SubscribeLocalEvent<CP14MagicEnergyContainerComponent, ComponentShutdown>(OnComponentShutdown);
|
||||
|
||||
SubscribeLocalEvent<CP14MagicEnergyExaminableComponent, ExaminedEvent>(OnExamined);
|
||||
}
|
||||
|
||||
private void OnSlotPowerChanged(Entity<CP14MagicEnergyAmbientSoundComponent> ent, ref CP14SlotCrystalPowerChangedEvent args)
|
||||
@@ -164,6 +166,17 @@ public partial class SharedCP14MagicEnergySystem : EntitySystem
|
||||
_alerts.GetMaxSeverity(ent.Comp.MagicAlert.Value));
|
||||
_alerts.ShowAlert(ent, ent.Comp.MagicAlert.Value, (short)level);
|
||||
}
|
||||
|
||||
private void OnExamined(Entity<CP14MagicEnergyExaminableComponent> ent, ref ExaminedEvent args)
|
||||
{
|
||||
if (!TryComp<CP14MagicEnergyContainerComponent>(ent, out var magicContainer))
|
||||
return;
|
||||
|
||||
if (!args.IsInDetailsRange)
|
||||
return;
|
||||
|
||||
args.PushMarkup(GetEnergyExaminedText(ent, magicContainer));
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -29,13 +29,13 @@ public sealed partial class CP14FireSpreadComponent : Component
|
||||
/// how often objects will try to set the neighbors on fire. In Seconds
|
||||
/// </summary>
|
||||
[DataField]
|
||||
public float SpreadCooldownMin = 5f;
|
||||
public float SpreadCooldownMin = 10f;
|
||||
|
||||
/// <summary>
|
||||
/// how often objects will try to set the neighbors on fire. In Seconds
|
||||
/// </summary>
|
||||
[DataField]
|
||||
public float SpreadCooldownMax = 10f;
|
||||
public float SpreadCooldownMax = 20f;
|
||||
|
||||
/// <summary>
|
||||
/// the time of the next fire spread
|
||||
|
||||
@@ -12,6 +12,7 @@ cp14-modifier-explosive = explosive mines
|
||||
cp14-modifier-ruins = ancient ruins
|
||||
cp14-modifier-xeno = xenomorphs
|
||||
cp14-modifier-zombie = swarms of undead
|
||||
cp14-modifier-slime = slimes
|
||||
cp14-modifier-skeleton = sentient skeletons
|
||||
cp14-modifier-dyno = prehistoric fauna
|
||||
cp14-modifier-mole = predatory moles
|
||||
|
||||
@@ -12,6 +12,7 @@ cp14-modifier-explosive = взрывных мин
|
||||
cp14-modifier-ruins = древних руин
|
||||
cp14-modifier-xeno = ксеноморфов
|
||||
cp14-modifier-zombie = толп нежити
|
||||
cp14-modifier-slime = слаймов
|
||||
cp14-modifier-skeleton = разумные скелеты
|
||||
cp14-modifier-dyno = доисторической фауны
|
||||
cp14-modifier-mole = хищных кротов
|
||||
|
||||
@@ -22,11 +22,11 @@
|
||||
sprite: _CP14/Objects/Bureaucracy/paper.rsi
|
||||
state: scrolls
|
||||
|
||||
#- type: storePositionSell
|
||||
# id: CP14ClothingCloakAmuletGold
|
||||
# price: 80
|
||||
# factions:
|
||||
# - Sylphoria
|
||||
# service: !type:CP14SellPrototypeService
|
||||
# proto: CP14ClothingCloakAmuletGold
|
||||
# count: 1
|
||||
- type: storePositionSell
|
||||
id: CP14ClothingCloakAmuletGold
|
||||
price: 80
|
||||
factions:
|
||||
- Sylphoria
|
||||
service: !type:CP14SellPrototypeService
|
||||
proto: CP14ClothingCloakAmuletGold
|
||||
count: 1
|
||||
|
||||
@@ -33,12 +33,12 @@
|
||||
Blunt: 3
|
||||
Shock: 3
|
||||
- type: CP14SpellEffectOnHit
|
||||
prob: 0.75
|
||||
prob: 0.3
|
||||
effects:
|
||||
- !type:CP14SpellApplyEntityEffect
|
||||
effects:
|
||||
- !type:Electrocute
|
||||
electrocuteTime: 0.5
|
||||
electrocuteTime: 1
|
||||
electrocuteDamageScale: 1
|
||||
- !type:CP14SpellSpawnEntityOnTarget
|
||||
spawns:
|
||||
|
||||
@@ -98,7 +98,7 @@
|
||||
effects:
|
||||
- !type:Jitter
|
||||
- !type:FlammableReaction
|
||||
multiplier: 1.5
|
||||
multiplier: 1
|
||||
- !type:AdjustTemperature
|
||||
amount: 6000
|
||||
- !type:Ignite
|
||||
@@ -1,46 +0,0 @@
|
||||
- type: entity
|
||||
id: CP14BaseFlammable
|
||||
abstract: true
|
||||
categories: [ ForkFiltered ]
|
||||
components:
|
||||
- type: CP14FlammableAmbientSound
|
||||
- type: AmbientSound
|
||||
enabled: false
|
||||
volume: -5
|
||||
range: 5
|
||||
sound:
|
||||
path: /Audio/Ambience/Objects/fireplace.ogg #TODO replace
|
||||
- type: Appearance
|
||||
- type: Reactive
|
||||
groups:
|
||||
Flammable: [ Touch ]
|
||||
Extinguish: [ Touch ]
|
||||
- type: Flammable
|
||||
fireSpread: true
|
||||
canResistFire: false
|
||||
alwaysCombustible: true
|
||||
canExtinguish: true
|
||||
firestacksOnIgnite: 0.5
|
||||
firestackFade: 0.3
|
||||
damage:
|
||||
types:
|
||||
Heat: 0.5
|
||||
- type: FireVisuals
|
||||
sprite: _CP14/Effects/fire.rsi
|
||||
normalState: small
|
||||
|
||||
- type: entity
|
||||
id: CP14BaseFlammableSpreading
|
||||
parent: CP14BaseFlammable
|
||||
abstract: true
|
||||
components:
|
||||
- type: CP14FireSpread
|
||||
|
||||
- type: entity
|
||||
id: CP14BaseFlammableSpreadingStrong
|
||||
parent: CP14BaseFlammableSpreading
|
||||
abstract: true
|
||||
components:
|
||||
- type: CP14FireSpread
|
||||
spreadCooldownMin: 1
|
||||
spreadCooldownMax: 3
|
||||
@@ -82,6 +82,53 @@
|
||||
- type: CP14AutoIgnite
|
||||
- type: CP14ActiveFireSpreading
|
||||
- type: TimedDespawn
|
||||
lifetime: 60
|
||||
lifetime: 120
|
||||
- type: CP14FireSpread
|
||||
- type: CP14DespawnOnExtinguish
|
||||
- type: CP14DespawnOnExtinguish
|
||||
|
||||
- type: entity
|
||||
id: CP14BaseFlammable
|
||||
abstract: true
|
||||
categories: [ ForkFiltered ]
|
||||
components:
|
||||
- type: CP14FlammableAmbientSound
|
||||
- type: AmbientSound
|
||||
enabled: false
|
||||
volume: -5
|
||||
range: 5
|
||||
sound:
|
||||
path: /Audio/Ambience/Objects/fireplace.ogg #TODO replace
|
||||
- type: Appearance
|
||||
- type: Reactive
|
||||
groups:
|
||||
Flammable: [ Touch ]
|
||||
Extinguish: [ Touch ]
|
||||
- type: Flammable
|
||||
fireSpread: true
|
||||
canResistFire: false
|
||||
alwaysCombustible: true
|
||||
canExtinguish: true
|
||||
firestacksOnIgnite: 0.25
|
||||
firestackFade: 0.15
|
||||
damage:
|
||||
types:
|
||||
Heat: 0.25
|
||||
- type: FireVisuals
|
||||
sprite: _CP14/Effects/fire.rsi
|
||||
normalState: small
|
||||
|
||||
- type: entity
|
||||
id: CP14BaseFlammableSpreading
|
||||
parent: CP14BaseFlammable
|
||||
abstract: true
|
||||
components:
|
||||
- type: CP14FireSpread
|
||||
|
||||
- type: entity
|
||||
id: CP14BaseFlammableSpreadingStrong
|
||||
parent: CP14BaseFlammableSpreading
|
||||
abstract: true
|
||||
components:
|
||||
- type: CP14FireSpread
|
||||
spreadCooldownMin: 1
|
||||
spreadCooldownMax: 3
|
||||
@@ -19,10 +19,10 @@
|
||||
id: CP14RoundObjectivesRule
|
||||
parent: CP14BaseGameRule
|
||||
components:
|
||||
- type: CP14CommonObjectivesRule
|
||||
departmentObjectives:
|
||||
CP14Command:
|
||||
- CP14TownSendObjectiveGroup
|
||||
#- type: CP14CommonObjectivesRule
|
||||
# departmentObjectives:
|
||||
# CP14Command:
|
||||
# - CP14TownSendObjectiveGroup
|
||||
- type: CP14PersonalObjectivesRule
|
||||
roleObjectives:
|
||||
CP14Guildmaster:
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
forced: true
|
||||
revertOnCrit: true
|
||||
revertOnDeath: true
|
||||
transferDamage: true
|
||||
transferDamage: false
|
||||
polymorphSound: !type:SoundPathSpecifier
|
||||
path: /Audio/Magic/forcewall.ogg
|
||||
exitPolymorphSound: !type:SoundPathSpecifier
|
||||
|
||||
@@ -124,28 +124,29 @@
|
||||
minGroupSize: 1
|
||||
maxGroupSize: 2
|
||||
|
||||
- type: cp14DemiplaneModifier
|
||||
id: EnemyInvisibleWhistler
|
||||
levels:
|
||||
min: 6
|
||||
max: 10
|
||||
name: cp14-modifier-invisible-whistler
|
||||
categories:
|
||||
Danger: 0.4
|
||||
requiredTags:
|
||||
- CP14DemiplaneUnderground
|
||||
layers:
|
||||
- !type:OreDunGen
|
||||
entity: CP14MobMonsterInvisibleWhistler
|
||||
count: 2
|
||||
minGroupSize: 1
|
||||
maxGroupSize: 2
|
||||
#- type: cp14DemiplaneModifier #Removed to Whistler rebalance
|
||||
# id: EnemyInvisibleWhistler
|
||||
# levels:
|
||||
# min: 6
|
||||
# max: 10
|
||||
# name: cp14-modifier-invisible-whistler
|
||||
# categories:
|
||||
# Danger: 0.4
|
||||
# requiredTags:
|
||||
# - CP14DemiplaneUnderground
|
||||
# layers:
|
||||
# - !type:OreDunGen
|
||||
# entity: CP14MobMonsterInvisibleWhistler
|
||||
# count: 2
|
||||
# minGroupSize: 1
|
||||
# maxGroupSize: 2
|
||||
|
||||
- type: cp14DemiplaneModifier
|
||||
id: MobSlimeElectric
|
||||
levels:
|
||||
min: 1
|
||||
max: 10
|
||||
name: cp14-modifier-slime
|
||||
categories:
|
||||
Danger: 0.3
|
||||
layers:
|
||||
@@ -160,6 +161,7 @@
|
||||
levels:
|
||||
min: 1
|
||||
max: 10
|
||||
name: cp14-modifier-slime
|
||||
categories:
|
||||
Danger: 0.3
|
||||
requiredTags:
|
||||
@@ -176,6 +178,7 @@
|
||||
levels:
|
||||
min: 1
|
||||
max: 10
|
||||
name: cp14-modifier-slime
|
||||
categories:
|
||||
Danger: 0.3
|
||||
requiredTags:
|
||||
|
||||
Reference in New Issue
Block a user