aboutsummaryrefslogtreecommitdiff
path: root/src/game/Creature.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/game/Creature.h')
-rw-r--r--src/game/Creature.h17
1 files changed, 10 insertions, 7 deletions
diff --git a/src/game/Creature.h b/src/game/Creature.h
index be421f26ad2..d5b6b23a025 100644
--- a/src/game/Creature.h
+++ b/src/game/Creature.h
@@ -10,12 +10,12 @@
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#ifndef TRINITYCORE_CREATURE_H
@@ -205,10 +205,11 @@ struct CreatureInfo
uint32 equipmentId;
uint32 MechanicImmuneMask;
uint32 flags_extra;
- char const* ScriptName;
+ uint32 ScriptID;
uint32 GetRandomValidModelId() const;
uint32 GetFirstValidModelId() const;
-
+
+ // helpers
SkillType GetRequiredLootSkill() const
{
if(type_flags & CREATURE_TYPEFLAGS_HERBLOOT)
@@ -218,7 +219,7 @@ struct CreatureInfo
else
return SKILL_SKINNING; // normal case
}
-
+
bool isTameable() const
{
return type == CREATURE_TYPE_BEAST && family != 0 && (type_flags & CREATURE_TYPEFLAGS_TAMEBLE);
@@ -498,7 +499,9 @@ class TRINITY_DLL_SPEC Creature : public Unit
CreatureInfo const *GetCreatureInfo() const { return m_creatureInfo; }
CreatureDataAddon const* GetCreatureAddon() const;
- char const* GetScriptName() const;
+
+ std::string GetScriptName();
+ uint32 GetScriptId();
void prepareGossipMenu( Player *pPlayer, uint32 gossipid = 0 );
void sendPreparedGossip( Player* player );
@@ -524,7 +527,7 @@ class TRINITY_DLL_SPEC Creature : public Unit
// overwrite WorldObject function for proper name localization
const char* GetNameForLocaleIdx(int32 locale_idx) const;
-
+
void setDeathState(DeathState s); // overwrite virtual Unit::setDeathState
bool LoadFromDB(uint32 guid, Map *map);