Fix the Disenchanting lens deleting books

Closes #482
This commit is contained in:
Ellpeck 2016-12-18 11:29:23 +01:00
parent bea1b4e798
commit c6b6f1610a
2 changed files with 2 additions and 2 deletions

View file

@ -43,7 +43,7 @@ public class LensDisenchanting extends Lens{
for(EntityItem item : items){ for(EntityItem item : items){
if(item != null && !item.isDead){ if(item != null && !item.isDead){
ItemStack stack = item.getEntityItem(); ItemStack stack = item.getEntityItem();
if(StackUtil.isValid(stack)){ if(StackUtil.isValid(stack) && StackUtil.getStackSize(stack) == 1){
Item stackItem = stack.getItem(); Item stackItem = stack.getItem();
if(stackItem == Items.BOOK || stackItem == Items.ENCHANTED_BOOK){ if(stackItem == Items.BOOK || stackItem == Items.ENCHANTED_BOOK){
if(book == null){ if(book == null){

View file

@ -986,7 +986,7 @@ booklet.actuallyadditions.chapter.lensDetonation.name=Lens of Detonation
booklet.actuallyadditions.chapter.lensDetonation.text.1=The <item>Lens of Detonation<r> will create a firey explosion <imp>around the block the laser hits<r>. <n>Be careful with this. Seriously. <n>(With this lens, the laser also goes 3 times as far!) booklet.actuallyadditions.chapter.lensDetonation.text.1=The <item>Lens of Detonation<r> will create a firey explosion <imp>around the block the laser hits<r>. <n>Be careful with this. Seriously. <n>(With this lens, the laser also goes 3 times as far!)
booklet.actuallyadditions.chapter.lensDisenchanting.name=Lens of Disenchanting booklet.actuallyadditions.chapter.lensDisenchanting.name=Lens of Disenchanting
booklet.actuallyadditions.chapter.lensDisenchanting.text.1=The <item>Lens of Disenchanting<r> can be used to <imp>tranfer<r> a single <imp>enchantment<r> from an enchanted item to either a <item>Book<r> or an already <item>Enchanted Book<r>. <n>This can be achieved by <imp>throwing the two items in front of the laser<r>, but they have to be together <imp>in one blockspace<r>. <n>When they are hit by the laser, the <imp>topmost enchantment<r> from the non-book item is <imp>removed<r> and <imp>added onto the book<r>. <n><n>However, this uses <imp><energy> CF<r>. booklet.actuallyadditions.chapter.lensDisenchanting.text.1=The <item>Lens of Disenchanting<r> can be used to <imp>tranfer<r> a single <imp>enchantment<r> from an enchanted item to either a <item>Book<r> or an already <item>Enchanted Book<r>. <n>This can be achieved by <imp>throwing the two items in front of the laser<r> (more than one of every type won't work!), but they have to be together <imp>in one blockspace<r>. <n>When they are hit by the laser, the <imp>topmost enchantment<r> from the non-book item is <imp>removed<r> and <imp>added onto the book<r>. <n><n>However, this uses <imp><energy> CF<r>.
booklet.actuallyadditions.chapter.lensMining.name=Lens of the Miner booklet.actuallyadditions.chapter.lensMining.name=Lens of the Miner
booklet.actuallyadditions.chapter.lensMining.text.1=The <item>Lens of the Miner<r> can <imp>create ores<r> out of blocks in its sight. <n>When the laser hits a <item>block of stone<r>, it will convert it into <imp>different overworld ores<r>, whereas a <item>block of netherrack<r> will be converted into <imp>nether ores<r>. <n>Each operation uses <imp><energy> CF<r>, however each operation requires <imp>additional power<r> depending on the rarity of the ore that is generated. booklet.actuallyadditions.chapter.lensMining.text.1=The <item>Lens of the Miner<r> can <imp>create ores<r> out of blocks in its sight. <n>When the laser hits a <item>block of stone<r>, it will convert it into <imp>different overworld ores<r>, whereas a <item>block of netherrack<r> will be converted into <imp>nether ores<r>. <n>Each operation uses <imp><energy> CF<r>, however each operation requires <imp>additional power<r> depending on the rarity of the ore that is generated.