• Recently Browsing

    No registered users viewing this page.

  • Posts

    • How would I go about searching for srg names inside my IDE (IDEA)? It sounds far easier than using discord or irc.
    • I've been trying to install ATM3 (All The Mods 3) on Forge, I am using  1.12.2 forge. Even though I put the ATM3 folder inside the Minecraft mod folder, the mod won't appear on Minecraft.
    • Well, for options one and two you're right, but for option three? I know there's an option to have the model for handheld items/dropped items be different than the model used in the inventory. How would I tackle that?   And if that isn't good enough, where would I start if I wanted to hack the itemstack UI renderer? Is there documentation for this?
    • I checked out his tutorials, but I don't think they will work in my case. The cubes that I am rendering are not custom TileEntities as they need to be rendered in any possible position. Using the RenderWorldLastEvent#getMatrixStack doesn't seem to have a matrix stack I can manipulate to get what I want. I ended up finding a solution which works, but uses the now deprecated GlStateManager methods.   Render Entry @SubscribeEvent public static void onWorldRender(RenderWorldLastEvent event) { // Grab Minecraft instance and check if player exists (in world). Minecraft mc = Minecraft.getInstance(); ClientPlayerEntity player = mc.player; if(player == null) return; ActiveRenderInfo info = mc.gameRenderer.getActiveRenderInfo(); CubeBatch batch = new CubeBatch(); batch.begin(info.getProjectedView(), info.getPitch(), info.getYaw()); for(ICubeScene scene : scenes) { if(!scene.isVisible()) continue; scene.render(batch, player, event.getPartialTicks()); } batch.end(); }   Rendering Process @SuppressWarnings("deprecation") public final class CuRender { private static boolean rendering = false; /** * Sets up the OpenGL environment for rendering in world space. * @param origin - Origin of the camera (typically player's eye position). */ public static void begin(Vec3d origin, Vec2f angle) { if(rendering) throw new IllegalStateException("Cannot begin while rendering."); rendering = true; GlStateManager.pushMatrix(); GlStateManager.rotatef(angle.x, 1, 0, 0); // Fixes camera rotation. GlStateManager.rotatef(angle.y + 180, 0, 1, 0); // Fixes camera rotation. GlStateManager.translated(0.5 - origin.x, 0.5 - origin.y, 0.5 - origin.z); GlStateManager.disableDepthTest(); GlStateManager.disableTexture(); GlStateManager.disableLighting(); GlStateManager.enableBlend(); GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA); } /** * Returns the OpenGL environment back to normal. */ public static void end() { if(!rendering) return; GlStateManager.disableBlend(); GlStateManager.enableLighting(); GlStateManager.enableTexture(); GlStateManager.enableDepthTest(); GlStateManager.popMatrix(); rendering = false; } /** * Renders the cube in world space. * @param cube */ public static void cube(Cube cube) { GlStateManager.pushMatrix(); // Position GlStateManager.translated(cube.getX(), cube.getY(), cube.getZ()); // Rotate GlStateManager.translated(cube.getOriginX() / 2, cube.getOriginY() / 2, cube.getOriginZ() / 2); GlStateManager.rotatef(-cube.getYaw(), 0, 1, 0); GlStateManager.rotatef(cube.getPitch(), 1, 0, 0); GlStateManager.scaled(cube.getScaleX(), cube.getScaleY(), cube.getScaleZ()); // Scale GlStateManager.translated(-cube.getOriginX() / 2, -cube.getOriginY() / 2, -cube.getOriginZ() / 2); GlStateManager.scaled(0.5, 0.5, 0.5); // Normalize if(cube.isWired()) { // Wire Cube renderEdges(cube.getWireColor(), null); } else if(cube.isSolid()) { // Solid Cube for(int i = 0; i < UnitCube.FACE_COUNT; i++) { Face face = UnitCube.FACES[i]; quad(cube.getFaceColor(i), face.v1, face.v2, face.v3, face.v4); } } else { // Mixed Cube boolean[] removedEdge = new boolean[UnitCube.EDGE_COUNT]; for(int i = 0; i < UnitCube.FACE_COUNT; i++) { if(!cube.isFaceSolid(i)) continue; Face face = UnitCube.FACES[i]; quad(cube.getFaceColor(i), face.v1, face.v2, face.v3, face.v4); quad(cube.getFaceColor(i), face.v1, face.v4, face.v3, face.v2); for(Edge edge : face.edges) { int j = UnitCube.getEdgeIndex(edge); removedEdge[j] = true; } } renderEdges(cube.getWireColor(), removedEdge); } GlStateManager.popMatrix(); } private static void renderEdges(Color4f color, boolean[] removedEdges) { glColor4f(color); GL11.glBegin(GL11.GL_LINES); for(int i = 0; i < UnitCube.EDGE_COUNT; i++) { if(removedEdges != null && removedEdges[i]) continue; Edge edge = UnitCube.EDGES[i]; glVertex3d(edge.v1); glVertex3d(edge.v2); } GL11.glEnd(); } /** * Renders a quad with the specified vertices. OpenGL must be in GL_QUADS mode to work. * @param v1 * @param v2 * @param v3 * @param v4 */ public static void quad(Color4f color, Vec3d v1, Vec3d v2, Vec3d v3, Vec3d v4) { glColor4f(color); GL11.glBegin(GL11.GL_QUADS); glVertex3d(v1); glVertex3d(v2); glVertex3d(v3); glVertex3d(v4); GL11.glEnd(); } private static void glVertex3d(Vec3d v) { GL11.glVertex3d(v.x, v.y, v.z); } private static void glColor4f(Color4f c) { GL11.glColor4f(c.r, c.g, c.b, c.a); } }   This code is mostly 1.12 code, but 1.15 didn't maintain the player head rotation in the matrix. Passing in the pitch and yaw I was able to rotate the matrix to have the illusion of world space rendering.
    • Hello guys , I have a problem , can you tell me what is it? here is the crash !  ---- Minecraft Crash Report ---- // Don't be sad, have a hug! ❤️ Time: 2/21/20 2:27 PM Description: Unexpected error java.lang.NullPointerException: Unexpected error     at net.minecraft.client.multiplayer.PlayerControllerMP.func_78750_j(PlayerControllerMP.java:373)     at net.minecraft.client.multiplayer.PlayerControllerMP.func_78765_e(PlayerControllerMP.java:346)     at net.minecraft.client.Minecraft.func_71407_l(Minecraft.java:1723)     at net.minecraft.client.Minecraft.func_71411_J(Minecraft.java:1097)     at net.minecraft.client.Minecraft.func_99999_d(Minecraft.java:397)     at net.minecraft.client.main.Main.main(SourceFile:123)     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)     at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)     at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)     at java.lang.reflect.Method.invoke(Unknown Source)     at net.minecraft.launchwrapper.Launch.launch(Launch.java:135)     at net.minecraft.launchwrapper.Launch.main(Launch.java:28) A detailed walkthrough of the error, its code path and all known details is as follows: --------------------------------------------------------------------------------------- -- Head -- Thread: Client thread Stacktrace:     at net.minecraft.client.multiplayer.PlayerControllerMP.func_78750_j(PlayerControllerMP.java:373)     at net.minecraft.client.multiplayer.PlayerControllerMP.func_78765_e(PlayerControllerMP.java:346) -- Affected level -- Details:     Level name: MpServer     All players: 0 total; []     Chunk stats: MultiplayerChunkCache: 0, 0     Level seed: 0     Level generator: ID 00 - default, ver 1. Features enabled: false     Level generator options:      Level spawn location: World: (8,64,8), Chunk: (at 8,4,8 in 0,0; contains blocks 0,0,0 to 15,255,15), Region: (0,0; contains chunks 0,0 to 31,31, blocks 0,0,0 to 511,255,511)     Level time: 0 game time, 0 day time     Level dimension: 0     Level storage version: 0x00000 - Unknown?     Level weather: Rain time: 0 (now: false), thunder time: 0 (now: false)     Level game mode: Game mode: survival (ID 0). Hardcore: false. Cheats: false     Forced entities: 0 total; []     Retry entities: 0 total; []     Server brand: ~~ERROR~~ NullPointerException: null     Server type: Non-integrated multiplayer server Stacktrace:     at net.minecraft.client.multiplayer.WorldClient.func_72914_a(WorldClient.java:420)     at net.minecraft.client.Minecraft.func_71396_d(Minecraft.java:2740)     at net.minecraft.client.Minecraft.func_99999_d(Minecraft.java:426)     at net.minecraft.client.main.Main.main(SourceFile:123)     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)     at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)     at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)     at java.lang.reflect.Method.invoke(Unknown Source)     at net.minecraft.launchwrapper.Launch.launch(Launch.java:135)     at net.minecraft.launchwrapper.Launch.main(Launch.java:28) -- System Details -- Details:     Minecraft Version: 1.12.2     Operating System: Windows 10 (x86) version 10.0     Java Version: 1.8.0_231, Oracle Corporation     Java VM Version: Java HotSpot(TM) Client VM (mixed mode), Oracle Corporation     Memory: 338744568 bytes (323 MB) / 749285376 bytes (714 MB) up to 1060372480 bytes (1011 MB)     JVM Flags: 6 total; -XX:HeapDumpPath=MojangTricksIntelDriversForPerformance_javaw.exe_minecraft.exe.heapdump -XX:+UseConcMarkSweepGC -XX:+CMSIncrementalMode -XX:-UseAdaptiveSizePolicy -Xmn128m -Xmx1024m     IntCache: cache: 0, tcache: 0, allocated: 0, tallocated: 0     FML: MCP 9.42 Powered by Forge 14.23.5.2768 11 mods loaded, 11 mods active     States: 'U' = Unloaded 'L' = Loaded 'C' = Constructed 'H' = Pre-initialized 'I' = Initialized 'J' = Post-initialized 'A' = Available 'D' = Disabled 'E' = Errored     | State  | ID                 | Version           | Source                              | Signature                                |     |:------ |:------------------ |:----------------- |:----------------------------------- |:---------------------------------------- |     | UCHIJA | minecraft          | 1.12.2            | minecraft.jar                       | None                                     |     | UCHIJA | mcp                | 9.42              | minecraft.jar                       | None                                     |     | UCHIJA | FML                | 8.0.99.99         | forge-1.12.2-14.23.5.2768.jar       | e3c3d50c7c986df74c645c0ac54639741c90a557 |     | UCHIJA | forge              | 14.23.5.2768      | forge-1.12.2-14.23.5.2768.jar       | e3c3d50c7c986df74c645c0ac54639741c90a557 |     | UCHIJA | chameleon          | 1.12-4.1.3        | Chameleon-1.12-4.1.3 (3).jar        | None                                     |     | UCHIJA | flansmod           | 5.5.2             | Flan's Mod-1.12.2-5.5.2.jar         | None                                     |     | UCHIJA | flansmodapocalypse | 1.0               | Flan's Mod-1.12.2-5.5.2.jar         | None                                     |     | UCHIJA | cfm                | 6.3.1             | furniture-6.3.1-1.12.2.jar          | None                                     |     | UCHIJA | ironchest          | 1.12.2-7.0.67.844 | ironchest-1.12.2-7.0.72.847.jar     | None                                     |     | UCHIJA | journeymap         | 1.12.2-5.5.9      | journeymap-1.12.2-5.5.9.jar         | None                                     |     | UCHIJA | storagedrawers     | 1.12.2-5.4.0      | StorageDrawers-1.12.2-5.4.0 (1).jar | None                                     |     Loaded coremods (and transformers):      GL info: ' Vendor: 'Intel' Version: '4.4.0 - Build 21.20.16.4821' Renderer: 'Intel(R) HD Graphics 520'     Launched Version: 1.12.2     LWJGL: 2.9.4     OpenGL: Intel(R) HD Graphics 520 GL version 4.4.0 - Build 21.20.16.4821, Intel     GL Caps: Using GL 1.3 multitexturing. Using GL 1.3 texture combiners. Using framebuffer objects because OpenGL 3.0 is supported and separate blending is supported. Shaders are available because OpenGL 2.1 is supported. VBOs are available because OpenGL 1.5 is supported.     Using VBOs: Yes     Is Modded: Definitely; Client brand changed to 'fml,forge'     Type: Client (map_client.txt)     Resource Packs:      Current Language: English (US)     Profiler Position: N/A (disabled)     CPU: 4x Intel(R) Core(TM) i5-6200U CPU @ 2.30GHz
  • Topics

  • Who's Online (See full list)