Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local summons = getCreatureSummons(cid)
- local pos = getThingPos(cid)
- if #summons < 1 then
- doPlayerSendTextMessage(cid, MESSAGE_EVENT_DEFAULT, 'You can\'t use this spell without a frog pet.')
- doSendMagicEffect(pos, CONST_ME_POFF)
- return true
- end
- local level = math.max(1, tonumber(getCreatureStorage(cid, basicStorage + 1)))
- for _, uid in pairs(summons) do
- if getCreatureName(uid):lower() == storage then
- level = nil
- end
- end
- if not level then
- doPlayerSendTextMessage(cid, MESSAGE_EVENT_DEFAULT, 'You can\'t use this spell without a frog pet.')
- doSendMagicEffect(pos, CONST_ME_POFF)
- return true
- end
- if param == '' then
- doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'Command param required.')
- doSendMagicEffect(pos, CONST_ME_POFF)
- return true
- end
- if getPlayerStorageValue(cid,5000) == "snake" or getPlayerStorageValue(cid,5000) == "snail" then
- doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'You must have frog pet not another.')
- doSendMagicEffect(pos, CONST_ME_POFF)
- return false
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement