Results 1 to 9 of 9
Just something I've been toying with over the last few days. It's a text-mode turn based strategy game, which I've called Turious.
When I started this ages ago it was ...
- 11-01-2009 #1Linux User
- Join Date
- Jan 2006
- Posts
- 414
I wrote a little game...
Just something I've been toying with over the last few days. It's a text-mode turn based strategy game, which I've called Turious.
When I started this ages ago it was in C++, but when I took a look at the source I wasn't happy with how I'd done some things, so I dumped the lot and rewrote it in plain C.
It's nothing particularly special, but if you want to have a play here it is:
http://203.143.236.125/turious.tar.gz
It's just the source (GPL of course) so you'll have to compile it yourself (just run make, it's not that hard). I've tried it on 32 and 64 bit systems.
The game has:
2 classes of soldier
3 classes of civilian
3 levels of difficulty (setable from the options menu)
up to 5 ai enemies (setable from the options menu - although if you feel like editing the makefile.inc you can up this to however many you want)
same basic in-game help
If you have a play let me know
- 11-01-2009 #2
I wanted to have a look at the sourcecode.
For Reviewing what you did etc.
And well I didnt have had a look let. Well the Make Files look nice
But, when I started the SourceCode Revieuw I noticed this thing that is REALLY annoying (sorry to be negative) and thats that you use main.c ALL THE TIME.. its really annoying for revieuwing your sourcecode
so, little advice. use 1 main.c at the most.
Ill have a look now and let you know what I'd think off your SourceCode + the Game
- 11-01-2009 #3
- 11-01-2009 #4Just Joined!
- Join Date
- Jul 2009
- Location
- Chicago, IL
- Posts
- 9
I'll give it a go next time I am on Linux. I looked though the code and it looks neat, your coding style is also good (although your file names could be named a bit better).
- 11-02-2009 #5Linux User
- Join Date
- Jan 2006
- Posts
- 414
The main.c thing was an experiment on my part, I wanted to try it out as a means of easily tracking the main file for each section of the game (semi pointless in this case due to the small size of the project)... it worked for that, but was a pain in the *** when there's half a dozen main.c's open in the editor (another experiment, used Geany - which is quite nice), so I won't be doing that again.
Might change it, as there's still a couple of things I'd like to add to the game. Coding style is more or less 'kernel coding standards' so glad you like it.
btw RobinVossen, what where the 'nice little hacky things'? I didn't think I did anything particularly interesting in this (which tends to be a rather rare thing for me
).
Last edited by darkrose0510; 11-02-2009 at 01:00 AM.
- 11-02-2009 #6
- 11-27-2009 #7Linux User
- Join Date
- Jan 2006
- Posts
- 414
My little game is growing up...

I've been experimenting with SDL lately, I've written a widget library which is powering the game. When I get the graphical version working I'll post the code.
- 11-27-2009 #8
Here's a little bug fix for src/player/main.c:
without this, you have to buy a huge amount of brigadiers to attack someone with a large army.Code:214c214 < if (sold > players[0].brigadiers) { --- > if (brig > players[0].brigadiers) {Linux user #126863 - see http://linuxcounter.net/
- 11-27-2009 #9Linux User
- Join Date
- Jan 2006
- Posts
- 414
Thanks Roxoff, just made the change, and the tarball above has been updated.


Reply With Quote

