pax bard (#943)
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
using Content.Shared._CP14.MagicSpell.Components;
|
||||
using Content.Shared._CP14.MagicSpell.Events;
|
||||
using Content.Shared.CombatMode.Pacification;
|
||||
using Content.Shared.Damage.Components;
|
||||
using Content.Shared.Hands.Components;
|
||||
using Content.Shared.Instruments;
|
||||
@@ -16,6 +17,7 @@ public abstract partial class CP14SharedMagicSystem
|
||||
SubscribeLocalEvent<CP14MagicEffectVerbalAspectComponent, CP14CastMagicEffectAttemptEvent>(OnVerbalCheck);
|
||||
SubscribeLocalEvent<CP14MagicEffectManaCostComponent, CP14CastMagicEffectAttemptEvent>(OnManaCheck);
|
||||
SubscribeLocalEvent<CP14MagicEffectStaminaCostComponent, CP14CastMagicEffectAttemptEvent>(OnStaminaCheck);
|
||||
SubscribeLocalEvent<CP14MagicEffectPacifiedBlockComponent, CP14CastMagicEffectAttemptEvent>(OnPacifiedCheck);
|
||||
|
||||
//Verbal speaking
|
||||
SubscribeLocalEvent<CP14MagicEffectVerbalAspectComponent, CP14StartCastMagicEffectEvent>(OnVerbalAspectStartCast);
|
||||
@@ -90,6 +92,15 @@ public abstract partial class CP14SharedMagicSystem
|
||||
}
|
||||
}
|
||||
|
||||
private void OnPacifiedCheck(Entity<CP14MagicEffectPacifiedBlockComponent> ent, ref CP14CastMagicEffectAttemptEvent args)
|
||||
{
|
||||
if (HasComp<PacifiedComponent>(args.Performer))
|
||||
{
|
||||
args.PushReason(Loc.GetString("cp14-magic-spell-pacified"));
|
||||
args.Cancel();
|
||||
}
|
||||
}
|
||||
|
||||
private void OnVerbalAspectStartCast(Entity<CP14MagicEffectVerbalAspectComponent> ent, ref CP14StartCastMagicEffectEvent args)
|
||||
{
|
||||
var ev = new CP14VerbalAspectSpeechEvent
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
using Content.Shared._CP14.MagicSpellStorage;
|
||||
using Content.Shared.FixedPoint;
|
||||
|
||||
namespace Content.Shared._CP14.MagicSpell.Components;
|
||||
|
||||
/// <summary>
|
||||
/// Blocks the target from using magic if they are pacified.
|
||||
/// </summary>
|
||||
[RegisterComponent, Access(typeof(CP14SharedMagicSystem), typeof(CP14SpellStorageSystem))]
|
||||
public sealed partial class CP14MagicEffectPacifiedBlockComponent : Component
|
||||
{
|
||||
}
|
||||
@@ -16,4 +16,5 @@ cp14-magic-spell-need-verbal-component = You can't cast the spell out loud.
|
||||
cp14-magic-spell-need-somatic-component = You don't have your hands free.
|
||||
|
||||
cp14-magic-spell-stamina-not-enough = You don't have the energy to do it.
|
||||
cp14-magic-staminacost = Stamina cost
|
||||
cp14-magic-staminacost = Stamina cost
|
||||
cp14-magic-spell-pacified = It could hurt someone!
|
||||
@@ -16,4 +16,5 @@ cp14-magic-spell-need-verbal-component = Вы не можете произнес
|
||||
cp14-magic-spell-need-somatic-component = Вам не хватает свободных рук.
|
||||
|
||||
cp14-magic-spell-stamina-not-enough = Вам не хватает сил, чтобы сделать это.
|
||||
cp14-magic-staminacost = Затраты энергии
|
||||
cp14-magic-staminacost = Затраты энергии
|
||||
cp14-magic-spell-pacified = Это может навредить кому либо!
|
||||
@@ -22,6 +22,7 @@
|
||||
- CP14AreaEntityEffectFireRune
|
||||
- type: CP14MagicEffectCastingVisual
|
||||
proto: CP14RuneEarthWall
|
||||
- type: CP14MagicEffectPacifiedBlock
|
||||
- type: EntityWorldTargetAction
|
||||
range: 10
|
||||
itemIconStyle: BigAction
|
||||
|
||||
@@ -24,6 +24,7 @@
|
||||
- type: CP14MagicEffectSomaticAspect
|
||||
- type: CP14MagicEffectCastingVisual
|
||||
proto: CP14RuneFireball
|
||||
- type: CP14MagicEffectPacifiedBlock
|
||||
- type: EntityWorldTargetAction
|
||||
checkCanAccess: false
|
||||
raiseOnUser: true
|
||||
|
||||
@@ -71,7 +71,7 @@
|
||||
- type: Sprite
|
||||
sprite: _CP14/Effects/music.rsi
|
||||
layers:
|
||||
- state: notes_3
|
||||
- state: notes_5
|
||||
color: "#79b330"
|
||||
shader: unshaded
|
||||
|
||||
|
||||
@@ -0,0 +1,83 @@
|
||||
- type: entity
|
||||
id: CP14ActionSpellPeaceBallade
|
||||
name: Peace ballade
|
||||
description: Your music is filled with peaceful magic, forbidding anyone near you to fight.
|
||||
components:
|
||||
- type: Sprite
|
||||
sprite: _CP14/Actions/Spells/healing.rsi
|
||||
state: peace_music
|
||||
- type: CP14MagicEffectCastSlowdown
|
||||
speedMultiplier: 0.8
|
||||
- type: CP14MagicEffectManaCost
|
||||
manaCost: 5
|
||||
- type: CP14MagicEffect
|
||||
magicType: Healing
|
||||
effects:
|
||||
- !type:CP14SpellSpawnEntityOnTarget
|
||||
spawns:
|
||||
- CP14AreaEntityEffectPeaceBallade
|
||||
- type: CP14MagicEffectRequiredMusicTool
|
||||
- type: CP14MagicEffectCastingVisual
|
||||
proto: CP14RunePeaceBallade
|
||||
- type: InstantAction
|
||||
itemIconStyle: BigAction
|
||||
sound: !type:SoundPathSpecifier
|
||||
path: /Audio/Magic/rumble.ogg
|
||||
icon:
|
||||
sprite: _CP14/Actions/Spells/healing.rsi
|
||||
state: peace_music
|
||||
event: !type:CP14ToggleableInstantActionEvent
|
||||
effectFrequency: 1
|
||||
cooldown: 15
|
||||
castTime: 120
|
||||
hidden: true
|
||||
|
||||
- type: entity
|
||||
id: CP14AreaEntityEffectPeaceBallade
|
||||
categories: [ HideSpawnMenu ]
|
||||
components:
|
||||
- type: TimedDespawn
|
||||
lifetime: 1.6
|
||||
- type: CP14AreaEntityEffect
|
||||
range: 3
|
||||
maxTargets: 4
|
||||
whitelist:
|
||||
components:
|
||||
- MobState
|
||||
effects:
|
||||
- !type:CP14SpellSpawnEntityOnTarget
|
||||
spawns:
|
||||
- CP14ImpactEffectPeaceBallade
|
||||
- !type:CP14SpellApplyEntityEffect
|
||||
effects:
|
||||
- !type:GenericStatusEffect
|
||||
key: Pacified
|
||||
component: Pacified
|
||||
type: Add
|
||||
time: 1.5
|
||||
|
||||
- type: entity
|
||||
id: CP14ImpactEffectPeaceBallade
|
||||
parent: CP14BaseMagicImpact
|
||||
categories: [ HideSpawnMenu ]
|
||||
components:
|
||||
- type: Sprite
|
||||
sprite: _CP14/Effects/music.rsi
|
||||
layers:
|
||||
- state: notes_5
|
||||
color: "#bd4fda"
|
||||
shader: unshaded
|
||||
|
||||
- type: entity
|
||||
id: CP14RunePeaceBallade
|
||||
parent: CP14BaseMagicRune
|
||||
categories: [ HideSpawnMenu ]
|
||||
components:
|
||||
- type: PointLight
|
||||
color: "#bd4fda"
|
||||
- type: Sprite
|
||||
sprite: _CP14/Effects/music.rsi
|
||||
layers:
|
||||
- state: notes_3
|
||||
color: "#bd4fda"
|
||||
shader: unshaded
|
||||
@@ -63,7 +63,7 @@
|
||||
- type: Sprite
|
||||
sprite: _CP14/Effects/music.rsi
|
||||
layers:
|
||||
- state: notes_3
|
||||
- state: notes_5
|
||||
color: "#e8cb56"
|
||||
shader: unshaded
|
||||
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
startSpeech: cp14-kick-emote-start
|
||||
endSpeech: cp14-kick-emote
|
||||
emote: true
|
||||
- type: CP14MagicEffectPacifiedBlock
|
||||
- type: EntityTargetAction
|
||||
canTargetSelf: false
|
||||
range: 1
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
endSpeech: "Glacies acus!"
|
||||
- type: CP14MagicEffectCastingVisual
|
||||
proto: CP14RuneIceShards
|
||||
- type: CP14MagicEffectPacifiedBlock
|
||||
- type: EntityWorldTargetAction
|
||||
repeat: true
|
||||
checkCanAccess: false
|
||||
|
||||
@@ -24,6 +24,7 @@
|
||||
- CP14ActionSpellKick
|
||||
- CP14ActionSpellHealBallade
|
||||
- CP14ActionSpellSpeedBallade
|
||||
- CP14ActionSpellPeaceBallade
|
||||
|
||||
- type: loadout
|
||||
id: CP14ActionSpellBase
|
||||
@@ -272,6 +273,19 @@
|
||||
actions:
|
||||
- CP14ActionSpellSpeedBallade
|
||||
effects:
|
||||
- !type:JobRequirementLoadoutEffect
|
||||
requirement:
|
||||
!type:TraitsRequirement
|
||||
inverted: true
|
||||
traits:
|
||||
- CP14ManaWasting
|
||||
|
||||
- type: loadout
|
||||
id: CP14ActionSpellPeaceBallade
|
||||
dummyEntity: CP14ActionSpellPeaceBallade
|
||||
actions:
|
||||
- CP14ActionSpellPeaceBallade
|
||||
effects:
|
||||
- !type:JobRequirementLoadoutEffect
|
||||
requirement:
|
||||
!type:TraitsRequirement
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 323 B After Width: | Height: | Size: 326 B |
@@ -5,7 +5,7 @@
|
||||
"y": 32
|
||||
},
|
||||
"license": "All right reserved",
|
||||
"copyright": "Created by .kreks., cure_burn, cure_poison, heal_music, speed_music, plant_growth by TheShuEd",
|
||||
"copyright": "Created by TheShuEd, cure_wounds created by .kreks.",
|
||||
"states": [
|
||||
{
|
||||
"name": "cure_burn"
|
||||
@@ -19,6 +19,9 @@
|
||||
{
|
||||
"name": "heal_music"
|
||||
},
|
||||
{
|
||||
"name": "peace_music"
|
||||
},
|
||||
{
|
||||
"name": "plant_growth"
|
||||
},
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 360 B |
Binary file not shown.
|
Before Width: | Height: | Size: 349 B After Width: | Height: | Size: 329 B |
Reference in New Issue
Block a user