jov8486

Create a skript that if a magma block is named Magma Gem, on right click it launches a spinning magma block projectile that slows players down skript version 2.15.4 skbee 3.25.2 skript reflect 2.6.3

Kodari AI
KodariJul 26 at 6:20 am 4
MagmaGemProjectile
A Skript-powered Minecraft ability that turns a specially named Magma Gem into a throwable magma block projectile. When a player right-clicks while holding a magma block named “Magma Gem,” the script launches a fast-spinning falling magma block toward the player’s view direction. The projectile travels without gravity, detects nearby players, applies Slowness on impact, stops when hitting blocks, and automatically expires after a short duration. Designed for Skript 2.15.4 with SkBee 3.25.2 and Skript-Reflect 2.6.3.

Place magma-gem.sk in plugins/Skript/scripts/, then run /sk reload magma-gem.

[Generation stopped]

jov8486
📎 2 files 3,158 chars
📄
pasted-code-1785047088043.txt
txt 52 lines
▶
[06:24:22]
[Skript] Reloading gems.sk...
[06:24:22]
Line 20: (gems.sk)
[06:24:22]
    Can't understand this expression: 'direction of player'
[06:24:22]
    Line: set {_direction} to direction of player
[06:24:22]
 
[06:24:22]
Line 21: (gems.sk)
[06:24:22]
    Can't understand this condition/effect: multiply {_direction} by 1.35
[06:24:22]
    Line: multiply {_direction} by {@projectile-speed}
[06:24:22]
 
[06:24:22]
Line 23: (gems.sk)
[06:24:22]
    Can't understand this condition/effect: spawn a falling block of magma block at {_start}
[06:24:22]
    Line: spawn a falling block of magma block at {_start}
[06:24:22]
 
[06:24:22]
Line 47: (gems.sk)
[06:24:22]
    Can't understand this condition/effect: remove {_projectile}
[06:24:22]
    Line: remove {_projectile}
[06:24:22]
 
[06:24:22]
Line 51: (gems.sk)
[06:24:22]
    Can't understand this condition/effect: remove {_projectile}
[06:24:22]
    Line: remove {_projectile}
[06:24:22]
 
[06:24:22]
Line 55: (gems.sk)
[06:24:22]
    Can't understand this condition/effect: remove {_projectile}
[06:24:22]
    Line: remove {_projectile}
[06:24:22]
 
[06:24:22]
    Encountered 6 errors while reloading gems.sk! (53ms)
📄
pasted-code-1785047104588.txt
txt 54 lines
▶
# Magma Gem Projectile
# Requires Skript 2.15.4
# Compatible with SkBee 3.25.2 and Skript-Reflect 2.6.3
#
# Place this file in plugins/Skript/scripts/
# Reload with: /sk reload magma-gem

options:
    projectile-speed: 1.35
    projectile-lifetime: 40
    hit-radius: 1.25
    slowness-duration: 3 seconds

on right click:
    if event-item is magma block:
        if name of event-item is "&#CF0000ᴍ&#C50000ᴀ&#BA0000ɢ&#B00000ᴍ&#A60000ᴀ 󞊰ɢ󑽠ᴇC0000ᴍ":
            cancel event

            set {_start} to eye location of player
            set {_direction} to direction of player
            multiply {_direction} by {@projectile-speed}

            spawn a falling block of magma block at {_start}
            set {_projectile} to last spawned entity
            set gravity of {_projectile} to false
            set velocity of {_projectile} to {_direction}

            loop {@projectile-lifetime} times:
                wait 1 tick

                if {_projectile} is not alive:
                    stop

                set {_location} to location of {_projectile}
                set velocity of {_projectile} to {_direction}
                set yaw of {_projectile} to (yaw of {_projectile} + 35)
                set pitch of {_projectile} to (pitch of {_projectile} + 20)

                set {_hit} to false
                loop all players in radius {@hit-radius} around {_location}:
                    if loop-player is not player:
                        apply slowness 2 to loop-player for {@slowness-duration}
                        set {_hit} to true
                        stop loop

                if {_hit} is true:
                    remove {_projectile}
                    stop

                if block at {_location} is solid:
                    remove {_projectile}
                    stop

            if {_projectile} is alive:
Kodari AI
KodariJul 26 at 6:34 am 28
  1. Replace the unsupported look-direction and vector-scaling expressions.

  2. Keep the projectile spawn syntax compatible with SkBee and remove the cascading entity errors.

  3. Add a corrected complete script ready for /sk reload gems.

The errors come from syntax that your installed Skript build is not accepting. This version avoids the falling-block spawn effect entirely by using an invisible armor stand wearing a magma block, so it remains visible as a spinning magma-block projectile without relying on the failing effect.

Updated magma-gem.sk to avoid the unsupported syntax:

  • Uses vector from yaw ... and pitch ...

  • Uses set standard length for projectile speed

  • Uses an invisible armor stand wearing a magma block as the projectile

  • Uses kill to remove the projectile

  • Keeps spinning, collision detection, and Slowness effects

Place it in:

Plain Text
plugins/Skript/scripts/

Reload it with:

Plain Text
/sk reload magma-gem

The item must be a magma block named exactly:

Plain Text
&#CF0000ᴍ&#C50000ᴀ&#BA0000ɢ&#B00000ᴍ&#A60000ᴀ &#910000ɢ&#860000ᴇ&#7C0000ᴍ
Kodari can make mistakes. Review important code before using.
Files
magma-gem.sk
Code
1 57
magma-gem.sk
# Magma Gem Projectile
# Requires Skript 2.15.4
# Compatible with SkBee 3.25.2 and Skript-Reflect 2.6.3
#
# Place this file in plugins/Skript/scripts/
# Reload with: /sk reload magma-gem

options:
    projectile-speed: 1.35
    projectile-lifetime: 40
    hit-radius: 1.25
    slowness-duration: 3 seconds

on right click:
    if event-item is magma block:
        if name of event-item is "&#CF0000ᴍ&#C50000ᴀ&#BA0000ɢ&#B00000ᴍ&#A60000ᴀ &#910000ɢ&#860000ᴇ&#7C0000ᴍ":
            cancel event

            set {_start} to eye location of player
            set {_direction} to vector from yaw (yaw of player) and pitch (pitch of player)
            set standard length of {_direction} to {@projectile-speed}

            spawn an armor stand at {_start}
            set {_projectile} to last spawned entity
            set helmet of {_projectile} to magma block
            set invisible of {_projectile} to true
            set gravity of {_projectile} to false
            set velocity of {_projectile} to {_direction}

            loop {@projectile-lifetime} times:
                wait 1 tick

                if {_projectile} is not alive:
                    stop

                set {_location} to location of {_projectile}
                set velocity of {_projectile} to {_direction}
                set yaw of {_projectile} to (yaw of {_projectile} + 35)
                set pitch of {_projectile} to (pitch of {_projectile} + 20)

                set {_hit} to false
                loop all players in radius {@hit-radius} around {_location}:
                    if loop-player is not player:
                        apply slowness 2 to loop-player for {@slowness-duration}
                        set {_hit} to true
                        stop loop

                if {_hit} is true:
                    kill {_projectile}
                    stop

                if block at {_location} is solid:
                    kill {_projectile}
                    stop

            if {_projectile} is alive:
                kill {_projectile}