Jump to content

51 errors after updating my Forge


trulis

Recommended Posts

A lot of this is because of the recent changes regarding textures. (Which I am definitely not a fan of. I hate having hundreds of files for what could've fit in two.)

 

"The method setItemName(String)/setBlockName(String) is undefinded for the type Item/Block":

Whereever you are using setItemName(String) or setBlockName(String), replace that with setUnlocalizedName(String). This should fix it. Same goes for getItem/BlockName(String), just use getUnlocalizedName(String).

 

"The constructor Block(int, int, Material) is undefined":

In your BlockWhatever classes, your constructors are probably looking like this right now:

public BlockWhatever(int par1, int par2, Material par3Material) {
    super(par1, par2, par3Material);
}

You need to change it to look like this:

public BlockWhatever(int par1, Material par2Material) {
    super(par1, par2Material);
}

Of course you will have to get rid of the second parameter when declaring your blocks as well then.

 

With the other stuff, I can't help you since I haven't figured that new texture stuff my self yet.

Link to comment
Share on other sites

Thanks Saphirian, that solved a bunch of my compile errors as well. Let us know when you figure out the new texture stuff. As far as I can tell, the function

public int getIconFromDamage(int par1)

needs to be

public Icon getIconFromDamage(int par1)

but I cant figure out how to create said Icon relevant to my items/blocks to return in that function.

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.