Syntax Error Help!

Discussion in 'Plugin Development' started by AboveExpertt, Oct 5, 2012.

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

    AboveExpertt

    Well I have an error I just can't fix :
    Code:
    public PlayerListener PlayerListener = new PlayerListener(this);{
    [Error]The constructor PlayerListener(Main) is undefined ^ ^ ^ ^
    And:
    Code:
    pm.registerEvents(this.PlayerListener, this);
    [Error]The method registerEvents(Listener, Plugin) in the type PluginManager is not applicable for the arguments (PlayerListener, Main)
     
  2. Offline

    germanchocolate

    its
    Code:
    public final PlayerListener pl = new PlayerListener(plugin);
    and
    Code:
    pm.registerEvents(pl, this);
     
  3. Well, it actually depends on how you declared the constructor of 'PlayerListener' or if you declared one at all.
     
Thread Status:
Not open for further replies.

Share This Page