Jadex AgentKeeper – Dungeon Keeper alike Game – [Update: Code is now Public]

Don’t know if I posted to this yet or not. But I REALLY like the vid! The game looks great.

1 Like
@t0neg0d said: Don't know if I posted to this yet or not. But I REALLY like the vid! The game looks great.

hey ^^ thanks. I also like you newest Video. Cool stuff your new Gui.

Maybe you like to contribute to this Project to feature your Gui in a nice Game. Moving to GoogleCode soon, think next Week. Only if you like of course, just thinking could be very cool for the Project and the visibility of your Gui…but just an Idea, we´ll see, dont know what kind of Gamess are the main Focus from your Gui. Until now its still Nifty.

@PhilipWilluweit said: hey ^^ thanks. I also like you newest Video. Cool stuff your new Gui.

Maybe you like to contribute to this Project to feature your Gui in a nice Game. Moving to GoogleCode soon, think next Week. Only if you like of course, just thinking could be very cool for the Project and the visibility of your Gui…but just an Idea, we´ll see, dont know what kind of Gamess are the main Focus from your Gui. Until now its still Nifty.

Been trying to keep this as open ended as possible by just providing functional controls that you would find in most UI libraries. Is there a demo of the game to play so I can see what your doing currently for the UI?

Not yet but the Gameplay is like dungeon Keeper 2 so minimap, Statusstuff, Tabs For Selectin Monster, Buildings, Spells And So On.

Hey, i hade som Fun with 100x faster Imps, so I would like to Share :slight_smile:

About the Video (you can watch it in 1080p):

  • Shows the new LightSetup in Action

  • The Minimap is now Rotating with the Camera. Is that cool or should the Map always be fixed?
    (Anyway I am working on a “box” that shows the active Visible Area on the Minimap and can be “moved” to have an other option to move the camera).

  • Finished implemted the Mana Generation. You can see it in the top-left Corner: The Mana, and the Number of Tiles the player owns (the Green Number).
    The more Tiles he owns the more Mana. You can that value changing when the Imps claim more Tiles(like in the new Video).

  • And some small IMP test with 100x faster Working Time(Walking & Working) for Imps. As you can see they have small issues yet, 5 blocks I had to click again ^^

  • So Long, Philip

[video]http://youtu.be/04bZbuMBJN4[/video]

The minimap should rotate. It’s hard to mentally rotate stuff, and even for those who can it is a distraction.
The minimap should display some compass indicator - an arrow, or an N letter, or whatever.

Also, I’ve always been wanting to be able to click the minimap and move there.

It would be interesting to hear what made those five blocks survive. Was the mistake that led to that misbehaviour something that could have been caught in a unit test, or by applying different programming patterns, or is it something that’s hard to avoid from the outset?

@toolforger said: The minimap should rotate. It's hard to mentally rotate stuff, and even for those who can it is a distraction. The minimap should display some compass indicator - an arrow, or an N letter, or whatever.

Also, I’ve always been wanting to be able to click the minimap and move there.

It would be interesting to hear what made those five blocks survive. Was the mistake that led to that misbehaviour something that could have been caught in a unit test, or by applying different programming patterns, or is it something that’s hard to avoid from the outset?

yeah, minimap moving is finished soon.

About the Imp issues: The Code for him is really obsolet, is the last Agent I made with BDIv2, so anyway I will refractor him from Scratch in BDIv3 (withoud anoying XML Stuff). Of course I could make some Testcases and find the Issue, but I will do that after refractor him. Its not hard to Avoid, Jadex has also a hole control Center where you can very good observe the running Agents in Detail, like witch Goals are Active, Goal Failed or not? Which Plan he is actually trying and so on.

I suspect a race condition, which typically doesn’t show up in monitoring tools.
Not worth fixing before the refactoring if your goal is to get the thing running.
Very much worth fixing before the refactoring if your goal is to understand how such a problem could happen, as the refactoring might change the situation enough to simply hide the problem.
Personally, I’m after the latter, so I’d prefer it if you found out what happened, but I do understand that my priorities aren’t necessarily yours :slight_smile:

Here’s another potential issue: On http://www.activecomponents.org/bin/view/Env+User+Guide/01+Introduction, I see that agents that live in an EnvSupport environment cannot be moved to another platform.
Are there plans to lift that restriction? It would be really helpful for load balancing (but it would of course require exchanging lots of environment state between platforms, so I’m not too hopeful).
I may be misinterpreting this stuff anyway, I’ve just started reading the docs.

Our EnvSupport implementation is kind of dusty but still usefull. Going to make some changes to let it run as an Service in future, so it can be everywhere.

