Skip to content

Circle Effect

AkitoBurrito edited this page Oct 7, 2022 · 3 revisions

Circle Effect

Source Code

Description: This effect creates a 2D circle.

Configuration:

Option Description Type Default Value
particle The name of the particle that is displayed. (uses different particle names compared to general magicspells). The list of these particles can be found here. String FLAME
particles The number of particles that are displayed. Integer 20
orient Whether or not to orient to the direction of the source location. Boolean false
xRotation The rotation of the effect along the x axis. Double 0
yRotation The rotation of the effect along the y axis. Double 0
zRotation The rotation of the effect along the z axis. Double 0
angularVelocityX Turns the effect by this angle each iteration around the x-axis. Double 0.01571
angularVelocityY Turns the effect by this angle each iteration around the y-axis. Double 0.01848
angularVelocityZ Turns the effect by this angle each iteration around the z-axis. Double 0.02027
radius The radius of this sphere or circle, in blocks. Float 0.4
maxAngle The maximum angle of the circle. Used to make a partial circle. Double 6.28319
resetCircle Start at the same location each step, use this along with maxAngle and wholeCircle to form persistent semicircles. Boolean false
xSubtract Subtracts from the x location if needed. Double 0
ySubtract Subtracts from the y location if needed. Double 0
zSubtract Subtracts from the z location if needed. Double 0
enableRotation The rotation of the effect along the x axis. Boolean true
wholeCircle Whether or not to make a whole circle each iteration. Boolean false
type The type of effect used. The three types are DELAYED, INSTANT, and REPEATING. String REPEATING
period How long to wait, in ticks, between each iteration. Integer 2
iterations Number of times to repeat the effect. Integer 50

Example:

CircleExample:
    spell-class: ".instant.DummySpell"
    effects:
      Effect1:
        position: caster
        effect: effectlib 
        effectlib:
            class: CircleEffect
            particle: FLAME
            particles: 20
            orient: false
            xRotation: 0
            yRotation: 0
            zRotation: 0
            radius: 0.4
            resetCircle: false
            xSubtract: 0
            ySubtract: 0
            zSubtract: 0         
            enableRotation: true
            wholeCircle: false
            type: REPEATING
            period: 2
            iterations: 50
Clone this wiki locally