Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function onSay(cid, words, param)
- local config = {
- Saffari_Pos = {Exit = {x=1339,y=1471,z=7}},
- Storages = {874547,874548},
- Level = 50,
- Price = 2000,
- Time = 30,
- }
- if (words == "") then
- doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE,"invalid command, for more information enter !saffari info")
- elseif(param == "!saffari info") then
- doShowTextDialog(cid,2160,"Saffari Info:\n\nLevel Minimum: "..config.Level.."\nSaffari Cost: "..config.Price.."\nTime Limit: "..config.Time.." minutes\n\nThe safari is home to rare creatures, some are dangerous and others not\n[*Warning*]\nis only allowed to enter with saffari balls.\n\nTo leave enter command:\n!saffari leave")
- elseif(param == "!saffari leave") then
- if getPlayerStorageValue(cid, config.Storages[1]) >= 1 then
- doTeleportThing(cid, config.Saffari_Pos.Exit)
- setPlayerStorageValue(cid, config.Storages[1], -1)
- setPlayerStorageValue(cid, config.Storages[2], -1)
- doPlayerSendTextMessage(cid,22,'you left the saffari zone.')
- else
- doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE,"you are not in Saffari")
- end
- end
- return true
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement