Game Development Community

How to control world limit interaction ?

by Wicked Sunny · in Torque X Platformer Kit · 06/26/2007 (11:28 am) · 3 replies

Thomas

I want the player actor to collide with the world limit boundary say for 'n' number of times, after that if player collides again he will die.

but say if in last try he touches a platform instead , then the script will again change to 'n' numbers and he can touch the world limit again for 'n' number of times.

In normal c programming a simple if else loop will do this, but I have no idea such a function can be created for the world limit.

Some thing like the carrots and player and drill interaction in the platformer starter kit but with the world limits of the player. I can do this with triggers or scene objects, but I need it for a much broader area, so best option will be to use the world limit itself rather then putting triggers every next tile.

How exactly will I script this in TXB and also TGB ( If you cannot answer TGB answers here. I will post in TGB forums). How do I define such a function for world limits ?



I will be bothering you a lot for some time Thomas, I need to fully prepare intrinsic basics of platformer in TGB or TXB by end of July and I am learning both of them together. ;)

Even though TGB 1.3 has its own problems, I have learned a lot in TGB during last 3 day (as you know I am stuck with TXB for now), I think I can make a unique game using TGB even with its limited features and problems. TXB - well kit already provides ready made templates, and if I start initially in TGB I can always import scenes from TGB into TXB.

I think I have a very bright future ahead with Torque games.

and Thank you for keeping up with my questions and me :D

About the author

Sunny is Multi Award Winning Poet, Writer, Designer and Chef. He is the Director of PublishingGurus.com, a book publishing company.


#1
06/26/2007 (12:24 pm)
For world limits? When the player touches a world limit it will trigger an event. Just add 1 to a variable in the event, and if the event happens and it is past 'n', just have it call the function to kill the player. If the player touches a certain platform, set the variable to 0. Pretty simple, I think.
#2
06/26/2007 (12:44 pm)
Yep, that would work. :)
#3
06/26/2007 (9:29 pm)
Thanks

Thomas & Thomas :)