Solved Partile on arrow

  • Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!

    Now, what are you waiting for? Join the community now!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

Status
Not open for further replies.

MrNygus

Active Member
Jan 28, 2017
116
2
18
26
on shoot:
set {_last} to last spawned arrow
while {_last}:
#spawn 25 of particle flame:0 offset by 0.2, 0.2, 0.2 at {_last}'s location
spawn 5 of particle angry villager at {_last}'s location
wait 1 tick

I want to get effect like spell, but I have a problem with particles. How can I spawn particles? I have always errors like:
Can't understand this condition/effect: spawn 5 of particle angry villager at {_last}'s location (SpecialWands.sk, line 64: spawn 5 of particle angry villager at {_last}'s location')
 
You would be better using skDragon and do the following:
code_language.skript:
drawDot count 5, particle angryvillager, center projectile, visibleRange 16

But your code wouldn't work anyways because the following reasons:
1. You're using last spawned arrow instead of just projectile (which should be event-projectile).
2. You're doing a while loop that doesn't check anything, what you're actually doing is:
code_language.skript:
while last spawned arrow:
or if you have skQuery it would be:
code_language.skript:
while last spawned arrow is true:
which would get the same result. For check when the arrow is on the ground you can use the following methods:

code_language.skript:
while "%tag ""inGround"" of projectile%" is "0": #Needs skStuff

while ground state of projectile is false: #Needs Skellett

while projectile isn't on ground: #Needs RandomSK.

while block 0.1 below projectile is air: #Just with vanilla Skript, not as accurate as the other methods though
 
Status
Not open for further replies.