Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

ctbe

Members
  • Content Count

    85
  • Joined

  • Last visited

Everything posted by ctbe

  1. The mod quark does not wish to run in Minecraft version Minecraft 1.8. You will have to remove it to play. Perhaps that is the problem. I think you need to remove the quark mod as the version it was compiled for is different. Or so it gives the impression. I don't know about a best version as I think the word "best" is considered subjective in many places by many people and touching it is probably a hot button subject among players, but maybe you could try the latest minecraft version for which a stable version of forge exists.
  2. Why thanks for the references and explanation. I know I said I'm leaving it, but just to show my whole problem, here is the rendering result of my code and the code itself that makes the linked video. Lid Rotation: https://vgy.me/EvxpWl Chest Body Rotation (how I wanted the lid to rotate): https://vgy.me/NOOLZg Code... (This code is quite a bit so don't worry if you don't look at it. I'm opting for going static.) TileEntity (TileEntitySimpleChest.kt) http://www.codesend.com/view/67ca9f38cda506bb1cbd0485d549aa8b/ Block properties
  3. It's okay guys. I appreciate the intention on helping , but I'm really leaving it since this has been eating me for too long. If anyone asks me to add animation to my chests for when the lid opens and close I'll just tell them I don't know how to do it as I don't understand the GL. Don't worry . Here is an illustration in 2D of what I meant in my first post that is happening with the gl calls. In step 3, all the axes of reference get rotated. Meaning that any translation in the x axis afterwards, will be diagonal. This is 2D, but in minecraft, all 3 axes of reference get r
  4. Thanks for the answer, but I give up. I think no one has ever managed to do a custom chest in minecraft. If they did, they had a thorough understanding of what opengl is doing. I don't. I'll make my chest a simple static block. No animation or anything.
  5. I previously asked this question and I was told to translate, rotate, then translate back. After many hours of debugging trying to understand what was going wrong, I have come to the conclusion that it doesn't work like that. When one rotates using GlStateManager.rotate, all the axes of the OBJ rotate as well. In other words, the final translation will translate in reference to the rotated axis, making it impossible to translate to it's previous position. For example: // Move in the x axis 0.5 (works fine) GlStateManager.translate(0.5, 0, 0) // Rotate around the z axis, 45 degrees (
  6. The lightning got fixed by using this.setLightmapDisabled(true) as in the solution found here. But I feel I'm still doing something wrong since if I place more than one block, one lid renders normally lighted, and the other dark. Perhaps I should change the model of the block below the lid to be less than 1x1x1. After all, I have read various times it is not recommended to render anything bigger than 1x1x1. Edit: After a check, this doesn't solve the brightness issue. As when the chest and the player stand in a completely dark area, the lid can be seen clearly d
  7. I'm trying to use ModelChest to render a lid for my chest in a TESR. However, the lid renders dark and upside down. I don't know if calling render on a model from the overridden function is not the correct way to do it or recommended. I do know that when I tried this but while extending FastTESR, the code crashed because of some buffering issues and the crash was caused by the call of render(0.0625f) over the model. Not understanding how it works I might me doing something ridiculous here. This is my code: class TileEntitySimpleBoxRenderer : TileEntitySpecialRenderer<TileEntitySi
  8. Oh no, it wasn't because I didn't want to write Java. I was okay with it . I was expecting to make a mod which when I finished planning it, it required me to use a lot of Collections, and with that expectation, I knew I could use Scala (from previous experience) to my advantage and their immutable collections for a little bit of additional performance if I were to program it correctly. But after writing a good amount of code for my mod in Scala I was like "Ugh, going back to Java". Right now yes, though I'm okay with it, I'm reluctant to use Java, but at first no. This is
  9. The answers I look on this question would be answers that would be mostly based on opinion. But if you have predictable facts, that would be awesome. Yesterday I found out my project didn't compile and had to use Scorg to be able to compile it. I was thinking of re-writing it from scratch, but this time using Java because of fear that Scorg may stop being available in the future. I have been using Scala because I had many immutable collections which were providing me a slightly better performance although that wasn't always the case. In order to perform some operations, sometimes I
  10. Quite interesting. I was unaware of those details. Thanks. I will use the ClientTickEvent.
  11. I recently read somewhere in an answer to an old thread that rarely one should subscribe to KeyInputEvent when handling KeyBindings. That one should subscribe instead to ClientTickEvent. Of course, the answer was fitted to the context of that thread. In my case, in which all I do is open a GuiScreen menu should I subscribe with this @Subscribe def onKeyInput (keyInputEvent: KeyInputEvent): Unit = { // Do my logic here using KeyBinding.isKeyDown() } or with this @Subscribe def onClientTickEvent (clientTickEvent: ClientTickEvent): Unit = { // Do my logic here using
  12. I was so tired that I accidentally used sendChatMessage(String) instead of sendMessage(ITextComponent) which is what I really needed. (I know, programming while tired is not a good move) However, it surprised me that one cannot use color codes for sendChatMessage as they get filtered and the § character is treated as disallowed. The offender will get disconnected with the message: "Illegal characters in chat" on the screen. Would anyone happen to know of reasons for why sending chat messages with color is disallowed? I don't need to broadcast chat messages with color. I just need t
  13. I see. Then config is not the way to go for my purposes. I'll use GuiScreen with GuiButton then. To apply a custom property from my own mod to other items that may not necessarily come from my mod. If you take two of any, all properties would be mutually exclusive so I wanted a radio button. A GuiButton for example could work to remember only one property and then the player applies it to any item it wants in the game. But now I understand I'm doing the wrong approach. I'll use GuiScreen instead of a Gui config. Thanks.
  14. My code is like this (source @Choonster): @Config(modid = TestMod3.MODID) @Config.LangKey("testmod3.config.title") public class ModConfig { @Config.Comment("This is an example boolean property.") public static boolean fooBar = false; @Mod.EventBusSubscriber private static class EventHandler { /** * Inject the new values and save to the config file when the config has been changed from the GUI. * * @param event The event */ @SubscribeEvent public static void onConfigChanged(ConfigChangedEvent.OnConfigChang
  15. Either ItemModelMesher or RenderItem is null. You can test which one of them is giving null by first getting each one of them into a variable and debugging to see which one of them is been null. To solve it and not debug anything, use ModelLoader instead of ModelMesher. ModelLoader.setCustomModelResourceLocation(item, 0, new ModelResourceLocation(item.getRegistryName(), "inventory"))
  16. Been a couple of hours trying to change the rotation point of the handles in this code's TESR: https://wiki.mcjty.eu/modding/index.php/Render_Block_TESR_/_OBJ-1.12 The following GlStateManager.rotate(angle, 0, 1, 0); rotates around the origin of the OBJ model. I'd like to change the pivot point the rotate method will end up using. I'm originally practicing with this tutorial to understand the concepts to then make a custom chest, but if there is a way to change this it may also help me with another OBJ item I have in which the item rotates weirdly when thrown as an it
  17. If I'm not mistaking, the item needs to be registered in the game registry before registering its model. The calling order must change as so @EventHandler public void preInit(FMLPreInitializationEvent e) { RPVPItems.createItems(); Main.proxy.preInit(e); }
  18. What is the name of the class that contains TESR code to render the animation when a chest opens and closes? Trying to make a custom chest. Edit: Nevermind. Found it. It's the TileEntityChestRenderer. -Source: https://minecraft.gamepedia.com/Talk:Chest
  19. Thank you very much. It was that. I'm not an expert either, but I do know it automatically changes the Scala Boolean to a Java boolean (the primitive). Meaning it is not boxed. Got it working with any of the following: setDefaultState(blockState.getBaseState.withProperty(BlockProperties.IS_HANDLES, java.lang.Boolean.FALSE)) or setDefaultState(blockState.getBaseState.withProperty(BlockProperties.IS_HANDLES, false.asInstanceOf[java.lang.Boolean]) or setDefaultState(blockState.getBaseState.withProperty(BlockProperties.IS_HANDLES, Boolean.box(false)) Thanks.
  20. Probably simple, but it's eating me. I'm having trouble compiling this tutorial, but in scala: https://wiki.mcjty.eu/modding/index.php/Render_Block_TESR_/_OBJ-1.12 The line that goes setDefaultState(blockState.getBaseState().withProperty(IS_HANDLES, false)); In scala is the same, but without the semicolon at the end of course. As shown in the code, IS_HANDLES is of type PropertyBool as that is what the convenience implementation PropertyBool.create("") returns. Got a type mismatch exception found :net.minecraft.block.properties.PropertyB
  21. Oh. Then that defeats the purpose of having a custom crafting table. Given the circumstances I will use the workaround. Thanks. Edit: I will either use the workaround in my first post, or simply don't use an InventoryCrafting slot. The only reason I was using a InventoryCrafting slots was that it was the only way to trigger onCraftMatrixChanged method when the player did something in the custom table and update everything accordingly. Because normal slots didn't trigger that method.
  22. Yes. I just found that out and edited my main post. I'll check how to fix it because my recipes are custom, but don't extend IRecipe. I was using another way of matching recipes, etc. Now I understand it wasn't the correct way. My question is though, if I register my custom recipes (as IRecipe) in the GameRegistry, will they be craftable in a normal crafting table? Because I want them only be craftable on my custom crafting table, not a normal one.
  23. I made a custom crafting table. In the Container it has a variable of type InventoryCrafting named craftMatrix, like the ContainerWorkbench class. It also has a variable of type InventoryCraftResult named craftResult. The thing is that that when I craft something and put the resulting ItemStack in the output slot, I can take it from it, but the ItemStacks in craftMatrix, increase twice in size. I debugged for hours to find what was going on and found that the responsible for said behavior was the method slotClick from the Container class. I overrode the slotClick method and canceled the call t
×
×
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.