Jephthah's Domain
Home Smallville Ramblings Movie Thoughts Programming Stuff Random Rants Pi Page Billy Gilman



View all Random Pictures.







Super Star Lights

spiderwebman.net

Priceless Design

Other not as cool looking links...


If you have the urge to link to me...

Programming Stuff
index | Previous (passwords) | Next (timeline jumping)


Dragging Objects

I basically took a lesson from Cartoon Smart, but redid it to ensure that I had learned how to do it myself. I discovered the nice function in Flash the enables you to drag an object in two ways. I incorporated those ways in this one project. You can do the traditional drag by just clicking and holding down the mouse while moving it around and the little green blob will follow your mouse. I also made it so that if you just click on the blue circle, the blob will drag with you without you holding down the mouse. Then to stop the dragging, simply roll over the red square/circle thing. It was a fun mini-project!

In order to drag the object, I had to include a "blank" hit area over it, and I found it harder than I thought to have an invisible area that you could click on. Flash kept wanting to add it's own key frames that I was trying to get rid of!
Code Used:(on invisible hit area over the blob)

(There is other code in the blue and red circles, but this is the basics of it)
Home | Smallville Ramblings | Movie Thoughts | Programming Stuff | Random Rants | Pi Page | Billy Gilman
© Jephthah October 2005