Nice , but that other way that is posted is better , as some sprites require a different way to be loaded , such as client , class44 and class30 subs.
|
|
YA YA,
I don't think this has been posted before.
So I'm gonna teach you how to load custom Sprites
.tep 1:.
First find the name of the sprite you want. I will use STATICONS 0.
.tep 2:.
Open up: Class30_Sub2_Sub1_Sub1
.tep 3:.
Next press Ctrl+F and search for layout.
.tep 4:.
Now underneath the last } of that we need to tell the client to load the sprites.
So use this as an example for STATICONS 0:
Notice the STATICONS and the 0 are in different places, watch for that!else if (s.equalsIgnoreCase("STATICONS") && i == 0)
{
try
{
Image image = Toolkit.getDefaultToolkit().getImage("./sprites/"+s+" "+i+".png"); //System.getProperty("user.dir") + "\\"+i+".png");
anIntArray1439 = new int[anInt1440 * anInt1441];
PixelGrabber pixelgrabber = new PixelGrabber(image, 0, 0, anInt1440, anInt1441, anIntArray1439, 0, anInt1440);
pixelgrabber.grabPixels();
//System.out.println(s+" "+i+".png"+ " hopefully loaded");
}
catch (Exception exception)
{
System.out.println(((Object) (exception)));
}
}
.tep 5:.
Replace the above with the name of your sprites,
and you done!You can now load custom sprites
I don't know if you can do this another way, but this is how I just found out today
Nice , but that other way that is posted is better , as some sprites require a different way to be loaded , such as client , class44 and class30 subs.
by this I mean normal sprites like stat icons etc
If You think that this has been posted alredy, your wrong, people have the wrong idea about "Sprites", Sprites are the little icons E.G, Buttons, Icons, Tabs Etc.
Images are things like the Gameframe...





Wow didnt realise it was that easy, thanks so much, rep 4 u!
hey its about time u do something xD uv been gone for so longanyhoo nice tut i knew how to do some of it but this summed it up
thanks




| « "Fixing" Lord Gliomaru's sinful prayer pack | Npc Bundle 2 (Issue four) » |
| Thread Information |
Users Browsing this ThreadThere are currently 1 users browsing this thread. (0 members and 1 guests) |