Reduce count after all frames are ran
This commit is contained in:
parent
4a196e0522
commit
fec4aab3f0
|
|
@ -26,9 +26,10 @@ public class FrameSpawnerLocation extends BukkitRunnable {
|
|||
public void run() {
|
||||
if (iterator.hasNext())
|
||||
iterator.next().spawn(location);
|
||||
else if (amount != 0)
|
||||
else if (amount != 0) {
|
||||
iterator = frames.iterator();
|
||||
else {
|
||||
amount--;
|
||||
} else {
|
||||
this.cancel();
|
||||
if (Config.DEBUG)
|
||||
Logger.info("Stopped repeating task due to end of frames");
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user