Scheduler (or Command sender) and instances

Discussion in 'Plugin Development' started by JustRendering, Nov 17, 2017.

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

    JustRendering

    Hello, I need help with my plugin. I am using a bukkit scheduler, but the thing is, is every time my game ends, it adds a new instance. It makes it so there are more events for every one. If you join it sends you the message more then once. It honestly could be the command sender. But i dont know.

    Can someone send me the correct way to register a scheduler to not have more instances. And can someone send me the correct way have a plugin do a command. I will try them both to fix my plugin.
     
  2. Offline

    Unknown123

    Code:
    private BukkitRunnable run = new BukkitRunnable() {
        @Override
        public void run() {
            //Do what you want
        }
    }
    Code:
    run.runTaskWHATEVER();
     
  3. Offline

    MightyOne

    Please research before asking. Things like an onCommand example have been discussed a hundred times.
    You will also find some threads about BukkitRunnables
     
Thread Status:
Not open for further replies.

Share This Page