PDA

View Full Version : need some help on an assignment


waffler
05-19-2006, 03:52 PM
Hi, my assignment is to have a car go around the tracks of a roller coaster. Is there any way to have the car stay on the tracks? I can't figure this one out.

Jabberwocky
05-19-2006, 04:57 PM
One of the example worlds that comes with the Alice installation package is an amusement park. Once you open it, pan to the right in the preview window until you see the sky cars; you can then run the world and watch them move. I'd think you're trying to do something like that.

Closing the World Play window, if you'll then look at the methods of the World object you'll see the first one is skycarAnimation. Click the Edit button and take a look at that code. Basically the car moves in line with the wire, mimicking or giving the illusion that it's tethered to it. I believe you'll have to do something like that; which I'd think would be tedious.

It would be nice if you could truly attach the cars to the coaster's track, just give them some momentum and watch them go, but I'm afraid you are going to have to move them forward, up, down, rolling and straightening as you go.

Take a look at the cars on the coaster in the amusement park example. If you want to add a bit of pizzaz to your animation instead of just moving one car, create a list and perform all of the above movements on a bunch of cars one by one.

Have fun!

lanceA
05-19-2006, 06:58 PM
I think we have to be careful not to confuse STUDENTS who are new to Alice and overwhelm them with information that possibly they have not covered in class.;)

zarfang8
11-15-2009, 08:59 AM
as you start out, you should probably have the cars move very slowly, and when it works out, speed it up to look more realistic. It definetly will be challenging to do though.