Page 1 of 1

Multiple Rooms/Levels Online Tutorial

PostPosted: Sun Feb 15, 2004 4:20 am
by trajecto
So your character has happened upon a dwelling and wishes to enter or perhaps your character has reached the next level in your game. Either way you need to change the scenery and quick...

Ready?

PostPosted: Sun Feb 15, 2004 4:28 am
by jazz_e_bob
Standing by...

PostPosted: Sun Feb 15, 2004 4:52 am
by trajecto
Two methods are:

1. Use Destroy Actor and Create Actor simultaneously to change the game environment.

2. "Transport" your view and/or actor to another area of your game environment where other artwork is drawn.

PostPosted: Sun Feb 15, 2004 5:49 am
by jazz_e_bob
I think the transporter method might be best.

Easier to keep track of. You can simply scroll around and look at all of your levels.

You could also use activation regions to load only 1 level at a time into memory. (if you are fussy about these kind of things :wink: )

Are we planning on using reiners tile sets and GE's tiling feature?

http://www.reinerstileset.4players.de:1059/index.htm

Over and out.

PostPosted: Sun Feb 15, 2004 11:32 pm
by Just4Fun
The Announcer states:

"Just4Fun has recently been sited following in tortoise like fashion behind the rest of the GE team... Ghostie will soon be levitating through walls and doorways! :oops:

PostPosted: Tue Feb 17, 2004 4:25 am
by trajecto
You can use any graphics you want for this, the key thing to keep in mind is the size of your view. Since I am a Pocket PC guy I like to use 240 x 320. I like the transport method also unless for example very few objects are changing and I don't want to leave my particular scene.

Let's start with a Splash Screen being our first "level" - when the game starts this is the first thing we see, then we make selections such as "Intro, Credits, Play" - and leave the screen.

Example: Grail Quest intro screen

PostPosted: Tue Feb 17, 2004 4:44 am
by trajecto
Here we go!

1. Create your Splash Screen like I have shown, use an Art editor like Adobe Photoshop or PaintShop Pro. It's good to save your original project files so you can edit your text later but you will need to export out one of the recognized formats for GE such as GIF or PNG.

2. Crop the artwork around "Play" and save that off as it's own image.

3. Start a GE session, under Config set your Game Properties resolution size to 240 x 320 (Pocket PC).

4. Add an Actor "splash" and add your splash screen graphic as the animation.

5. Add an actor on top of your splash screen named "play" and add your play graphic as the animation. Adjust it so it blends right on top of the splash screen background, it should be able to match perfectly.

6. Add a Mouse Button Down event to "play" use the left mouse button as the event.

7. Use Add Action Script Editor:

view.y -=320;

THAT'S IT!

This will jump the view above your splash screen where you have your game waiting. I have a walking character there now who is the parent of the view so it follows him now. I have also set limits on his range so he can't walk onto the splash screen.

Now you can add onto this and add a Help Screen, Credits screen. Maybe when you press "Play" the button will change color, etc...

PostPosted: Tue Feb 17, 2004 5:13 am
by makslane
Put a Activation Region around the splash actor.
And other around each level.

So, your game will load more fast and save memory if your levels have many scripts, or actors....


How save memory?

Your splash will be unloaded when your Activation Region not more intersect the view !


This thing make easy have multiple level in one ged file

PostPosted: Wed Feb 18, 2004 4:07 am
by trajecto
Thanks Makslane!

I see how Activation Regions works.

How about this: If I have one large world my character is walking around in can I have a "grid" of Activation Regions?

I'm trying a grid of them, it seems to be working, is there a limit to the number of Activation Regions you can have?

PostPosted: Wed Feb 18, 2004 1:00 pm
by makslane
You can have a grid. There is no limit

PostPosted: Wed May 31, 2006 5:23 pm
by frodo
another way to do multiple levels is to have level 1 saved as a seperate game, level 2 the same, and so on. then just load the correct level with "LoadGame" function.
also, the levels must be saved in the same folder. for example, all saved in the folder "My games".

Questions about activation regions...do they work?

PostPosted: Sun Mar 16, 2008 6:36 pm
by DST
I have a lot of questions, because these things aren't working the way everyone says they should.

1. If i create multiple game files, couldn't the user just open level3.exe or level3.dat and start playing from there?

2. If i create multiple game files, and i need to make a last minute update to the code, don't i have to go update that code in every single file? (that doesn't sound like much fun)

3. Why is it when i use activation regions, GE crashes when exporting the game? Over and over and with several files i have this problem. Ge freezes during export, then i remove the activation region, try it again, and everything is fine. Except for the 1,429 actors loaded into the memory simultaneously!

Any help would be very....helpful.

Re: Multiple Rooms/Levels Online Tutorial

PostPosted: Mon Mar 17, 2008 5:10 am
by DilloDude
Itr is true, with separate files you can just open a later one. Either you have to save variables to say that you are supposed to open that one (except someone might be able to save that to) or you just have to not care, if they want to spoil it then they can feel free.

And yes, if you do use multiple files, you do have to change stuff in every single file (if you want it changed in all of them) :shock: See my post here for my list of the pros and cons of various multiple level methods (although I didn't mention the problem above, about people just opening a later level. :| An oversight.)