<commit_before>package dinglydell.techresearch.item;

import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.util.ChatComponentText;
import net.minecraft.world.World;
import dinglydell.techresearch.PlayerTechDataExtendedProps;
import dinglydell.techresearch.TechResearch;
import dinglydell.techresearch.experiment.ExperimentNotebook;
import dinglydell.techresearch.experiment.ExperimentNotebook.BlockState;
import dinglydell.techresearch.gui.GuiResearch;
import dinglydell.techresearch.gui.GuiResearch.ResearchLevel;

public class ItemNotebook extends Item {

	public ItemNotebook() {

	}

	@Override
	public boolean onItemUse(ItemStack stack,
			EntityPlayer player,
			World world,
			int x,
			int y,
			int z,
			int p_77648_7_,
			float p_77648_8_,
			float p_77648_9_,
			float p_77648_10_) {
		if (player.isSneaking()) {
			return false;
		}
		world.playSoundAtEntity(player, TechResearch.MODID
				+ ":item.notebook.open", 1f, 1f);
		if (world.isRemote) {
			GuiResearch.openGui(ResearchLevel.notebook);
		}
		return true;<commit_msg>Notebook now opens properly<commit_after>package dinglydell.techresearch.item;

import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.util.ChatComponentText;
import net.minecraft.world.World;
import dinglydell.techresearch.PlayerTechDataExtendedProps;
import dinglydell.techresearch.TechResearch;
import dinglydell.techresearch.experiment.ExperimentNotebook;
import dinglydell.techresearch.experiment.ExperimentNotebook.BlockState;
import dinglydell.techresearch.gui.GuiResearch;
import dinglydell.techresearch.gui.GuiResearch.ResearchLevel;

public class ItemNotebook extends Item {

	public ItemNotebook() {

	}

	@Override
	public ItemStack onItemRightClick(ItemStack stack,
			World world,
			EntityPlayer player) {
		if (player.isSneaking()) {
			return stack;
		}
		world.playSoundAtEntity(player, TechResearch.MODID
				+ ":item.notebook.open", 1f, 1f);
		if (world.isRemote) {
			GuiResearch.openGui(ResearchLevel.notebook);
		}
		return stack;
{'fraction_non_alphanumeric': 0.09188704616763783, 'fraction_numerical': 0.012998655311519497, 'mean_word_length': 5.6626865671641795, 'pattern_counts': {'":': 2, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1461191', 'n_tokens_mistral': 809, 'n_tokens_neox': 714, 'n_words': 128}