Jump to content

Mod crashes when I try to place a custom fire block


WolfAmaril

Recommended Posts

I have absolutely no idea why this thing is breaking (I'm using modding as a way to teach myself Java as the professor at my school was next to useless)

 

This is the crash log I get

 

[10:17:53] [Client thread/INFO] [sTDOUT]: [net.minecraft.client.Minecraft:displayCrashReport:388]: ---- Minecraft Crash Report ----

// Hey, that tickles! Hehehe!

 

Time: 12/14/14 10:17 AM

Description: Unexpected error

 

java.lang.ClassCastException: com.wolfamaril.coloredflame.block.BlockFireColoredBlack cannot be cast to net.minecraft.block.BlockFire

at net.minecraft.client.renderer.RenderBlocks.renderBlockByRenderType(RenderBlocks.java:363)

at net.minecraft.client.renderer.WorldRenderer.updateRenderer(WorldRenderer.java:207)

at net.minecraft.client.renderer.RenderGlobal.updateRenderers(RenderGlobal.java:1618)

at net.minecraft.client.renderer.EntityRenderer.renderWorld(EntityRenderer.java:1263)

at net.minecraft.client.renderer.EntityRenderer.updateCameraAndRender(EntityRenderer.java:1087)

at net.minecraft.client.Minecraft.runGameLoop(Minecraft.java:1056)

at net.minecraft.client.Minecraft.run(Minecraft.java:951)

at net.minecraft.client.main.Main.main(Main.java:164)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:606)

at net.minecraft.launchwrapper.Launch.launch(Launch.java:135)

at net.minecraft.launchwrapper.Launch.main(Launch.java:28)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:606)

at GradleStart.bounce(GradleStart.java:107)

at GradleStart.startClient(GradleStart.java:100)

at GradleStart.main(GradleStart.java:55)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:606)

at com.intellij.rt.execution.application.AppMain.main(AppMain.java:134)

 

 

A detailed walkthrough of the error, its code path and all known details is as follows:

---------------------------------------------------------------------------------------

 

-- Head --

Stacktrace:

at net.minecraft.client.renderer.RenderBlocks.renderBlockByRenderType(RenderBlocks.java:363)

at net.minecraft.client.renderer.WorldRenderer.updateRenderer(WorldRenderer.java:207)

at net.minecraft.client.renderer.RenderGlobal.updateRenderers(RenderGlobal.java:1618)

at net.minecraft.client.renderer.EntityRenderer.renderWorld(EntityRenderer.java:1263)

 

-- Affected level --

Details:

Level name: MpServer

All players: 1 total; [EntityClientPlayerMP['Player580'/23, l='MpServer', x=-1148.50, y=65.62, z=-14.50]]

Chunk stats: MultiplayerChunkCache: 531, 531

Level seed: 0

Level generator: ID 01 - flat, ver 0. Features enabled: false

Level generator options:

Level spawn location: World: (-1151,4,-12), Chunk: (at 1,0,4 in -72,-1; contains blocks -1152,0,-16 to -1137,255,-1), Region: (-3,-1; contains chunks -96,-32 to -65,-1, blocks -1536,0,-512 to -1025,255,-1)

Level time: 700 game time, 700 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: creative (ID 1). Hardcore: false. Cheats: false

Forced entities: 1 total; [EntityClientPlayerMP['Player580'/23, l='MpServer', x=-1148.50, y=65.62, z=-14.50]]

Retry entities: 0 total; []

Server brand: fml,forge

Server type: Integrated singleplayer server

Stacktrace:

at net.minecraft.client.multiplayer.WorldClient.addWorldInfoToCrashReport(WorldClient.java:415)

at net.minecraft.client.Minecraft.addGraphicsAndWorldToCrashReport(Minecraft.java:2555)

at net.minecraft.client.Minecraft.run(Minecraft.java:980)

at net.minecraft.client.main.Main.main(Main.java:164)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:606)

at net.minecraft.launchwrapper.Launch.launch(Launch.java:135)

at net.minecraft.launchwrapper.Launch.main(Launch.java:28)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:606)

at GradleStart.bounce(GradleStart.java:107)

at GradleStart.startClient(GradleStart.java:100)

at GradleStart.main(GradleStart.java:55)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:606)

at com.intellij.rt.execution.application.AppMain.main(AppMain.java:134)

 

-- System Details --

Details:

Minecraft Version: 1.7.10

Operating System: Windows 7 (amd64) version 6.1

Java Version: 1.7.0_60, Oracle Corporation

Java VM Version: Java HotSpot 64-Bit Server VM (mixed mode), Oracle Corporation

Memory: 838836848 bytes (799 MB) / 1037959168 bytes (989 MB) up to 1037959168 bytes (989 MB)

JVM Flags: 3 total; -Xincgc -Xmx1024M -Xms1024M

AABB Pool Size: 0 (0 bytes; 0 MB) allocated, 0 (0 bytes; 0 MB) used

IntCache: cache: 0, tcache: 0, allocated: 0, tallocated: 0

FML: MCP v9.05 FML v7.10.85.1230 Minecraft Forge 10.13.2.1230 4 mods loaded, 4 mods active

mcp{9.05} [Minecraft Coder Pack] (minecraft.jar) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available

