Jump to content

2 small problems :)


Recommended Posts

Hey, it's me again :P



I've got 2 questions:


1st -> im holding a stack of 5 items (new item), it's a soup. When I eat one, all others just disappear and left is only 1 bowl :/

i jsut don't get it, i set it's stack size to 5 >.<

here's the Item:

public class Soup extends ItemSoup

        public Soup(int id)
                super(id, 6);
        public void func_94581_a(IconRegister iconRegister)
            iconIndex = iconRegister.func_94245_a("east_crips:x-4ns");



and 2nd -> I want translations for my item's names. So i went out, looking wor a solution and found a forum post.

I did it like this, but it's not working. it's not changing when i set the lang. to german. Is it correct like this? ...

LanguageRegistry.addName(Soup, "Soup");
LanguageRegistry.instance().addStringLocalization("Soup.name", "de_DE", "Suppe");


I just can't find a solution for all this, trying to do as much as i can alone to get more into it.. but hey, everyone needs some help at the beginning of something.. i guess.. ^^





Link to comment
Share on other sites

you have extended itemsoup with your food class and that can only have a stack of one and is programmed when eaten to replace the soup stack(1) with a bowl stack(1) so you just have to make your food item a single stack or just extend itemfood instead but then you might have to change some of your classes code.

Use examples, i have aspergers.

Examples make sense to me.

Link to comment
Share on other sites

//EDIT: just figured it out myself :) ".name" was missing in key.

For all the people who might have the same problem and search for an answer,

it should look like this:

(Unlocalized name is "Soup")
LanguageRegistry.addName(Soup, "Soup");
LanguageRegistry.instance().addStringLocalization("item.Soup.name", "de_DE", "Suppe");




right now, it's like this:


(Unlocalized name is "Soup")
LanguageRegistry.addName(Soup, "Soup");
LanguageRegistry.instance().addStringLocalization("item.Soup", "de_DE", "Suppe");

but when i run minecraft, there's no name when im hovering over it. why? i dont know :D

this is weird.. someone help me please :)

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.

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.

  • Create New...

Important Information

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