-----------------------------------------
-- ID: 5969
-- Item: Plate of Piscator's Paella
-- Food Effect: 4 Hrs, All Races
-----------------------------------------
-- HP 45
-- Dexterity 6
-- Accuracy % 16 (cap 85)
-- Undead Killer 6
-----------------------------------------

require("scripts/globals/status");

-----------------------------------------
-- OnItemCheck
-----------------------------------------

function onItemCheck(target)
local result = 0;
	if (target:hasStatusEffect(EFFECT_FOOD) == true) then
		result = 246;
	end
return result;
end;

-----------------------------------------
-- OnItemUse
-----------------------------------------

function onItemUse(target)
	target:addStatusEffect(EFFECT_FOOD,0,0,14400,5969);
end;

-----------------------------------------
-- onEffectGain Action
-----------------------------------------

function onEffectGain(target,effect)
	target:addMod(MOD_HP, 45);
	target:addMod(MOD_DEX, 6);
	target:addMod(MOD_FOOD_ACCP, 16);
	target:addMod(MOD_FOOD_ACC_CAP, 85);
	target:addMod(MOD_UNDEAD_KILLER, 6);
end;

-----------------------------------------
-- onEffectLose Action
-----------------------------------------

function onEffectLose(target,effect)
	target:delMod(MOD_HP, 45);
	target:delMod(MOD_DEX, 6);
	target:delMod(MOD_FOOD_ACCP, 16);
	target:delMod(MOD_FOOD_ACC_CAP, 85);
	target:delMod(MOD_UNDEAD_KILLER, 6);
end;
