Interior Scale and Collision
by Masser · in Torque Game Engine · 12/03/2007 (1:21 pm) · 13 replies
In World Editor, when you scale an interior (e.g. a complex item like a building), does the collision attached to it scale with it? This doesn't seem to be the case in my experiments so far, so I was wondering if I did something wrong. Thanks.
#2
Does it matter that I created the DIF in Cosntructor and exported as DIF (normal export)? This is my normal pipeline and I never had problems until now. Perhaps I just have more testing to do and I made a stupid mistake (like maybe the door was truly too small to walk through after scaling). Thanks for the feedback.
12/03/2007 (3:40 pm)
Hmmm... Interesting. I generally follow a world scale of my own too so I don't have to scale much, unless I want to for variety (and less objects). What brought on this realization was that I was trying an old trick of scaling an object -1 along the X axis (to get a mirrored object) and it seemed to have no collision to speak of. Then, just to test, I took the same DIF (a building with doors) and scaled it .75 and it seemed like the doors sealed up. Scaling it back to "1 1 1" brought the doors back instantly.Does it matter that I created the DIF in Cosntructor and exported as DIF (normal export)? This is my normal pipeline and I never had problems until now. Perhaps I just have more testing to do and I made a stupid mistake (like maybe the door was truly too small to walk through after scaling). Thanks for the feedback.
#3
12/03/2007 (3:45 pm)
Ive had these problems before and a simple mission reload has solved mines
#4
however 0.75 should be allright. are you it's not just that your player is now colliding w/ the edges of the smaller door ? i have a mission with DIFs scaled by 0.4, and the doors etc are all fine.
12/03/2007 (4:12 pm)
I wouldn't be surprised if a negative scale breaks DIFs,however 0.75 should be allright. are you it's not just that your player is now colliding w/ the edges of the smaller door ? i have a mission with DIFs scaled by 0.4, and the doors etc are all fine.
#5
I tried something I should have tried before, which was to scale down my player and bounding box the same amount I did the building. He goes through the doors fine.
The negative scaling trick will not work, of course, as this just seems to break the collision completely. Maybe I'll go digging through the engine code to see if this can be remedied.
Thanks everyone.
12/03/2007 (5:09 pm)
You guys are right. Sorry.I tried something I should have tried before, which was to scale down my player and bounding box the same amount I did the building. He goes through the doors fine.
The negative scaling trick will not work, of course, as this just seems to break the collision completely. Maybe I'll go digging through the engine code to see if this can be remedied.
Thanks everyone.
#6
sometimes that works, but i wouldn't bet on it.
eg X and Z.
12/03/2007 (5:53 pm)
You might try a negative scale on an even number of axes,sometimes that works, but i wouldn't bet on it.
eg X and Z.
#7
12/03/2007 (7:04 pm)
Orion: I thought you had something there. The suggestion was just weird enough that it might work. Unfortunately, it didn't. Plus, anything involving the Z axis results in an upside down building which is not the effect I was going for. Thanks for the attempt.
#8
12/03/2007 (9:26 pm)
Lol! well it was maybe worth a shot. but i'm curious; did the basic collision stuff work ?
#9
12/03/2007 (9:59 pm)
Orion: I'm not sure what you mean by "basic collision" but when I do a negative scale on any axis (or 2 or all 3), there seems to be NO collision at all. I can walk right through the building.
#10
12/03/2007 (10:05 pm)
Gotcha. well, ce la vie. by basic collision i mean just like being able to walk on a surface but it sounds like that didn't work.
#11
I'll have to try it out on things that I know work.
12/04/2007 (6:26 am)
You're using the patched version of Constructor 1.03, right? I can't remember. I've pointed so many people to it. It fixed a number of collision issues.I'll have to try it out on things that I know work.
#12
If the DIF seems to have proper collision when scaled to "1 1 1" and ".75 .75 .75" in World Editor, but not at "-1 1 1", is there reason to believe that Constructor is to blame? Is it maybe a bug in the engine?
Thank you for your help.
12/04/2007 (7:37 am)
If you mean the version of 1.0.3 where I had to download the seperate EXE and overwrite my installed 1.0.3 version, then yes. Is there a more current version?If the DIF seems to have proper collision when scaled to "1 1 1" and ".75 .75 .75" in World Editor, but not at "-1 1 1", is there reason to believe that Constructor is to blame? Is it maybe a bug in the engine?
Thank you for your help.
#13
12/04/2007 (7:51 am)
I was just making sure that you had the patched EXE and that it wasn't the issue. It seems like an engine issue with negative scaling.
Associate David Montgomery-Blake
David MontgomeryBlake