Jump to content

Recommended Posts

Posted

Hi!

I really would like myself understand the answer on my question but two hours later was never able understand.

As seen from the title of the topic, I'm experimenting with shrubs.

 

My class code: http://pastebin.com/cG7jZTZU

 

When RenderType is "0" bush block in the inventory and on the ground looks like a block with the correct texture bush. (Meta read correct)

[spoiler=Img1]6aWfPenTYqc.jpg

 

 

When RenderType is "1" all the bushes blocks in the inventory look like dead bush, but on the ground look correct. (Meta read not correct)

[spoiler=Img2]PqyCrWJ3OEw.jpg

 

 

What am I doing wrong?

Posted

Hi, thanks for answer!

 

I wanted to make a block with three different sprites with different indexes metadata. But I got three of the same block with the same sprite.

I do not understand why the unit inherited from class "Block" with established RenderType: "1", in three blocks with different indices Metadata uses the same sprite for texture.

 

I wrote the code at the example taken here:

https://bitbucket.org/godshawk/isis/src/d4ed632ec2b69e93bbd5ab1865491e4e6f1090c2/minecraft/net/minecraft/block/BlockTallGrass.java?at=master

Posted

Hi

 

OK, so if I understand your question:

With renderType 1, the blocks on the ground are fine (deadbush, tallgrass, fern) but the ones in the inventory (on the creative tab) are all deadbush?

 

I don't see an obvious reason for that.

 

I'd suggest you put a breakpoint into getRenderType (returning 1) while viewing the inventory, then trace out into the vanilla code to see why it's not using the damage (meta) value.

 

-TGG

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.