00:00
00:00
Newgrounds Background Image Theme

cdhoeh0112 just joined the crew!

We need you on the team, too.

Support Newgrounds and get tons of perks for just $2.99!

Create a Free Account and then..

Become a Supporter!

Point and Click advice

300 Views | 1 Reply
New Topic Respond to this Topic

Point and Click advice 2015-08-03 13:18:33


I am currently creating a simple point and click adventure game template. The current progress can be seen here. Zip file here.

I need some advice on how to handle the "rectangles" that will trigger transitions between views when they are clicked. You know, when you click on a hole, the view will switch to looking in the hole.

The way I'm doing it now is by creating MovieClips, naming them, and then creating a class that stores their data. I've also been naming them based on where they lead. Doing it this way will certainly create a high number of obscurely named MCs sitting in the library. It definitely feels wrong.

I would appreciate any advice on a better way to handle transitioning in a game like this.

Response to Point and Click advice 2015-08-03 13:27:13


Just a rough idea, but you can consider a multi linked list.

---
Scene.as
----
var items:Array = []; // Contains all objects in scene.
var to:Array = []; // Array of Scenes. Contains all scenes reachable from this scene.

---
Item.as
---
var visual:MovieClip;
var id:int; // Item ID.

I'm tired and only thought about this for a minute. I could be completely off track.


Check out the Flash RPG I made in 2024. It takes about 25 minutes to complete.

BBS Signature