About the Imp again: Is about some issues with my 3d enviroment, not the Agent itself. The Agent worked fine and well tested before in a DungeonKeeper 2d Szenario I had before. And race condition: We really take care about them. The Core-Developer really now what they are Doing. There are no Problems with Raceconditions in Jadex itself. Thats why we juse the http://www.activecomponents.org/bin/view/AC+User+Guide/03+Asynchronous+Programming Async. Programming pattern since BDIv2 and later.
BDIv3 Agents dont even have an own Thread anymore, so they can´t even block ressources anymore when its not their turn. You can run several thousends of them on a normal CPU.
I thought about some Zerg-Mass-Attack stuff in AgentKeeper but the limitation is here the Object and PolyCount , not the BDIv3 AI Logic, when I load more then 200-300 Monsters controlled by their own BDIv3 Agent the Same time in the SceneGraph (have to use more BatchNodes for Monsters too - to make that possible to).

Sweet, this is looking good.
The docs look really good, too. Somebody went to really great lengths to help people over any initial hurdles.

Yep, I read the async stuff. True, insisting on value messaging (no shared memory) should eliminate the vast majority of races, but it doesn’t deal with all of them I think.

Good to know it’s the graphics that’s the bottleneck, not the AI.

I was a bit surprised to see annotations that contain Java source inside text. I fear that this will have all sorts of unfortunate side effects, from making it hard for refactoring tools to find all references to a class or member to making it hard for the JVM to optimize the code. I haven’t seen any of these side effects yet, so maybe it’s nothing to worry about and it all might be justified in the end, but I’ll be keeping my eyes peeled for any trouble coming from that corner.

Are the sources of your project available somewhere? I’d really like to study it and (hopefully) send patches, that would be the fastest way to get my feet wet with Jadex.

Ok no demo atm, some Problem on the server, send you new link when finished

I’m downloading it right now, but it is having really slow download speeds, less that 0.1mb a second, and the zip is 157mb :frowning:

Ok some Problem von the Server, I remove the link temporaly

Ok, you can Download the Playable Jar now here: http://code.google.com/p/jadex-agentkeeper/downloads/list

Don´t forget to extract the File first :o)

Please Post your Frames + Screen Resolution and System if you like, when you maximaze the Window. (Settings -> Stats or just simply press F5).

Hi,

I use w7 64 bit pro, my pc is composed by a i5 2550k 3.3 Ghz and a Nvidia 560 GTX + a SSD as system hard drive…i think there are the most important information for a game ;).
I play in full hd 1920x1080 and my framerate is between 130-140 average (in fullScreen)

Update about the Project: We Made the SVN connected with our Jenkins Server. So every Night you got a new Playable-Nightly-Builded Version of the Game!!
I case you forget where the Project is: here: ^^ https://code.google.com/p/jadex-agentkeeper/ click on the ZIP and enjoy it after extracting ^^

Right now you can see a new Dungeonheart and Portal made by someone from Hamburg too, I just added some cool Fog-Effect.
Ah and the chickens, (you can find them in the Hatchery) but they don´t have animations jet…have to do that…

Hello Guys.

I made some Tutorial Video-Series about the Game.

This one is maybe interesting for you, it shows how you can make your own Levels with the LevelEditor.

[video]http://youtu.be/hWPcLIpTBfE[/video]

Enjoy! :slight_smile:

1 Like

Just took a tour through the sources, here are my first impressions.
Please read with the usual caveats about first impressions: I probably misunderstood some things, overgeneralized others, and missed relevant generalizations elsewhere. YMMV.

First thing that registered wasn’t Jadex-related though, more around code quality… a lot both of you have to learn still, young padawans.
There are several things that could have been done better without additional effort, and some things that didn’t improve code quality but must have cost time.
On the plus side, the signs of code cleanup indicate that at least one of the coders is already on the path to becoming a better programmer.

Second thing: How did Jadex impact the overall code structure.
BDI (belief/desire/intention) as a conceptual framework has definitely had a positive influence. I think I’ll follow that model even in projects that don’t use Jadex.
The widespread use of Futures also looked like a great tool. Greatly simplifies offloading a computation to another thread and synchronizing only when and if the result is actually needed.
What made me back off in horror was agent property handling. Best practice is to define getters and setters, then use something like Apache BeanUtils (or their Spring equivalent) in those areas where code or configuration doesn’t know the bean type. Jadex does it the other way round, requiring a string key and a type cast for each property access. And at least the Agentkeeper code uses this to handle everyday properties like gold, mana, time spent for a task, and similar stuff - that’s not a problem on something as simple as dungeon creatures, but inacceptable as soon as you can’t keep all property details in your head anymore, a point that you typically reach after a few months of fulltime coding (which Agentkeeper hasn’t seen yet).
What I have not seen is how the agent management tools would work for managing the entities agents in a game. I guess the Agentkeeper game isn’t large or complicated enough (yet) for any management tools to truly make a difference.

You misunderstood one total basic thing: You only need Properties for SpaceObjects.
They don´t have anything to do with Agents.
Agents uses Beliefs for their internal State.

You should put as much logic as possible in the Agent.

An SpaceObject “can” be an Avatar of an Agent.

Please consider too that the code still needs lots of cleanup or changes from old things I know now better.
Consider the hole IMP Code and everything in the OLDAI Packages as Deprecated.

Do you have examples where I can increase code quality. You just speaking in totally general terms. Thats not helping at all.

What you mean the other Coder? There is only me until now (for the AgentKeeper code) :slight_smile: