character.h
cowmud-0.11/src/character.h · 783 B
From the archive cowmud-0.11.tar.gz
Download the archive « Back to the archive contents
#ifndef _CHARACTER_H_
#define _CHARACTER_H_
#include "descriptor.h"
#include "container.h"
class Character:public Descriptor, public Container {
public:
Character();
~Character();
Character(int sock);
void save(); // Saves the character/mobile to the filename equal to the name of the container
bool load(); // Loads the character/mobile from the filename equal to the name of the container
void setPword(string str); // sets the character's password
string getPword(); // accesses the character's password
bool isPwordOk(); // checks if a password is invalid
private:
void outputCharacter(ofstream &oFile); // Outputs all pertinant information to an output file stream
string pword;
};
#endif