Nevar pievienot vairāk kā 25 tēmas
Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.
|
- package structures.basic;
-
- /**
- * A basic representation of of the Player. A player
- * has health and mana.
- *
- * @author Dr. Richard McCreadie
- *
- */
- public class Player {
-
- int health;
- int mana;
-
- public Player() {
- super();
- this.health = 20;
- this.mana = 0;
- }
- public Player(int health, int mana) {
- super();
- this.health = health;
- this.mana = mana;
- }
- public int getHealth() {
- return health;
- }
- public void setHealth(int health) {
- this.health = health;
- }
- public int getMana() {
- return mana;
- }
- public void setMana(int mana) {
- this.mana = mana;
- }
-
-
-
- }
|