[SOLVED] The method registerEvents is undefined for the type main?

Discussion in 'Spigot Plugin Development' started by rickerd120, Jul 9, 2015.

  1. hi,

    i trying to get multi classes but when i put registerEvents(this, new onjoinevent()); in the main class.
    it says the method registerevents is un.... for type main. i dont get it? i set it on the right place under

    public void onEnable. the name of class 1 the ''main'' class = main and the other class, class 2 is onjoinevent.

    also on the onjoinevent class it get a error there it says the same thing but then by getlogger().

    main; http://pastebin.com/E2UZPyJ0

    onjoinevent; http://pastebin.com/v9FuGGwb
     
    #1 rickerd120, Jul 9, 2015
    Last edited: Jul 9, 2015
  2. that works but what is the problem in the other class?
     
  3. You should really read what your IDE is telling you. It most likely was saying this is not a method because there is no method that requires a plugin and a class. There is on the other hand a method that requires a class and a plugin.
     
  4. thanks its fixed!
     
  5. thanks for your help, but its fixed!