Add entity- and tileentity-sensitive versions of Spell#canBeCastByNPCs and Spell#canBeCastByDispensers

This commit is contained in:
Electroblob77
2020-01-27 16:42:28 +00:00
parent b682740751
commit 3052e56d03
42 changed files with 160 additions and 96 deletions
@@ -50,7 +50,7 @@ public class ItemScroll extends Item implements ISpellCastingItem {
if(tab == WizardryTabs.SPELLS){
List<Spell> spells = Spell.getSpells(Spell.allSpells);
List<Spell> spells = Spell.getAllSpells();
spells.removeIf(s -> !s.applicableForItem(this));
for(Spell spell : spells){
@@ -41,7 +41,7 @@ public class ItemSpellBook extends Item {
if(tab == WizardryTabs.SPELLS){
List<Spell> spells = Spell.getSpells(Spell.allSpells);
List<Spell> spells = Spell.getAllSpells();
spells.removeIf(s -> !s.applicableForItem(this));
for(Spell spell : spells){