1. The forums will be archived and moved to a read only mode in about 2 weeks (mid march).

Solved Need help with enchants

Discussion in 'Development' started by TwistedAsylumMC, Feb 17, 2018.

  1. TwistedAsylumMC

    TwistedAsylumMC Slime

    Messages:
    96
    GitHub:
    twistedasylummc
    Im trying to make a kits plugin i have
    PHP:
                                        $helmet Item::get(31001);
                                        
    $helmet->addEnchantmet(new EnchantmentInstance($p2)); 
    and get this error
    Code:
    [08:27:01] [Server thread/CRITICAL]: Error: "Call to undefined method pocketmine\item\DiamondHelmet::addEnchantmet()" (EXCEPTION) in "plugins/KitPvP-master/src/DynamicNetwork/Commands/KitCommand" at line 303
    Can anyone help? it worked before but now it doesn't
     
  2. SalmonDE

    SalmonDE Zombie Pigman

    Messages:
    739
    GitHub:
    SalmonDE
    You've got a typo in there.
    It's called Item::addEnchantment().
     
  3. kenygamer

    kenygamer Banned Banned

    Messages:
    106
    GitHub:
    kenygamer
    If the fix above worked, mark this as "Solved".
     
  4. HBIDamian

    HBIDamian HBIDamian Staff Member

    Messages:
    365
    GitHub:
    HBIDamian
    What is the point in strolling through the forum, for a topic that you had no hand in helping, just to say that.
    That's just as stupid as you stealing LDX's Plugin, and calling it your own, and breaking his license/copyright.
     
  5. kenygamer

    kenygamer Banned Banned

    Messages:
    106
    GitHub:
    kenygamer
    The LDX case is completely irrelevant here; I don't appreciate another someone spreading the word about fake stuff just like the discussion I had yesterday with dogee.
     
  6. kenygamer

    kenygamer Banned Banned

    Messages:
    106
    GitHub:
    kenygamer
    And what is the point of blaming me, even, in the wrong category? Please stop talking about the LDX case. I never claimed his code as mine, and all this is being currently handled via PM like civilizated and mature people. Instead, you're spreading the word about stuff that needs clarification, just like dogee does.

    To answer your question: to contribute in the forum, and since the problem in question might have been already solved, to avoid leaving solved threads as non-solved. Who cares about this? Me.
     
    Last edited: Feb 18, 2018
    xXNiceAssassinlo YT likes this.
  7. Diduhless

    Diduhless Baby Zombie

    Messages:
    199
    GitHub:
    Diduhless
    PHP:
    $helmet->addEnchantment(Enchantment::getEnchantment(0));
    You can also add ->setLevel(number) to put a level to the enchantment
     
    OnTheVerge likes this.
  8. SalmonDE

    SalmonDE Zombie Pigman

    Messages:
    739
    GitHub:
    SalmonDE
    That's outdated.
     
  9. HBIDamian

    HBIDamian HBIDamian Staff Member

    Messages:
    365
    GitHub:
    HBIDamian
    Spreading word? Nah, everyone already knows that you talk bullpoop already. :) And in a few pmmp related group chats, we know you are bullpoop :D
     
    Az928 and OnTheVerge like this.
  10. kenygamer

    kenygamer Banned Banned

    Messages:
    106
    GitHub:
    kenygamer
    Say whatever you want, you are not getting anything continuing to talk about old stuff. If I had problems with certain people I have already solved my problems with that certain people, or I am currently doing an attempt in solving any problems and clarifying things. Instead, you are doing the same dogee and a few others do; keeps insisting and giving a wrong concept about me, and is more than convinced for what "someone", or your "best friend" said.

    I am not replying to this thread anymore because this is going off-topic. If you want a mature discussion move this to private messaging. If you mind, add me on Discord: kenygamer#8667
     
    Last edited: Feb 18, 2018
  11. HBIDamian

    HBIDamian HBIDamian Staff Member

    Messages:
    365
    GitHub:
    HBIDamian
    First sensible think you said in ages
     
    OnTheVerge likes this.
  12. kenygamer

    kenygamer Banned Banned

    Messages:
    106
    GitHub:
    kenygamer
    Maybe.
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.