Team Effort

Posted By: msmith2468

Team Effort - 01/04/12 19:18

I have been working on a game during my time off of school. its far from finished but i have the foundation done.



to play the game there is an example level i made that can be found in the play menu.

the game is made for two people using the same keyboard but can easily be played with one person. one player uses the WASD keys to move and the other uses the arrow keys. when both players are close to each other you can merge together. when merged the colors mix, also one player control's up and down and the other controls left and right. to unmerge press space again and you will return to your original colors.

its important to only stay on tiles of your own color. white is always safe and black tiles will change to whatever color you are.

you can also create your own levels with the creation kit.



you can import and export levels to the game. as of now you can only do this with the first save spot.

more detailed instructions can be found in the read me file.

The game still needs a lot of work but i am open to suggestions, ideas, and criticism.

Here is the link - http://www.mikeswickedgames.com/Team%20Effort%20Game.htm
Posted By: msmith2468

Re: Team Effort - 01/06/12 19:31

I have done a lot of work on this game in the past couple days. so i thought i would release another version of the game. i have added more tools/obstacles. a story mode with 11 levels. Music and a couple other things. Try it out, let me know what you think.










Here is the Link - http://www.mikeswickedgames.com/Team%20Effort%20Game.htm
Posted By: Rackscha

Re: Team Effort - 01/06/12 20:17

Pretty good. Just tested it, but feels good. Nice mechanic(the coop part is the best about it).

Havent read through the options but, is there a key to restart a level, when a friend locked you by coloring all black floors? laugh
Posted By: msmith2468

Re: Team Effort - 01/06/12 20:51

@Rakscha
Thanks i am glad you liked it.

unfortunately there is not a key to restart the level yet. i plan to make ESC bring up a menu to reset the level or return to the menu. Don't try that now though because ESC exits the game and i have not yet implemented a save option.



I was planning on writing my own save load function. but it would be on the slow side. so i was thinking of implementing the built in save load functions in game studio but the problem is that when i update the game a user would not be able to just load his old save file. He would need to start over. so i was waiting to be sure of everything i wanted to save so i only have to write it once and all game saves will work in all versions of the game.
Posted By: Rackscha

Re: Team Effort - 01/07/12 01:36

For story, isnt the save/load very simpel?

Just save the number of the last completed level. You dont need to save the complete gamestate. Just the plain progress.

0 -> no level solved
1 -> level 1 solved
2 -> 1-2 solved

etc.

AT least i do not expect a save function to save during a challange(like a gamestate in Emulators), but the levels i have unlocked.

Greetings
Rackscha
Posted By: msmith2468

Re: Team Effort - 01/07/12 02:17

@Rackscha
yes for the level progress that is simple.
but i also need to save the username entered for each of the 4 username slots.
that brings us up to eight things to be saved into a file and then read from the file into the game on load. And still all this is relatively simple to do. Then i save the option changes which is still just a couple variables.

but the part i am worried about is saving the custom levels. right now i have four save slots. that each have a title, level size, and level tile code representation. and i would like to extend the save slots to 20. This is a lot of information to store and decode. which makes the built in save and load functions look appealing.



perhaps separate save files would be the best way to go. one for the story mode that saves the user names and their progress. another that saves the names of the custom game slots. then perhaps 20 others that save the contents of the custom game slots. all would be loaded right before they are used and saved right after. (just a thought) im still thinking about it.
Posted By: Rackscha

Re: Team Effort - 01/07/12 02:54

Using the ingame save/load is a problem: it breaks imediatly when you make heavy changes and doesnt allow to restore older save files.

for save load: think about a structure.

For example:

ID
Content
ID
Content
ID
Content
...


ID sais which type of content is following next(player profile, level file etc if you aim to put it in one file)
After reading the ID, you continue with the required reading function for your content type.

Easy and simple.

EDIT. i.e. if ID is your ID for levelfiles, you know the structure. A level file could be like this:

Name
tilesize_x
tilesize_y
tileinfo1
tileinfo2
tileinfo3
...

and so on.
So you have a reading function which reads the leveldata the same way you have written it.(you might consider writing another function for your tileinfo, if its more than some values)

Greets
Rackscha
Posted By: msmith2468

Re: Team Effort - 01/07/12 03:26

@Rackascha
Thanks that all sounds good.
so basically i save everything into one text file then when i want to load something in the game i search the text file for a keyword(ID) and have the contents to be loaded right after.

ill see if i can get it working.
ill probably still use 2 save files. one that is loaded when the game i opened that contains the Option changes, and Story user names and progress. The other containing the Custom game data using your ID/Content method.

Thanks
Posted By: Rackscha

Re: Team Effort - 01/07/12 06:37

No, you are not searching for it. But it allows a flexible structure for loading and saving.(load it all at once).

But for example you could save like this:

playerprofile
level
playerprofile

or like this:
playerprofile
playerprofile
level
level

