Sign in to follow this  
XDaWNeDX

Beginning of "The battle of the Apes"

Recommended Posts

XDaWNeDX    113
I have little GAME programming experience. I HAVE programmed a simple game, barnumized.com/downloads/release0.01.5.rar but that's about it.
I plan on creating this in allegro. Not for the experience, just cuz I wanna make a game quickly. All the while reading the toymaker's website for help on directx programming.

Currently for this game, I have a player that can move in a single map that is hardcoded into the game. Collision detection works, etc.

The game is 2d top-down view, just cuz I don't want to work on gravity right now. :D


NOTE. I HAVE NEVER SEEN "Planet of the Apes" NOR HAVE I EVER HEARD OF THE MOVIE PRIOR TO WRITING THIS. (I heard of that movie AFTER giving this to somebody to help me find a name)


Anyhoo, the protagonist is a nerd named Eugene. The antagoist(s) are the evil monkey's whom created war many long years ago.

Eugene, being a nerd is of course AGAINST having to go fight. He'd much rather stay home and play som more shoot-em-up ultimate chess, but his grandmother's pleading forces him to attempt to change the world.

As Eugene progresses through the game, his character evolves, so to speak. He'll slowly become a more tough person. Clothe's changing, etc. And at the very end, he'll pick a nickname for himself, and the story at the beginning will be RE-WROTE using Eugene's new nickname, rather than adam. Along with a few things that Eugene does along the way.

