I need an action that throw X item on the ground when my cap is under X. If my cap is under 30 and the monter drop a battle hammer, then throw the battle hammer on the ground, else move to my backpack.

I've tried but didn't works:
if
cap < 67 then
setsettings("Settings\\Looting\\List\\battle hammer\\Destination","ground")
else
setsettings("Settings\\Looting\\List\\battle hammer\\Destination","Purple Backpack")
end