Library EffectLib - Manage your effects the nice way. (Text/Image in Particles)

Discussion in 'Resources' started by Slikey, Apr 21, 2014.

Thread Status:
Not open for further replies.
  1. Offline

    mjra007

    The new method .setDynamicOrigin isnt working for me, am I using it wrong?


    Code:
            VortexEffect coneeffect = new VortexEffect(em);
                              
                                coneeffect.radius = (float) 5;
                                coneeffect.helixes = 6;
                                coneeffect.circles = 3;
                                coneeffect.speed = 1000;
                                coneeffect.particle = ParticleEffect.SPELL_WITCH;                       
                                coneeffect.setDynamicOrigin(new DynamicLocation(player.getLocation()));
                                coneeffect.start();
                                expm.setExp(0);
    It used to work with .setEntity() but that has been removed since v3.5

    Console error (open)

    Code:
    at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:338) ~[JavaPluginLoader$1.class:1.7.10-1481.148]
            at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62) ~[RegisteredListener.class:1.7.10-1481.148]
            at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.java:507) [SimplePluginManager.class:1.7.10-1481.148]
            at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:492) [SimplePluginManager.class:1.7.10-1481.148]
            at org.bukkit.craftbukkit.v1_7_R4.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:223) [CraftEventFactory.class:1.7.10-1481.148]
            at org.bukkit.craftbukkit.v1_7_R4.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:193) [CraftEventFactory.class:1.7.10-1481.148]
            at net.minecraft.network.NetHandlerPlayServer.func_147346_a(NetHandlerPlayServer.java:821) [nh.class:?]
            at net.minecraft.network.play.client.C08PacketPlayerBlockPlacement.func_148833_a(SourceFile:60) [jo.class:?]
            at net.minecraft.network.play.client.C08PacketPlayerBlockPlacement.func_148833_a(SourceFile:9) [jo.class:?]
            at net.minecraft.network.NetworkManager.func_74428_b(NetworkManager.java:244) [ej.class:?]
            at net.minecraft.network.NetworkSystem.func_151269_c(NetworkSystem.java:173) [nc.class:?]
            at net.minecraft.server.MinecraftServer.func_71190_q(MinecraftServer.java:991) [MinecraftServer.class:?]
            at net.minecraft.server.dedicated.DedicatedServer.func_71190_q(DedicatedServer.java:431) [lt.class:?]
            at net.minecraft.server.MinecraftServer.func_71217_p(MinecraftServer.java:809) [MinecraftServer.class:?]
            at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:669) [MinecraftServer.class:?]
            at java.lang.Thread.run(Unknown Source) [?:1.8.0_60]
    Caused by: java.lang.IllegalArgumentException: Origin Location cannot be null!
            at de.slikey.effectlib.Effect.setDynamicOrigin(Effect.java:283) ~[?:?]
            at net.enchantedoasis.particles.onRightClick.onPlayerInteractDreadlord(onRightClick.java:134) ~[?:?]
            at sun.reflect.GeneratedMethodAccessor25.invoke(Unknown Source) ~[?:?]
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_60]
            at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_60]
            at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:334) ~[JavaPluginLoader$1.class:1.7.10-1481.148]
            ... 15 more
     
  2. Offline

    mcdorli

    This is null coneeffect.setDynamicOrigin(new DynamicLocation(player.getLocation()));
     
  3. Offline

    mjra007

    How do we set a color to an effect, I tried this it doesnt work.
    Code:
    warpeffect.color = Color.fromBGR(6, 100, 220);
     
    Last edited: Dec 22, 2015
  4. Offline

    Assasinsheep

    I am getting a issue with using your testeffectlib plugin

    Code:
    28.12 20:49:39 [Server] INFO ... 15 more
    28.12 20:49:39 [Server] INFO at org.bukkit.command.PluginCommand.execute(PluginCommand.java:44) ~[spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
    28.12 20:49:39 [Server] INFO at me.LCastr0.EffectLibTest.EffectCommands.onCommand(EffectCommands.java:41) ~[?:?]
    28.12 20:49:39 [Server] INFO Caused by: java.lang.NoSuchMethodError: de.slikey.effectlib.effect.ArcEffect.setLocation(Lorg/bukkit/Location;)V
    28.12 20:49:39 [Server] INFO at java.lang.Thread.run(Thread.java:745) [?:1.8.0_51]
    28.12 20:49:39 [Server] INFO at net.minecraft.server.v1_8_R3.MinecraftServer.run(MinecraftServer.java:556) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
    28.12 20:49:39 [Server] INFO at net.minecraft.server.v1_8_R3.MinecraftServer.A(MinecraftServer.java:653) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
    28.12 20:49:39 [Server] INFO at net.minecraft.server.v1_8_R3.DedicatedServer.B(DedicatedServer.java:374) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
    28.12 20:49:39 [Server] INFO at net.minecraft.server.v1_8_R3.MinecraftServer.B(MinecraftServer.java:714) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
    28.12 20:49:39 [Server] INFO at net.minecraft.server.v1_8_R3.SystemUtils.a(SourceFile:44) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
    28.12 20:49:39 [Server] INFO at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_51]
    28.12 20:49:39 [Server] INFO at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_51]
    28.12 20:49:39 [Server] INFO at net.minecraft.server.v1_8_R3.PlayerConnectionUtils$1.run(SourceFile:13) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
    28.12 20:49:39 [Server] INFO at net.minecraft.server.v1_8_R3.PacketPlayInChat.a(PacketPlayInChat.java:1) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
    28.12 20:49:39 [Server] INFO at net.minecraft.server.v1_8_R3.PacketPlayInChat.a(PacketPlayInChat.java:45) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
    28.12 20:49:39 [Server] INFO at net.minecraft.server.v1_8_R3.PlayerConnection.a(PlayerConnection.java:997) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
    28.12 20:49:39 [Server] INFO at net.minecraft.server.v1_8_R3.PlayerConnection.handleCommand(PlayerConnection.java:1162) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
    28.12 20:49:39 [Server] INFO at org.bukkit.craftbukkit.v1_8_R3.CraftServer.dispatchCommand(CraftServer.java:641) ~[spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
    28.12 20:49:39 [Server] INFO at me.incomprehendable.dev.pwp.FakeSimpleCommandMap.dispatch(FakeSimpleCommandMap.java:98) ~[?:?]
    28.12 20:49:39 [Server] INFO at org.bukkit.command.PluginCommand.execute(PluginCommand.java:46) ~[spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
    28.12 20:49:39 [Server] INFO org.bukkit.command.CommandException: Unhandled exception executing command 'arc' in plugin EffectLibTest v2.5
    28.12 20:49:39 [Server] ERROR null
    28.12 20:49:39 [Server] INFO AsasinTreepig: /arc
     
  5. Offline

    mcdorli

    28.12 20:49:39 [Server] INFO Caused by: java.lang.NoSuchMethodError: de.slikey.effectlib.effect.ArcEffect.setLocation(Lorg/bukkit/Location;)V
     
  6. Offline

    LCastr0

    What particle type are you using?


    I think EffectLibTest might not be updated... I'll take a look
     
  7. Offline

    mine2012craft

    Hello,
    Im trying to have a Cone and a Line run at the same time. I got the cone working, but i cant figure out how to setup the Line.
    Here is my current code:
    Code:
    ConeEffect cone = new ConeEffect(Core.em);
             cone.particle = ParticleEffect.FLAME;
             cone.iterations = 17;
             cone.setDynamicOrigin(new DynamicLocation(player.getEyeLocation()));
             cone.randomize = false;
             cone.start();
    
    LineEffect line = new LineEffect(Core.em);
             line.particle = ParticleEffect.FLAME;
             line.setDynamicOrigin(new DynamicLocation(player.getEyeLocation()));
             line.iterations = 17;
             line.start();
    Also, is there a way to speed up the cone generation? (Meaning make the cone generate particles faster)

    EDIT: Nvm, I figured it out. Now I need to figure out how to get it to deal damage... Feel free to give me advice on this problem.

    Also, if anyone needs the line code that I used (Btw EffectLib has nothing to do with it) here it is:

    Code:
    Location start = player.getEyeLocation();
             Vector increase = start.getDirection();
             for (int counter = 0; counter < 100; counter++) {
                 Location point = start.add(increase);
                 ParticleEffect.FLAME.display(0F, 0F, 0F, 0.04F, 5, point, 8D);
                 ParticleEffect.FLAME.display(0F, 0F, 0F, 0F, 1, point, 8D);
                 ParticleEffect.SMOKE_NORMAL.display(0F, 0F, 0F, 0.06F, 5, point, 8D);
     
                 }
     
    Last edited: Jan 17, 2016
  8. Offline

    raum

    I'm currently updating from pre 3.5 to post 3.5 and having to change out all the .setEntities ...

    I'm having an issue with several of the effects not working as intended (Probably just need more fixing), however the Sky Rocket effect I can't seem to get to work at all anymore.

    Whether I do .setDynamicTarget or .setDynamicOrigin to the player's location, it doesn't seem to do anything and I'm not seeing anything else that may make it work correctly. I do see in the Jump Effect that there is a '.getEntity' still, but nothing to SET said entity. Am I just missing missing something?

    Suggestions? Thanks!
     
  9. Offline

    HeavyMine13

    I still can't get colors to work :///
     
  10. Can you please make directional circular beams.
     
Thread Status:
Not open for further replies.

Share This Page