View Full Version : Teach me how to code!
Guys, next year one of the classes im taking is Digital Logic, which means coding. Coding with any language you want. Im thinking Python cause people say its easy. Only problem is I dislike looking at tutorials, and un aware of where to begin.
We do ened to make a final project though at the end of the year i think, and so im thinking of something to do.....
One of my friends made a working LAN chat, and one of my friends made a working Internet browser, but i've always been into games, not useful programs, so im thinking a simple game!
From playing Freeway Warrior (well, reading it I guess) I've decided i wanna make a simulation of Post Apocalyptic Texas, where the player is tasked with doing, well, whatever he wants really, but there'd be linear elements, like;
Helping a bus load of survivors reach Big Springs, a haven for people not viced by the wasteland (Good ending)
Helping a Biker gang kill the bus load of people (and getting all the fuel the people had on the bus, thus helping the biker gang reign over the texas wastelands until they run out of fuel)
Barely getting involved (current neutral ending, because i can't think of anything)
Now Im thinking that so far the game would probably consist of a world map and local maps of towns and encounters. Things like ammo and guns would be very sparse (well, maybe. If guns were sparse fuel would be just as sparse, would it no?), because its years after a nuclear war, right? Instead, people still use things like swords, arrows, axes, all that fun stuff, as well as vehicles, and mounts (like horsies, radiated and not radiated)
I'd also kind of like to give the player the ability to create his own ending to the story, like helping out villages, becoming the leader of his own bandit gang, etc
Thats all I got so far. The problem would be actually figuring out how to code it. I know next year and Digital logic are quite a ways away, but I wanna get a head start!
The Fifth Horseman
15-03-2010, 02:04 AM
Personally I'd suggest C++, but that might just be me.
Also note that what you described is anything but simple. The more freedom the player has, the more things you have to account for in the game engine.
World map... well, you won't have anything in the way of graphics to start with, except what you code yourself.
First see if you can make an almost completely linear game. Then work on expanding it.
_r.u.s.s.
15-03-2010, 10:45 AM
if you've never coded before and want to learn coding you should start with a language semantically created for learning, so it would be either pascal or delphi
but if you just "wanted it to quickly be done and i don't care about coding that much", i'd probably pick java
also, i don't what kind of "languages" do they allow using, because if you only want to create a game and nothing else, you could even pick programs like game maker, that would be perfect for someone who never coded before and wants to create a game and don't bother about coding much later
Tomekk
15-03-2010, 04:13 PM
I could pass on what I know of C++. :)
Peter
15-03-2010, 07:32 PM
Don't be a lazy bastard and read a tutorial. They are there TO TEACH YOU HOW TO PROGRAM
why should we redo the work somebody else has already done ?
supa_mario
16-03-2010, 05:13 AM
lol programming courses have weird names. At our school it's called Information Science. We're supposed to be learning Java but we usually just end up playing Counter Strike on LAN.
If you're planning on learning how to make a game. The only language that you'll actually have any visible results within a year is action-script. Although nowhere along the lines of what you're wanting. The trouble with action-script is that it is quite a lot different from all those other languages, so once you learn it you'll be back to square one when you want to learn something like C++ or something. It will help with the whole logic of programming however.
hunvagy
16-03-2010, 05:51 AM
Fubb, as Fifth mentioned before, what you described is not simple, and definitely not easy, if you have never coded in your life. Also IMO it's really not the pick of language that is relevant, but the mindset and the logics behind what you do. But the suggestions before me are pretty valid, if you want the easy way out then java it should be. If you want to do it in a windows environment, I'd suggest to stay away from Pascal, because that most likely won't run :) Delphi might be a good choice, as it is fairly easy to incorporate graphics in there, though I can't vouch for performance, but that is not your concern here, I guess. Also take into account, that if your game features any kind of enemies, make them static like in a gamebook, or else you'd have AI programming at your hand, and I sincerely doubt you'd have the time for that :)
arete
16-03-2010, 06:40 AM
"Guys, I want loads of clean clothes, and i want them fast, easy and they need to smell nice, but i don't wanna learn how to use the washing machine!! What can I do??
Please don't tell me to read the manual, cos I hate reading the manual.
Would you help me wash them? I guess I can figure out where to get the powder, and the fabric softener's hard to use, but I'm thinking of getting this ultra-high tech process going so that I can wash really well.
Any suggestions?"
_r.u.s.s.
16-03-2010, 03:53 PM
lol programming courses have weird names. At our school it's called Information Science. We're supposed to be learning Java but we usually just end up playing Counter Strike on LAN.
If you're planning on learning how to make a game. The only language that you'll actually have any visible results within a year is action-script. Although nowhere along the lines of what you're wanting. The trouble with action-script is that it is quite a lot different from all those other languages, so once you learn it you'll be back to square one when you want to learn something like C++ or something. It will help with the whole logic of programming however.
why is information science weird..? that's most probably the most common name for "the computer thingy". and what do you think IT stands for?
also, with game maker he'd achieve way more than with actionscript, as a newbie
I've used game maker.....it lacks the power i need. Me and a friend were trying to make a greek-mythology theme'd game but yea......only so much can be done with game maker....
also Arete, shush! :p
fine, i will read tutorials :\ and all that jazz....
And i have done some scripting (only Auto-It though) but that was like 2 years ago, i don't remember anymore of it
supa_mario
17-03-2010, 05:23 AM
why is information science weird..? that's most probably the most common name for "the computer thingy". and what do you think IT stands for?
also, with game maker he'd achieve way more than with actionscript, as a newbie
It would make a lot more sense just to call it programming. Or 'copy everything out of the book while the teacher does his own thing. '
hunvagy
17-03-2010, 07:00 AM
It would make a lot more sense just to call it programming. Or 'copy everything out of the book while the teacher does his own thing. '
Which kinda defeats the whole meaning of learning to code. And it's called Information Sciences for a reason: AI, Databases, Algorythms etc. are Informations sciences. And coding is the last thing you do, and with most of today coding languages, it's a job that even a monkey could do :p At least that is what we've been told, and I do think there is truth in there.
The Fifth Horseman
17-03-2010, 09:20 PM
I've used game maker.....it lacks the power i need. Me and a friend were trying to make a greek-mythology theme'd game but yea......only so much can be done with game maker....
also Arete, shush! :p
fine, i will read tutorials :\ and all that jazz....
And i have done some scripting (only Auto-It though) but that was like 2 years ago, i don't remember anymore of it
Well, to have a starting point, find a gamebook with an engine similar to what you want and try to replicate it in software. What you need to pay attention to is the character creation system, how the combat works and how to manage the inventory. The rest should (should!) be straightforward once you have those worked out.
Also, if you're going with C++, there is a library called "Allegro" for all your graphic needs.
If you want to go with Freeway Warrior, the first book is accessible at http://www.projectaon.org/en/Main/HighwayHolocaust
Well, to have a starting point, find a gamebook with an engine similar to what you want and try to replicate it in software. What you need to pay attention to is the character creation system, how the combat works and how to manage the inventory. The rest should (should!) be straightforward once you have those worked out.
Also, if you're going with C++, there is a library called "Allegro" for all your graphic needs.
If you want to go with Freeway Warrior, the first book is accessible at http://www.projectaon.org/en/Main/HighwayHolocaust
Thanks for the link...so this game book is just simple html docs with hyper links? Thats quite neat, even I can do that!
at least I think I can...The hyper links and stuff I understand easy, how to set the back ground as the gray with the 'freeway' warrior sign is another thing, but then again thats prolly just a header that one could set in MS word, Open office writer/web, etc.
Once I get some free time I'll tinker around a bit and see what I come up with :3:
Thanks for the link Fifth!
The Fifth Horseman
18-03-2010, 09:34 AM
You're kind of entirely missing the point. Writing a gamebook versus implementing its' mechanics in a software program are two different things.
Do yo umean kind of making some sort of shell capable of running the game book files or something?
Im yound and niave, FORGIVE ME!
The Fifth Horseman
19-03-2010, 04:46 AM
A shell is a description as good as any. For practical purposes, though, you'll want to split the files into separate data files for easier handling - I'd suggest keeping each paragraph in a separate file.
And you'll have to develop your own basic structure for the game data files - if you want to use HTML files from other sources, you'd have to write your own parser in the first place (and that's assuming they are structured well enough for the utility to avoid issues).
To begin with, you'll need to be able to:
1. Display a paragraph from a text file on the screen.
2. Present the player with a list of choices.
3. Move to the paragraph the player selected... IF it's an allowed choice
That's the basics common to each and every gamebook. :p It's also only the beginning of your trouble, because you'll find yourself doing these next:
1. Break up a multi-screen / multi-paragraph entry into separate screens and allow the player to move forward and backward.
2. Add game flags and inventory to make some of the choices dependant on the currently triggered flags and the presence (or lack of) inventory contents.
3. Add support for forced moving from paragraph to paragraph (no player choice), only requiring player confirmation to execute the move.
4. Add support for random number generation and forced move from paragraph to paragraph dependent on the generated number.
5. Add events affecting the player (health, inventory etc) during the gameplay.
6. Add combat engine
7. Add support for different weapons.
8. Make sure 5, 6 and 7 don't mess up the rest of the game. :)
Good luck. :)
The Fifth Horseman
19-03-2010, 06:20 PM
Okay, I might have a few things you can experiment with for your engine (IMHO it's easier to develop an adaptable engine and then create custom data for it).
You can be the Stainless Steel Rat, as a simple "straight" paragraph game with no combat and minimal random nuber generation (coin toss) http://www.mediafire.com/download.php?enzdzmwy2nk
Golden Dragon: Temple of the Flame as a slightly more complex title, with statistics, inventory, skill checks and combat. http://www.mediafire.com/download.php?jzyodvzdmm3
Barbarian Prince, as an example of a map-based semi-nonlinear adventure game http://www.mediafire.com/download.php?yk4miinjjmi
hunvagy
20-03-2010, 08:26 AM
Heh, maybe I should check these out, too :) Anyway just wanted to add a tidbit: If you really want to make your life easy (and you decide on one of the 4th Gen Languages) XML could help you in a lot of ways. Combined with the WPF (Windows Presentation Foundation) you really could do some good looking stuff without too much hassle :)
_r.u.s.s.
20-03-2010, 10:48 AM
hey fubb do you want to be able to run the game on all os?
vBulletin® v3.7.1, Copyright ©2000-2025, Jelsoft Enterprises Ltd.