A loader - Two problems

Discussion in 'Programming General' started by Coron, Sep 1, 2011.

A loader - Two problems
  1. Unread #1 - Sep 1, 2011 at 11:02 AM
  2. Coron
    Joined:
    Aug 9, 2009
    Posts:
    287
    Referrals:
    0
    Sythe Gold:
    0

    Coron Forum Addict
    Banned

    A loader - Two problems

    I'm currently playing around with loading RS and reflection. So far it's going well, I can reflect information like camera pitch and yaw. But I have two problems that I need help with.

    runescape.jar contains all the files I need, loader.jar does not. How can I reflect information like the camera pitch from loader.jar?

    Also, how can I paint on the client?

    Thanks, I hope I made my problems clear :p
     
  3. Unread #2 - Sep 1, 2011 at 8:58 PM
  4. Jimmy
    Joined:
    Jun 24, 2008
    Posts:
    2,421
    Referrals:
    10
    Sythe Gold:
    25

    Jimmy Ghost
    Retired Sectional Moderator $5 USD Donor

    A loader - Two problems

    You have to obtain the classloader instance responsible for loading the classes in runescape.jar. Calling the getClassLoader of the canvas class should accomplish this.

    Ex:
    Code:
    applet.getComponent(0).getClass().getClassLoader()
    As for painting on the canvas, you can do this by overriding the getGraphics() method of the parent class to the applet's canvas (either xboot java.awt.Canvas with your own overridden method or use a bytecode editing library to change the superclass of the canvas subclass in the client to your own custom class that paints onto the canvas's graphics).
     
  5. Unread #3 - Sep 1, 2011 at 10:40 PM
  6. itsboom
    Joined:
    May 7, 2010
    Posts:
    290
    Referrals:
    0
    Sythe Gold:
    0

    itsboom Forum Addict

    A loader - Two problems

    does runescape.jar instantiate loader.jar?
     
  7. Unread #4 - Sep 2, 2011 at 2:48 AM
  8. Jimmy
    Joined:
    Jun 24, 2008
    Posts:
    2,421
    Referrals:
    10
    Sythe Gold:
    25

    Jimmy Ghost
    Retired Sectional Moderator $5 USD Donor

    A loader - Two problems

    It's the other way around. Just decompile the loader and see what it does (it won't decompile perfectly, but you should get some idea what it does).
     
  9. Unread #5 - Sep 2, 2011 at 11:23 AM
  10. Coron
    Joined:
    Aug 9, 2009
    Posts:
    287
    Referrals:
    0
    Sythe Gold:
    0

    Coron Forum Addict
    Banned

    A loader - Two problems

    Thanks Jimmy!
     
< help with embedding a .jar to winows.forum | C++ Exercises + Problem >

Users viewing this thread
1 guest


 
 
Adblock breaks this site