The ids tell you which type of content is coming when loading.
The same loading routine which uses different subloading routines, based on IDs can load both files.
Normally, you should seperate level files from profiles.
But thats up to you.
Posted By: msmith2468

Re: Team Effort - 01/07/12 08:55

Ok i understand.
structure the save file with keywords and data so that when i read from it the keyword signifies where to place the data. this way the order of the save file dose not matter and if i want to add more data to the save file then old save files can still be read.
(right?)


if you create a level in my game and export it then open it up with a text editor you will see that its structure is simple. its structured like this.

TITLE*SIZE*TILEDATA*

to decode it i read one letter at a time until i reach a "*" then i save the first segment as title. i continue until i reach another "*" then save the contents as size. then i continue until i reach the last "*" and save the contents as tile-data. its simple but it works.
however using this method for a large save file with many variables would be difficult, confusing, and time consuming. not to mention trying to add new stuff to save.


Your way is much cleaner
im trying to figure out the best way to do it...

idea - 1
open file and read it to a really really long string
compare the beginning of the string with a bunch of (ID's) when an ID is located remove it from the string then read the contents from the beginning of the string to a end marker perhaps a "*". to the specified variable for that ID. remove that data from the string.
Continue decoding the string until it is empty. (i could save time loading the tile-data by calculating the length based on the dimensions of the level then copying it all at once instead of one letter at a time)


idea - 2
use a "," to separate all the data in the file (ID,DATA,ID,DATA) then learn more about delimiters and find a way to separate the contents by the "," .
then compare the first ID contents with keys. when found copy data contents into correct variable.
repeat this until all contents is sorted.


I might run into problems with the first idea. i am sure i would exceed some string size limit.
Posted By: Rackscha

Re: Team Effort - 01/07/12 16:28

Idea-3:
Use gamestudios file functions.

if you use file_var_write you can store a number in a file. With file_str_write, you can write a string to a file.

saving:

file_str_write(handle, "Hi");
file_str_write(handle, "its");
file_str_write(handle, "me");

loading:

file_str_read(handle, str1); //str1 is now "Hi"
file_str_read(handle, str2); //str2 is now "its"
file_str_read(handle, str3); //str3 is now "Me"

there are some alternate versions of file_str_read (look into the manual)
But as you can see, the functions already use seperation.

file_str_read reads until it hits a return/nextline char OR hits a seperator(usually ,).

so for writing you'll always first use file_var_write to note the ID and then start writing your data, and on loading you always do

file_var_read
look which content it means and use its function
after content is read out use file_var_read again

Greetings
Rackscha
Posted By: msmith2468

Re: Team Effort - 01/07/12 17:12

@Rackscha
That's exactly what i have been looking for. Thanks
Posted By: msmith2468

Re: Team Effort - 01/10/12 03:09

@Rackscha
Thanks a lot.
I have my save\load functions working perfectly. Its quick, organized and works good. I used your ID\Data method and when i add more content to be saved in future updates previous saved games should not have a problem loading.

I have also went through my code and cleaned it up a bit,I added some more music, a pause menu with a restart button, and I fixed a couple Bugs.

Ill keep working on it a little and try to release an update this weekend.
Posted By: Rackscha

Re: Team Effort - 01/10/12 11:26

No problem laugh
Posted By: msmith2468

Re: Team Effort - 01/17/12 16:37

Team Effort Alpha V0.5

I have been working on the game.
Here is a list of some of the things that have been added.

-Game save and load (save files should work in future updates)
-Options menu (adjust sound,music View controls)
-New levels and level adjustments in story mode
-A New Example level which features all of the tiles found in the games
-Added more songs
-Added animations for menu screens
-Added new Tiles
-Pressure Button Red
-Pressure Button Blue
-Pressure Button Yellow
-Pressure Button Purple
-Pressure Button Orange
-Pressure Button Green
-Toggle Button Red
-Toggle Button Blue
-Toggle Button Yellow
-Toggle Button Purple
-Toggle Button Orange
-Toggle Button Green
-Door Red
-Door Blue
-Door Yellow
-Door Purple
-Door Orange
-Door Green
-Cracked Floor Red
-Cracked Floor Blue
-Cracked Floor Yellow
-Cracked Floor Purple
-Cracked Floor Orange
-Cracked Floor Green
-Cracked Floor White

I have also removed some tiles that i had before.

From this point i am going to focus on polishing the game a bit.
So please let me know of any bugs or things that do not flow or work well so i can be sure to fix them. Thanks a lot

Here are some Screens





You can find the DownLoad The Zipped folder Here

EDIT: Updated the link
Team Effort Alpha V0.5
Posted By: msmith2468

Re: Team Effort - 01/18/12 03:25

One of the files in the last link i posted did not work. If you had problems with it then please download this ziped folder.

Team Effort Alpha V0.5.1

Sorry for the inconvenience.

I also posted a demo video.

Team Effort Alpha V0.5 Video

Let me know what you think.
© 2024 lite-C Forums