Rollback – Day 6

It’s been a few days. I last updated after having developed a simple city generator, designed to create a place for the enemy faction to propagate.

With the city in place, I have spent the last four days and 1600 lines of code working on developing systems for the faction. I find writing AI to be a difficult task. I have no trouble thinking logically about the interactions I want to occur, but the complexity always blows out, and with complexity comes bugs.

That said, I am relieved to say that the heavy lifting is done and my enemy AI is all but complete.

I have attached a work in progress build below. I suggest skimming the following post as it will frame your understanding of what is happening.

The goal from day one has been to allow a faction to grow organically within the city rather than be hand created.

In real life I am sure the complexities of operating an underground resistance movement are staggering. This creates a challenge, as I must distill this complexity into simple components – while retaining behaviour that is representative of reality. I have taken some liberties.

Faction Structure

In Rollback factions work in the following way:

  1. Operatives are recruited for a specific task.
  2. Operatives occupy a ‘home’ building, relevant to their task.
  3. Operatives path from their home building to other relevant buildings.

Multiple operatives and operatives of different types are able to occupy the same building. For example, soldiers may occupy and guard a storehouse, as well as a storeman.

The diagram below depicts the interactions between the building types and the faction’s operative types.

Faction Structure

The faction looks functional. Appropriate operatives are pathing to appropriate buildings – but for the sake of Rollback deeper functionality is required.

I envision the following scenario occurring in the final game:

Conflict begins. The player is faced with missile attacks on their territory. The player identifies the missile storehouses, and begins a ground offensive. Their troops are met with faction soldiers and fighting occurs on the streets.

I want the intensity of those missiles attacks, and the duration of the ground combat to be directly reflective of the faction’s capabilities.
Having a faction that looks real is not enough – when faced with missile attacks, I want to know how many missiles in their arsenal and at what rate they have the capacity to fire them. When I roll in with tanks I want to know how many soldiers I am confronting, and how many man-portable rockets they’re armed with.

And I want the player’s actions, prior to, and during the conflict, to be able to influence these things.

Faction Statistics

Faction statistics track all variables related to the faction – from weapon storage levels, to operative recruitment rates. Each individual operatives has associated statistics. The faction’s statistics are the total of all operative statistics.

Faction statistics drive the faction. Although ostensibly the smuggler may be collecting weapons from the tunnel, and then transporting these weapons to a specific storehouse – this behaviour is entirely superficial. Behind the scenes, the smuggler’s smuggling rate (represented as weapons smuggled per day) is added to the faction’s total weapon stores. In the same way as the smuggler’s physical behaviour plays no part in determining actual faction statistics, the specific destination storehouse doesn’t either.

Now – if the smuggler is destroyed, his smuggling rate is removed from the total.
If the storehouse is destroyed, a relevant amount of weapons are destroyed.

The system allows for a wide range of relevant behaviours, with a relatively simple and trouble free design.

The table below lists each operative type and their statistics.

Operative type Statistics
Smuggler Increases weapons smuggled per day.
Storeman None (functions to build storehouse).
Soldier Increases missiles fired per day.
General Increases missiles fired per day, small bonus to recruitment.
Military Head Increases missiles fired per day, large bonus to recruitment.
Media Worker Small bonus to recruitment.
Media Head Large bonus to recruitment.
Diplomat Increases limit on weapons that can be smuggled per day.
Political Head Bonus to recruitment, increase limit on weapons that can be smuggled per day.

Faction Recruitment

There’s little point to having a chain of buildings, operatives and statistics if the faction has no way of growing over time.

The faction recruitment system allows the faction to recruit new operatives intelligently and in reaction to the player’s interference. For example, prioritise the recruitment of smugglers if the player were to assassinate all of their existing ones.

Recruitment is heavily influenced by faction statistics. The faction assesses the priority of specific operative types, and continuously recruits, based off these priorities.

Recruitment priorities are calculated based off a list of rules. These rules generally relate faction statistics to each other, proposing an optimal ratio that the faction should strive towards.

For example, one rule may have the faction attempt to ensure that they have the storage capacity to host the yield of exactly 3 days of weapon smuggling.

The faction will tweak the prioritisation of relative operatives – in this case, smuggler and storeman – in an attempt to retain this balance.

If a storehouse was to be destroyed, the faction would dramatically increase prioritisation on storehouses, otherwise, as time progresses and the stores continually fill, smuggler prioritisation would slowly increase.

That is my progress for now.

I invite you to download the work in progress build from the links below to observe the systems in play.

Please be aware that this is not representative in any way of the player experience and is simply a sneak peek into these systems. No effort has been made to balance, and these systems are open to change, so some counterintuitive behaviour can be expected. Don’t launch fullscreen as there is no way to exit from within the game.

Rollback v0.2 PC

Rollback v0.2 oSX

Next on the list is developing the player experience. I’m excited to finally start building a game on top of these foundations.


0 Responses to “Rollback – Day 6”

  1. Leave a Comment

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

Playing on Playstation 3

Red Dead Revolver - I paid about $1000 for my launch model PS3, so I guess it's time I get some use out of that emotion chip crammed inside. I remember Red Dead Revolver looking rather good when it was released, and despite the low resolution and odd blurring (that I attribute to playing on a HD set) the game holds up well. It looks good despite these graphical limitations because the art direction is so precise and awesome. And it isn't just the art direction, the music, dialogue and set design (for some reason, set seems a more fitting word than level) all work in tandem to recreate an iconic Wild West atmosphere. Red Dead Revolver doesn’t aim to recreate life in the Wild West, it allows our imagination to take over and populates the locale with legendary men and their legendary stories.

Playing on iPhone

edge - Well I never thought I'd consider playing a game on iPhone as actually gaming, but edge has turned me around. The game is built for the iPhone. Sure, it could be ported, but the elegance of what has been created is astounding, it boggles the mind and makes me wonder what amazing gems we'd receive if current gen consoles weren't clones of eachother.

Playing on PC

Sins of a Solar Empire, Demigod, Generals - Zero Hour - It may be a temporary effect as I slowly reintroduce the PC into my gaming diet, but it seems every title I’m excited to play on the platform is either a strategy game, or a cheap indie game. PC gaming isn’t dead, it’s just restricted to titles that require complex input or a pointing device, and games that couldn't be developed or distributed on other platforms. I guess that’s part of the reason the AppStore is so far a success, there were a lot of indie devs stuck on PC for lack of a better alternative.


January 2013
« Dec   Jul »

%d bloggers like this: