2012-06-26 00:13:30 +02:00
|
|
|
-- @docclass Player
|
|
|
|
|
2012-07-23 17:11:53 +02:00
|
|
|
InventorySlotOther = 0
|
2012-07-10 14:15:31 +02:00
|
|
|
InventorySlotHead = 1
|
|
|
|
InventorySlotNeck = 2
|
|
|
|
InventorySlotBack = 3
|
|
|
|
InventorySlotBody = 4
|
|
|
|
InventorySlotRight = 5
|
|
|
|
InventorySlotLeft = 6
|
|
|
|
InventorySlotLeg = 7
|
|
|
|
InventorySlotFeet = 8
|
|
|
|
InventorySlotFinger = 9
|
|
|
|
InventorySlotAmmo = 10
|
|
|
|
|
|
|
|
InventorySlotFirst = 1
|
|
|
|
InventorySlotLast = 10
|
|
|
|
|
2012-01-11 00:38:32 +01:00
|
|
|
function Player:isPartyLeader()
|
|
|
|
local shield = self:getShield()
|
|
|
|
return (shield == ShieldWhiteYellow or
|
|
|
|
shield == ShieldYellow or
|
|
|
|
shield == ShieldYellowSharedExp or
|
|
|
|
shield == ShieldYellowNoSharedExpBlink or
|
|
|
|
shield == ShieldYellowNoSharedExp)
|
|
|
|
end
|
|
|
|
|
|
|
|
function Player:isPartyMember()
|
|
|
|
local shield = self:getShield()
|
2012-06-26 00:13:30 +02:00
|
|
|
return (shield == ShieldWhiteYellow or
|
|
|
|
shield == ShieldYellow or
|
|
|
|
shield == ShieldYellowSharedExp or
|
|
|
|
shield == ShieldYellowNoSharedExpBlink or
|
2012-01-11 00:38:32 +01:00
|
|
|
shield == ShieldYellowNoSharedExp or
|
|
|
|
shield == ShieldBlueSharedExp or
|
|
|
|
shield == ShieldBlueNoSharedExpBlink or
|
|
|
|
shield == ShieldBlueNoSharedExp or
|
|
|
|
shield == ShieldBlue)
|
|
|
|
end
|
|
|
|
|
|
|
|
function Player:isPartySharedExperienceActive()
|
|
|
|
local shield = self:getShield()
|
2012-06-26 00:13:30 +02:00
|
|
|
return (shield == ShieldYellowSharedExp or
|
|
|
|
shield == ShieldYellowNoSharedExpBlink or
|
2012-01-11 00:38:32 +01:00
|
|
|
shield == ShieldYellowNoSharedExp or
|
|
|
|
shield == ShieldBlueSharedExp or
|
|
|
|
shield == ShieldBlueNoSharedExpBlink or
|
|
|
|
shield == ShieldBlueNoSharedExp)
|
|
|
|
end
|
2012-07-09 08:59:16 +02:00
|
|
|
|
|
|
|
function Player:hasVip(creatureName)
|
|
|
|
for id, vip in pairs(g_game.getVips()) do
|
|
|
|
if (vip[1] == creatureName) then return true end
|
|
|
|
end
|
|
|
|
return false
|
2012-07-09 08:59:16 +02:00
|
|
|
end
|