Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -------------------- System --------------------
- _, nickname = pcall(nil)
- local admin = string.match(nickname, "(.-)%.")
- for _, v in next, {'AutoShaman', 'AutoNewGame', 'AutoTimeLeft', 'PhysicalConsumables','AfkDeath','AutoScore','MortCommand','MinimalistMode'} do
- tfm.exec['disable' .. v]()
- end
- system.disableChatCommandDisplay()
- ------------------------------------------------
- -- Editáveis!
- local map = '@7554227'
- -- Definir as coordenadas dos lugares.
- local convenient = {
- ['iniciar'] = {500,100},
- ['assistir'] = {300,370},
- ['desfilou'] = {1120,380},
- ['palco'] = {580,325},
- }
- -- Não editável.
- local staff = {admin:lower()}
- table.contains = function(rawTable, existentValue)
- for index, value in pairs(rawTable) do
- if value == existentValue then
- return true
- end
- end
- return false
- end
- formatText = function(txt,form)
- p = {} for k in txt:gmatch(form) do p[#p + 1] = k end return p
- end
- eventNewPlayer = function(name)
- tfm.exec.respawnPlayer(name)
- if table.contains(staff,name:lower()) then tfm.exec.setNameColor(name,'0x'..(name == admin and 'FF0000' or '3b3b3b')..'') else tfm.exec.setNameColor(name,'0xC2C2DA') end
- end
- eventNewGame = function()
- ui.setMapName('Halloween party!')
- end
- eventLoop = function()
- table.foreach(tfm.get.room.playerList, eventNewPlayer)
- end
- eventChatCommand = function(name,c)
- local value = ''
- local c = formatText(c:lower(),'[^%s]+')
- if table.contains(staff,name:lower()) then
- if c[1] == 'chat' then c[1] = '' ui.addPopup(1,0,'<b><font size="10" color="#000000'..(name == admin and 'FF0000' or '')..'">['..(name == admin and 'Apresentadora' or 'Jurada')..' '..name..']</font> '..table.concat(c,' ')..'</b>',nil,260,175,280,true) end
- if c[1] == 'iniciar' then tfm.exec.movePlayer (c[2],convenient[c[1]][1],convenient[c[1]][2]) end
- if c[1] == 'assistir' then tfm.exec.movePlayer (c[2],convenient[c[1]][1],convenient[c[1]][2]) end
- if c[1] == 'desfilou' then tfm.exec.movePlayer (c[2],convenient[c[1]][1],convenient[c[1]][2]) end
- if c[1] == 'palco' then tfm.exec.movePlayer (c[2],convenient[c[1]][1],convenient[c[1]][2]) end
- end
- if c[1] == 'staff' and name == admin and not table.contains(staff,c[2]) then staff[#staff + 1] = c[2] end
- if c[1] == 'unstaff' and name == admin and admin:lower() ~= c[2] and table.contains(staff,c[2]) then for k,v in next, staff do if v == c[2] then value = k end end table.remove(staff,value) end
- end
- tfm.exec.newGame(map)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement