engine demo
Ever wonder where all the cool, fully scrolling games are on Scratch? With enough searching you can find a few games like this. This little demo is an engine for this very thing. Instead of using big sprites that scroll side-by-side displaying chunks of a game map, it uses 12 small (32x32 pixel) sprites that ALL scroll. The benefit of this is that not only can they scroll, they can also change costumes while moving. This gives you the ability use a handful of images to make HUGE (or even infinite) game maps! If you are not familiar with how tiling systems work in games, you should be! Tile-based games include... Super Mario, Pac-Man, Dig Dug, Bomberman, most NES, SNES RPG games (and a lot of others), and on and on. Hello!!!
Tiles? In other worlds, the map for this demo doesn't exist as an image, instead it is created by all those moving sprites (a full version would use 100+ moving sprites btw) as they switch between a relatively small set of costumes. Think of all the bricks in Super Mario, they are actually created by stamping 1 brick image wherever you need it. This is HUGE in Scratch because it is a great way to deal with the 10M project limit. You could easily make a random map generator to create an RPG or platformer map that goes on forever!
So where is the map stored in the project? It is stored as data in lists. If a single map is 10 tiles wide by 10 tiles tall, it has 100 tiles. A simple system would store data for each of those 100 tiles... which costume to use and if the player can walk there or gets blocked. If you use color-sensing you don't even need to store the blocking/walkable data. At the end of the day, it all comes down to how much you can squeeze into a project that still runs fast.
So why did I stop with this simple version? Because when I mocked up a full version, my little old Home XP pc couldn't handle the load. And that is without the tons of RPG game code added.
So for now, here is where we diverge paths. If you have the skills and/or the desire to make an epic Scratch game, this is a great system to take over. I would consider it the evolution of scrollx, and please don't think that I am taking credit for any of this, it has all obviously been done before. I'm just doing it in Scratch. As for me, my current plan is to nock the tile size down to 16x16 or smaller, the colors down to 16 or less (consider an artistic challenge, heh) and the game screen down... all to see if I can make my pc run this thing. I hope so because I have been waiting for a long time to do this!! If I have workable success I will do 2 full-blown games, a platformer and a rpg. PEACE
Last edited by Locomule (2012-04-12 10:16:45)
Offline
Nice engine!
Unfortunately, it is rather small...
I came up with an infinite scrolling, random generating engine (You could use it for just infinite scrolling) I tried to explain it to someone, but they didn't understand. So I'm now working on a demo project.
Maybe this should go in help with scripts...? As it is telling you how to make this... I suppose...
Offline
your right.
Last edited by sonicfan12p (2012-04-12 10:52:53)
Offline