Bounding box coordinates in datablocks
by Martin Banks · in Torque 3D Professional · 08/27/2009 (1:50 pm) · 5 replies
What frame of reference is used to define the coordinates of a bounding box in a datablock? I am having trouble defining them for a character that I have created. Examples of how others have done this successfully would be useful.
Thanks is advance.
Thanks is advance.
About the author
#2
08/27/2009 (2:17 pm)
Thanks Michael, that was the method that I have employed. I was hoping to either have a way to simply select and scale the bounding box by eye, or to get some coordinate reference so I could calculate it based on the object's dimensions.
#3
08/27/2009 (3:36 pm)
You should be able to modify the datablock's bounds from the console ( or probably the datablock editor ) and then re-assign the same datablock on your player from the inspector ( to get onNewDataBlock triggered ).
#4
I have a character whose bounding box is not centered. Is there a way I can move the center?
08/28/2009 (12:02 pm)
Awesome that will work.I have a character whose bounding box is not centered. Is there a way I can move the center?
#5
08/30/2009 (11:18 pm)
Not without some code changes. You could add a new field to the PlayerData datablock, then modify where the bounding box is calculated in Player::onNewDataBlock. Just look at one of the existing fields (like boxSize) to see what to change.
Associate Michael Hall
Distracted...
Now for the tedious bit... exit the game and make your change(s) to the boundingbox setting(s) in the datablock. Restart and check your new bounding box.