Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- gameAdmin = "NAME"
- time = 0
- function Main()
- tfm.exec.disableAfkDeath(true)
- tfm.exec.disableAutoNewGame(true)
- tfm.exec.disableAutoTimeLeft(true)
- tfm.exec.disableMortCommand(true)
- tfm.exec.disableAutoShaman(true)
- tfm.exec.disableAutoScore(true)
- tfm.exec.newGame(7594965)
- tfm.exec.setGameTime(0)
- ui.addPopup(1,2,"<p align='center'>Theme:",gameAdmin,540,315,250,true)
- end
- function eventLoop()
- time = time +0.5
- if (time == 420) then
- for index,name in pairs(tfm.get.room.playerList) do
- tfm.exec.killPlayer(index)
- tfm.exec.setPlayerScore(index,0)
- end
- tfm.exec.chatMessage("Winner is being chosen...")
- end
- end
- putBackground = function(playerName)
- tfm.exec.addImage("16a379e41fc.jpg", "?0", 0, 17, playerName)
- tfm.exec.addImage("16a37e3854f.jpg", "!0", 0, 150, playerName)
- tfm.exec.setUIMapName("<b>Fashion Show</b>")
- tfm.exec.chatMessage("<font color='#AD6AD9' size='14'><b>Welcome to the Funcorp Fashion Show!</b></font>\n<font color='#C29ADC'>Dress your best according to the current theme and win cheese! Look out, you only have a few minutes until the show starts.</font>\n<font color='#AD6AD9'>The judge is the organizer of this room. The cheese reward will be distributed by them.</font>\n<font color='#C29ADC'>Ready, set, GO <b>FASHION</b> CRAZY!</font>", playerName)
- end
- eventNewGame = function()
- putBackground()
- end
- function eventNewPlayer(playerName)
- ui.addTextArea(1,theme,nil,145,140,133,23,0xD94A98,0xF27EBE,0.8,true)
- ui.addTextArea(2,"<font color='#FFFFFF' size='17'>THEME:",nil,145,108,88,24,0xD94A98,0xF27EBE,0.8,true)
- tfm.exec.respawnPlayer(playerName)
- putBackground(playerName)
- end
- function eventPlayerDied(playerName)
- tfm.exec.respawnPlayer(playerName)
- end
- function eventPopupAnswer(popupID,playerName,answer)
- theme = ""
- if (popupID == 1) and (answer ~= "") and (#answer <= 15) then
- theme = "<font color='#FFFFFF' size='13'><b>"..answer.."</b>"
- ui.addTextArea(1,theme,nil,145,140,133,23,0xD94A98,0xF27EBE,0.8,true)
- ui.addTextArea(2,"<font color='#FFFFFF' size='17'>THEME:",nil,145,108,88,24,0xD94A98,0xF27EBE,0.8,true)
- time = 0
- tfm.exec.setGameTime(421)
- ui.removeTextArea(0,gameAdmin)
- end
- if (#answer > 15) then
- ui.addPopup(1,2,"<p align='center'>Theme:",gameAdmin,540,315,250,true)
- ui.addTextArea(0,"<p align='center'><font size='20' color='#A01614'><b>!<font size='16'> Too long <font size='20'>!</b></font>\n("..#answer..")",gameAdmin,540,257,250,nil,0xF6CFC9,0xE5A397,0.8,true)
- end
- if (answer == "") then
- ui.addPopup(1,2,"<p align='center'>Theme:",gameAdmin,540,315,250,true)
- ui.addTextArea(0,"<p align='center'><font size='20' color='#A01614'><b>!<font size='16'> Too short <font size='20'>!</b></font>\n("..#answer..")",gameAdmin,540,257,250,nil,0xF6CFC9,0xE5A397,0.8,true)
- end
- end
- Main()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement