Game Development Community

How do I move items when they are shot or collided with?

by Marvin Hawkins · in General Discussion · 12/02/2008 (11:28 pm) · 4 replies

Hello I'm sorry if this is a noobish post. I've worked with this issue for about a day and would like some insight from the community. For the game project that I'm working on I want to be able to (shoot) or move objects when they are collided with through script.

When I say collided with I mean through when they collide with the player or a projectile. I did find some usueful code on how to make items aware of these collisions. But another question, What methods/functions do I use to call a move function?

obj.moveme() doesn't seem to work for me? What is the syntax/case for moving things in Torque? I really appreciate any insight you all can provide.

#1
12/02/2008 (11:54 pm)
Hi Marvin,
what you are looking for is rigid shape:
http://www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=5495
#2
12/03/2008 (11:11 am)
Wow thank you Michael. This Resource is Awesome!
#3
12/03/2008 (11:55 am)
Keep in mind that the rigidshape class is already part of Torque, TGE and TGEa, so you only need the datablocks and script collision methods not the whole resource.
#4
12/07/2008 (9:29 am)
Ah. yeah i meant to post about this but yes i tested it and it works very well. Thanks for the input guys. It's such an easy implementation.