I use other simple method, just checking the item if is not null and is type, name and meta/lore i look for, i just set the item in hand to null....
It is removed, but u did not update the player inventory :)
add last p.updateInventory(); and will work :)
I loop it and it work :)
for (Double i : countall.values())
sum += i;
... and yes, how to return 25.6% it...
Thanks i will try it tomorrow :)
Use this site to check your YAML for errors
So, i want to get the average number by summering all keys in HashMap and divide by the size of it.
but return me the last number, i try...
ok, I think i solved it :)
but i found a bug, if the item is in offhand, cannot be modified, will check if the item in offhand is that i look for...
how can i check is that item is a that i look for and is not null :)
(item.getType() != null && item.getType().compareTo(Material.<myItem>) < 0) ?
Every time when IF return false i get NullPointerException
when i check IF the item is that i look for, is item have meta, is have lore, is have...
I'm trying to check for item in player inventory on event with loop.
I can get the item and based on specified lore i want to do something with...
how can i do that ?
Compile Spigot 1.9 with BuildTools.jar in order to get SpecialSource.jar & SpecialSource-2.jar respectively.
How can i get how may mobs are spawned in area from specified type and make changes only one or few of them ?
example: get how many...
Separate names with a comma.