How you expect me to talk to you, while you are +-30 years old. I told you like 2 or even 3 times to "clean the file from useless code" aka remove everything summon related. Obviously you did *not*. I gave you cleaned file and *no idea* why you added brackets which break the code. Could you explain me, WHY, why did you add brackets there?
Yeah, here is the place to help people learn and understand and all you are doing so far, is throwing away the knowledge we want to pass. In addition, it's enough to read the code to understand what's wrong.
player.getSummon() - wait, what? Summon? I don't care about summon, the code is *not* about summon - let's remove it!
Sorry to say, but you pretend to be a retard, so far.
-----
All I told you so far is correct and you should learn.
- take random code
- clean it from useless stuff
- add your code
- enjoy
Guess what, I had to throw few 'fack', 'goddamn' and 'kurwa' untill you proceed to step.. 2. So yeah, something is wrong here. You don't want to learn, you don't read what I'm saying to you or you are simply a retard and you should say it at first.
----
Anyway, you heav CLEAN FILE. So what left to do? Add your 1 line code aka plyaer.addSkill(..). Also, obviously, you should add destroyItem line, otherwise item will stay in inventory.