Solved 'An internal error occurred while attempting to perform this command' error

Discussion in 'Plugin Development' started by KarimAKL, Mar 8, 2018.

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

    KarimAKL

    When i try to use the command from the plugin i just made and i don't have permission to use it i get the error in the in-game chat: 'An internal error occurred while attempting to perform this command' and in the console this is the error: https://pastebin.com/QJSabdqd As i said, this only happens when i don't have permission, with permission it works as it should.
    Classes:
    View attachment 31355 And another one:
    View attachment 31356
     
  2. Online

    timtower Administrator Administrator Moderator

    @KarimAKL I think that the string in the config is non-existing.
     
  3. Offline

    KarimAKL

  4. Online

    timtower Administrator Administrator Moderator

    @KarimAKL check the capitalization on the PlayerList, it is not the same.
    And that is the one in your IDE, what does the one in the plugins folder look like?
     
  5. Offline

    KarimAKL

    Oh, it needs to be capitalized the same aswell? Whoops mb then. :p Anyway, i'm new to this so uhm.. What is IDE and where do i find the plugins folder?
    EDIT: Oh, you meant the config in the plugins folder on the server? If so then there is no folder with the plugin name for some reason. Did i forget something? If so then why is there no errors in the plugin?
    EDIT 2: When i changed the capitalization it seemed to work but now i have a problem where it says that i don't have permission(which is what i want) but it also tells me the usage of the command from the plugin.yml for some reason. :/
     
    Last edited by a moderator: Mar 8, 2018
  6. Online

    timtower Administrator Administrator Moderator

    @KarimAKL IDE is your development environment.
    You are not returning true after the no permissions message.
     
  7. Offline

    KarimAKL

    Oh yeah, right mb again. Anyway, do you know why i don't have a folder for my plugin? (The folder where a config normally is)
     
  8. Online

    timtower Administrator Administrator Moderator

  9. Offline

    KarimAKL

  10. Online

    timtower Administrator Administrator Moderator

    @KarimAKL What is the return value from setupEconomy() ?
    And could you use [code] <actual code here> [/code] instead of the images?
    Then we can copy paste and it will resize when we scale the page
     
  11. Offline

    KarimAKL

    Oh, sorry. Where do i find the return value from setupEconomy()?
     
  12. Online

    timtower Administrator Administrator Moderator

    @KarimAKL You are using it in the if statement, I suspect that it is false so the default config is never copied.
     
  13. Offline

    KarimAKL

    Sure that makes sense but where do i find out and change it from false to true?
     
  14. Online

    timtower Administrator Administrator Moderator

    @KarimAKL Your put a print statement in the if statement
     
  15. Offline

    KarimAKL

    Then.. Like this?
    Main Class onEnable:
    And then start the server?
    EDIT: I just tried this and found out colors doesn't work with this, anyway it said failed so what do i do now?
     
  16. Online

    timtower Administrator Administrator Moderator

    @KarimAKL Colors are something with the console, something you should ignore.
    And that means that you don't have an economy plugin installed.
     
  17. Offline

    KarimAKL

    Oh, okay. :p I changed the essentials.jar file to a disabled file for testing, that's probably why, haha. Thanks for all the help. :D
     
Thread Status:
Not open for further replies.

Share This Page