2013-10-15 05:36:07 +02:00
|
|
|
package mekanism.client;
|
|
|
|
|
|
|
|
import mekanism.client.sound.SoundHandler;
|
|
|
|
import mekanism.common.Mekanism;
|
2013-12-05 22:42:00 +01:00
|
|
|
import mekanism.common.PacketHandler;
|
|
|
|
import mekanism.common.PacketHandler.Transmission;
|
|
|
|
import mekanism.common.network.PacketKey;
|
|
|
|
import net.minecraft.entity.player.EntityPlayer;
|
|
|
|
|
|
|
|
import org.lwjgl.input.Keyboard;
|
|
|
|
|
2013-11-03 22:54:33 +01:00
|
|
|
import cpw.mods.fml.relauncher.Side;
|
|
|
|
import cpw.mods.fml.relauncher.SideOnly;
|
2013-10-15 05:36:07 +02:00
|
|
|
|
|
|
|
public class MekanismClient extends Mekanism
|
|
|
|
{
|
|
|
|
@SideOnly(Side.CLIENT)
|
|
|
|
/** The main SoundHandler instance that is used by all audio sources */
|
|
|
|
public static SoundHandler audioHandler;
|
|
|
|
|
|
|
|
//General Configuration
|
|
|
|
public static boolean enableSounds = true;
|
|
|
|
public static boolean fancyUniversalCableRender = true;
|
2013-12-08 18:49:48 +01:00
|
|
|
public static double baseSoundVolume = 1;
|
2013-11-03 02:07:55 +01:00
|
|
|
|
|
|
|
public static long ticksPassed = 0;
|
2013-12-05 22:42:00 +01:00
|
|
|
|
|
|
|
public static void updateKey(EntityPlayer player, int key)
|
|
|
|
{
|
|
|
|
if(Keyboard.isKeyDown(key) != keyMap.has(player, key))
|
|
|
|
{
|
|
|
|
PacketHandler.sendPacket(Transmission.SERVER, new PacketKey().setParams(key, Keyboard.isKeyDown(key)));
|
|
|
|
keyMap.update(player, key, Keyboard.isKeyDown(key));
|
|
|
|
}
|
|
|
|
}
|
2013-10-15 05:36:07 +02:00
|
|
|
}
|