The NickName will be chosen by the player playing through the game, and if the player chooses a specific name something extra will be given to them. (Haven't thought of what. Perhaps another playthrough on the same file, using a brand new character?) There will be hints throughout the game as to WHAT this name will be. (Things hidden behind walls, etc.)

But yeah, that's basically the game. The beginning of the game (from when you hit "new game" to when you gain full control of the player) is as follows:

[code]


Computer:
BANG BANG, POW!

Eugene: YES! HIGH SCORE! I finally beat the ultimate computer in shoot-em-up chess!

GrandMother:

EUGENE! I NEED TO SPEAK WITH YOU FOR A MOMENT, COME DOWN HERE PLEASE!

Eugene:
Can it wait grandma? I'm on a roll!

GrandMother:
NO, IT'S REALLY IMPORTANT!

Eugene:
Alright, I'll be right there.

GrandMother:
A long time ago...

SCENE CHANGE: Past, black/white peaceful humans and monkeys

There was once a time when the humans and the monkeys had lived in peace.
However, this was a time long since forgotten.

SCENE CHANGE: SlideShow of present, coloured fighting images between human and monkey

There was one day a monkey, one that had been full of such revulsion towards the human race.
He made claims such that humans were "evil" and were attempting to take over the world.
Shunned from the monkey's race - as the majority were in peace with humans -, he decided to create a group.
One so evil that it would create a war greater than the last.

SCENE CHANGE: PAST WAR

They devised an evil plan, too force a human to attack the monkey's leader.
They wrote a note to the human's leader, Adam, declaring war. Signed from the monkey's leader.
After the war started, the evil monkey's stole the note back and burned it. Removing all evidence of such a fact, and
forcing the humans to seem like the evil ones.

SCENE CHANGE: BURNING NOTE

Adam had fought valiantly, but to no avail. After nearly 15 years of war, the monkey's retreated.

*pause*

GrandMother:
Eugene, Adam was my father, your great grandfather. He told me to give this note to you just before he died.

*Eugene recieves note*

Eugene:
huh?! My great grandfather was a fighter??

GrandMother:
Yes, your great grandfather was the Adam told in all these stories.

Eugene:
But grandmother, I had never met him. How could he have possibly known of me?

GrandMother:
He was in the military, trying to defend our race in case the monkey's decide to attack again. We told him of you, but he couldn't leave his post in fear of another attack.
Go ahead, open the note.

SCENE CHANGE: Opening note
SCENE CHANGE: OPENED NOTE

Note:

Dear Eugene,
I know you never met me, but I've heard lots about you.
I know you will be great someday, which is why I have
such a great task to ask of you.

For you see, the Monkey's have attacked again. At the
time of writing this note, they've nearly breached our
main walls. You're of great decent Eugene, I know you
can save us. Your grandmother has the key's to the
basement, go down there and grab my sword I used in the
last war.

Good luck, Adam.


SCENE CHANGE:

Eugene:
You sure this was meant for me, not somebody else?

GrandMother:
Yes.. I wish it wasn't, but Adam told me very specifically to get this to you Eugene.

Eugene:
Can I GIVE it to somebody else?

GrandMother:
I'm afraid not, only descendants of our family can wield our sword, and I'm too old.

Eugene:
Grr... fine.

GrandMother:
Thank you, and believe me, if we could give it all to somebody else I would.

Eugene:
But... Grandmother, what does this all mean?

GrandMother:
I don't know, but nothing good for sure. Come on, I need to take you to the basement.



SCENE CHANGE: WALKING TO BASEMENT/ ENTERING BASEMENT

SCENE CHANGE: Glowing sword in a sheath with a shield.

SCENE CHANGE: Eugene grabs sword and enter's a battle sequence with two "Leader Monkey"s



GrandMother: Oh gosh, Adam did always practice his sword play down here...

Well, I better tell you how to fight, and fast!

You see the "attack" button there Eugene?


Eugene:
Yeah, what does it do?? HURRY UP GRANDMA!


GrandMother:
Calm down Eugene, these monkey's are harmless. They're wooden.


BATTLE SEQUENCE CHANGE: Leader Monkey's change to Wooden Targets. (the names)


GrandMother:
Anyways, the attack button uses your most basic attack. It takes up none of your energy. Try it out.



PLAYER INPUT: Select "attack"
BATTLE SEQUENCE: Use "attack" spell.
Lose 30 HP from improper sword play.


GrandMother:
Oops, try not to miss the targets next time. Go to the "Inventory" button, and use "HP Potion".


PLAYER INPUT: Select inventory > HP Potion.

GrandMother:
There are also various 'skills' you can use under the "skills" button, but you haven't learned any useful skills.


BATTLE SEQUENCE CHANGE: Display Skill's screen with "programming" as only skill.


GrandMother:
Go ahead and finish up this battle and come upstairs, I'll be waiting for you.

PLAYER INPUT: Finish battle.


SCREEN HELP:
Use the up/left/right/down key's to move your player around, and 'space' to interact with objects such as doors, chests, etc.

PLAYER INPUT: Grab the sheath / sword.

if the go out door to early.
GrandMother:
Oh, Eugene, there's also a sheath and a shield downstairs. Make sure to grab them, they'll be handy.
else
GrandMother:
Ah, I see you've grabbed the sheath and the shield as well

GrandMother:
Here are some more potions for you.

*Eugene recieved some potions*

Eugene:
Thanks grandma...

GrandMother:
Be careful out there Eugene, it's dangerous.

Eugene:
I shall.


BEGIN MAIN GAME.


[/code]


I'm going for a really ridiculous game, I want it to be humorous, but with a solid, albeit wierd, storyline. All mentions of monkeys will be changed to "ape" I'm just in a lazy mood so won't change all occurences.

This beginning is NOT complete whatsoever, I have multiple things to add. Such as the sister yelling and screaming, etc. I want to make the beginning SIMILAR to LOZ: the wind waker. In the sense their is a young main character with a sister and a grandmother, all involved in the beginning of the story.

Share this post


Link to post
Share on other sites
JoeCooper    350
"[color="#1C2837"][size="2"]NOR HAVE I EVER HEARD OF THE MOVIE PRIOR TO WRITING THIS"[/size][/color]

[color="#1C2837"][size="2"]Welcome to Earth![/size][/color]

[color="#1C2837"][size="2"]"[/size][/color][color="#1C2837"][size="2"]the protagonist is a nerd named Eugene"[/size][/color]

[color="#1C2837"][size="2"]Gold star for the name.[/size][/color]

[color="#1C2837"][size="2"]"[/size][/color][color="#1C2837"][size="2"]As Eugene progresses ... [/size][/color][color="#1C2837"][size="2"]But yeah, that's basically the game"[/size][/color]

[color="#1C2837"][size="2"]That's not a game, but then this isn't the game design forum either.[/size][/color]

[color="#1C2837"][size="2"]Did you recently watch Gattaca? At a glance this description reminds me, very slightly, of Gattaca, where (incidentally) the main character takes the identity of a man named Eugene. (You should watch the movie regardless of whether or not it has anything to do with this because it's a good movie.)[/size][/color]

[size="3"][color="#1C2837"][size="2"]Anyway, so I looked at the text.[/size][/color][/size]

[size="3"][color="#1C2837"][size="2"]Shorten it![/size][/color][/size]

[size="3"][color="#1C2837"][size="2"]I wrote this for a practice project I just puked onto the iTunes store called Spell Tanks:[/size][/color][/size]

[size="3"][color="#1C2837"][size="2"][code]1 (Mayor) "Mister Frank Hank! I'm the mayor of Portville. We're under attack and we need your help! Show us how to fight!"
2 (Frankhank) "Did you get the tank I asked for?"
3 (Mayor) "Yes. My staff stayed up all night building it out of car parts and paper mache. And we found some brave young men at Shopmart for your army."
4 (Minuteman Sean) "Whutup."
5 (Frankhank) "Are you ready for battle, son?"
6 (Sean) "Uh, yeah, totally. Dude, if we could just hide out in the mountains, that'd be totally cool."
7 (Mayor) "Alright they're coming! Get everyone in a good spot before they attack!"

(Player arranges units)

8 (Wentworth) "Greetings. My name is Gavin Wentworth and I'm taking this city. What are you gonna do about it?"
9 (Frankhank with guitar) "Rock."[/code]

This was rather longer than I'd like, but every line has a distinct purpose.

#6, for example, characterizes Minuteman Sean while also [i]communicating that the mountains are a good defensive position.[/i] Everything else is either some careful characterization of the world, situation or characters or a hint regarding the game state - or instructional.[i]
[/i]
That said, I would recommend against having a "story" of any kind in-game on your second project.
[color="#000000"][size="3"]
[size="3"][size="2"][color="#1C2837"][size="2"][size="2"]If you jump from something very primitive to your great epic, you're falling prey to the [url="http://www.the-wabe.com/notebook/second-system.html"]Second System Effect[/url]. Read that page carefully.[/size][/size][/color][/size][/size][/size][/color][/size][/color][/size]
[size="3"][color="#1C2837"][size="2"][color="#000000"][size="3"][size="3"][size="2"][color="#1C2837"] [/color][/size][/size][/size][/color]
This kind of story adds substantial complexity and content workload. Do not underestimate the complex bureaucratics of software and fitting all these pieces together, having the different software components negotiate what is supposed to be happening on screen and when and how to respond to user input, how to read scripts, etc.[/size][/color][/size]
[size="3"] [/size]
[size="3"][color="#1C2837"][size="2"]I'm talking about the programming.[/size][/color][/size]
[size="3"] [/size]
[size="3"][color="#1C2837"][size="2"]My first project with a story (that actually came together) was my sixth, excluding games I wrote as a teenager and a variety of applications. And it was just talking heads inserted at different points of gameplay.[/size][/color][/size]
[size="3"] [/size]
[size="3"][color="#1C2837"][size="2"]You also need to develop your actual game design skills some so that you can craft mechanics to artistic visions more effectively.[/size][/color][/size]
[size="3"][color="#1C2837"][size="2"]
In the meantime, if you want to write a story, write a story. I just started writing a novel on a lark in January. I got to 80,000 words or so before I had to take a break for school, and the whole exercise helped my writing and grades.[/size][/color][/size]

Share this post


Link to post
Share on other sites
XDaWNeDX    113
[quote name='JoeCooper' timestamp='1307587474' post='4821183']
"[color="#1c2837"][size="2"]NOR HAVE I EVER HEARD OF THE MOVIE PRIOR TO WRITING THIS"[/size][/color]

[color="#1c2837"][size="2"]Welcome to Earth![/size][/color]
[/quote]
I believe it's the Ape planet, not earth. But that's ok.
[quote name='JoeCooper' timestamp='1307587474' post='4821183']

[color="#1c2837"][size="2"]"[/size][/color][color="#1c2837"][size="2"]the protagonist is a nerd named Eugene"[/size][/color]

[color="#1c2837"][size="2"]Gold star for the name.[/size][/color]
[/quote]
Yeah, I'm modelling this game against my life. OTHER than you know... Freakin ape's attacking, my great grandfather being a legendary hero, that kinda stuff. But other than that, Eugene is me with a different name. So he'll be a nerd, and eventually become a nerd that's not so nerdy.
[quote name='JoeCooper' timestamp='1307587474' post='4821183']
[color="#1c2837"][size="2"]"[/size][/color][color="#1c2837"][size="2"]As Eugene progresses ... [/size][/color][color="#1c2837"][size="2"]But yeah, that's basically the game"[/size][/color]

[color="#1c2837"][size="2"]That's not a game, but then this isn't the game design forum either.

[/size][size="2"][/quote]
[/size][/color]Actually, that "basically the game" starts at this sentence.
Anyhoo, the protagonist is a nerd named Eugene.
[quote name='JoeCooper' timestamp='1307587474' post='4821183']
[color="#1c2837"][size="2"]Did you recently watch Gattaca? At a glance this description reminds me, very slightly, of Gattaca, where (incidentally) the main character takes the identity of a man named Eugene. (You should watch the movie regardless of whether or not it has anything to do with this because it's a good movie.)
[/quote]
[/size][/color]I haven't, but just because his name is Eugene, I am going to have to soon.

[quote name='JoeCooper' timestamp='1307587474' post='4821183']
[size="3"][color="#1c2837"][size="2"]Anyway, so I looked at the text.[/size][/color][/size]

[size="3"][color="#1c2837"][size="2"]Shorten it![/size][/color][/size]
[/quote]
Nah, I'm going to lengthen it. But it's going to be an interactive beginning.

Talking is going to be done fire emblem / LOZ style. EVENTUALLY (when the game is complete) I'll add in some voice actors. I've got a friend who can do an amazing nerd voice.
[quote name='JoeCooper' timestamp='1307587474' post='4821183']
[size="3"][color="#1c2837"][size="2"]I wrote this for a practice project I just puked onto the iTunes store called Spell Tanks:[/size][/color][/size]

[size="3"][color="#1c2837"][size="2"][code]1 (Mayor) "Mister Frank Hank! I'm the mayor of Portville. We're under attack and we need your help! Show us how to fight!"
2 (Frankhank) "Did you get the tank I asked for?"
3 (Mayor) "Yes. My staff stayed up all night building it out of car parts and paper mache. And we found some brave young men at Shopmart for your army."
4 (Minuteman Sean) "Whutup."
5 (Frankhank) "Are you ready for battle, son?"
6 (Sean) "Uh, yeah, totally. Dude, if we could just hide out in the mountains, that'd be totally cool."
7 (Mayor) "Alright they're coming! Get everyone in a good spot before they attack!"

(Player arranges units)

8 (Wentworth) "Greetings. My name is Gavin Wentworth and I'm taking this city. What are you gonna do about it?"
9 (Frankhank with guitar) "Rock."[/code]

This was rather longer than I'd like, but every line has a distinct purpose.

#6, for example, characterizes Minuteman Sean while also [i]communicating that the mountains are a good defensive position.[/i] Everything else is either some careful characterization of the world, situation or characters or a hint regarding the game state - or instructional.[i]
[/i]
That said, I would recommend against having a "story" of any kind in-game on your second project.
[color="#000000"][size="3"]
[size="3"][size="2"][color="#1c2837"][size="2"][size="2"]If you jump from something very primitive to your great epic, you're falling prey to the [url="http://www.the-wabe.com/notebook/second-system.html"]Second System Effect[/url]. Read that page carefully.[/size][/size][/color][/size][/size][/size][/color][/size][/color][/size]
[size="3"][color="#1c2837"][size="2"][color="#000000"][size="3"][size="3"][size="2"][color="#1c2837"][/color][/size][/size][/size][/color]
This kind of story adds substantial complexity and content workload. Do not underestimate the complex bureaucratics of software and fitting all these pieces together, having the different software components negotiate what is supposed to be happening on screen and when and how to respond to user input, how to read scripts, etc.[/size][/color][/size]
[size="3"][/size]
[size="3"][color="#1c2837"][size="2"]I'm talking about the programming.[/size][/color][/size]
[size="3"][/size]
[size="3"][color="#1c2837"][size="2"]My first project with a story (that actually came together) was my sixth, excluding games I wrote as a teenager and a variety of applications. And it was just talking heads inserted at different points of gameplay.[/size][/color][/size]
[size="3"][/size]
[size="3"][color="#1c2837"][size="2"]You also need to develop your actual game design skills some so that you can craft mechanics to artistic visions more effectively.[/size][/color][/size]
[size="3"][color="#1c2837"][size="2"]
In the meantime, if you want to write a story, write a story. I just started writing a novel on a lark in January. I got to 80,000 words or so before I had to take a break for school, and the whole exercise helped my writing and grades.[/size][/color][/size]
[/quote]


The storyline only forces the following details in the programming:

1. Weapons, shields and possibly sheath's as equipment.
2. Player's interacting with other NPC's.
3. Player's interacting with Items.
4. A battle scene
5. An option at the end to type a name and load it into a string.
6. Multiple types of enemies.

That's basically simple to code.
1 will be slightly harder, but not impossible.(durr)
2/3 will be slightly difficult, but very easy none-the-less.
4 will be a little tedious to code, but simple.
5 is EXTREMELY easy.
6 will be as simple as adding a for loop/if else if to 4.


Currently, this is just me working on the story while I'm at school, so it hasn't been implemented yet. When I DO get it implemented, I'll see how it feels. If it's too long, I'll shorten it. If not, I'll make it longer.

The beginning will be interactive. Not tedious.

I know what I'm doing, and it still needs to be put INTO a game... So, any changes to details will be done there. Thanks for your information though, but I'm not falling victim to second system effect. This is the first storyline I've wrote. Ever.

Share this post


Link to post
Share on other sites
XDaWNeDX    113
[quote name='Elovoid' timestamp='1307605389' post='4821234']
Are you looking for constructive advice and feedback or praise and attention?
[/quote]


Both. :D The reason I turned down everything in the past post is because I didn't. I'm taking his advice, watching that movie. And I don't want a quick 5 sentence beginning... I want it to actually have a story to it.

Share this post


Link to post
Share on other sites
JoeCooper    350
"[color="#1C2837"][size="2"]I'm not falling victim to second system effect. This is the first storyline I've wrote"[/size][/color]
[size="3"] [/size]
[size="3"][color="#1C2837"][size="2"]I'm talking about the software and production. You've written one game. This is your second. And it's about architecture, not features.[/size][/color][/size]
[size="3"] [/size]
[size="3"][color="#1C2837"][size="2"]I realize it may be the case that you need to take a swing at it to understand what I'm referring to. I did, too.[/size][/color][/size]
[size="3"] [/size]
[size="3"][color="#1C2837"][size="2"]I'll make one more comment try to illustrate the difference, then give some hints that may help.[/size][/color][/size]
[size="3"] [/size]
[size="3"][color="#1C2837"][size="2"]On my last project I wrote the same game twice from scratch. [/size][/color][/size][color="#1C2837"][size="2"]The first iteration had an automatic, square map and no tools for artistic expression, icons, or menu. It was 6,000 lines of code and took a week.[/size][/color]

[color="#1C2837"][size="2"]The second iteration, with the talking heads and levels and such, had 17,500 lines, a grand total of about 20 drawings and took nearly three months.[/size][/color]
[size="3"] [/size]
[size="3"][color="#1C2837"][size="2"]Now for those hints.[/size][/color][/size]
[size="3"] [/size]
[size="3"][color="#1C2837"][size="2"]When you design software, you're designing a bureaucracy. You need the intellectual tools to do this. Understand and respect the Model/View/Controller pattern. Understand the [i]observer pattern[/i] and object oriented principles. Understand the multiple inheritance tools of your language. (C++'s MI differs radically from C# and Java.)[/size][/color][/size]
[size="3"] [/size]
[size="3"][color="#1C2837"][size="2"]Assume that you will have a [i]third project[/i]. This means two things. One is that if your current (second) project fails and you give up, [i]do not abandon your third project. [/i]Second, remember that if a cool idea is too much for you, it is OK to put it off onto your next project or further because this project is not your magnum opus.[/size][/color][/size]
[size="3"] [/size]
[size="3"][color="#1C2837"][size="2"]About the writing.[/size][/color][/size]
[size="3"] [/size]
[size="3"][color="#1C2837"][size="2"]It's a bit close to home. This is sometimes called the [url="http://www.writerswrite.com/journal/sept97/keegan.htm"]autobiographical urge[/url]. You might try to avoid falling into the trap of forced epicness; do not underestimate the power of understatement. The best game writing is other minimal and [i]pithy[/i] or written well enough to add some genuine entertainment value. Sometimes they are both, but if they're neither, they wind up on [url="http://www.escapistmagazine.com/videos/view/unskippable"]Unskippable[/url].[/size][/color][/size]
[size="3"] [/size]
[size="3"][color="#1C2837"][size="2"]Try to find other ways, beside a lengthy narrative, to [i]characterize the scenario[/i]. You can have all the story you want, but you need more tools in your bag. A game is not a script. It is an entertainment product featuring game rules, visual arts, music, an environment you can move around in. Can any of this express the same content? Yessir.[/size][/color][/size]
[size="3"] [/size]

Share this post


Link to post
Share on other sites
XDaWNeDX    113
No, I understand. But I'm working at this from beginning to end. In that direction, although I'll only REALLY need to make the first 3/4 maps before it's probably going to just be adding in NPC's, etc and not much extra programming. Although, boss fights, etc will need to be programmed in. Which is why I'm going to program it to be able to later add in the function for the boss fight, then add about 2-3 lines of code to make it display the boss sequence, instead of the regular monster sequence.

I've got a method to my madness. The way I will work at this game is in chunks. The first part was removing the damn lag from the tile array. I fixed that by making the bitmap a video bitmap, rather than loading from memory... Which I thought I did but I mised 1 line of code so yeah. But that's off topic. My check list will be checked in the following order.

[list][*]Working map with 6 DIFFERENT tiles (loaded into a full screen game, just 6 different bitmaps... )[*]Collision detection[*]Scrolling maps ~ Character stays JUST ABOUT the middle of the screen. I want it put off to the side ever so slightly just to have some little design difference. But in this stage, the ENTIRE MAP will be loaded. So even things that AREN'T displayed will be loaded at this point.[*]Only load what is displayed. ~ This fixes that lag problem that'll probably arise[*]Main screen ~ New Game, Load Game, Options, Exit[*]Create the beginning of the game UP UNTIL THEY GO INTO BASEMENT (if creating the NPC chats is too difficult, then first create NPC talking)[*]In the debugging map, I'll create some way (which I already have a theory for, and it should work) to interact with Items / NPCs on the map[*]In the debugging map, I'll create doors, to allow players to move from map to map. So I guess this would be 2 debugging maps. :D[*]Create an extremely simple battle sequence that will allow easy upgrading to the battle sequence I want.[*]Create an item class (well, 4 different item classes) and a few items. HP Potion, Sword, Shield, Sheath.[*]BEGIN Implementing LUA. It'll be difficult, but I'm sure I can do it if I do some research.[*]Finish beginning of the game[*]Record a recording using my manly man narrator voice I've been working on for the "A long time ago" story... Cuz I'm changin how that will be said so I can be the narrator there. :D Obviously I can't act as an old grandma...[*]Implement that manly man narrator voice! :D[*]Release this version to facebook, and NOWHERE ELSE. (I don't need to be pressured.)[*]Create the UI basd off of some code I will have added earlier.[*]Create a database to hold player info... maybe. Depending on what I want to do when I get here. I may allow users to cheat and edit their player's stats by saving them in a .txt file, may encrypt the files, or may even hold all player info on a server(which means online interactions possibly) But this isn't guaranteed. However, there WILL be a database to hold high scores. Such as lowest completion time, etc.[*]Begin making the fourth map. (currently have eugene's room, main living room in the house and the basement) This room will be the kitchen, and will store an easter egg, as well as a hint for some pretty big secret. The map itself will be done, I'll just need to know WHERE to put the easter egg, and HOW TO WORD the hint.[*]Make the fifth map. Outside of the house.[*]Start getting people to draw graphics for this game. (Seeing as at this point it'll seem as if it's going somewhere, artists will be easier to gather.)[*]Make the rest of the maps, creating bosses, finish implementing lua and everything else that needs to be added.[/list]I WILL have problems, but this is a project that will be completed, if I run into problems that are too large to get around, I'll take a break from it and learn a bit more about making games,possibly make a few smaller games and teach myself some things, but this game is something I want done. This'll be my first major game that I complete and it will be completed someday.

I have a realistic view of 3 months (assuming I'm not busy at all) to complete the first little bit. Just completing the beginning part. No art however, will be implemented. And no lua included yet.

The CItem class will have members to say what the item's description is, etc.




The CPotion class:
[code]
int m_HPHeal; // How much HP this potion heals, 0 for none.
int m_MPHeal; // How much MP this potion heals, 0 for none.
int m_Amount; // How many potions are left. 0 for none, I REALLY hope you didn't need me to say that.
int m_PoisonChance // Chance to have the potion fail and poison you. 0 for no chance, 100 for always poison
int m_StatChange: // What stat does this potion change. 0 for no stat, 1 for str, 2 for dex, etc. And for anybody cheating this game, changing this variable to a specific value will prompt you with a secret. I think of everybody, not just hackers.
int m_Teleporter; // Where does this potion teleport the player? 0 for no teleportation
[/code]

I KNOW I forgot a few variables here.

The reason theres so many that won't have been implemented yet, is for ease of implementation later. Including these allows me to code additional if's to decide where to teleport them, which means later when I want to implement teleportation via potions, I won't have to go change 100's of lines of code

The CWeapon class:
[code]
int m_Damage;
int m_Weight;
int m_Type;
[/code]
etc, too lazy to write out the variables but they will be in depth to save the writing them out later, and then replacing however many functions within my code to include the new variables.

Share this post


Link to post
Share on other sites
JoeCooper    350
I'll point out some red flags for you to mind going forward.

1) A would recommend a strict [i]cap[/i] on how long you devote to this project, possibly 3 months, certainly no more than 6.

One of the main things you're learning is how to architect a program. When you realize you're doing it wrong, you'll need to digest what you've learned and do another project, possibly from scratch. You want to do short projects so you can do more, in order to get more practice and learn more.

2) [i]Due to the hindsight if doing exactly what you're doing,[/i] I ordered my most recent project a little different...

The first milestone looked like [url="https://www.facebook.com/video/video.php?v=10150112860268686"]this[/url]. Here the core data structures including map positions, units and states are implemented, the game loop is basically implemented, [i]and the core action is implemented[/i].

"Core action" here means that one unit (which touched and dragged) and be instructed to reposition elsewhere.

Literally, the controller class has a single method "moveUnit" which would move a unit and make a battle happen if necessary.

So the first milestone had a focus on the core action. With a few more bits, it was a playable [i]game[/i] if completely art-free. This is a tetristic view and doesn't constitute a whole product, but is minimally necessary.

After that, I had clarified all the presentation and art expression needs (how can levels be scripted? what needs to be possible?) and began build the software up to where it could facilitate such things. I did not mix level construction in with other key things. When it could present levels, a huge chunk of the code was done. It took about a month and a half to get there.

[url="https://www.facebook.com/video/video.php?v=10150153254068686"]This is what it looked liked[/url]. Note how the units slide from position to position.

I'm going to go over how this works with respect to the different classes [i]and[/i] in the context of the "game loop" for you because I had a very poor mental image of this when I started.

This will apply to your project because your art and presentation needs are more complicated than mine.

MoveUnit now used path-finding (A*) to add a set of single step moves to a queue which are executed asynchronously. Every frame, a 'do stuff' instruction would be sent to the controller where it would perform movements, once per frame. When I added animations and speech and other activity disruptions, the 'do stuff' instruction would do nothing and just return while 'blocked'.

So we'd wind up with a cycle like...

---user instructs movement from point A to B (I'll skip the details, except that literally a "TouchesEnded" or "MouseUp" event was executed in the middle of the game loop).
---After determining what's clicked on what, Controller.moveUnit is called...
---Controller.moveUnit finds 4 steps from A to B and adds them to queue...
---paint***GAME LOOP RESTART***
---The controller's "do stuff" method is called.
---The controller now has a queue of moves. It performs the first after rule checks and makes a change to the appropriate Unit class.
---Unit class broadcasts a state change notification...
---The subscribing UnitDrawer class receives it and broadcasts "animation started" notification (and preps its state).
---Controller receives "animation start" notification and sets an "animations are happening" flag.
---Paint. The unit drawer paints the unit as having slid a little slightly... The UnitDrawer class handles its own state to move the image.
***GAME LOOP RESTART***
---Controller is "blocked" by the "animation started" flag; it does zilch.
---Certain inputs are "blocked" because the controller claims not to be accepting new instructions.
---Paint; unit drawer moves a little...

This repeats for several loop iterations until the UnitDrawer decides, at its own discretion, that its animation is complete and broadcasts the Animation Complete notification. Moving on...

***GAME LOOP RESTART***
---Controller, having received this notification, is now unblocked, and moves[i] another[/i] step, taking it off the queue too...

This repeats several times until we come to a destination where there is ALREADY A UNIT!

So what happens then is that the controller, after checking if there's a human player involved, picks a word from a hat, loads that word, declares itself blocked as it is waiting for a spelling, and broadcasts a "word pending" notification.

The View fetches this word, presents the spelling prompt, and the loop continues repeating 60 times a second while the UI is on screen and the controller is blocked, until the player has entered a spelling and tapped "Go".

The controller then unblocks, performs battle logic on the next loop iteration, performs another move if necessary, and so forth and so forth.

So to recap. I built the core game, I had decided on the needs of the scripting (the artistic expression) and built the piece of software to the extent it could facilitate these content needs and presentation needs, rather than mixing levels in with the rest of the todo list.

3) "[color="#1C2837"][size="2"]Create an extremely simple battle sequence that will allow easy upgrading to the battle sequence I want."[/size][/color]

[color="#1C2837"][size="2"]I have no idea what a battle sequence means but if it's radically different from the map view, ala Final Fantasy, than you may want to push a new game loop onto the stack, then bail from it when the battle is over.[/size][/color]

[color="#1C2837"][size="2"][i]Decide on the actual game rules before writing any actual production code.[/i] Do not fail to mind that you're building a game.[/size][/color]
[color="#1C2837"][size="2"]4) "[/size][/color][color="#1C2837"][size="2"]BEGIN Implementing LUA. It'll be difficult, but I'm sure I can do it if I do some research."[/size][/color]
[size="3"][color="#1C2837"][size=2]
[/size][/color][/size]
[color="#1C2837"][size="2"]It's not difficult, just make sure it's appropriate. You will be implementing an action queue of some sort; when a lua function calls methods, it won't block and wait for a few iterations of your game loop to happen.[/size][/color]
[size="3"][color="#1C2837"][size=2]
[/size][/color][/size][color="#1C2837"][size="2"]I decided that I needed an action queue (which supports things like loading maps, creating units, making characters speak, directing the view) and decided that I did not also need a full scripting language, so I simply wrote a crude file format for the action lists. [url="http://burtonvision.com/images/fht1.sts"]Example[/url].[/size][/color]
[size="4"][color="#1C2837"][size=2]
[/size][/color][/size]
[size="3"][color="#1C2837"][size="2"]On a side note, I successfully implemented LUA in my previous, failed project so if you run into implementation troubles (it doesn't perfectly jive with C++), you can contact me for hints. I added my contact info to my project.[/size][/color][/size]

[color="#1C2837"][size="2"]5) The biggest red flag is that you've now described your implementation plan (partially) and I still have no idea what your game is. I'll refer to my not earlier; ask yourself if you can build your game as an artless prototype and it qualify as a game. If not, you have more work to do before you write [i]any[/i] code, even seemingly innocuous display code.[/size][/color]
[size="3"][color="#1C2837"][size=2]
[/size][/color][/size][color="#1C2837"][size="2"]For example, the basic display code in my game, a VertexBuffer class, is designed with a lot of assumptions about what's displayed, how, and the fact that it will be on iPad. It may or may not apply to other games.[/size][/color]
[color="#1C2837"]
[/color][color="#1C2837"][size="2"][i]Finally[/i], I'll note that you should make good use of tools. I wrote this game in C++ primarily because I planned to use the same code on iOS, Android and Window, because Objective-C is poorly supported on the latter two platforms, and because the memory management benefit in Obj-C 2.0 only works on Mac, I decided that C++ would be better for me anyway.[/size][/color]
[color="#1C2837"]
[/color][color="#1C2837"][size="2"]My [i]next[/i] project, which will be on Windows only, will be done in C# because [i]it will save me time and effort[/i].[/size][/color]

[color="#1C2837"][size="2"]Do my reasons for using C++ apply to you? I bet not. I will not discuss languages further because it's something people tend to pass bricks about, but do consider all the tools at your disposal.[/size][/color]

[color="#1C2837"][size="2"]P.S. If you ask, I can share code privately.[/size][/color]

Share this post


Link to post
Share on other sites
XDaWNeDX    113
I know exactly how I want my game to look, feel and just about every single detail about it.

1) I won't have a cap. As in all honesty, I can not provide a realistic estimate as to when the afforementioned game will be in the final stages.

