From 7fef3a22c9e45332cc86d56dabc4945e8015ac03 Mon Sep 17 00:00:00 2001 From: RedmenNL Date: Sun, 12 Jan 2014 18:00:14 +0100 Subject: [PATCH] Release Candidate 1! --- java/com/dynious/soundscool/SoundsCool.java | 4 + .../soundscool/block/BlockSoundPlayer.java | 42 +++++++++- .../client/gui/GuiLocalSoundsList.java | 2 +- .../client/gui/GuiRemoteSoundsList.java | 9 +- .../soundscool/client/gui/GuiSoundPlayer.java | 52 ++++++++++-- .../soundscool/client/gui/GuiSounds.java | 38 +++++++-- .../soundscool/command/CommandSoundsCool.java | 3 - .../creativetab/CreativeTabSoundsCool.java | 29 +++++++ .../soundscool/handler/GuiHandler.java | 2 - .../soundscool/handler/NetworkHandler.java | 18 +++- .../soundscool/handler/SoundHandler.java | 4 +- .../handler/event/SoundEventHandler.java | 1 - .../soundscool/helper/NetworkHelper.java | 6 +- .../packet/client/CheckPresencePacket.java | 2 - .../client/GetUploadedSoundsPacket.java | 2 - .../packet/client/SoundPlayerPlayPacket.java | 7 -- .../client/SoundPlayerSelectPacket.java | 2 +- .../packet/server/UploadedSoundsPacket.java | 24 ++++-- .../dynious/soundscool/proxy/ClientProxy.java | 2 +- .../dynious/soundscool/proxy/CommonProxy.java | 7 +- java/com/dynious/soundscool/sound/Sound.java | 8 +- .../tileentity/TileSoundPlayer.java | 77 +++++++++++++++--- resources/assets/soundscool/lang/en_US.lang | 5 ++ .../textures/blocks/soundPlayer_side.png | Bin 0 -> 3086 bytes .../textures/blocks/soundPlayer_top.png | Bin 0 -> 3051 bytes resources/mcmod.info | 10 +-- 26 files changed, 284 insertions(+), 72 deletions(-) create mode 100644 java/com/dynious/soundscool/creativetab/CreativeTabSoundsCool.java create mode 100644 resources/assets/soundscool/lang/en_US.lang create mode 100644 resources/assets/soundscool/textures/blocks/soundPlayer_side.png create mode 100644 resources/assets/soundscool/textures/blocks/soundPlayer_top.png diff --git a/java/com/dynious/soundscool/SoundsCool.java b/java/com/dynious/soundscool/SoundsCool.java index 3deb99a..0521ee8 100644 --- a/java/com/dynious/soundscool/SoundsCool.java +++ b/java/com/dynious/soundscool/SoundsCool.java @@ -2,6 +2,7 @@ import com.dynious.soundscool.block.ModBlocks; import com.dynious.soundscool.command.CommandSoundsCool; +import com.dynious.soundscool.creativetab.CreativeTabSoundsCool; import com.dynious.soundscool.handler.GuiHandler; import com.dynious.soundscool.handler.SoundHandler; import com.dynious.soundscool.lib.Reference; @@ -14,6 +15,7 @@ import cpw.mods.fml.common.event.FMLPreInitializationEvent; import cpw.mods.fml.common.event.FMLServerStartingEvent; import cpw.mods.fml.common.network.NetworkRegistry; +import net.minecraft.creativetab.CreativeTabs; @Mod(modid = Reference.modid, name = Reference.name, version = Reference.version) public class SoundsCool @@ -24,6 +26,8 @@ public class SoundsCool @SidedProxy(clientSide = Reference.clientProxy, serverSide = Reference.commonProxy) public static CommonProxy proxy; + public static CreativeTabs tabSoundsCool = new CreativeTabSoundsCool(CreativeTabs.getNextID(), Reference.modid); + @EventHandler public void preInit(FMLPreInitializationEvent event) { diff --git a/java/com/dynious/soundscool/block/BlockSoundPlayer.java b/java/com/dynious/soundscool/block/BlockSoundPlayer.java index d70192d..de517db 100644 --- a/java/com/dynious/soundscool/block/BlockSoundPlayer.java +++ b/java/com/dynious/soundscool/block/BlockSoundPlayer.java @@ -1,22 +1,30 @@ package com.dynious.soundscool.block; import com.dynious.soundscool.SoundsCool; +import com.dynious.soundscool.lib.Names; +import com.dynious.soundscool.lib.Reference; import com.dynious.soundscool.tileentity.TileSoundPlayer; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; import net.minecraft.block.Block; import net.minecraft.block.BlockContainer; import net.minecraft.block.material.Material; +import net.minecraft.client.renderer.texture.IIconRegister; import net.minecraft.creativetab.CreativeTabs; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.tileentity.TileEntity; +import net.minecraft.util.IIcon; import net.minecraft.world.IBlockAccess; import net.minecraft.world.World; +import net.minecraftforge.common.util.ForgeDirection; public class BlockSoundPlayer extends BlockContainer { public BlockSoundPlayer() { super(Material.field_151576_e); - this.func_149647_a(CreativeTabs.tabBlock); + this.func_149647_a(SoundsCool.tabSoundsCool); + this.func_149663_c(Names.soundPlayer); } @Override @@ -69,4 +77,36 @@ public void func_149695_a(World world, int x, int y, int z, Block block) ((TileSoundPlayer)tile).setPowered(world.isBlockIndirectlyGettingPowered(x, y, z)); } } + + private IIcon blockTop; + private IIcon blockSide; + + //registerIcons() + @Override + @SideOnly(Side.CLIENT) + public void func_149651_a(IIconRegister iconRegister) + { + blockTop = iconRegister.registerIcon(Reference.modid + ":" + String.format("%s_top", getUnwrappedUnlocalizedName(this.func_149739_a()))); + blockSide = iconRegister.registerIcon(Reference.modid + ":" + String.format("%s_side", getUnwrappedUnlocalizedName(this.func_149739_a()))); + } + + //getIcon() + @Override + @SideOnly(Side.CLIENT) + public IIcon func_149691_a(int side, int metaData) + { + if (ForgeDirection.getOrientation(side) == ForgeDirection.UP || ForgeDirection.getOrientation(side) == ForgeDirection.DOWN) + { + return blockTop; + } + else + { + return blockSide; + } + } + + protected String getUnwrappedUnlocalizedName(String unlocalizedName) + { + return unlocalizedName.substring(unlocalizedName.indexOf(".") + 1); + } } diff --git a/java/com/dynious/soundscool/client/gui/GuiLocalSoundsList.java b/java/com/dynious/soundscool/client/gui/GuiLocalSoundsList.java index 7e0059b..85ec039 100644 --- a/java/com/dynious/soundscool/client/gui/GuiLocalSoundsList.java +++ b/java/com/dynious/soundscool/client/gui/GuiLocalSoundsList.java @@ -12,7 +12,7 @@ public class GuiLocalSoundsList extends GuiScrollingList public GuiLocalSoundsList(IListGui parent, int listWidth) { - super(parent.getMinecraftInstance(), listWidth, parent.getWidth(), 32, parent.getHeight() - 32 + 4, 10, 35); + super(parent.getMinecraftInstance(), listWidth, parent.getWidth(), 32, parent.getHeight() - 64, 10, 35); this.parent = parent; } diff --git a/java/com/dynious/soundscool/client/gui/GuiRemoteSoundsList.java b/java/com/dynious/soundscool/client/gui/GuiRemoteSoundsList.java index 35381d3..979f6d0 100644 --- a/java/com/dynious/soundscool/client/gui/GuiRemoteSoundsList.java +++ b/java/com/dynious/soundscool/client/gui/GuiRemoteSoundsList.java @@ -1,6 +1,7 @@ package com.dynious.soundscool.client.gui; import com.dynious.soundscool.handler.NetworkHandler; +import com.dynious.soundscool.sound.Sound; import cpw.mods.fml.client.GuiScrollingList; import net.minecraft.client.renderer.Tessellator; @@ -10,7 +11,7 @@ public class GuiRemoteSoundsList extends GuiScrollingList public GuiRemoteSoundsList(IListGui parent, int listWidth) { - super(parent.getMinecraftInstance(), listWidth, parent.getWidth(), 32, parent.getHeight() - 32 + 4, 10, 35); + super(parent.getMinecraftInstance(), listWidth, parent.getWidth(), 32, parent.getHeight() - 32, 10, 35); this.parent = parent; } @@ -47,11 +48,11 @@ protected int getContentHeight() @Override protected void drawSlot(int listIndex, int var2, int var3, int var4, Tessellator var5) { - String sound = NetworkHandler.uploadedSounds.get(listIndex); + Sound sound = NetworkHandler.uploadedSounds.get(listIndex); if (sound != null) { - this.parent.getFontRenderer().drawString(this.parent.getFontRenderer().trimStringToWidth(sound, listWidth - 10), this.left + 3 , var3 + 2, 0xFFFFFF); - //this.parent.getFontRenderer().drawString(this.parent.getFontRenderer().trimStringToWidth(NetworkHandler.hasServerSound(sound.getSoundName())? "Uploaded": "Not uploaded", listWidth - 10), this.left + 3 , var3 + 12, 0xCCCCCC); + this.parent.getFontRenderer().drawString(this.parent.getFontRenderer().trimStringToWidth(sound.getSoundName(), listWidth - 10), this.left + 3 , var3 + 2, 0xFFFFFF); + this.parent.getFontRenderer().drawString(this.parent.getFontRenderer().trimStringToWidth(sound.getCategory(), listWidth - 10), this.left + 3 , var3 + 12, 0xCCCCCC); } } } diff --git a/java/com/dynious/soundscool/client/gui/GuiSoundPlayer.java b/java/com/dynious/soundscool/client/gui/GuiSoundPlayer.java index 69f790d..60aca3e 100644 --- a/java/com/dynious/soundscool/client/gui/GuiSoundPlayer.java +++ b/java/com/dynious/soundscool/client/gui/GuiSoundPlayer.java @@ -2,18 +2,21 @@ import com.dynious.soundscool.SoundsCool; import com.dynious.soundscool.handler.NetworkHandler; -import com.dynious.soundscool.network.packet.client.ClientPlaySoundPacket; +import com.dynious.soundscool.handler.SoundHandler; import com.dynious.soundscool.network.packet.client.GetUploadedSoundsPacket; import com.dynious.soundscool.network.packet.client.SoundPlayerPlayPacket; -import com.dynious.soundscool.network.packet.client.SoundPlayerSelectPacket; +import com.dynious.soundscool.sound.Sound; import com.dynious.soundscool.tileentity.TileSoundPlayer; -import cpw.mods.fml.common.network.FMLOutboundHandler; -import cpw.mods.fml.common.network.NetworkRegistry; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.FontRenderer; import net.minecraft.client.gui.GuiButton; import net.minecraft.client.gui.GuiScreen; +import net.minecraft.client.resources.I18n; +import org.apache.commons.io.FileUtils; +@SideOnly(Side.CLIENT) public class GuiSoundPlayer extends GuiScreen implements IListGui { private GuiRemoteSoundsList soundsList; @@ -30,7 +33,8 @@ public void initGui() { super.initGui(); soundsList = new GuiRemoteSoundsList(this, 150); - this.field_146292_n.add(new GuiButton(0, this.field_146294_l / 2 - 75, this.field_146295_m - 38, "Play")); + this.field_146292_n.add(new GuiButton(0, getWidth() / 2, getHeight() - 42, I18n.getStringParams("gui.done"))); + this.field_146292_n.add(new GuiButton(1, getWidth() / 2, getHeight() - 72, "Play")); } @Override @@ -38,6 +42,25 @@ public void drawScreen(int p_571_1_, int p_571_2_, float p_571_3_) { this.soundsList.drawScreen(p_571_1_, p_571_2_, p_571_3_); super.drawScreen(p_571_1_, p_571_2_, p_571_3_); + + Sound sound = tile.getSelectedSound(); + if (sound != null) + { + this.getFontRenderer().drawString(sound.getSoundName(), getWidth()/2 + 100 - (this.getFontRenderer().getStringWidth(sound.getSoundName())/2), 30, 0xFFFFFF); + + boolean hasSound = SoundHandler.getSound(sound.getSoundName()) != null; + String uploaded = hasSound? "Downloaded": "Not downloaded"; + this.getFontRenderer().drawString(uploaded, getWidth()/2 + + 100 - (this.getFontRenderer().getStringWidth(uploaded)/2), 60, hasSound? 0x00FF00: 0xFF0000); + + String category = NetworkHandler.uploadedSounds.get(tile.getSelectedIndex()).getCategory(); + this.getFontRenderer().drawString(category, getWidth()/2 + 100 - (this.getFontRenderer().getStringWidth(category)/2), 90, 0xFFFFFF); + + if (sound.getSoundLocation() != null) + { + String space = FileUtils.byteCountToDisplaySize(sound.getSoundLocation().length()); + this.getFontRenderer().drawString(space, getWidth()/2 + 100 - (this.getFontRenderer().getStringWidth(space)/2), 120, 0xFFFFFF); + } + } } @Override @@ -47,7 +70,14 @@ protected void func_146284_a(GuiButton button) switch (button.field_146127_k) { case 0: - SoundsCool.proxy.getChannel().writeOutbound(new SoundPlayerPlayPacket(tile)); + this.field_146297_k.func_147108_a(null); + this.field_146297_k.setIngameFocus(); + break; + case 1: + if (tile.getSelectedSound() != null) + { + SoundsCool.proxy.getChannel().writeOutbound(new SoundPlayerPlayPacket(tile)); + } break; } } @@ -73,13 +103,13 @@ public void selectSoundIndex(int selected) @Override public boolean soundIndexSelected(int var1) { - return tile.getSelected() == var1; + return tile.getSelectedIndex() == var1; } @Override public int getWidth() { - return field_146295_m; + return field_146294_l; } @Override @@ -93,4 +123,10 @@ public void drawBackground() { func_146276_q_(); } + + @Override + public boolean doesGuiPauseGame() + { + return false; + } } diff --git a/java/com/dynious/soundscool/client/gui/GuiSounds.java b/java/com/dynious/soundscool/client/gui/GuiSounds.java index 3b390e8..51d3c3f 100644 --- a/java/com/dynious/soundscool/client/gui/GuiSounds.java +++ b/java/com/dynious/soundscool/client/gui/GuiSounds.java @@ -2,6 +2,7 @@ import com.dynious.soundscool.SoundsCool; import com.dynious.soundscool.client.audio.SoundPlayer; +import com.dynious.soundscool.handler.NetworkHandler; import com.dynious.soundscool.handler.SoundHandler; import com.dynious.soundscool.helper.NetworkHelper; import com.dynious.soundscool.network.packet.client.GetUploadedSoundsPacket; @@ -12,6 +13,7 @@ import net.minecraft.client.gui.GuiScreen; import net.minecraft.client.resources.I18n; import net.minecraft.entity.player.EntityPlayer; +import org.apache.commons.io.FileUtils; import javax.swing.*; @@ -34,10 +36,10 @@ public void initGui() { super.initGui(); soundsList = new GuiLocalSoundsList(this, 150); - this.field_146292_n.add(new GuiButton(0, this.field_146294_l / 2 - 75, this.field_146295_m - 38, I18n.getStringParams("gui.done"))); - this.field_146292_n.add(new GuiButton(1, this.field_146294_l / 2 - 75, 38, "Select File")); - this.field_146292_n.add(new GuiButton(2, this.field_146294_l / 2 - 75, field_146295_m/2 - 20, "Play Sound")); - this.field_146292_n.add(new GuiButton(3, this.field_146294_l / 2 - 75, field_146295_m/2 + 20, "Upload")); + this.field_146292_n.add(new GuiButton(0, getWidth() / 2, getHeight() - 42, I18n.getStringParams("gui.done"))); + this.field_146292_n.add(new GuiButton(1, 10, getHeight() - 42, 150, 20, "Select File")); + this.field_146292_n.add(new GuiButton(2, getWidth() / 2, getHeight() - 102, "Play Sound")); + this.field_146292_n.add(new GuiButton(3, getWidth() / 2, getHeight() - 72, "Upload")); fileChooser = new JFileChooser(Minecraft.getMinecraft().mcDataDir); } @@ -46,6 +48,26 @@ public void drawScreen(int p_571_1_, int p_571_2_, float p_571_3_) { this.soundsList.drawScreen(p_571_1_, p_571_2_, p_571_3_); super.drawScreen(p_571_1_, p_571_2_, p_571_3_); + + if (selectedSound != null) + { + this.getFontRenderer().drawString(selectedSound.getSoundName(), getWidth()/2 + 100 - (this.getFontRenderer().getStringWidth(selectedSound.getSoundName())/2), 30, 0xFFFFFF); + + boolean hasSound = NetworkHandler.hasServerSound(selectedSound.getSoundName()); + String uploaded = hasSound? "Uploaded": "Not uploaded"; + this.getFontRenderer().drawString(uploaded, getWidth()/2 + + 100 - (this.getFontRenderer().getStringWidth(uploaded)/2), 60, hasSound? 0x00FF00: 0xFF0000); + + if (selectedSound.getCategory() != null) + { + this.getFontRenderer().drawString(selectedSound.getCategory(), getWidth()/2 + 100 - (this.getFontRenderer().getStringWidth(selectedSound.getCategory())/2), 90, 0xFFFFFF); + } + + if (selectedSound.getSoundLocation() != null) + { + String space = FileUtils.byteCountToDisplaySize(selectedSound.getSoundLocation().length()); + this.getFontRenderer().drawString(space, getWidth()/2 + 100 - (this.getFontRenderer().getStringWidth(space)/2), 120, 0xFFFFFF); + } + } } @Override @@ -120,7 +142,7 @@ public boolean soundIndexSelected(int var1) @Override public int getWidth() { - return field_146295_m; + return field_146294_l; } @Override @@ -134,4 +156,10 @@ public void drawBackground() { func_146276_q_(); } + + @Override + public boolean doesGuiPauseGame() + { + return false; + } } diff --git a/java/com/dynious/soundscool/command/CommandSoundsCool.java b/java/com/dynious/soundscool/command/CommandSoundsCool.java index 5bb76f7..7253047 100644 --- a/java/com/dynious/soundscool/command/CommandSoundsCool.java +++ b/java/com/dynious/soundscool/command/CommandSoundsCool.java @@ -1,11 +1,8 @@ package com.dynious.soundscool.command; -import com.dynious.soundscool.SoundsCool; import com.dynious.soundscool.helper.NetworkHelper; import com.dynious.soundscool.lib.Commands; import com.dynious.soundscool.network.packet.server.OpenGUIPacket; -import com.dynious.soundscool.network.packet.server.SoundNotFoundPacket; -import cpw.mods.fml.common.network.FMLOutboundHandler; import net.minecraft.command.CommandBase; import net.minecraft.command.ICommand; import net.minecraft.command.ICommandSender; diff --git a/java/com/dynious/soundscool/creativetab/CreativeTabSoundsCool.java b/java/com/dynious/soundscool/creativetab/CreativeTabSoundsCool.java new file mode 100644 index 0000000..14869c8 --- /dev/null +++ b/java/com/dynious/soundscool/creativetab/CreativeTabSoundsCool.java @@ -0,0 +1,29 @@ +package com.dynious.soundscool.creativetab; + +import com.dynious.soundscool.block.ModBlocks; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; +import net.minecraft.creativetab.CreativeTabs; +import net.minecraft.item.Item; +import net.minecraft.item.ItemBlock; +import net.minecraft.item.ItemStack; + +public class CreativeTabSoundsCool extends CreativeTabs +{ + public CreativeTabSoundsCool(int id, String name) + { + super(id, name); + } + + @Override + public Item getTabIconItem() + { + return null; + } + + @SideOnly(Side.CLIENT) + public ItemStack func_151244_d() + { + return new ItemStack(ModBlocks.soundPlayer); + } +} diff --git a/java/com/dynious/soundscool/handler/GuiHandler.java b/java/com/dynious/soundscool/handler/GuiHandler.java index 97ef62d..fb95ca5 100644 --- a/java/com/dynious/soundscool/handler/GuiHandler.java +++ b/java/com/dynious/soundscool/handler/GuiHandler.java @@ -26,10 +26,8 @@ public Object getClientGuiElement(int ID, EntityPlayer player, World world, int switch(ID) { case 0: - System.out.println("Opening GUI"); return new GuiSounds(player); case 1: - System.out.println("Opening GUI"); TileEntity tile = world.func_147438_o(x, y, z); if (tile != null && tile instanceof TileSoundPlayer) { diff --git a/java/com/dynious/soundscool/handler/NetworkHandler.java b/java/com/dynious/soundscool/handler/NetworkHandler.java index 3b5126c..9361990 100644 --- a/java/com/dynious/soundscool/handler/NetworkHandler.java +++ b/java/com/dynious/soundscool/handler/NetworkHandler.java @@ -1,5 +1,6 @@ package com.dynious.soundscool.handler; +import com.dynious.soundscool.sound.Sound; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; import org.apache.commons.lang3.ArrayUtils; @@ -10,14 +11,27 @@ public class NetworkHandler { - public static ArrayList uploadedSounds = new ArrayList(); + public static ArrayList uploadedSounds = new ArrayList(); private static Map soundChunks = new HashMap(); + @SideOnly(Side.CLIENT) + public static boolean hasServerSound(Sound sound) + { + return uploadedSounds.contains(sound); + } + @SideOnly(Side.CLIENT) public static boolean hasServerSound(String soundName) { - return uploadedSounds.contains(soundName); + for (Sound sound : uploadedSounds) + { + if (sound.getSoundName().equals(soundName)) + { + return true; + } + } + return false; } public static void addSoundChunk(String soundName, byte[] soundChunk) diff --git a/java/com/dynious/soundscool/handler/SoundHandler.java b/java/com/dynious/soundscool/handler/SoundHandler.java index b3b9a01..332d729 100644 --- a/java/com/dynious/soundscool/handler/SoundHandler.java +++ b/java/com/dynious/soundscool/handler/SoundHandler.java @@ -91,7 +91,7 @@ else if (file.isDirectory()) @SideOnly(Side.CLIENT) public static void playSound(String soundName, int x, int y, int z) { - Sound sound = SoundHandler.getSound(Minecraft.getMinecraft().func_147104_D().serverName, soundName); + Sound sound = SoundHandler.getSound(soundName); if (sound != null) { SoundPlayer.playSound(sound.getSoundLocation(), x, y, z); @@ -105,7 +105,7 @@ public static void playSound(String soundName, int x, int y, int z) @SideOnly(Side.CLIENT) public static Sound setupSound(File file) { - File category = new File("sounds" + File.separator + Minecraft.getMinecraft().func_147104_D().serverName); + File category = new File("sounds" + File.separator + Minecraft.getMinecraft().func_147104_D().serverMOTD); if (!category.exists()) { category.mkdir(); diff --git a/java/com/dynious/soundscool/handler/event/SoundEventHandler.java b/java/com/dynious/soundscool/handler/event/SoundEventHandler.java index 78ca528..a5d2aeb 100644 --- a/java/com/dynious/soundscool/handler/event/SoundEventHandler.java +++ b/java/com/dynious/soundscool/handler/event/SoundEventHandler.java @@ -12,7 +12,6 @@ public class SoundEventHandler @SubscribeEvent public void onSoundLoad(SoundSetupEvent event) { - System.out.println("setup codecs!"); try { SoundSystemConfig.setCodec("wav", CodecWav.class); diff --git a/java/com/dynious/soundscool/helper/NetworkHelper.java b/java/com/dynious/soundscool/helper/NetworkHelper.java index 827f276..bbefcbe 100644 --- a/java/com/dynious/soundscool/helper/NetworkHelper.java +++ b/java/com/dynious/soundscool/helper/NetworkHelper.java @@ -24,7 +24,6 @@ public class NetworkHelper { public static final int PARTITION_SIZE = 10000; - @SideOnly(Side.SERVER) public static void sendPacketToPlayer(IPacket packet, EntityPlayer player) { SoundsCool.proxy.getChannel().attr(FMLOutboundHandler.FML_MESSAGETARGET).set(FMLOutboundHandler.OutboundTarget.PLAYER); @@ -36,10 +35,9 @@ public static void sendPacketToPlayer(IPacket packet, EntityPlayer player) public static void clientSoundUpload(Sound sound) { uploadSound(sound); - NetworkHandler.uploadedSounds.add(sound.getSoundName()); + NetworkHandler.uploadedSounds.add(new Sound(sound.getSoundName(), Minecraft.getMinecraft().thePlayer.getDisplayName())); } - @SideOnly(Side.SERVER) public static void serverSoundUpload(Sound sound, EntityPlayer player) { SoundsCool.proxy.getChannel().attr(FMLOutboundHandler.FML_MESSAGETARGET).set(FMLOutboundHandler.OutboundTarget.PLAYER); @@ -55,7 +53,7 @@ private static void uploadSound(Sound sound) byte[] bytes = ArrayUtils.subarray(soundBytes, i, i + Math.min(PARTITION_SIZE, soundBytes.length - i)); SoundsCool.proxy.getChannel().writeOutbound(new SoundChunkPacket(sound.getSoundName(), bytes)); } - String category = FMLCommonHandler.instance().getEffectiveSide().isClient()? Minecraft.getMinecraft().thePlayer.getDisplayName(): MinecraftServer.getServer().getServerHostname(); + String category = FMLCommonHandler.instance().getEffectiveSide().isClient()? Minecraft.getMinecraft().thePlayer.getDisplayName(): MinecraftServer.getServer().getMOTD(); SoundsCool.proxy.getChannel().writeOutbound(new SoundUploadedPacket(sound.getSoundName(), category)); } diff --git a/java/com/dynious/soundscool/network/packet/client/CheckPresencePacket.java b/java/com/dynious/soundscool/network/packet/client/CheckPresencePacket.java index 0af2e95..556e34f 100644 --- a/java/com/dynious/soundscool/network/packet/client/CheckPresencePacket.java +++ b/java/com/dynious/soundscool/network/packet/client/CheckPresencePacket.java @@ -1,12 +1,10 @@ package com.dynious.soundscool.network.packet.client; -import com.dynious.soundscool.SoundsCool; import com.dynious.soundscool.handler.SoundHandler; import com.dynious.soundscool.helper.NetworkHelper; import com.dynious.soundscool.network.packet.IPacket; import com.dynious.soundscool.network.packet.server.SoundNotFoundPacket; import com.dynious.soundscool.sound.Sound; -import cpw.mods.fml.common.network.FMLOutboundHandler; import io.netty.buffer.ByteBuf; import net.minecraft.entity.Entity; import net.minecraft.entity.player.EntityPlayer; diff --git a/java/com/dynious/soundscool/network/packet/client/GetUploadedSoundsPacket.java b/java/com/dynious/soundscool/network/packet/client/GetUploadedSoundsPacket.java index 2bc6c5e..425539b 100644 --- a/java/com/dynious/soundscool/network/packet/client/GetUploadedSoundsPacket.java +++ b/java/com/dynious/soundscool/network/packet/client/GetUploadedSoundsPacket.java @@ -1,10 +1,8 @@ package com.dynious.soundscool.network.packet.client; -import com.dynious.soundscool.SoundsCool; import com.dynious.soundscool.helper.NetworkHelper; import com.dynious.soundscool.network.packet.IPacket; import com.dynious.soundscool.network.packet.server.UploadedSoundsPacket; -import cpw.mods.fml.common.network.FMLOutboundHandler; import io.netty.buffer.ByteBuf; import net.minecraft.entity.Entity; import net.minecraft.entity.player.EntityPlayer; diff --git a/java/com/dynious/soundscool/network/packet/client/SoundPlayerPlayPacket.java b/java/com/dynious/soundscool/network/packet/client/SoundPlayerPlayPacket.java index 00fbe8d..5aef8b3 100644 --- a/java/com/dynious/soundscool/network/packet/client/SoundPlayerPlayPacket.java +++ b/java/com/dynious/soundscool/network/packet/client/SoundPlayerPlayPacket.java @@ -1,16 +1,10 @@ package com.dynious.soundscool.network.packet.client; -import com.dynious.soundscool.SoundsCool; import com.dynious.soundscool.network.packet.IPacket; -import com.dynious.soundscool.network.packet.server.ServerPlaySoundPacket; import com.dynious.soundscool.tileentity.TileSoundPlayer; -import cpw.mods.fml.common.network.FMLOutboundHandler; -import cpw.mods.fml.common.network.NetworkRegistry; import io.netty.buffer.ByteBuf; import net.minecraft.tileentity.TileEntity; import net.minecraft.world.World; -import net.minecraft.world.WorldManager; -import net.minecraft.world.WorldProvider; import net.minecraftforge.common.DimensionManager; public class SoundPlayerPlayPacket implements IPacket @@ -43,7 +37,6 @@ public void readBytes(ByteBuf bytes) if (tile != null && tile instanceof TileSoundPlayer) { ((TileSoundPlayer)tile).playCurrentSound(); - System.out.println("PLAY!"); } } } diff --git a/java/com/dynious/soundscool/network/packet/client/SoundPlayerSelectPacket.java b/java/com/dynious/soundscool/network/packet/client/SoundPlayerSelectPacket.java index 99b74fa..c4331ee 100644 --- a/java/com/dynious/soundscool/network/packet/client/SoundPlayerSelectPacket.java +++ b/java/com/dynious/soundscool/network/packet/client/SoundPlayerSelectPacket.java @@ -22,7 +22,7 @@ public SoundPlayerSelectPacket(TileSoundPlayer tile) this.x = tile.field_145851_c; this.y = tile.field_145848_d; this.z = tile.field_145849_e; - this.selected = tile.getSelected(); + this.selected = tile.getSelectedIndex(); } @Override diff --git a/java/com/dynious/soundscool/network/packet/server/UploadedSoundsPacket.java b/java/com/dynious/soundscool/network/packet/server/UploadedSoundsPacket.java index b49a895..c010868 100644 --- a/java/com/dynious/soundscool/network/packet/server/UploadedSoundsPacket.java +++ b/java/com/dynious/soundscool/network/packet/server/UploadedSoundsPacket.java @@ -17,18 +17,25 @@ public UploadedSoundsPacket() @Override public void readBytes(ByteBuf bytes) { - ArrayList soundList = new ArrayList(); + ArrayList soundList = new ArrayList(); int sounds = bytes.readInt(); for (int y = 0; y < sounds; y++) { - int fileLength = bytes.readInt(); - char[] fileCars = new char[fileLength]; - for (int i = 0; i < fileLength; i++) + int soundNameLength = bytes.readInt(); + char[] soundNameCars = new char[soundNameLength]; + for (int i = 0; i < soundNameLength; i++) { - fileCars[i] = bytes.readChar(); + soundNameCars[i] = bytes.readChar(); } - soundList.add(String.valueOf(fileCars)); + int soundCatLength = bytes.readInt(); + char[] soundCatChars = new char[soundCatLength]; + for (int i = 0; i < soundCatLength; i++) + { + soundCatChars[i] = bytes.readChar(); + } + soundList.add(new Sound(String.valueOf(soundNameCars), String.valueOf(soundCatChars))); } + NetworkHandler.uploadedSounds = soundList; } @@ -43,6 +50,11 @@ public void writeBytes(ByteBuf bytes) { bytes.writeChar(c); } + bytes.writeInt(sound.getCategory().length()); + for (char c : sound.getCategory().toCharArray()) + { + bytes.writeChar(c); + } } } } diff --git a/java/com/dynious/soundscool/proxy/ClientProxy.java b/java/com/dynious/soundscool/proxy/ClientProxy.java index f012fcf..195359d 100644 --- a/java/com/dynious/soundscool/proxy/ClientProxy.java +++ b/java/com/dynious/soundscool/proxy/ClientProxy.java @@ -24,6 +24,6 @@ public void soundSetup() @Override public EmbeddedChannel getChannel() { - return channel.get(Side.CLIENT); + return channels.get(Side.CLIENT); } } diff --git a/java/com/dynious/soundscool/proxy/CommonProxy.java b/java/com/dynious/soundscool/proxy/CommonProxy.java index c8ccb35..2614ca4 100644 --- a/java/com/dynious/soundscool/proxy/CommonProxy.java +++ b/java/com/dynious/soundscool/proxy/CommonProxy.java @@ -14,7 +14,7 @@ public class CommonProxy { - public EnumMap channel; + public EnumMap channels; public void initTileEntities() { @@ -23,16 +23,15 @@ public void initTileEntities() public void initNetworking() { - channel = NetworkRegistry.INSTANCE.newChannel(Reference.modid, new ChannelHandler()); + channels = NetworkRegistry.INSTANCE.newChannel(Reference.modid, new ChannelHandler()); } public void soundSetup() { - } public EmbeddedChannel getChannel() { - return channel.get(Side.SERVER); + return channels.get(Side.SERVER); } } diff --git a/java/com/dynious/soundscool/sound/Sound.java b/java/com/dynious/soundscool/sound/Sound.java index bd7ffbf..6b3a3bb 100644 --- a/java/com/dynious/soundscool/sound/Sound.java +++ b/java/com/dynious/soundscool/sound/Sound.java @@ -18,7 +18,13 @@ public Sound(File soundLocation) path = ""; this.category = path; this.soundName = soundLocation.getName(); - System.out.println(category + " & " + soundName); + } + + public Sound(String soundName, String category) + { + this.soundLocation = null; + this.soundName = soundName; + this.category = category; } public String getCategory() diff --git a/java/com/dynious/soundscool/tileentity/TileSoundPlayer.java b/java/com/dynious/soundscool/tileentity/TileSoundPlayer.java index bd870e3..6fec7cf 100644 --- a/java/com/dynious/soundscool/tileentity/TileSoundPlayer.java +++ b/java/com/dynious/soundscool/tileentity/TileSoundPlayer.java @@ -5,16 +5,19 @@ import com.dynious.soundscool.handler.SoundHandler; import com.dynious.soundscool.network.packet.client.SoundPlayerSelectPacket; import com.dynious.soundscool.network.packet.server.ServerPlaySoundPacket; +import com.dynious.soundscool.sound.Sound; import cpw.mods.fml.common.network.FMLOutboundHandler; import cpw.mods.fml.common.network.NetworkRegistry; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; +import net.minecraft.nbt.NBTTagCompound; +import net.minecraft.network.NetworkManager; +import net.minecraft.network.Packet; +import net.minecraft.network.play.server.S35PacketUpdateTileEntity; import net.minecraft.tileentity.TileEntity; public class TileSoundPlayer extends TileEntity { private boolean isPowered = false; - private String selectedSound = ""; + private Sound selectedSound; private int selected = -1; public void setPowered(boolean powered) @@ -39,7 +42,15 @@ public void selectSoundIndex(int selected) if (selected >= 0 && selected <= NetworkHandler.uploadedSounds.size()) { - this.selectedSound = NetworkHandler.uploadedSounds.get(selected); + Sound sound = SoundHandler.getSound(NetworkHandler.uploadedSounds.get(selected).getSoundName()); + if (sound != null) + { + this.selectedSound = sound; + } + else + { + this.selectedSound = NetworkHandler.uploadedSounds.get(selected); + } } else { @@ -50,7 +61,7 @@ public void selectSoundIndex(int selected) { if (selected >= 0 && selected <= SoundHandler.getSounds().size()) { - this.selectedSound = SoundHandler.getSounds().get(selected).getSoundName(); + this.selectedSound = SoundHandler.getSounds().get(selected); } else { @@ -59,16 +70,62 @@ public void selectSoundIndex(int selected) } } - public int getSelected() + public int getSelectedIndex() { return this.selected; } - @SideOnly(Side.SERVER) + public Sound getSelectedSound() + { + if (selected != -1 && selectedSound == null) + { + selectSoundIndex(selected); + } + return selectedSound; + } + public void playCurrentSound() { - SoundsCool.proxy.getChannel().attr(FMLOutboundHandler.FML_MESSAGETARGET).set(FMLOutboundHandler.OutboundTarget.ALLAROUNDPOINT); - SoundsCool.proxy.getChannel().attr(FMLOutboundHandler.FML_MESSAGETARGETARGS).set(NetworkRegistry.INSTANCE.new TargetPoint(func_145831_w().provider.dimensionId, field_145851_c, field_145848_d, field_145849_e, 64)); - SoundsCool.proxy.getChannel().writeOutbound(new ServerPlaySoundPacket(selectedSound, field_145851_c, field_145848_d, field_145849_e)); + if (selected != -1 && selectedSound == null) + { + selectSoundIndex(selected); + } + if (selectedSound != null) + { + SoundsCool.proxy.getChannel().attr(FMLOutboundHandler.FML_MESSAGETARGET).set(FMLOutboundHandler.OutboundTarget.ALLAROUNDPOINT); + SoundsCool.proxy.getChannel().attr(FMLOutboundHandler.FML_MESSAGETARGETARGS).set(NetworkRegistry.INSTANCE.new TargetPoint(func_145831_w().provider.dimensionId, field_145851_c, field_145848_d, field_145849_e, 64)); + SoundsCool.proxy.getChannel().writeOutbound(new ServerPlaySoundPacket(selectedSound.getSoundName(), field_145851_c, field_145848_d, field_145849_e)); + } + } + + //readFromNBT + @Override + public void func_145839_a(NBTTagCompound compound) + { + super.func_145839_a(compound); + selected = compound.getInteger("selected"); + } + + //writeToNBT + @Override + public void func_145841_b(NBTTagCompound compound) + { + super.func_145841_b(compound); + compound.setInteger("selected", selected); + } + + @Override + public void onDataPacket(NetworkManager net, S35PacketUpdateTileEntity pkt) + { + selected = pkt.func_148857_g().getInteger("selected"); + } + + //getDescriptionPacket() + @Override + public Packet func_145844_m() + { + NBTTagCompound compound = new NBTTagCompound(); + compound.setInteger("selected", selected); + return new S35PacketUpdateTileEntity(field_145851_c, field_145848_d, field_145849_e, 1, compound); } } diff --git a/resources/assets/soundscool/lang/en_US.lang b/resources/assets/soundscool/lang/en_US.lang new file mode 100644 index 0000000..fa045af --- /dev/null +++ b/resources/assets/soundscool/lang/en_US.lang @@ -0,0 +1,5 @@ +# Block localizations +tile.soundPlayer.name=Sound Player + +# Inventory localizations +itemGroup.soundscool=Sounds Cool \ No newline at end of file diff --git a/resources/assets/soundscool/textures/blocks/soundPlayer_side.png b/resources/assets/soundscool/textures/blocks/soundPlayer_side.png new file mode 100644 index 0000000000000000000000000000000000000000..60284d00cdd2cb9936866e4bfc19e72cd53cda86 GIT binary patch literal 3086 zcmV+p4Ds`cP)KLZ*U+IBfRsybQWXdwQbLP>6pAqfylh#{fb6;Z(vMMVS~$e@S=j*ftg6;Uhf59&ghTmgWD0l;*T zI709Y^p6lP1rIRMx#05C~cW=H_Aw*bJ-5DT&Z2n+x)QHX^p z00esgV8|mQcmRZ%02D^@S3L16t`O%c004NIvOKvYIYoh62rY33S640`D9%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U998vm4nApc-4~J1 z8vOMCik`;dLX2_bVB0qI-Ukv9dha6#u7zt5WBh(h*GFS!FtgiQRY&i%m*?||5W=5} ch^F<|09CQvzZ3Ii$p8QV07*qoM6N<$f{XIJC;$Ke literal 0 HcmV?d00001 diff --git a/resources/assets/soundscool/textures/blocks/soundPlayer_top.png b/resources/assets/soundscool/textures/blocks/soundPlayer_top.png new file mode 100644 index 0000000000000000000000000000000000000000..67a7648cec0cdcf9c02a4677da9cf805d85c1851 GIT binary patch literal 3051 zcmVKLZ*U+IBfRsybQWXdwQbLP>6pAqfylh#{fb6;Z(vMMVS~$e@S=j*ftg6;Uhf59&ghTmgWD0l;*T zI709Y^p6lP1rIRMx#05C~cW=H_Aw*bJ-5DT&Z2n+x)QHX^p z00esgV8|mQcmRZ%02D^@S3L16t`O%c004NIvOKvYIYoh62rY33S640`D9%Y2D-rV&neh&#Q1i z007~1e$oCcFS8neI|hJl{-P!B1ZZ9hpmq0)X0i`JwE&>$+E?>%_LC6RbVIkUx0b+_+BaR3cnT7Zv!AJxW zizFb)h!jyGOOZ85F;a?DAXP{m@;!0_IfqH8(HlgRxt7s3}k3K`kFu>>-2Q$QMFfPW!La{h336o>X zu_CMttHv6zR;&ZNiS=X8v3CR#fknUxHUxJ0uoBa_M6WNWeqIg~6QE69c9o#eyhGvpiOA@W-aonk<7r1(?fC{oI5N*U!4 zfg=2N-7=cNnjjOr{yriy6mMFgG#l znCF=fnQv8CDz++o6_Lscl}eQ+l^ZHARH>?_s@|##Rr6KLRFA1%Q+=*RRWnoLsR`7U zt5vFIcfW3@?wFpwUVxrVZ>QdQz32KIeJ}k~{cZZE^+ya? z2D1z#2HOnI7(B%_ac?{wFUQ;QQA1tBKtrWrm0_3Rgps+?Jfqb{jYbcQX~taRB;#$y zZN{S}1|}gUOHJxc?wV3fxuz+mJ4`!F$IZ;mqRrNsHJd##*D~ju=bP7?-?v~|cv>vB zsJ6IeNwVZxrdjT`yl#bBIa#GxRa#xMMy;K#CDyyGy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