Pulser Spell - TheComputerGeek2/MagicSpells GitHub Wiki
spell-class: ".targeted.PulserSpell"
targeting
cast argument values:
Value | Supported |
---|---|
entity |
false |
location |
true |
entity_from_location |
false |
Spell Effect Positions:
delayed
- Plays the effect at the pulser's location whenever a pulse happens.blockdestruction
- Plays the effect at the pulser's location when the spell ends.
Description:
A targeted spell creates a block at the targeted location, which then casts spells.
Configuration:
Since 4.0 Beta 13 some of these options support dynamic values through numeric or string expressions.
Option | Description | Type | Default | Supports expressions |
---|---|---|---|---|
block-type |
The type of block the pulser will be. | String | "diamond_block" |
true |
y-offset |
The vertical offset to place the pulser block. | Integer | 0 |
true |
interval |
The time in ticks between each spellcast the pulser makes. | Integer | 30 |
true |
total-pulses |
Defines how many times the pulser should attempt to cast its spells before expiring. | Integer | 5 |
true |
cap-per-player |
How many pulsers each player can have at once. | Integer | 10 |
false |
max-distance |
The maximum amount of blocks the player can be from their pulser block before it vanishes. | Double | 30 |
true |
unbreakable |
Should the pulser block be unbreakable? | Boolean | false |
true |
only-count-on-success |
If true, only successfully cast spells (requiring targets, as an example) will count towards total-pulses . Useful in making trap-style spells. |
Boolean | false |
true |
spell-on-break |
Sub-spell the pulser should cast if it is broken. | String | false |
|
spells |
The sub-spells the pulser should cast. Must be able to target a radius or the ground. | String List | false |
|
str-at-cap |
String message for if the player has the maximum amount of pulsers out already. | Rich Text | "You have too many effects at once." |
true |
Example:
HunterTrap:
spell-class: ".targeted.PulserSpell"
cooldown: 12
range: 3
total-pulses: 2
interval: 5
max-distance: 500
block-type: gray_carpet
only-count-on-success: true
str-modifier-failed: "The trap can only be placed below your feet!"
str-at-cap: "You can only control 2 traps at once!"
cap-per-player: 2
modifiers:
- pitch >70 required
spells:
- trapAoe
trapAoe:
spell-class: ".targeted.AreaEffectSpell"
horizontal-radius: 2
vertical-radius: 1
can-target: players,nonplayers
spells:
- trapEntomb
trapEntomb:
spell-class: ".targeted.EntombSpell"
can-target: players,nonplayers
block-type: cobweb
duration: 30