Players above terrain
by Skylar Kelty · in Torque Game Engine · 09/04/2006 (12:31 pm) · 8 replies
Hi,
Im having a problem where the players seem to hover one torque unit above the terrain.
Its an issue in stock TGE I believe.
To be honest I hav'nt looked into it but i'd be grateful if any of you have any ideas.
Thanks,
James
Im having a problem where the players seem to hover one torque unit above the terrain.
Its an issue in stock TGE I believe.
To be honest I hav'nt looked into it but i'd be grateful if any of you have any ideas.
Thanks,
James
About the author
#2
09/05/2006 (12:54 am)
Its fluffy
#3
The player uses a bounding box to determine collision, which doesn't conform to the terrain. Picture a box sitting flat on an angled surface, part of the box will be floating in mid air.
You might be able to trim down the size of the bounding box to help alleviate the problem but don't go too far or things like collision and shadows will break.
This picture should help illustrate the problem:
09/05/2006 (3:12 am)
It's not a bug; it's just old school collision detection at its best ;)The player uses a bounding box to determine collision, which doesn't conform to the terrain. Picture a box sitting flat on an angled surface, part of the box will be floating in mid air.
You might be able to trim down the size of the bounding box to help alleviate the problem but don't go too far or things like collision and shadows will break.
This picture should help illustrate the problem:
#4
Might re-write the player collision so it takes the bouding box and then moves the player down 1 TU,
do you think thats a good idea though? Like you said, shadows might break and render below the terrain.
09/05/2006 (8:14 am)
Thanks Tim.Might re-write the player collision so it takes the bouding box and then moves the player down 1 TU,
do you think thats a good idea though? Like you said, shadows might break and render below the terrain.
#5
09/05/2006 (9:01 am)
I wouldn't worry about it, most people won't even notice in the heat of battle.
#6
09/05/2006 (9:05 am)
I just like everything to be perfect, maybe ill do it for DawnOfMen 2
#7
09/09/2006 (4:38 am)
If you do I would really like to see what you come up with since I think your solution might help me with an issue I am having like this, but with objects affected by real-time terrain deformation.
#8
For my next game though, terrain deformation will be implemented and so ill have to come up with a solution for that problem, shouldnt be too hard
09/09/2006 (4:49 am)
Anything I come up with for this wont help you with thatFor my next game though, terrain deformation will be implemented and so ill have to come up with a solution for that problem, shouldnt be too hard
Torque Owner AllynMcelrath