From 9d1fbb5a538b3c5a1ba7d5ab55f39033ddb880f1 Mon Sep 17 00:00:00 2001 From: Jared Adams Date: Fri, 14 Aug 2009 12:21:07 -0600 Subject: Add functions to more easily work with equipment Move hair changes back over to them; related server change was reverted. Also move NPCs back over to extending Player. NPCs will have equipment in the future too, but for now, disable that part while we finish the system. --- src/npc.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'src/npc.h') diff --git a/src/npc.h b/src/npc.h index 5335d8cd..46e48184 100644 --- a/src/npc.h +++ b/src/npc.h @@ -27,7 +27,7 @@ class Graphics; class Text; -class NPC : public Being +class NPC : public Player { public: NPC(int id, int job, Map *map); @@ -38,6 +38,9 @@ class NPC : public Being void talk(); + void setSprite(unsigned int slot, int id, + const std::string &color = ""); + /** * Gets the way an NPC is blocked by other things on the map */ @@ -56,6 +59,9 @@ class NPC : public Being */ virtual Map::BlockType getBlockType() const { return Map::BLOCKTYPE_CHARACTER; } //blocks like a player character + + // Colors don't change for NPCs + virtual void updateColors() {} }; extern int current_npc; -- cgit v1.2.3-70-g09d2