Game
NAVINHA (Little Ship)
8 years ago

Building the environment


When I began my oldest project “PIXEL FIGHTERS”, I took inspiration on CAROL SHAW’S RIVER RAID concept. River Raid is one of the most brilliant game designs I saw by all my life. Unecessary explain how Carol Shaw did it, you can read about her here:

http://filosofiashmup.blogspot.com.br/2012/09/ficamos-velhos.html

Starting from the Carol’s idea, I created a pseudo-procedural map generator! HAHAHAH! Yeah, I’ll conquer the world!

The method is simple: PIXEL FIGHTER has 40 stages + some secrets, and create one by one would make me tired. The solution were create a simple conditioned numeric code, where a variable controls the pieces of map. This variable is generated randomically, and each value is equivallent to one group of scenario elements.

5d0b8189303a6.png

So, for clear your mind, the algorithm is:

if(stage is number(x)){
environment_group=(e)
if(environment==(e)){
piece_of_map=(random(40);
}
}

5d0b818b3a18d.png

Where:
x= the number of stage, between 1 to 40 (or the number of secret stages);
e=the number of environment group. I organized it on some groups, as follow:

1=ocean with islands
2=ocean without islands
3=cold ocean with cold islands
4=Antarctica
5=desert with dunes
6=desert with rock mountains
7=swamp
8=lava
9=jungle
10=moon/space

Each environment group is a sprite composed by 40 frames, this is the reason to number 40 at algorithm.

When game starts, the variable (e) is pre defined by author, because the stage shows its properties to player, when the stage is selected.

If map shows Africa, and player select it, the program give to (e) the value 5, 6 or 9, depending of map region. However, the variable for piece of map is choosen randomically by CPU, and its value is mandatory between 1 and 40.

If you try use this system, you can change the value for pieces, isn’t mandatory you use 40. I use this number because it is enough for me, 40 different pieces multiplied by 10 different scenarios multiplied by 6 sprites in game generate too many dynamic scenarios, is wonderful to see it working! :)

You can see the prototype of this feature here:
https://www.youtube.com/watch?v=VAe4HodY7Zg

The video shows a red square, it marks the playable area (for debug). Pixel Fighters has a minimal screen size, 160x120px, and I create this system using Macromedia Flash MX 2004, with Actionscript 1 and 2.

At beginning, the software runs weirdly, after some moments, it create and combine incredible scenario elements, like roads, hills, forests, cities, islands, etc.

Pixel Fighters is still in development, but it map generator runs perfectly. I adapted it sucessful to GAME MAKER 8.0 and this made me more happy :)

5d0b818d6534f.png

You can see the PIXEL FIGHTERS environments on my Deviant gallery:
http://tiaoferreira.deviantart.com/gallery/44921402/Game-art

Also, you’ll see the system working on NAVINHA, heheh!



0 comments

Loading...

Next up

Concept art

Continuing concept

Dualplay

Native joysticks!

Updated the chest in the maze, adding sound, particles and better animation. But what's in the chest?

Heya! I wanted to show some gameplay progress i made so far. I hope you like it ^^

The whole squad is here!

Interested? Follow me!

One of the most critical update for Sunblaze demo. Now you are able to pet a cat! Finally!

Call it 'wrong turn'!🚫 The feeling of running into a house with only one exit🚪, and being doomed to die. #pixelart #pixelartist #pixelartwork #art #pixel #indiegame #IndieGameDev #indieartist

I worked so hard to get all four of them to the end safely, but then...