Jump to content

How to paint NPC?


massih

Recommended Posts

Can I also use this method to paint the NPC it self on the screen instead of on the minimap?

 

For that you would do something like:

g.fill(npc.getModel().getBoundingBox(npc.getGridX(), npc.getGridY(), npc.getZ()));

Note: use g.fill to create a filled in rectangle, or g.draw if you just want the outline.

Edited by Explv
Link to comment
Share on other sites

It's been a while since I've played with these methods, but if I remember correctly there is a drawModel() method.

 

When you click the [x] NPCs debug option, it draws an outline around all NPC models in the game. I reversed OSBot and inserted code to see how it was doing this; there is an internal method called something like:

 

GraphicUtilities.drawModel(obj, color, x, y)

 

I am just going off memory here, but it was definitely the GraphicUtilities class.

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
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  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.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...