• entries
    437
  • comments
    1000
  • views
    335623

ASSAULT

Sign in to follow this  
evolutional

85 views

I'm currently trying to figure out a good way to organise properties within my game whilst letting it be as configurable as possible (eg: to read from a simple XML or database file).

Attack: "Bolter" type "Weapon/Ranged"
Bonuses: +3 against "Armour/None"; +1 against "Armour/Light"; +0 against "Armour/Medium"; -1 against "Armour/Heavy"; -3 against "Armour/Assault"

In these cases, Armour/XXX are all categories of Armour - but what is armour to be 'classed' as? A defense bonus? The same system also needs to be handle the fact that although we might have an object based on "Armour/Light" but it's also granting the unit invulnerability to all movement impairment effects and grants a +strength bonus (to increase melee attack power). Likewise, "Bolter" although "Weapon/Ranged", we might want to make it explode on impact (perhaps triggering a +fire damage bonus), or maybe designed to entirely circumvent a certain named armour bonus or effect, or cause a crapload of damage to a specific unit class (eg: Robot killer!)

I'm really having difficulty actually explaining what I mean/want - perhaps that's half the problem. It's all potentially 'standard' RPG and/or wargame stuff (yeah I've looked at the C# Workshop stuff too).

Does anyone get what I'm babbling at? If so, any ideas of a basic design or terminology I should look for?

Sign in to follow this  


1 Comment


Recommended Comments

I think I get what you're saying, it's a common problem. And IMO, that way to deal with armor would probably get a little out of hand. For example, with the system you describe, to make an armor type more resistant you would have to change every type of attack.

What you need is to give each class more general properties. Abusing inheritance here is a good thing, so a small change in a base class will change all the 'child' classes and you can tinker with the values at will.

There are generic properties for armor, and some other generic modifiers for each armor type (making better armor stronger but also heavier; etc). A plain vanilla attack type will work with these without any special code, that's the beauty of it. Then an attack like fire can be better against a specific armor class if you want, or a specific armor might have other modifiers/properties like the free movement you're talking about.

There are always matters like whether an attack type holds information about the armors (bonus vs. this, etc), or the armor holds info about the attack types. This is irrelevant, chose one and go with it.

You could simply make a huge table with all of the possible interactions of every possible combination of items and effects; but that is the exact opposite of what I'm talking about. The more inheritable properties there are, the easier it is to maintain.

Share this comment


Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now