Two new spells of light (#404)

* light spell

* fix
This commit is contained in:
Nim
2024-08-10 13:08:14 +03:00
committed by GitHub
parent 9f4932a8af
commit bf256b25e9
11 changed files with 312 additions and 0 deletions

View File

@@ -0,0 +1,86 @@
- type: entity
id: CP14ActionSpellFlashLight
name: Flash Light
description: Creates a flash of bright, blinding light.
components:
- type: CP14MagicEffect
manaCost: 10
telegraphyEffects:
- !type:CP14SpellSpawnEntityOnTarget
spawns:
- CP14ImpactEffectFlashLight
effects:
- !type:CP14SpellSpawnEntityOnTarget
spawns:
- CP14SpawnEffectFlashLight
- type: CP14MagicEffectVerbalAspect
startSpeech: "Lux clara..."
endSpeech: "excaecant inimicos meos"
- type: CP14MagicEffectCastingVisual
proto: CP14RuneFlashLight
- type: WorldTargetAction
useDelay: 5
range: 10
itemIconStyle: BigAction
sound: !type:SoundPathSpecifier
path: /Audio/Magic/rumble.ogg
icon:
sprite: _CP14/Effects/Magic/spells_icons.rsi
state: flash_light
event: !type:CP14DelayedWorldTargetActionEvent
delay: 0.5
- type: entity
id: CP14RuneFlashLight
parent: CP14BaseMagicRune
categories: [ HideSpawnMenu ]
components:
- type: PointLight
color: "#efedff"
- type: Sprite
layers:
- state: sun
color: "#efedff"
shader: unshaded
- type: entity
id: CP14ImpactEffectFlashLight
parent: CP14BaseMagicImpact
categories: [ HideSpawnMenu ]
components:
- type: Sprite
layers:
- state: particles_up
color: "#efedff"
shader: unshaded
- type: entity
id: CP14SpawnEffectFlashLight
components:
- type: Sprite
sprite: /Textures/Objects/Fun/goldbikehorn.rsi
visible: false
state: icon
- type: TriggerOnSpawn
- type: TimedDespawn
lifetime: 5
- type: FlashOnTrigger
range: 4
duration: 4
- type: SpawnOnTrigger
proto: CP14SpellFlashEffect
- type: entity
id: CP14SpellFlashEffect
noSpawn: true
components:
- type: PointLight
enabled: true
radius: 5
energy: 14
netsync: false
- type: LightFade
duration: 0.5
- type: TimedDespawn
lifetime: 0.5

View File

@@ -0,0 +1,113 @@
- type: entity
id: CP14ActionSpellSphereOfLight
name: Sphere of Light
description: Materialization of a bright and safe light source.
components:
- type: CP14MagicEffect
manaCost: 10
effects:
- !type:CP14SpellSpawnEntityOnTarget
spawns:
- CP14ImpactEffectSphereOfLight
- !type:CP14SpellSpawnInHandEntity
spawns:
- CP14SphereOfLight
- type: CP14MagicEffectVerbalAspect
startSpeech: "Appare in manu tua..."
endSpeech: "sphaera lucis"
- type: CP14MagicEffectSomaticAspect
- type: CP14MagicEffectCastingVisual
proto: CP14RuneSphereOfLight
- type: InstantAction
useDelay: 15
itemIconStyle: BigAction
sound: !type:SoundPathSpecifier
path: /Audio/Magic/rumble.ogg
icon:
sprite: _CP14/Effects/Magic/spells_icons.rsi
state: sphere_of_light
event: !type:CP14DelayedInstantActionEvent
delay: 0.5
breakOnMove: false
- type: entity
id: CP14RuneSphereOfLight
parent: CP14BaseMagicRune
categories: [ HideSpawnMenu ]
components:
- type: PointLight
color: "#efedff"
- type: Sprite
layers:
- state: sun
color: "#efedff"
shader: unshaded
- type: entity
id: CP14ImpactEffectSphereOfLight
parent: CP14BaseMagicImpact
categories: [ HideSpawnMenu ]
components:
- type: Sprite
layers:
- state: particles_up
color: "#efedff"
shader: unshaded
- type: entity
id: CP14SphereOfLight
name: Sphere of light
parent: BaseItem
description: A lump of bright light in the shape of a sphere.
components:
- type: TimedDespawn
lifetime: 300 # 5 min
- type: Sprite
sprite: _CP14/Effects/Magic/sphere_of_light.rsi
noRot: true
layers:
- state: icon
shader: unshaded
- type: Item
size: Ginormous
- type: Tag
tags:
- ForceableFollow
- type: Fixtures
fixtures:
fix1:
shape:
!type:PhysShapeAabb
bounds: "-0.2,-0.2,0.2,0.2"
density: 30
hard: true
mask:
- ItemMask
layer:
- Opaque
- type: LandAtCursor
- type: MovementIgnoreGravity
- type: PointLight
radius: 5.0
energy: 6
color: "#efedff"
- type: Damageable
- type: EmitSoundOnLand
sound:
path: /Audio/Effects/drop.ogg
params:
volume: -100 #Yes, it's stupid, but it's easier
- type: Destructible
thresholds:
- trigger:
!type:DamageTrigger
damage: 10
behaviors:
- !type:DoActsBehavior
acts: [ "Destruction" ]
- !type:PlaySoundBehavior
sound:
path: /Audio/Weapons/Guns/Hits/energy_meat1.ogg
params:
variation: 0.250
volume: -12

View File

@@ -172,3 +172,40 @@
- type: CP14SpellStorage
spells:
- CP14ActionSpellIceFloor
- type: entity
id: CP14ClothingRingSphereOfLight
parent: CP14ClothingRingBase
name: conductive ring
description: A standard mana-conductive ring that allows the user to create a sphere of light.
suffix: Sphere of Light
components:
- type: Sprite
layers:
- state: brass_ring
- state: citrine_stone_small
- type: CP14SpellStorageRequireAttune
- type: CP14MagicAttuningItem
- type: CP14SpellStorageAccessWearing
- type: CP14SpellStorage
spells:
- CP14ActionSpellSphereOfLight
- type: entity
id: CP14ClothingRingFlashLight
parent: CP14ClothingRingBase
name: conductive ring
description: A standard mana-conductive ring that allows the user to create a bright flash of light that blinds enemies.
suffix: Flash Light
components:
- type: Sprite
layers:
- state: brass_ring
- state: citrine_stone_small
- type: CP14SpellStorageRequireAttune
- type: CP14MagicAttuningItem
- type: CP14SpellStorageAccessWearing
- type: CP14SpellStorage
spells:
- CP14ActionSpellFlashLight