Project P1d for CS4496, instructor Jarek Rossignac.


Switch Type Accident

red car attempts to switch lanes and well, you know the drill: green car goes ZOWIE!!

Prevention.
The green car could have been more aware and could have stayed out of red car's blind spot. Also, if she realized red car might switch lanes, she could have slowed down a bit to prevent this. A good wail on the horn never hurts, either. (d will simulate this).

The red car could have either USED his rear view mirrors, or better aligned them as to make them useful. Also doing simple things such as using a turn signal and turning his head to check would have been nice. (f to simulate this.


To view this content, you need to install Java from java.com


How to & Command List

0 - Linear Interpolation Mode (done on a per frame basis)
1 - Bezier Interpolation Mode (done on a per frame basis)
2 - Circular Interpolation Mode (done on a per frame basis)
r - Toggle road editor on/off. (When this is on, all cars will be removed from the display)

SHIFT-1 - Show 1 Car
SHIFT-2 - Show 2 Cars
SHIFT-3 - Show 3 Cars
SHIFT-4 - Show 4 Cars
SHIFT-5 - Show 5 Cars
SHIFT-6 - Show 6 Cars

- (minus) - Subtracts a frame from the current car (you can never go below 1)
= (equals) - Add a frame to the current car (never going above 6)
+ (plus) - Add a frame to the current car (never going above 6)
3 - Use 3 key frames per car
4 - Use 4 key frames per car
5 - Use 5 key frames per car
6 - Use 6 key frames per car

space - Start/Stop animation
a - Start/Stop animation

c - Reload the intial accident scenario.
f - Display how the driver should avoid this wreck.
d - Display how the person getting hit should have driven defensivly.

Source code: p1d.zip

Built with Processing