2) thanks for that extremely detailed post, but I'm sure that I will be able to figure most of it out as I go. I have noticed that as I go through my programming I learn things. So I generally program everything ensuring it will be easily changed later on. So if I were to screw something up here, it would be easily fixed.

3} there's another word for what I'm saying. But it's when the player collides with a monster, and then initiates battle. Like FF13, but obviously a much more simplistic battle system.

4) I have never programmed in lua. Er, rather, scripted using lua. Nor have I ever implemented it in a program. But lua makes adding things easier than hardcoding it in the game. So I can add Items, NPCs, etc without having to recompile.

5) The game IS a game. Its the game I wish to make, whether it is popular, succesful or one of the worst games ever created in the history of indie games, it will be something I created and for that I will be proud.

Tomorrow I plan on getting collision detection done. I was going to do it today, but I was busy with some HCORE gaming. (7.0 kdr in combat arms?? ^_^)

As well as collision detection I will add in NPC chats for when the player bumps into an npc. (I don't want the player to walk on the same spot as an NPC cuz that's unrealistic.)

And to top it off, one of the most simple pixel art tilesheets ever created. Except not a tilesheet cuz I don't know how to use one yet. (Although it is probably extremely simple. I've just never tried)

But, maybe to top that whipped topping with a cherry, I may also add in interchangeable maps. Being able to walk into a door and appear in another map.

