Jump to content

Help!


The King

Recommended Posts

I tried making a polygon on the tree with the tree pos but it wasn't accurate and didnt cover/wrap the tree so if you want to do a bounding box or something instead it'd be something like

 
titan.draw(treevariable.getModel().getBoundingBox(treevariable.getGridX(), treevariable.getGridY(), treevariable.getZ()));
 

where titan. is my onPaint reference e.g (Graphics2D titan)

treevariable is your tree variable you get the gist 

I tried mate, sorry feels.png

 

if you do however want to still try the polygon stuff it's 

 

titan.draw(treevariable.getPosition().getPolygon(getBot()));

Edited by Saiyan
  • Like 1
Link to comment
Share on other sites

I tried making a polygon on the tree with the tree pos but it wasn't accurate and didnt cover/wrap the tree so if you want to do a bounding box or something instead it'd be something like

 
titan.draw(treevariable.getModel().getBoundingBox(treevariable.getGridX(), treevariable.getGridY(), treevariable.getZ()));
 

where titan. is my onPaint reference e.g (Graphics2D titan)

treevariable is your tree variable you get the gist 

I tried mate, sorry feels.png

 

if you do however want to still try the polygon stuff it's 

 

titan.draw(treevariable.getPosition().getPolygon(getBot()));

 

Thanks bro it works smile.png

 

From Alek's woodcutter (pieced together):

 

GraphicUtilities.getModelBoundingBox(bot, o.getGridX(), o.getGridY(), o.getZ(), o.getModel());
g.drawRect(rectangle.x, rectangle.y, rectangle.width, rectangle.height);

 

 

Bro thanks for that but it didn't work with me

correct me if i am wrong, 2d graphics is not working in the tree we need 3d.

Edited by The King
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...