Health System Question~Creating Age of War-Like Game for iPod Touch

EthanZarovEthanZarov Member Posts: 156
edited November -1 in Working with GS (Mac)
Hey, I am creating a new itouch game inspired by age of war, and I am wondering if anyone knows a way to have a health System. For example, a swordsman has 20 Health, and deals 50 damage to a giant who has 150 Health. My question is how you can make different damages, so that the amount of hits it takes to kill enemies vary depending on how much attack your guys have, and how much health your enemies have. Thx!

Comments

  • Danneman101Danneman101 Member Posts: 59
    Well, that's the main downfall of GS, the inability to link two objects attributes directly (in this case player's attack with giant's health).

    What you need to do is create a "global" attribute ("GL_Attack" for instance) that constricts it's value to the player's current attack.

    Each time the giant records that it's been hit by the player's weapon, it deducts this global value (adjusted any way you want) from the health.
  • EthanZarovEthanZarov Member Posts: 156
    Ok that helps a little. But wouldnt that just effect one monster? How would I get it so the giant also deals damage and health?
  • Danneman101Danneman101 Member Posts: 59
    The "GL_Attack" attribute I was suggesting related to the player's attack, not the monsters. So there should be no problems there.

    For the monsters attacking the player, however, instead of attaching the player's health attribute to the player actor you could create a global "GL_Player_Health" attribute that controls the players health. This way each enemy could have an individual attack power, and directly adjust the player's health when it records that it has landed a blow to the player.

    A better approach would probably be to have a "GL_Player_Damage" attribute instead that monsters can manipulate. That way your player could have buffs that edit that damage before it adjusts the final health.

    As you can see you'll have to be pretty inventive to get this working well in GS. I'm not sure this is the best way to approach this as I haven't been using GS that long, but it's a start at least :)
  • EthanZarovEthanZarov Member Posts: 156
    kk thx!
Sign In or Register to comment.