Want a better Minecraft server? Read about SpigotMC here!
Separate names with a comma.
Discussion in 'Spigot Plugin Development' started by Mhalllz, May 31, 2018.
Each of the ItemStacks is uninitialized. You'll get tons of NullPointerExceptions.
None of the ItemStack variables are ever initialized in the beginning, so why even have them there? It'd be better to simply loop through all the available things you can enable and then create itemstacks based off that, and directly add them to the inventory from there. No need for the giant list of null-reference ItemStack variables, or even the tons of else-ifs