My task system seems to be set so that only the last player who attacked the monster, counts. I'm trying to get you to tell Party members to attack the monster.
Creaturescript:
I tried a few things using these tips:
Could anyone help me with this? How would my Creaturescript code look, so that the desired result was achieved?
Of course. That count only if the Party is active, and that count only for the Party players that attack the monster.
Thanks! <3
Creaturescript:
Lua:
function onKill(player, target)
local monster = config[target:getName():lower()]
if not monster or target:getMaster() then
return true
local party = player:getParty()
if party...
for ... party:getMembers()
end
local storageValue = player:getStorageValue(monster.storage)
if storageValue >= monster.start then
if storageValue >= monster.count then
player:sendTextMessage(MESSAGE_STATUS_CONSOLE_BLUE, "You have already killed " .. monster.count .. " " .. monster.plural .. ". Report back to Tusker in Thais.")
else
player:sendTextMessage(MESSAGE_STATUS_CONSOLE_BLUE, "You have killed [" .. storageValue .. "/" .. monster.count .. "] " .. monster.plural .. ".")
end
player:setStorageValue(monster.storage, storageValue + 1)
end
return true
end
I tried a few things using these tips:
Code:
local party = player:getParty()
if party...
for ... party:getMembers()
Could anyone help me with this? How would my Creaturescript code look, so that the desired result was achieved?
Of course. That count only if the Party is active, and that count only for the Party players that attack the monster.
Thanks! <3