Skip to content
Snippets Groups Projects
Commit ea378ed2 authored by dg's avatar dg
Browse files

Bows/Slings can not be used as melee weapons

git-svn-id: http://svn.net-core.org/repos/t-engine4@1828 51575b47-30f0-44d4-a5cc-537603b46e54
parent 2926ea60
No related branches found
No related tags found
No related merge requests found
......@@ -93,7 +93,7 @@ function _M:attackTarget(target, damtype, mult, noenergy)
-- All weapons in main hands
if self:getInven(self.INVEN_MAINHAND) then
for i, o in ipairs(self:getInven(self.INVEN_MAINHAND)) do
if o.combat then
if o.combat and not o.archery then
print("[ATTACK] attacking with", o.name)
local s, h = self:attackTargetWith(target, o.combat, damtype, mult)
speed = math.max(speed or 0, s)
......@@ -114,7 +114,7 @@ function _M:attackTarget(target, damtype, mult, noenergy)
offmult = (mult or 1) / (2 - (self:getTalentLevel(Talents.T_CORRUPTED_STRENGTH) / 9))
end
for i, o in ipairs(self:getInven(self.INVEN_OFFHAND)) do
if o.combat then
if o.combat and not o.archery then
print("[ATTACK] attacking with", o.name)
local s, h = self:attackTargetWith(target, o.combat, damtype, offmult)
speed = math.max(speed or 0, s)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment