Compilation Error

Discussion in 'Plugin Development' started by StyllerSystems, Mar 29, 2011.

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

    StyllerSystems

    I am using a code I got in a tutorial. In the tutorial the code completely worked, but when I even use the source files from the install it gives me the following errors:
    Code:
    Event.Type.PLAYER_COMMAND cannot be resolved or is not a field
    I am confused, afterward I looked at the Reference Libraries and Found that the class must have changed names. I have found
    Code:
    PLAYER_COMMAND_PREPROCESS
    and
    SERVER_COMMAND
    and I am wondering if either of those are the correct one.


    Problem Code:
    PHP:
    public class Main extends JavaPlugin {

        @
    Override
        
    public void onDisable() {
            
    System.out.println("ZHR Disabled")
        }
        @
    Override
        
    public void onEnable() {
            
    PluginManager pm getServer().getPluginManager();
             
    pm.registerEvent(Event.Type.PLAYER_COMMANDthis.setsysEvent.Priority.Normalthis);
            
    System.out.println"ZHR Version 1.0 Enabled );
        }
    }
    Could Anyone give me some help?
     
  2. Offline

    Edward Hand

  3. Offline

    StyllerSystems

    if it's outdated then why is it still stickied on this site?

    dang.
    OK thanks for the link. I'll check it out.
     
  4. Offline

    Plague

    Which one is it? I'll look into it.
     
  5. Offline

    StyllerSystems

  6. Offline

    Plague

    Well but he states under the video that there is a new one. No problem there I think.
     
  7. Offline

    Sammy

    I know this is quite an "unpopular" suggestion but you should really remove all those old tutorials, they generate more questions then solve
     
Thread Status:
Not open for further replies.

Share This Page