English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

hitTest() is a fast and easy way to detect collisions with the walls. The draw back is that it uses movie clip. We use the following format to check for collision: on the stage you put all non-walkable tiles in a layer called non-walkable. Under that layer you put the walkable tiles. Now select all tiles in the non-walkable layer and convert it to movie clip and give it instance name "back".
could i have step by step instructions please

2007-02-25 22:51:47 · 2 answers · asked by Anonymous in Computers & Internet Programming & Design

2 answers

There are endless amounts of books that cover actionscript collision detection...most of which that advise not to use hitTest as it is considerably less accurate than other methods. What you are asking is for someone to relay an entire book to you, which I feel is somewhat unfair. All I can do is recommend the easiest to read book on the subject:

http://www.amazon.co.uk/Foundation-ActionScript-Animation-Making-Things/dp/1590595181/sr=8-1/qid=1172499279/ref=pd_ka_1/026-1903795-5156400?ie=UTF8&s=books

It actually covers all elements of actionscript animation, but there is a chapter in it that explains collision detection better than I've ever come across before. It starts by showing you the hitTest method and then moves on to showing you more accurate ways of going about it.

If you are serious about flash, you really must invest in this book. Best of luck with it.

2007-02-26 01:19:17 · answer #1 · answered by gromitski 5 · 1 0

Making games by putting sprites on the stage is a maintenance and performance nightmare.

I recommend you start by learning ActionScript 2.0 or 3.0 and learning to code flash applications without using the timeline for animations. I know that's hard but trust me, it's worth it. You'll increase your value in the developer marketplace and learn a lot about your craft while you do it.

2007-02-25 22:57:40 · answer #2 · answered by Anonymous · 0 0

fedest.com, questions and answers