From 35cf6778de1ff4e9c4b38e311bcb1552693c6e2c Mon Sep 17 00:00:00 2001 From: Rat Date: Tue, 4 Aug 2009 12:38:35 +0200 Subject: *added script for training dummies *added new creature extra flag (CREATURE_FLAG_EXTRA_NO_SKILLGAIN) if set creature won't increase player's weapon skill --HG-- branch : trunk --- src/game/Player.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/game/Player.cpp') diff --git a/src/game/Player.cpp b/src/game/Player.cpp index 6e92e7d4b6a..0b75d090152 100644 --- a/src/game/Player.cpp +++ b/src/game/Player.cpp @@ -5288,6 +5288,9 @@ void Player::UpdateWeaponSkill (WeaponAttackType attType) if(m_form == FORM_TREE) return; // use weapon but not skill up + if(pVictim && pVictim->GetTypeId() == TYPEID_UNIT && (((Creature*)pVictim)->GetCreatureInfo()->flags_extra & CREATURE_FLAG_EXTRA_NO_SKILLGAIN)) + return; + uint32 weapon_skill_gain = sWorld.getConfig(CONFIG_SKILL_GAIN_WEAPON); switch(attType) -- cgit v1.2.3