FML{7.10.85.1230} [Forge Mod Loader] (forgeSrc-1.7.10-10.13.2.1230.jar) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available

Forge{10.13.2.1230} [Minecraft Forge] (forgeSrc-1.7.10-10.13.2.1230.jar) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available

ColoredFlame{1.7.10-1.0.0} [Colored Flame] (ColoredFlame) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available

Launched Version: 1.7.10

LWJGL: 2.9.1

OpenGL: GeForce GTX 765M/PCIe/SSE2 GL version 4.4.0 NVIDIA 344.75, NVIDIA Corporation

GL Caps: Using GL 1.3 multitexturing.

Using framebuffer objects because OpenGL 3.0 is supported and separate blending is supported.

Anisotropic filtering is supported and maximum anisotropy is 16.

Shaders are available because OpenGL 2.1 is supported.

 

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)

Vec3 Pool Size: 0 (0 bytes; 0 MB) allocated, 0 (0 bytes; 0 MB) used

Anisotropic Filtering: Off (1)

[10:17:53] [Client thread/INFO] [sTDOUT]: [net.minecraft.client.Minecraft:displayCrashReport:398]: #@!@# Game crashed! Crash report saved to: #@!@# C:\Users\Caleb\Desktop\Random Stuff\Minecraft\Mod Development\ColoredFlame\eclipse\.\crash-reports\crash-2014-12-14_10.17.53-client.txt

[10:17:53] [Client Shutdown Thread/INFO]: Stopping server

AL lib: (EE) alc_cleanup: 1 device not closed

 

Process finished with exit code -1

 

 

The code for my mod can be found here: https://github.com/WolfAmaril/ColoredFlame

Link to comment
Share on other sites

Y U NO WORK FIRE TXTURES

 

Because you never tell it what texture to use.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Link to comment
Share on other sites

Which is where I was last time the code came crashing down around my head. you wouldn't happen to know how to map fire textures, would you?

 

You missed the part where I don't know how to do that and am wondering if anyone could point me to somewhere that tells me how, didn't you?

Link to comment
Share on other sites

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Link to comment
Share on other sites

Having done so, I still can't see why the textures aren't working (At this point I suspect it's something really simple that I can't see).

 

The git repository I linked to in the OP contains the most recent version of my code, could someone who's not been working on it for 12 hours take a look and see if I'm missing something obvious?

Link to comment
Share on other sites

see if I'm missing something obvious?

 

Because you never tell it what texture to use.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Link to comment
Share on other sites

see if I'm missing something obvious?

 

Because you never tell it what texture to use.

 

I got that part.

One might assume that, since I'm still asking the question, I still haven't figured out how to tell it what texture to use.

one might also assume that, since you haven't given a helpful answer, you don't know how to tell it what texture to use either.

Link to comment
Share on other sites

fireBlack_Layer0.png

fireBlack_layer_0.png.mcmeta

 

Watch your capitalization. Also you have an additional underscore before your 0/1

Don't ask for support per PM! They'll get ignored! | If a post helped you, click the "Thank You" button at the top right corner of said post! |

mah twitter

This thread makes me sad because people just post copy-paste-ready code when it's obvious that the OP has little to no programming experience. This is not how learning works.

Link to comment
Share on other sites

One might assume that, since I'm still asking the question, I still haven't figured out how to tell it what texture to use.

one might also assume that, since you haven't given a helpful answer, you don't know how to tell it what texture to use either.

 

 

And I certainly do know how.  I'm just not going to write your code for you.

I've made several mods which involve textures.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Link to comment
Share on other sites

When you aren't even calling setTextureName, even after I tell you twice what you need to do so, I can't tell you what string you need to use to fix a missing texture problem.  You're using getTextureName in your IIcon registration, ergo you need to use setTextureName.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Link to comment
Share on other sites

would you be refering to the this.setTextureName("fireBlack"); in BlockFireColoredBlack.java inside the com.wolfamaril.coloredflame.block package or should I be calling it somewhere else?

 

Would you mean this class:

 

package com.wolfamaril.coloredflame.block;

public class BlockFireColoredBlack extends BlockFireColoredBase {
    public BlockFireColoredBlack()
    {
        super();
        this.setBlockName("fireBlack");
    }
}

 

Because if so, I do not see any calls to set the texture name.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Link to comment
Share on other sites

Ok, at this point either:

a) it will work

or

b) there will be a console error telling you what image could not be found.

 

Do double check that your meta files have the exact same name as the png, but with ".mcmeta" on the end, after the ".png".

 

Bad:

fireBlack_Layer0.png
fireBlack_layer_0.png.mcmeta //missing _
fireBlack_layer_0.mcmeta //missing .png
fireblack_layer0.png.mcmeta //different casing

 

Good:

fireBlack_Layer0.png
fireBlack_layer0.png.mcmeta

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Link to comment
Share on other sites

Add your mood id to the texture path.

"MODID:fireBlack"

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Link to comment
Share on other sites

OK, first off it's 31/32 working.

on the other hand, I challenge anyone to explain why one block, and one block only, looks like THIS

rr5c42.png

 

in my dev world and THIS

 

2r4mx5y.png

 

when I run [gradlew build] and put the jar in a test instance in minecraft.

I checked, the texture file and .mcmeta transferred over. how does half of one blocks' texture break when the mod is built?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

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