Activate a motor oncollision help
7 posts • Page 1 of 1
Re: Activate a motor oncollision help
You should really check out Grady's tut on starting to learn thyme.
- Code: Select all
//Variables
Scene.my.motor = false
//onCollide
(e)=>{Scene.my.motor = true}
//Motor
{Scene.my.motor}
-
standardtoaster - Posts: 606
- Joined: Mon Aug 31, 2009 7:57 pm
Re: Activate a motor oncollision help
Just to expand on standardtoaster's code
Make sure you have Advanced mode ON
Open Console (~)
Type in
Press enter to save it(Copy and paste works to)
On the object you want to trigger the Motor turning on in the Script menu in oncollide. Pump in
And on the hinge you want to be triggered in the script menu in Motor put in
And simply press enter to save it.
Make sure you have Advanced mode ON
Open Console (~)
Type in
- Code: Select all
Scene.my.motor = false
Press enter to save it(Copy and paste works to)
On the object you want to trigger the Motor turning on in the Script menu in oncollide. Pump in
- Code: Select all
(e)=>{Scene.my.motor = true}
And on the hinge you want to be triggered in the script menu in Motor put in
- Code: Select all
{Scene.my.motor}
And simply press enter to save it.
Last edited by Mystery on Sat Feb 06, 2010 2:49 am, edited 1 time in total.
-
Mystery - Posts: 2802
- Joined: Thu Sep 03, 2009 1:16 pm
- Location: Southern Australia
Re: Activate a motor oncollision help
Mystery, for the motor it would be:
not
- Code: Select all
{Scene.my.motor}
not
- Code: Select all
(e)=>{Scene.my.motor = true}
-
standardtoaster - Posts: 606
- Joined: Mon Aug 31, 2009 7:57 pm
Re: Activate a motor oncollision help
Whoops. Thanks for the correction.
-
Mystery - Posts: 2802
- Joined: Thu Sep 03, 2009 1:16 pm
- Location: Southern Australia
7 posts • Page 1 of 1
Who is online
Users browsing this forum: No registered users and 4 guests