Jumping questions
by Levi Walton · in Torque Game Builder · 08/31/2006 (9:38 am) · 3 replies
I used the mini platformer tutorial, and the juming and movement is fine, except if i jump against a wall the player will either jump the entire height of the wall regardless of height, or with attach to the wall and climb slowly up. i believe everything has been entered just like the tutorial. is this a problem that the tut doesnt cover (or possibly my error, if this has worked without a hitch for everyone else).
i think its just detecting a collision and telling it to jump. is there a way to detect a collision on the basis of angle. ex. if the collision is at "x" angle jump is false?
ive been through several posts and havent seen a similar problem but if i have missed it, please direct me there.
thanks for any help
i think its just detecting a collision and telling it to jump. is there a way to detect a collision on the basis of angle. ex. if the collision is at "x" angle jump is false?
ive been through several posts and havent seen a similar problem but if i have missed it, please direct me there.
thanks for any help
#2
from what ive read, apparently you can determine the surface normal on collision, so that tells me you should be able to say that if the collision is with a vertical surface that the player cant run up that surface.
ive looked at the other platformer tutorial, but being the non programmer i am its hard for me to determine what parts i need to cobble the two tutorials together, because i dont know what the commands and format are. but right now, my eyes are buring, and i think ill go curl up in a corner and sob uncontrollably. if there is some code out there that is already written and works and is up for public view. please show me. or any help really would be great.
09/04/2006 (2:56 pm)
No it appears we have it typed in the same, and im not running it on a mac. im not a programmer, more of an artist. ive done some stuff with director using lingo, but im still trying to learn torquesript. and snags like this can be kinda frustrating. ive been staring at this, going through forums, lookin at tutorial, and tearing through the reference guide for about 4 hours. but so far, everything i do doesnt do anything or hinders movement. from what ive read, apparently you can determine the surface normal on collision, so that tells me you should be able to say that if the collision is with a vertical surface that the player cant run up that surface.
ive looked at the other platformer tutorial, but being the non programmer i am its hard for me to determine what parts i need to cobble the two tutorials together, because i dont know what the commands and format are. but right now, my eyes are buring, and i think ill go curl up in a corner and sob uncontrollably. if there is some code out there that is already written and works and is up for public view. please show me. or any help really would be great.
#3
http://www.garagegames.com/mg/forums/result.thread.php?qt=50633
BTW, Levi is correct -- you CAN determine a surface normal for the collision, even when using castCollision. However, I tried using this approach, and while is MOSTLY worked, there were some other weird problems associated with it. Mainly, the guy vibrating quickly when you moved left/right into walls (this only happened some of the time), and then being unable to jump.
The approach in the thread above doesn't have this problem, and doesn't seem to have any other bad side-effects.
09/11/2006 (5:09 pm)
I've found what seems to be a workable solution to the "riding up the walls" problem. http://www.garagegames.com/mg/forums/result.thread.php?qt=50633
BTW, Levi is correct -- you CAN determine a surface normal for the collision, even when using castCollision. However, I tried using this approach, and while is MOSTLY worked, there were some other weird problems associated with it. Mainly, the guy vibrating quickly when you moved left/right into walls (this only happened some of the time), and then being unable to jump.
The approach in the thread above doesn't have this problem, and doesn't seem to have any other bad side-effects.
Torque Owner John Haley
Anyway, Levi, I can at least confirm it's not just you. And if you want, you can check out my post to see if we both entered the source code the same way. (I guess that's a safe assumption, seeing how we're both having the same problem.) Are you using a Mac too? I'm wondering if the Mac version still has some bugs that were cleaned in the Windows version. I only suggest that possibility because we seem to be the only two people with this problem.
...that, or we both made the same mistake!
(Edit -- added link to make life easier)