Jump to content

[SOLVED]sprite problem


tuskiomi

Recommended Posts

hello all, and thanks for reading my second post.

i have been forge coding for a week now and i am having trouble with PNGs and graphics.

basically its the way the png is formatted, i cannot get the "grid" onto the png much less load the code

if someone could tell me how to so this it would mean alot.

download: http://i1176.photobucket.com/albums/x331/tuskiomi/mithril_zps4c5bb4f8.png

Also, I should have you know that you are reading my signature.

Link to comment
Share on other sites

Okay so what you mean is that you want to create an image with a grid and you can't create the grid somehow?

Using a program like paint.net or photoshop or similar that can easly be done, just get some paint program and find some tutoprial on it via google :)

 

but I assume you want to create a texture file to contain your textures?

Can't you just use the original terrain file or something like this http://www.minecraftwiki.net/images/7/78/TerrainGuide.png

and just copy your textures onto the grid at the locations you want them to be?

If you guys dont get it.. then well ya.. try harder...

Link to comment
Share on other sites

Minecraft will soon(as of 1.5) have separate .png files for EVERY block!

Take a look at http://www.minecraftwiki.net/wiki/Texture_Packs#Textures_for_Blocks_and_Items_in_Minecraft_1.5

for more information on the new system, it's pretty awesome and will allow for easily custom animated block textures!

 

Starting from Minecraft 1.5, or snapshot 13w02a specifically, the "terrain.png" and "gui/items.png" files will be replaced by individual block and item images (sheet images). These individual images will be "stitched" together again at runtime, which will make sure that the default artwork is used if images are missing in the selected texture pack.

If you guys dont get it.. then well ya.. try harder...

Link to comment
Share on other sites

Okay so what you mean is that you want to create an image with a grid and you can't create the grid somehow?

Using a program like paint.net or photoshop or similar that can easly be done, just get some paint program and find some tutoprial on it via google :)

 

but I assume you want to create a texture file to contain your textures?

Can't you just use the original terrain file or something like this http://www.minecraftwiki.net/images/7/78/TerrainGuide.png

and just copy your textures onto the grid at the locations you want them to be?

i use paint .net and  for my mod im using an individual file. when i open my mod in eclipse i get this:

http://s1176.beta.photobucket.com/user/tuskiomi/media/blockerror_zps18a9792a.png.html

Also, I should have you know that you are reading my signature.

Link to comment
Share on other sites

Ah that texture is quite weird, but it's the "Error texture". This is the texture your block gets when it couldn't find the texture you told it to have. So you should check your code for what path you told it to find your texture inn, and for where you have it saved innside your MCP folders.

If you guys dont get it.. then well ya.. try harder...

Link to comment
Share on other sites

update: made a noob mistake and fixed that (i forgot the / in the file path)

still my texture continues to haunt me as it has yet another error:

http://s1176.beta.photobucket.com/user/tuskiomi/media/blockerror2_zps7801f73b.png.html

the ore is supposed to look like http://s1176.beta.photobucket.com/user/tuskiomi/media/mithril_zps4c5bb4f8.png.html?sort=3&o=2

Also, I should have you know that you are reading my signature.

Link to comment
Share on other sites

You generally start by putting the image in the top left corner, the first 16x16 pixel square at the top is '0' code wise, so you'd put that in as the parameter, then it's 1 for the 16x16 to the right of it and so on, basically it's reading the white space in your texture sheet not the texture that's located in the middle.

Link to comment
Share on other sites

You generally start by putting the image in the top left corner, the first 16x16 pixel square at the top is '0' code wise, so you'd put that in as the parameter, then it's 1 for the 16x16 to the right of it and so on, basically it's reading the white space in your texture sheet not the texture that's located in the middle.

here is the sample of my basic block

 

 

 

public class Blockrainbowwool extends Block {
public Blockrainbowwool(int ID){
super(ID,Material.rock); //<-is this a problem?
setTextureFile("/tuskiomi/modsheet.png"); //The texture file used
setBlockName("mithril"); 
setHardness(3.0F); 
setResistance(5.0F);
setCreativeTab(CreativeTabs.tabBlock);

}



public int getBlockTextureFromSide(int par1)
{
    return 0;//same texture for all sides
}

also i am still having trouble with spritesheets, do i have to edit where the devidiant between the different blocks are? i created the sheet in MS paint but then finished it in paint.net, is that okay? and can i store all items and blocks on one sheet?

Also, I should have you know that you are reading my signature.

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.



×
×
  • Create New...

Important Information

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