ENIGMA Forums

General fluff => Off-Topic => Topic started by: luiscubal on October 10, 2011, 01:10:39 pm

Title: Terrena a14 - my game
Post by: luiscubal on October 10, 2011, 01:10:39 pm
EDIT 5: Alpha 14 released - MUCH improved artificial intelligence(special thanks Wikipedia for helping me implement a binary heap that allowed me to implement a fast dijkstra's algorithm).
Fixed bug that caused AI to be aborted when taking a card from the deck after doing some actions before.
Added new terrain: Midnight Field, which is really hard to get right now
Changed some terrain costs/gains. I believe the game is a bit more balanced now.
Added new unit: War Balloon, which added some needed diversity to the Sky Civs deck units.

EDIT 4: Alpha 13 released - Made threaded loading optional - disabled by default because it was causing trouble on some computers. Both threaded loading and render textures can be activated by editing the Data/config.xml file.
Added the "Sea Adventures" deck, which includes several new cards, including one new terrain, some previously hard-to-get terrains, new units and a new event/magic card.
Now using mipmaps to ensure smoother zoom out appearance.

EDIT 3: Alpha 12 released - Improved general interface, added a few new cards and added a timeout to computer actions that forces AI to end turn if "next move" computations take too long.

EDIT 2: Alpha 11 released - Fixed a bug in the unit "quick action" menu, added a couple of new cards, modified a few old ones and introduced the concept of "picking a deck". As a result of these changes, the game should be much more balanced, but some harder-to-use cards(such as the "Swamp") will be harder to come by now. I intend to fix this by adding further decks in the future.

EDIT: Alpha 10 released - New version includes a number of improvements, including support for Intel GPUs and .NET 3.5. The new version is now a bit more configurable, a little bit prettier and (I hope) easier to understand(actions like "Move unit" should now be easier to figure out)

Not ENIGMA related, but I figured I'd post it here anyway.

Today, I'm releasing the 7th alpha of my game - Terrena - to the world.
This is the first public version of my game. I'm hoping to get valuable feedback so I can improve the game.

(https://lh4.googleusercontent.com/--3mlJupUC-c/TpMsL6dV0VI/AAAAAAAAAAs/W5Hp3PGxyAo/s400/terrena.png)

So what is it?
Terrena is a strategy game that combines elements of TCG(trading card games) with board games.
Players start with a tile called "capital" which they must defend from other players and the goal is to conquer all capitals.
For that, players must expand their territory by placing on the board terrain and unit cards, and balancing it all so they have enough resources
Additionally, event cards allow special effects to happen to improve the gameplay experience.

How does it work?
There are seven types of resources: Money, Food, Earth, Water, Fire, Air and Ether.
To place a terrain in the game, one must spend resources(typically money for some of the basic types of terrain) but, in exchange, terrains may give resources at the start of a turn.
With enough resources, one can also place units on the game, which can be used to conquer enemy territory(and so get more terrain). Conquering all enemy capitals means victory.
Each player has a deck of cards and one may take a card from the deck to his/her hand by "buying it"(losing 1 of the resource money). Once in the hand, the players can use the cards they have.

Is it complete?
Not even close. There are not enough types of terrain, units and events. Additionally, there are some images that could use improvement.
The AI is also not perfect and there are some gameplay features that I haven't added yet.
Also, the game is not very balanced right now. I hope future new cards will improve this.

Computer requirements
In spite of being a 2D game, Terrena seems to be pretty demanding in terms of requirements. On one hand, you'll need a decent resolution(which pretty much everyone has anyway), but even on some GPUs the game can sometimes drop to 10FPS. Generally, the more resolution the slower the game.
Also, owners of old Intel cards with no FBO support are out of luck. If the game is essentially an empty black window after taking a card from the deck, you may not have the minimum requirements.
In terms of software, I tested this on Linux Mono and it probably works on Windows too. It requires .NET framework 4.0(tested in Mono 2.10)

Note: If you are using Linux, please run the game with "sh terrena.sh" instead of directly running the executable with Mono.

Download
http://dl.dropbox.com/u/6459451/terrena-a14.zip
Title: Re: Terrena a7 - my game
Post by: TheExDeus on October 10, 2011, 05:04:37 pm
Is it made with ENIGMA? It has FBO support, so I guess not. Also, you load fonts and xml files from the directory, so unless you made some great additions, I guess you didn't use ENIGMA... Although it seems that it could easily be made in it.

About the game - I wasn't able to do much. I think I built something, and then attacked something, but I wasn't able to understand what. Also, the graphics are quite cool and amusing. Its amusing because it seems that you painted the outline either by hand or with some bad tool, but then spiced it up with some cool gradients.

Potential is there though. Maybe later when you make a tutorial or something I will be able to play it proper. Mainly because I am bad at these kinds of games so I need a very detailed walktrough to get started.
Title: Re: Terrena a7 - my game
Post by: luiscubal on October 10, 2011, 05:32:30 pm
It's not made with ENIGMA.
You're not the only user having trouble with understanding the interface, so I'm guessing I might be doing something wrong. I might do a series of introductory tutorials(kind of like campaigns), but I probably will have to change some things in the interface.
All graphics were made by me using Paint.NET and Pinta.

Thank you for trying though.
Title: Re: Terrena a7 - my game
Post by: Fede-lasse on October 11, 2011, 05:08:54 am
If it requires .NET, I assume that it's made with C#?

Also, curse you! I was about to post a "dead again" topic.
Title: Re: Terrena a7 - my game
Post by: luiscubal on October 11, 2011, 10:15:53 am
Quote
If it requires .NET, I assume that it's made with C#?
Correct. I'm not really a fan of other .NET languages.
Title: Re: Terrena a7 - my game
Post by: Jbolte on October 11, 2011, 04:28:17 pm
Very interesting game so far, I like it. I've been trying out SFML quite a bit lately as well. I recently made the switch to using C#, since I have more knowledge with C# than C++, but it's become hard for me to figure out how to manage loading images appropriately.
Title: Re: Terrena a7 - my game
Post by: luiscubal on October 11, 2011, 05:40:34 pm
Quote
Very interesting game so far, I like it.
Glad to know.

Quote
but it's become hard for me to figure out how to manage loading images appropriately.
I don't know what's the best way, but here's what I do:

I have a class named "ImagePack" that essentially contains a Dictionary that associates strings with textures. I tell ImagePack which textures I'll need and the class loads them. Then, when I dispose the class, it disposes all textures it contains.
For instance, all terrain/unit/event textures are in an ImagePack. So in case of Game Over, the game releases all those textures.
I handle card textures a bit differently, since although cards are textures, they are generated at game-time, rather than being on some game folder. I keep those in a separate dictionary, unrelated to ImagePack, and generate those textures as needed. So if the game hasn't encountered a card yet, then that card hasn't been rendered yet either.
I hope this helps. (some of the things I said here probably also apply to other languages)
Title: Re: Terrena a7 - my game
Post by: IsmAvatar on October 11, 2011, 11:46:02 pm
This is similar to how LateralGM manages the icons. We have a .properties file that maps string keys to icon paths. Of course, being Java, garbage collection is handled by the JVM.
Title: Re: Terrena a7 - my game
Post by: Fede-lasse on October 12, 2011, 04:01:59 am
Quote
If it requires .NET, I assume that it's made with C#?
Correct. I'm not really a fan of other .NET languages.
Hey, that's cool; I use C#, too.
Title: Re: Terrena a10 - my game
Post by: luiscubal on October 13, 2011, 12:10:57 pm
Updated the game to version Alpha 10.
I'm hoping this new version is easier to understand. Intel GPU users should definitively update to this version.
There is still a lot more to add, though.
Title: Re: Terrena a10 - my game
Post by: Rusky on October 13, 2011, 12:37:50 pm
Although running it in Mono still has the issue of not searching the working directory for dlls, the interface has improved a ton. There is much less hunting through menus to find things, and the text at the start helps massively in knowing what to do first. The rotating selection tile is somewhat distracting (and probably unnecessary), and the resource/card system, battles, dice-rolling, and the current player could use a little more explanation interface-wise, but mostly it's good.

However, some games the cards and resources I'm getting are rather unbalanced now. I can't seem to manage having both cards I can use and resources I can use them with, so I just sit on my tile doing nothing until I die. The computer players are interesting but also rather close together, and moving the camera around is difficult (maybe middle click panning instead of edges?). I'm also not always sure where the units are allowed to move (not on rivers? on others' tiles? etc), where tiles are allowed to be placed (hidden island requires water underneath, not just around), or which units are whose (maybe recolor helmets/sails instead of just circles). Finally, the cards could use an interface improvement similar to the character, to avoid modal menus just to decide whether to build as well as to show the information on the card in a more readable way from the main screen.

edit: after playing for a while it seems the units have reverted to their old behavior? I have to double click them to do anything?
Title: Re: Terrena a10 - my game
Post by: luiscubal on October 15, 2011, 06:08:21 pm
Alpha 11 available.
The rotating tile has been removed and the game should be easier to handle now(the cards should be more balanced thanks partially due to the concept of "picking a deck". Also, the initial position of the players is now random. About what whether a position is valid(for example, to move a unit), this version should make things much clearer.
The "quick action" menu not appearing in the units is a alpha 10 bug, fixed in this version.
Also, the new version has fireworks for those who win the game.

As for the other problems you listed, this version hasn't fixed them yet.
Regarding the hidden island requiring an ocean beneath - that's because the hidden island(like volcanos, jungles, etc.) are a terrain "promotion". You can see what the base terrain is by looking at the top right of the card.
Title: Re: Terrena a11 - my game
Post by: Rusky on October 16, 2011, 07:58:42 pm
Ah, good. The cards are much more balanced now, and I like the randomized positions.

Valid movement positions probably only need to be highlighted on hover, like placing terrain- when the majority of the screen turns red my first thought is "oh no death" :P

It would also be nice to start out further zoomed out, and to make zooming out less artifacty (esp. the grid lines, which can disappear or be missing pixels).

I also must say that now that the cards issue is fixed, it gets somewhat tedious to click though all the computer actions (since they do so much more).

Finally, I'm getting another text bug- the deck labels have some strange flickering and changing characters at the end, including both unicode-squares and others.
Title: Re: Terrena a12 - my game
Post by: luiscubal on November 11, 2011, 10:49:27 am
The new version should make computer turns much less tedious.

Also, while I would like to make zoomed out textures more smooth, I don't know how to do so. :(

EDIT: Actually, mipmaps seem to be what I'm looking for. Next version will include smooth textures for zoomed out situations.
Title: Re: Terrena a12 - my game
Post by: Rusky on November 11, 2011, 11:30:50 pm
The new version crashes after showing "loading..." for a bit after I choose a card pack. No errors, just quits.
Title: Re: Terrena a12 - my game
Post by: luiscubal on November 12, 2011, 08:33:40 am
What? Not even an exception? No stack trace? Nothing?
That definitively shouldn't happen... :(
Does it always happen or only some times? Does it happen with all decks? All languages? I can't seem to reproduce the issue...
Title: Re: Terrena a12 - my game
Post by: Rusky on November 12, 2011, 11:23:29 am
Correct- absolutely no output, every time for all decks and languages. I'm running it with "LD_LIBRARY_PATH=. ./Terrena.exe" from the top directory like I have in the past.
Title: Re: Terrena a12 - my game
Post by: luiscubal on November 12, 2011, 11:45:29 am
What does "echo $?" give?
Since it happens on loading time, I'd guess it would be a loading problem, but if there was a missing image it should crash with LOTS of output.
If it takes a bit, then it's possible that it's crashing just as soon as it *exits* the loading screen, but then again I see nothing that could cause that result.

BTW, did any of the previous versions you tried include a loading screen?
Title: Re: Terrena a12 - my game
Post by: Rusky on November 12, 2011, 01:23:35 pm
"echo $?" prints 1. It does seem possible that loading is successful but something immediately after fails.

I don't remember a loading screen, but I only noticed it this time because I was paying attention to anything that might happen right before the crash.
Title: Re: Terrena a12 - my game
Post by: luiscubal on November 12, 2011, 02:03:34 pm
I have to say, I knew there were differences between computers - and those differences were particularly great in the area of 3d graphics programming - but I never expected things to be this hard.
Tracing down problems is very hard when you don't have a computer to reproduce the bug... :(

If this is the first version with the loading screen, it's possible this is some sort of multithreaded-related bug. I'll see if I can test the older versions of Terrena to see what they have different and I'll also see if I can test the game on my other PC.

Actually, there is one more thing that can be tried, which is using the debug libraries instead of the ordinary ones(this can be changed in the dll.config files)

EDIT: Multi-threaded loading does seem to be the problem. It is now disabled by default(this can be changed in config.xml).
The new version includes a few extra bug fixes too.
Title: Re: Terrena a14 - my game
Post by: luiscubal on February 29, 2012, 03:54:46 pm
Terrena a14 released. The improved AI is the main improvement.
At this point, here's the list of main TODOs:

1. Add some more cards (I'd like to have at least one more deck)
2. Improve the AI a bit more (I still have lots of low-hanging fruit)
3. Allow the player to choose dices when starting the game
4. Add difficulty levels (this one won't be that hard, since I already have the basic blocks I need to do it)
5. Add some sort of tutorial
6. Improve game saving/loading
7. Port to new SFML drawing API, perhaps?

Anyway, I feel I'm really close to a beta release now.