Can you help me debug my plugin on someone else's server :P?

Discussion in 'Plugin Development' started by LRFLEW, Feb 25, 2011.

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

    LRFLEW

    I am the creator of plugins PvP Control and Unknown Command. I have tested my plugins, and they seemed to work well together, but on the server yuancity.zapto.org, the command /pvp returns "Unknown Command". I have tried to see if I can replicate it, but with the latest build, I can't get it to happen. I was wondering if some build within the 400+ range that had issues with onPlayerCommand() (I am working on implementing onCommand(), but it's not ready yet). If not, I'll talk to the admin, but I was wondering if there was something I didn't know.
     
  2. Offline

    darknesschaos

    dont use onPlayerCommand, afik it has been depreciated. Use the onCommand feature that has been added recently. and to keep commands only from players just do:
    if(!(sender instanceof player))
    return false; //or true if you want.

    edit:
    hmm, I cannot see the source of unknown command. What is it's priority? pvp priority?
     
  3. Offline

    Plague

    It's not deprecated, it just lacks a few features (more sources and help I think).

    Also do NOT just return false when sender is not a player, there is a thread about it from the devs, because the sender can be a WWW server...
     
  4. Offline

    darknesschaos

    I return false if the plugin has nothing to do with non-players.
     
  5. Offline

    LRFLEW

    It's at the ONE download link. PvP Control's commands use NORMAL while Unknown Command uses MONITOR (like it should).

    Where is it? I want to make sure my update that uses onCommand() uses it right, and I was planning on doing basically what darknesschaos said, only differently.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 10, 2016
  6. Offline

    Plague

Thread Status:
Not open for further replies.

Share This Page