Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local condition = Condition(CONDITION_ATTRIBUTES)
- condition:setParameter(CONDITION_PARAM_SUBID, 123)
- condition:setTicks(-1)
- local outfits = {
- [{128, 136}] = {
- key = CONDITION_PARAM_STAT_MAXHITPOINTS,
- value = {
- [0] = 500,
- [1] = 725, -- första addon
- [2] = 725, -- andra addon
- [3] = 1050 -- om spelaren har båda addons
- }
- }
- }
- function onLogin(cid)
- local player = Player(cid)
- local outfit = player:getOutfit()
- for looktype, targetLooktype in pairs(outfits) do
- if isInArray(looktype, outfit.lookType) then
- condition:setParameter(targetLooktype.key, targetLooktype.value[outfit.lookAddons])
- player:addCondition(condition)
- end
- end
- return true
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement