i dont know if its possible to make in flash, which i would find very hard to believe...i just wanted to display a model of a car bieng accelerated by magnets...its going from left to right on the screen..the start out speed is slow...but it as it comes close to a magnet, it draws it toward it and then right next to the positive magnet their is a negative on which repels it, thus making acceleration, the second model is the exact opposite, braking...the magnet places are switched...negative first and then positive...the only way i can think to make this is to subtract the x position of the car and the magnet and tell it if its within a certain amount of units, then to increase the pace which it travels accross...then to add resistance (which is very simple)... I need a mail form.:: I need a mail form for my website. I need to make a feedback form. Please help me. Also, I would like a banner-less mail form. http://answers.google.com/answers/threadview/id/323404.htmlHOME |
here is a really poor diagram on how i plan to set it up
acceleration
CAR--> + - +- +- +- +-
deceleration
CAR--> -+ -+ -+ -+ -+
thanks for all your help
first off, i wann say thank you, but it still wouldnt be accurate because in reality, the negative magnet would accelerate it more that the speed its already going at since its pushing the car forward...do u see what i mean? thanks for the help though, atleast now i have a base to start off with End Stage Renal Disease:: Please help me as I need to make some decisions about his future care and knowing how long he might last would help me. I would like to get Hospice involved http://answers.google.com/answers/threadview/id/477662.htmlHOME |
maybe u can create a dummy, say a MC around the area of the magnet and make it's visibility into 0.
name the positive side "magnetpos"
name the negative side "magnetneg"
make the car move automatically, like:
//script this in the frame
_root.move =1
_root.speed =3
//script this in the car(MC)
onclipevent(enterframe){
if(_root.move ==1){
this._x+=_root.speed
if(this.hittest(_root.magnetpos)){
_root.speed = 5
}
if(this.hittest(_root.magnetneg)){
_root.speed = 1
}
}
the idea is that the car movement speed is 3, if it gets near the positive side, the movement will change to 5(which is faster), and the speed will be 1 if it's close to the negative side.
u should add more AS to it to control the animation, this makes it kinda jaggy, but i hope it will give u the idea
haha, got it all mixed up, well just change the _root.speed to whatever u want man
Red Hat's Rough Recovery From CFO Exit
Windows Live Finds a New, Pre-installed Home
|