all groups > flash actionscript > april 2007 >
You're in the

flash actionscript

group:

Game Creation Question


Game Creation Question small_guy
4/9/2007 5:14:55 PM
flash actionscript:
Although I have a background in Flash, game creation has not been a part of it.
I have been asked to apply for a Flash position that would involve some game
creation. Towards this end, the company has a Flash Test to create what is (for
those who really know this area) a simple sounding game. I have got the start
of the effort and do not expect to be able to do the entire test. Nonetheless,
I do need to add something more before I submit what I've got. (I've Googled
all over for tutorials that might make sense - for me - on this. Found one
(that was done in Flash MX and does not want to seem to cooperate in Pro 8).

The gist of the game: single main character that you move with the arrow keys.
Objects are randomly falling. Player intentionally moves to have the objects
hit him. With each hit a score is tallied on a scoreboard until so many are hit
and a message saying You've Won is displayed.

Part of the criteria is that in the .fla file there are no objects on the
stage and that this is all built into one layer and one frame. (There is more
involving the creation of 3 custom classes: a game class, a man/player class
and the object class. Having not created classes before - and although spent
some time trying to work on that aspect of it - I am not going there.)

I have created a movie clip of the man and a movie clip of the object. In the
library I did a linkage of each. On the stage I have placed two empty movie
clips, each one linked to the movie clips of the actual figures in the library.
(Thus having no representations of them on the stage in the .fla.)

I have coded the four arrow keys to move the man character about the stage.

In light of time (of which there is none left) the only other part of the test
that I would at least like to make happen is to create random copies of the
object and have them randomly move.

If anyone has any insights into this part of this it would be greatly
appreciated.

Thanks.

Christian Seaborn
seaborn.christian@gmail.com
Re: Game Creation Question kglad
4/9/2007 6:38:33 PM
you don't need empty movieclips on stage to utilize the linkage and you'll
flunk that requirement by placing two on stage.

you can attach you man and object to the _level0 timeline. or if you like,
you can use createEmptyMovieClip to create a parent movieclip to which you'll
attach the man. and you can attach the object to the same empty movieclip or
create a separate parent using createEmptyMovieClip again.

you should use a loop (onEnterFrame or setInterval) to create your objects
(with some randomness in time of creation and placement and movement). each
object could have its own onEnterFrame loop (that's not great for efficiency
but they probably aren't interested in that if they want an object class anyway
and that would be easiest) to allow its own movement and to check when it's
moved off-stage and should be removed and if it hits the man.
Re: Game Creation Question small_guy
4/9/2007 9:01:47 PM
Thank you for the feedback/the help. (The job is not totally about putting
together games (otherwise they would not consider me at all since I have no
background in that area), but it is a part of it. So thanks again for the help
while I endeavor to get at least a small handle on how this part of Flash
works.)
Re: Game Creation Question kglad
4/9/2007 9:17:54 PM
AddThis Social Bookmark Button