summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/npc.cpp7
-rw-r--r--src/npc.h5
2 files changed, 9 insertions, 3 deletions
diff --git a/src/npc.cpp b/src/npc.cpp
index 5efee873..2eebed7b 100644
--- a/src/npc.cpp
+++ b/src/npc.cpp
@@ -40,7 +40,7 @@ static const int NAME_X_OFFSET = 15;
static const int NAME_Y_OFFSET = 30;
NPC::NPC(Uint32 id, Uint16 job, Map *map, Network *network):
- Being(id, job, map), mNetwork(network)
+ Player(id, job, map), mNetwork(network)
{
NPCInfo info = NPCDB::get(job);
@@ -94,6 +94,11 @@ void NPC::setName(const std::string &name)
Being::setName(displayName + " (NPC)");
}
+void NPC::setGender(int gender)
+{
+ Being::setGender(gender);
+}
+
Being::Type
NPC::getType() const
{
diff --git a/src/npc.h b/src/npc.h
index 432d26d1..0dff1dcb 100644
--- a/src/npc.h
+++ b/src/npc.h
@@ -24,13 +24,13 @@
#ifndef _TMW_NPC_H
#define _TMW_NPC_H
-#include "being.h"
+#include "player.h"
class Network;
class Graphics;
class Text;
-class NPC : public Being
+class NPC : public Player
{
public:
NPC(Uint32 id, Uint16 job, Map *map, Network *network);
@@ -38,6 +38,7 @@ class NPC : public Being
~NPC();
void setName(const std::string &name);
+ void setGender(int gender);
virtual Type
getType() const;