This commit is contained in:
Ellpeck 2016-01-11 22:02:41 +01:00
parent 5b166a784f
commit f014b1af57
2 changed files with 4 additions and 2 deletions

View file

@ -12,7 +12,7 @@ buildscript {
}
apply plugin: 'net.minecraftforge.gradle.forge'
version = "1.8.9-r22"
version = "1.8.9-r23"
group = "de.ellpeck.actuallyadditions"
archivesBaseName = "ActuallyAdditions"

View file

@ -24,6 +24,8 @@ import net.minecraft.nbt.NBTTagCompound;
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
import net.minecraftforge.fml.common.gameevent.PlayerEvent;
import java.util.Locale;
public class PlayerObtainEvents{
@SubscribeEvent
@ -34,7 +36,7 @@ public class PlayerObtainEvents{
if(!event.player.worldObj.isRemote && event.crafting != null && event.crafting.getItem() != null && event.crafting.getItem() != InitItems.itemBooklet){
String name = event.crafting.getItem().getRegistryName();
if(name != null && name.toLowerCase().contains(ModUtil.MOD_ID_LOWER)){
if(name != null && name.toLowerCase(Locale.ROOT).contains(ModUtil.MOD_ID_LOWER)){
NBTTagCompound compound = PersistentServerData.getDataFromPlayer(event.player);
if(compound != null && !compound.getBoolean("BookGottenAlready")){
compound.setBoolean("BookGottenAlready", true);