Jump to content

18107

Members
  • Posts

    14
  • Joined

  • Last visited

Everything posted by 18107

  1. I have a concept I would like to test before putting in effort to make a mod out of it. For this purpose I would like to edit invert.fsh. I have been unable to locate Minecraft's assets folder or any of the shaders in the development environment. Alternatively, is there a better way to modify the shader for rapid prototyping?
  2. I get the following errors when trying your code: FMLCommonHandler cannot be resolved The method getSource() is undefined for the type ModContainer I am also not sure which import to use for IOUtils.
  3. What is the correct way to load a file in assets while in development a environment, and after being compiled? In 1.12 I loaded files from assets/folder/file.name by using Minecraft.getMinecraft().getResourceManager().getResource(new ResourceLocation("modid:folder/file.name")); In 1.14.4 this is throwing a FileNotFoundException. On further investigation, this.namespaceResourceManagers.get(resourceLocationIn.getNamespace()) in SimpleReloadableResourceManager.getResource is returning null.
  4. I would like to handle events from an optional mod by using an @Optional method. How should I do this in 1.13? Example 1.12.2 code: @Optional.Method(modid="replaymod") @SubscribeEvent public void replayModRenderPre(com.replaymod.render.events.ReplayRenderEvent.Pre e) { //Do something }
  5. How would I go about doing this? I have been working on a coremod that causes the game to render the world 6 times per frame. Is this something that should have forge hooks for it, or is it better to use a coremod?
  6. If you want to run multiple versions of minecraft with version-specific mods, you can put them in separate folders. All 1.7.10 mods can be put in "mods/1.7.10", while 1.11.2 mods are in "mods/1.11.2". If you do this and have no mods directly in the mods folder, then there should be no conflict between versions.
  7. I am currently using @IFMLLoadingPlugin.MCVersion("1.11.2") to set the version of minecraft required. Before you ask, yes, I do need to use a coremod (rendering engine modifications). Is it possible to have the coremod loaded by forge in multiple versions? e.g. @IFMLLoadingPlugin.MCVersion("1.11", "1.11.2", "1.12") The actual code to modify classes is not an issue, and can be made to work for specific versions of minecraft.
  8. It appears that I'm an idiot (or shouldn't code when tired). I have since discovered a forge event in a nearby class that appears to provide the same information. Thanks for the help.
  9. When I use Class c = model.getClass(); c.getDeclaredField("models").setAccessible(true); c.getDeclaredField("models").get(model); it throws java.lang.IllegalAccessException: can not access a member of class net.minecraftforge.client.model.ModelLoader$WeightedRandomModel with modifiers "private final"
  10. At runtime the variable models holds all the data for all blocks in the game. I am attempting to write a rendering engine, and I need the shape of the blocks to do this. The interface IModel has 3 classes that implement it. Only one of these contains the variable 'models'. I have verified that 'model' is of the class 'WeightedRandomModel'. The compiler informs me that 'WeightedRandomModel' is not visible and I can't cast 'model' to it. I have read the reflect tutorial, but it doesn't seem to help my situation. Class.cast() deosn't seem to do what I want either. WeightedRandomModel wModel = (WeightedRandomModel) model; //Compiler error I would like to read all of the data in 'models', but I don't know how to access it.
  11. I am not familiar with reflection. How would I do something like this with reflection? public void doSomething(IModel model) { WeightedRandomModel wModel = (WeightedRandomModel) model; List<IModel> list = wModel.models; //Do something with list } Can you provide an example?
  12. I have found the following class. package net.minecraftforge.client.model; public final class ModelLoader extends ModelBakery { private static final class WeightedRandomModel implements IModel { private final List<IModel> models; } } I have an IModel object and I would like to access the models field. To do this, I must cast the object to ModelLoader.WeightedRandomModel. How can I modify WeightedRandomModel to be public? I have had no success with reflection or access transformers so far.
  13. Background information I have a mod that renders the game in 360 degrees. With the most recent changes/bug fixes, I have uncovered a new bug. The mod renders the game 6 times in 6 different directions, then uses a shader to combine all of the images into one. I am using GLStateManager.rotate(angle, 0, 1, 0); to rotate the camera. The chunks in the forward view are rendered correctly, but the chunks in other directions are often not rendered. The Request Can someone provide the name of the class or method that causes this? I have been unable to duplicate this bug using mcp (without forge). Resources The mod [1.10.2] Source code Note the flickering as chunks are occasionally rendered. [embed=425,349]<iframe width="560" height="315" src="https://www.youtube.com/embed/lK7bxjbTOv0" frameborder="0" allowfullscreen></iframe>[/embed] Loading the world from different locations with no code changes. Note the inconsistent results. [embed=425,349]<iframe width="638" height="358" src="https://www.youtube.com/embed/i12LYlt07sI" frameborder="0" allowfullscreen></iframe>[/embed] [embed=425,349]<iframe width="560" height="315" src="https://www.youtube.com/embed/qpn6f1u_NL4" frameborder="0" allowfullscreen></iframe>[/embed]
  14. Vanilla 1.8.9 works fine, however Forge crashes before reaching the main menu without any mods installed. These were all the logs I could find: EDIT: This could be a bug with the graphics drivers. I will test this and report back. SOLVED: by switching form an open source (nouveau) graphics driver to a proprietary (nvidia) driver. (Linux Mint 17.3) Game Output: hs_err_pid4379.log:
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.