November 4, 2006

/******************************************************************************
* Defines
*****************************************************************************/
#define CHARACTER_BASE_HEALTH (0)
#define CHARACTER_BASE_ENERGY (0)
#define CHARACTER_BASE_WEIGHT (0)
#define CHARACTER_BASE_MOVEMENT (0.0f)
#define CHARACTER_BASE_JUMPHEIGHT (0.0f)
#define CHARACTER_BASE_DAMAGERATIO (0.0f)

#define CHARACTERDATA_WEIGHT_ALLOWED (0.50) //50% before it becomes an issue
#define CHARACTERDATA_WEIGHT_CRITICAL (0.75) //75% before it becomes an problematic

#define CHARACTER_STANCE_CIVILIAN (0)
#define CHARACTER_STANCE_SWORDSMAN (1)
#define CHARACTER_STANCE_KNIGHT (2)
#define CHARACTER_STANCE_DUELIST (3)
#define CHARACTER_STANCE_CRUSADER (4)
#define CHARACTER_STANCE_SPEARSMAN (5)
#define CHARACTER_STANCE_LANCER (6)
#define CHARACTER_STANCE_THIEF (7)
#define CHARACTER_STANCE_ASSASSIN (8)
#define CHARACTER_STANCE_NINJA (9)
#define CHARACTER_STANCE_SAMURAI (10)
#define CHARACTER_STANCE_CASTER (11)
#define CHARACTER_STANCE_ROUGE (12)
#define CHARACTER_STANCE_BRAWLER (13)
#define CHARACTER_STANCE_ARCHER (14)
#define CHARACTER_STANCE_SCOUT (15)
#define CHARACTER_STANCE_GUNNER (16)
#define CHARACTER_STANCE_SNIPER (17)

#define CHARACTER_STANCEMOD_NORMAL (0)
#define CHARACTER_STANCEMOD_DASH (1)
#define CHARACTER_STANCEMOD_DEFEND (2)
#define CHARACTER_STANCEMOD_SKILL (3)

/******************************************************************************
* Structures
*****************************************************************************/
// Should hold information that is unique
// Stats: Level, Exp
// Information that does not change very often
typedef struct CharacterCore
{
public:
// Detailed Characteristics
int nExperience;
int nLevel;

// Proficentcies
float nSkillWithMelee; // Fists, Claws, Kicks
float nSkillWithSwords; // 1h Sword, 2h Sword, Katanas, etc...
float nSkillWithShields; // Shields!
float nSkillWithSpears; // Spears
float nSkillWithDaggers; // Daggers
float nSkillWithStaves; // Melee Staff, Casting Staff, etc...
float nSkillWithBows; // Bow and Arrow
float nSkillWithGuns; // Guns
float nSkillWithAxes; // 1h Axe, 2h Axe
float nSkillWithBooks; // Large Books, Combat Books, Spell Books?

float nSkillWithEarth; // Spell Efficiency Grounds Lighting
float nSkillWithLighting; // Spell Efficiency Vaporizes Water
float nSkillWithWater; // Spell Efficiency Smothers Fire
float nSkillWithFire; // Spell Efficiency Disrupts Wind
float nSkillWithWind; // Spell Efficiency Cuts Earth
float nSkillWithLight; // Spell Efficiency Opposes Dark
float nSkillWithDark; // Spell Efficiency Opposes Light
} CharacterCore;

// Should hold fixed information.
// Stats: Str, Dex, Agi, etc...
// Information that does not change very often
typedef struct CharacterStats
{
public:
// Base Values
float nMovement; //(Movement after stance and weight)
float nJumpHeight; //(Jump after stance and weight)

int nMaxTarget; //(Client driven target proposal system, max number

// Base Stats
int nStrength;
int nAgility;
int nVitality;
int nDexterity;
int nFocus;
int nSpirit;
int nMind;

// Computed Damage Ratios (from base stats and stance)
float nDamageRatioDefend; //(StanceMod, Damage ratio used when defending)
float nDamageRatioNormal; //(StanceMod, Damage ratio used when normal)
float nDamageRatioDash; //(StanceMod, Damage ratio used when dashing)
float nDamageRatioSkill; //(StanceMod, Damage ratio used when performing a skill)

// Computed Values (equipment, stance, and stats)
int nAttackSlash; //(Mostly bladed weapons, Dex.5, Str1)
int nAttackStab; //(Mostly pointed weapons, Dex.5, Str1)
int nAttackStrike; //(Mostly blunt weapons, Dex.5, Str1)

int nAttackEarth; // Weapon Elemental Damage
int nAttackLighting; // Weapon Elemental Damage
int nAttackWater; // Weapon Elemental Damage
int nAttackFire; // Weapon Elemental Damage
int nAttackWind; // Weapon Elemental Damage
int nAttackLight; // Weapon Elemental Damage
int nAttackDark; // Weapon Elemental Damage

int nAttackMagic; //(Raw magic attack power before elemental property,
int nEvade; //(Evades magic and physical, agility, weight)
int nDefence; //(Defence points from armor and stance modification)
int nHit; //(Accuracy based off dexterity mostly)
int nCriticalRate; //(Dex, Agility, Focus)

int nResistanceEarth; // Spell Efficiency Grounds Lighting
int nResistanceLighting; // Spell Efficiency Vaporizes Water
int nResistanceWater; // Spell Efficiency Smothers Fire
int nResistanceFire; // Spell Efficiency Disrupts Wind
int nResistanceWind; // Spell Efficiency Cuts Earth
int nResistanceLight; // Spell Efficiency Opposes Dark
int nResistanceDark; // Spell Efficiency Opposes Light

// Computed Values (from base stats)
int nMaxHealth; //(Max health)
int nMaxEnergy; //(Max energy)
int nMaxWeight; //(Maximum amount of weight the character can carry)
} CharacterStats;

// Should hold information that is changing
// and can be broadcasted to other client applications
// Should try to keep this information minimal to
// keep bandwidth usage down
typedef struct CharacterDetails
{
public:
// Detailed Characteristics
int nStance; //(current stance)
int nStanceMod; //(active stance modifier)

// Computed Values (from base stats)
int nCurHealth; //(Just counted)
int nCurEnergy; //(Just counted)
int nCurWeight; //(Computed from equipment and items carried)
} CharacterDetails;

Advertisements

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 )

Twitter picture

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

Facebook photo

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

Google+ photo

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

Connecting to %s

%d bloggers like this: