Page 1 of 8
mvEngine Development Thread
Posted: Tue Mar 23, 2010 6:50 pm
by mv2112
First, i guess im working on a sort of game engine. Its in the VERY baby stages, but you can download the .exe here ->
http://home.roadrunner.com/~mvonline/, it's in a zip file which contains the engine and the map editor. Tell me what you think of it? It's written in c++ and allegro. And now for my question:
What is an efficient way of storing and loading maps? Right now, my map file is like this:
Code: Select all
tile_sheet.bmp <- tile sheet to load tiles from
x x x x x x x x x x # x coordinates on screen and the # says to the engine "OMG, NO MORE VALUES ON THIS LINE!"
y y y y y y y y y y # y coordinates on screen
fx fx fx fx fx fx fx fx fx fx # x coordinate on tilesheet
fy fy fy fy fy fy fy fy fy fy # y coordinate on tilesheet
t t t t t t t t t t # type of file
w w w w w w w w w w # width of tiles
h h h h h h h h h h # height of tiles
All the letters represent integer values that get loaded into vectors in the engine.
basically, what i do is when i setup the map, i do a for loop:
Code: Select all
for(int i=0;i<map1->x.size();i++)
{
masked_blit(MAP,tile_sheet.bmp,fx[i],fy[i],x[i],y[i]); //something like this
}
I saved the tile configuration to BITMAP * MAP because refreshing the map using the for loop itself was EXTREMELY slow.
My way of loading maps works fine, but is there a more efficient way of doing it? I don't know how good my way will be with very large maps.
Here is url to youtube video:
http://www.youtube.com/watch?v=7anw-W423UA
Re: Questions about loading maps and check out my new project!
Posted: Tue Mar 23, 2010 7:02 pm
by mv2112
Also, if for some reason you cant run the files, tell me so i can fix, iv never distributed my executables before.
Re: Questions about loading maps and check out my new project!
Posted: Tue Mar 23, 2010 7:12 pm
by short
http://www.wisdom-soft.com/products/aut ... r_free.htm
honestly I see lots of projects that say "HEY, DL MY .EXE KKTHX"
the above program will allow you to make a basic video of your project and youtube will host it for free. Just sayin
edit: I can't vouch for the program I linked, but I use it and don't believe there are any hidden surprises
Re: Questions about loading maps and check out my new project!
Posted: Tue Mar 23, 2010 7:28 pm
by thejahooli
That is really good, I'm looking forward to seeing where this project goes.
mv2112 wrote:Also, if for some reason you cant run the files, tell me so i can fix, iv never distributed my executables before.
I downloaded it and both the map editor and engine ran fine.
Re: Questions about loading maps and check out my new project!
Posted: Tue Mar 23, 2010 7:44 pm
by avansc
runs in osx under wine, was not expecting that. the level editor is to cryptic tho.
Re: Questions about loading maps and check out my new project!
Posted: Tue Mar 23, 2010 7:56 pm
by mv2112
avansc wrote:runs in osx under wine, was not expecting that. the level editor is to cryptic tho.
I plan on making it more "User-Friendly" later on, right now though, it just works lol
.
Re: Questions about loading maps and check out my new project!
Posted: Tue Mar 23, 2010 7:58 pm
by mv2112
short wrote:http://www.wisdom-soft.com/products/aut ... r_free.htm
honestly I see lots of projects that say "HEY, DL MY .EXE KKTHX"
the above program will allow you to make a basic video of your project and youtube will host it for free. Just sayin
edit: I can't vouch for the program I linked, but I use it and don't believe there are any hidden surprises
I'll have to try that, everytime i try and use hypercam or camstudio, the quality is TRASH.
Re: Questions about loading maps and check out my new project!
Posted: Wed Mar 24, 2010 3:50 am
by LeonBlade
avansc wrote:runs in osx under wine, was not expecting that. the level editor is to cryptic tho.
Gah, I can't get it to work...
Re: Questions about loading maps and check out my new project!
Posted: Thu Mar 25, 2010 10:08 pm
by mv2112
short wrote:http://www.wisdom-soft.com/products/aut ... r_free.htm
honestly I see lots of projects that say "HEY, DL MY .EXE KKTHX"
the above program will allow you to make a basic video of your project and youtube will host it for free. Just sayin
edit: I can't vouch for the program I linked, but I use it and don't believe there are any hidden surprises
Okay, lets say for the sake of argument that someone was told he should make videos and post on youtube
. Now, lets say he actually might do that but he has a problem, he doesnt know what music to play in the background because he doesnt have a mic. What songs would you recommend that person putting in the video? Just for the sake of argument...
Re: Questions about loading maps and check out my new project!
Posted: Thu Mar 25, 2010 10:30 pm
by Maevik
Works great for me! Runs smooth, did not encounter any bugs.
Couple suggestions: It's very easy to get lost in the tile map, making it difficult to know what tiles are adjacent to the selected tile or where to find tiles similar to the selected tile. Maybe you could add a function that shows the entire tilesheet with the selected tile highlighted while SOMEKEY is pressed down.
Also, it would be better to have your tile navigation algorithm limit the user from being able to go off the tilesheet (getting the black tile.) It's always best to prevent an undesirable condition.
Great work! Keep it up!
Re: Questions about loading maps and check out my new project!
Posted: Thu Mar 25, 2010 10:31 pm
by GroundUpEngine
Just tryed ya Engine, works good. You might want to implement placing the Tile with your mouse once you find a nicer way to load maps
Nice work, great stuff!
Re: Questions about loading maps and check out my new project!
Posted: Thu Mar 25, 2010 10:36 pm
by mv2112
GroundUpEngine wrote:Just tryed ya Engine, works good. You might want to implement placing the Tile with your mouse once you find a nicer way to load maps
Nice work, great stuff!
I haven't quit figured out how i am going to get the mouse to work right, the map editor and engine don't use grids for the maps so it'll be hard lol.
Re: Questions about loading maps and check out my new project!
Posted: Thu Mar 25, 2010 10:39 pm
by mv2112
Maevik wrote:Works great for me! Runs smooth, did not encounter any bugs.
Couple suggestions: It's very easy to get lost in the tile map, making it difficult to know what tiles are adjacent to the selected tile or where to find tiles similar to the selected tile. Maybe you could add a function that shows the entire tilesheet with the selected tile highlighted while SOMEKEY is pressed down.
Also, it would be better to have your tile navigation algorithm limit the user from being able to go off the tilesheet (getting the black tile.) It's always best to prevent an undesirable condition.
Great work! Keep it up!
Did you download the version with the pressing 1,2,3, and 4 to switch tiles? I uploaded a new version to my site that fixes this problem by displaying the tile sheet and letting the user click on what tile they want.
EDIT: I forgot i linked directly to the file and not the site lol, i fix now
Re: Questions about loading maps and check out my new project!
Posted: Thu Mar 25, 2010 10:54 pm
by Maevik
Yeah, I was using the 1, 2, 3, 4 version. I'll have to check the newer one out later though since the wife is craving some attention :P
Re: Questions about loading maps and check out my new project!
Posted: Sun Mar 28, 2010 7:18 am
by MrDeathNote
Looks nice man, keep it up