This one depends on whether or not I have enough time. It would require a little work. Although I'm sure its as easy as redrawing the screen with a new tile array.


At SCHOOL tomorrow, I will do the following.

Create a new method for storing information.

Maps
Items
Monsterinfo
Playerinfo
Where portals lead to
Etc
Etc
Etc

And that's my plan for tomorrow. Whether I get it all done or not, as long as I've done something I'm happy.

Share this post


Link to post
Share on other sites
JoeCooper    350
The cap is for the current iteration of the project. I can tell by the details you give that you have no idea how much you're going to want to throw it out in a few months ;) I've nothing more to add, just do not fail to have a 3rd project and don't forget that Beethoven's 9th symphony wasn't his 2nd. Have fun, keep us apprised.

Share this post


Link to post
Share on other sites
Elovoid    108
[font="arial, verdana, tahoma, sans-serif"][size="2"][quote name='XDaWNeDX' timestamp='1308118798' post='4823488']
At SCHOOL tomorrow, I will do the following.
[stuff]
And that's my plan for tomorrow. Whether I get it all done or not, as long as I've done something I'm happy.
[/quote]

Don't get me wrong but at school you should do school stuff unless you mean in your free time.[/size][/font]
Education is a big plus in your career (be it game industry related or not) and will supply you with lot's of skills that will help you with programming and developing games (even as a hobby project). I wish I had listened to my father about this and I'm saying this being 30 now and with a rough start into real life. You can smooth out your own start with good education and I recommend not to skimp on that.

Doodling character sketches in your notepad should be ok but wandering off into some fantasy world/game you are creating and designing game functionality leads to fear (of tests), fear leads to anger, anger to hate and hate to the dark side of private lessons to get back on track with the schedule.

Share this post


Link to post
Share on other sites
XDaWNeDX    113
[quote name='JoeCooper' timestamp='1308135000' post='4823566']
The cap is for the current iteration of the project. I can tell by the details you give that you have no idea how much you're going to want to throw it out in a few months ;) I've nothing more to add, just do not fail to have a 3rd project and don't forget that Beethoven's 9th symphony wasn't his 2nd. Have fun, keep us apprised.
[/quote]
I've already wanted to throw it out the window. I don't, and I won't.

@elovoid its on my breaks. I understand education is important. But I would never draw concept art at school... I have trouble drawing stick figures. I COULDN'T draw concept art ^_^

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this