Skip to content

Instantly share code, notes, and snippets.

@su8
Created March 16, 2025 14:56
Show Gist options
  • Save su8/58899940a4c2911ad00629398112104e to your computer and use it in GitHub Desktop.
Save su8/58899940a4c2911ad00629398112104e to your computer and use it in GitHub Desktop.
#include <string>
class player
{
public:
player(std::string,std::string,int,int);
void setName(std::string);
void setArea(std::string);
void setLevel(int);
void setEXP(double);
void setHealth(double);
void setMaxHealth();
void setDamage();
std::string getName();
std::string getArea();
int getLevel();
double getHealth();
double getMaxHealth();
int getDamage();
int getEXP();
void setEXP(int);
int getEXPReq();
void setEXPReq();
private:
std::string playerName;
std::string playerArea;
int playerLevel;
double playerHealth;
double playerMaxHealth;
int playerDamage;
int EXP;
int EXPReq;
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment