Multiple onEnterFrame Events

Multiple onEnterFrame Events

Players

0

Rating

4.5★

Categories

Other

About

One problem with using onEnterFrame is that every movieclip only has one of them so you can only assign a single function to be used for a movieclip's onEnterFrame event at any given time. This (albeit odd) example shows how you can get around this using an addEnterFrameEvent function which runs multiple enterFrame event functions stored in an array for any single onEnterFrame event of a single movieclip. Some additional features are added to provide more control which can be seen in interacting with the street sign in this example. Simply click the sign to initiate 3 different function calls for one onEnterFrame event, each with their own set of parameters assigned when the sign is clicked. In addition, a helpful SimpleTweener function is used to scale and position the sign movieclip. This simple yet versitile function makes it easy to make simple tweens for many different properties using the same function.

Creator

Trevor McCauley

Game Studio

Category

Other

Type

Mini Game

Released

Recently

Players

0

By creator

More from Trevor McCauley

Same category

More Other games

Most Popular

You might also like

Trending games other players are loving right now.