Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- lag=0
- local toDespawn = {}
- do
- local addShamanObject = tfm.exec.addShamanObject
- tfm.exec.addShamanObject = function(...)
- toDespawn[#toDespawn + 1] = {
- addShamanObject(...),
- os.time() + 3000
- }
- return toDespawn[#toDespawn][1]
- end
- end
- tfm.exec.disableAllShamanSkills(true)
- tfm.exec.disableMortCommand(true)
- wonCountDown=1
- scores={0,0,0,0,0,0,0,0}
- maps={7455943}
- powery=320
- powerx=math.random(1600)
- mice=0
- ui.addTextArea(10, "", nil, -432, -822, 3625, 953, 0xff0000, 0x00a2ff, 0.6, true)
- Down=string.byte("S")
- tfm.exec.disableAutoShaman(true)
- tfm.exec.disableAutoNewGame(true)
- tfm.exec.disableAfkDeath(true)
- tfm.exec.disableAutoShaman(true)
- tfm.exec.disableAutoTimeLeft(true)
- tfm.exec.disableAutoScore(true)
- data={}
- text={}
- lang={}
- lang.en={profile2="Profile",rules="Rules</font></font></u><font size='12'>\n\n• Using tricks to glitch the game is not allowed\n\n• You are not allowed to hack just like in any other game.",rules2="Rules",commands="Powerups\n\n<font size='11'>Click - Spawns a random shaman object when you have the role of being a <J>Death</J>.\n\nSpacebar - Makes a large jump followed with an invisible cannon when you have the role of being a <J>Runner</J>. \n\nDown Arrow / S key - Gives you a boost of speed. (Works for both Deaths and Runners)",commands2="Powerups",credits="Credits</font></font><font face='verdana'><font size='11'>\n\n<N>Programming - Fuzzyfirsdog#0000\n\nModule Idea - Reddeathnick#3204\n\nPowerup Suggestions - Reddeathnick#3204, Seaqueen2003#000, Mugiwaraloffy#9866\n\nFinding Ways To Remove Hacks - Mariluiss#0000 \n\n<VP>Thank you ^^",credits2="Credits",youCanAttack="<R>Death: <N>You can attack",youCanNotAttack="<R>Death: <N>You can not attack",youCanUsePowerups="<VP>Runner: <N>You can use powerups",youCanNotUsePowerups="<VP>Runner: <N>You can not use powerups",attacked="ATTACKED",youAreARunner="You are a runner",youAreADeath="You are a death",help="In #deathrun there are <J>Deaths</J> and <J>Runners</J>. Deaths should try to kill the mice by clicking to spawn objects, if no runners get into the hole then deaths win! Runners are supposed to use the powerups they are given to get into the hole and escape Deaths. If one runner gets into the hole, runners win.",close="Close",help2="Help",superJump="SUPER JUMP",speed="SPEED",deathsWin="Deaths win!",runnersWin="Runners win!"}
- roles={"Death","Runner"}
- death=0
- runner=0
- miceInHole=0
- function setLang(n)
- for n,player in pairs(tfm.get.room.playerList) do
- text[n]=lang[tfm.get.room.playerList[n].community] or lang.en
- end
- end
- function bindMouse()
- for n,player in pairs(tfm.get.room.playerList) do
- tfm.exec.bindKeyboard(n, 39, true, true)
- tfm.exec.bindKeyboard(n, 37, true, true)
- tfm.exec.bindKeyboard(n, 65, true, true)
- tfm.exec.bindKeyboard(n, 68, true, true)
- tfm.exec.bindKeyboard(n, 32, true, true)
- system.bindMouse(n, true)
- tfm.exec.bindKeyboard(n, 40, true, true)
- tfm.exec.bindKeyboard(n, Down, true, true)
- end
- end
- bindMouse()
- tfm.exec.newGame(maps[math.random(#maps)])
- names={}
- theRole=1
- currentRole=roles[math.floor(theRole)]
- function changeCurrentRole()
- end
- numbs={1,2}
- function showTabs(n)
- ui.addTextArea(15, "<VP><a href='event:help'><font size='12'>"..text[n].help2.."</a> | <a href='event:credits'>"..text[n].credits2.." </a>|<a href='event:commands'> "..text[n].commands2.." </a>|<a href='event:rules'> "..text[n].rules2, n, 10, 30, 264, 26, 0x00aaff, 0x00eeff, 0, true)
- ui.addTextArea(155, "<VP><a href='event:profile'><font size='12'>"..text[n].profile2, n, 740, 30, 264, 26, 0x00aaff, 0x00eeff, 0, true)
- end
- for n,player in pairs(tfm.get.room.playerList) do
- changeCurrentRole()
- mice=mice+1
- table.insert(names,n)
- setLang(n)
- data[n]={facingx=85,name=n,role="Runner",points=0,spawnLimit=-1,ableToShoot=0,ableToShoot2=0,pointsAndScore=""}
- data[n].pointsAndScore=data[n].name.." "..data[n].points
- table.insert(scores,data[n].points)
- showTabs(n)
- tfm.exec.lowerSyncDelay(n)
- end
- n1=scores[math.floor(1)]
- n2=scores[math.floor(2)]
- n3=scores[math.floor(3)]
- print(n1)
- print(n2)
- print(n3)
- function findRoles(n)
- for n,player in pairs(tfm.get.room.playerList) do
- if data[n].role=="Death" then
- tfm.exec.movePlayer(n,150,30,false,0,0,false)
- elseif data[n].role=="Runner" then
- tfm.exec.movePlayer(n,70,300,false,0,0,false)
- end
- end
- end
- function findRolesNewPlayer(n)
- if data[n].role=="Death" then
- tfm.exec.movePlayer(n,150,30,false,0,0,false)
- elseif data[n].role=="Runner" then
- tfm.exec.movePlayer(n,70,300,false,0,0,false)
- end
- end
- a={}
- function eventNewPlayer(n)
- bindMouse()
- ui.addTextArea(10, "", n, -432, -822, 3625, 953, 0xff0000, 0x00a2ff, 0.6, true)
- mice=mice+1
- if not data[n] then
- data[n]={name=n,role="Runner",points=0,spawnLimit=-1,ableToShoot=0,ableToShoot2=0}
- end
- setLang(n)
- showTabs(n)
- table.insert(names,n)
- findRolesNewPlayer(n)
- tfm.exec.respawnPlayer(n)
- end
- function addToRoleNumber()
- for n,player in pairs(tfm.get.room.playerList) do
- if data[n].role=="Death" then
- death=death+1
- end
- if data[n].role=="Runner" then
- runner=runner+1
- end
- findRoles(n)
- end
- end
- tfm.exec.newGame(maps[math.random(#maps)])
- amountInA=0
- function punishGlitchers()
- if a then
- for i=1,amountInA do
- data[a[math.floor(amountInA)]].role="Runner"
- end
- end
- end
- randomDeath=names[math.floor(math.random(mice))]
- data[randomDeath].role="Death"
- lastDeath=""
- function eventNewGame()
- lag=0
- local toDespawn = {}
- do
- local addShamanObject = tfm.exec.addShamanObject
- tfm.exec.addShamanObject = function(...)
- toDespawn[#toDespawn + 1] = {
- addShamanObject(...),
- os.time() + 3000
- }
- return toDespawn[#toDespawn][1]
- end
- end
- time=0
- theRole=1
- powerx=math.random(1600)
- runner=0
- death=0
- mice=0
- for n,player in pairs(tfm.get.room.playerList) do
- mice=mice+1
- changeCurrentRole()
- data[n].role="Runner"
- data[n].ableToShoot=0
- data[n].ableToShoot2=0
- data[n].spawnLimit=-1
- end
- mice=mice
- data[randomDeath].role="Death"
- addToRoleNumber()
- findRoles(n)
- print("Last death: "..lastDeath)
- end
- locationx=0
- locationy=0
- objects={54}
- function eventMouse(n,x,y)
- system.bindMouse(n,false)
- if data[n].role=="Death" then
- lag=lag+1
- if lag>3 then
- randomDeath=names[math.floor(math.random(mice))]
- data[randomDeath].role="Death"
- local toDespawn = {}
- table.insert(a,n)
- amountInA=amountInA+1
- do
- local addShamanObject = tfm.exec.addShamanObject
- tfm.exec.addShamanObject = function(...)
- toDespawn[#toDespawn + 1] = {
- addShamanObject(...),
- os.time() + 0000
- }
- return toDespawn[#toDespawn][1]
- end
- end
- ui.addTextArea(133, "<R><font size='17'><b>USING LAG TRICKS OR HACKS ARE NOT ALLOWED IN THIS ROOM", n, 143, 150, 534, 91, 0x324650, 0x000000, 1, true)
- time=-0.5
- tfm.exec.newGame(maps[math.random(#maps)])
- eventNewGame()
- end
- data[n].spawnLimit=2
- ui.addTextArea(2, "<font color='#FF9000'><font size='30'><b>"..n.." "..text[n].attacked, nil, x, y, 425, 100, 0x324650, 0x000000, 0, false)
- locationx=x
- locationy=y
- tfm.exec.addShamanObject(objects[math.random(#objects)],locationx,locationy,0,0,20,false)
- tfm.exec.displayParticle(0,locationx,locationy,0.5,0.5,0.5,0.5,nil)
- tfm.exec.displayParticle(0,locationx,locationy,-0.5,-0.5,-0.5,-0.5,nil)
- tfm.exec.displayParticle(2,locationx,locationy,3,-3,3,-3,nil)
- tfm.exec.displayParticle(2,locationx,locationy,-3,3,-3,3,nil)
- tfm.exec.displayParticle(0,locationx,locationy,-0.5,0.5,-0.5,0.5,nil)
- tfm.exec.displayParticle(0,locationx,locationy,0.5,-0.5,0.5,-0.5,nil)
- tfm.exec.displayParticle(2,locationx,locationy,1,-3,1,-3,nil)
- tfm.exec.displayParticle(2,locationx,locationy,1,1,3,1,nil)
- tfm.exec.displayParticle(2,locationx,locationy,-1,3,-1,3,nil)
- tfm.exec.displayParticle(2,locationx,locationy,-1,-1,-3,-1,nil)
- tfm.exec.displayParticle(5,locationx,locationy,0.5,0.5,0.5,0.5,nil)
- tfm.exec.displayParticle(5,locationx,locationy,-0.5,-0.5,-0.5,-0.5,nil)
- tfm.exec.displayParticle(5,locationx,locationy,-0.5,0.5,-0.5,0.5,nil)
- tfm.exec.displayParticle(5,locationx,locationy,0.5,-0.5,0.5,-0.5,nil)
- end
- end
- time=0
- number1=0
- number2=0
- number3=0
- function eventPlayerGetCheese(n)
- randomDeath=n
- print(n)
- if data[n].role=="Runner" then
- tfm.exec.chatMessage(text[n].runnersWin,n)
- time=118
- data[n].points=data[n].points+3
- for n,player in pairs(tfm.get.room.playerList) do
- table.insert(scores,data[n].points)
- ui.addTextArea(133, "<b><font size='40'><font color='#0ff164'>"..text[n].runnersWin, n, 296, 282, 351, 189, 0xd41717, 0x000000, 0, true)
- if data[n].role=="Runner" then
- data[n].points=data[n].points+2
- wonCountDown=-5
- end
- end
- end
- function eventPlayerWon(n)
- print("yo")
- randomDeath=n
- if data[n].role=="Death" then
- time=117
- end
- for n,player in pairs(tfm.get.room.playerList) do
- ui.addTextArea(133, "<b><font size='40'><font color='#d40000'>"..text[n].deathsWin, n, 296, 282, 351, 189, 0xd41717, 0x000000, 0, true)
- tfm.exec.chatMessage(text[n].deathsWin,n)
- randomDeath=names[math.floor(math.random(mice))]
- end
- tfm.exec.newGame(maps[math.random(#maps)])
- print("Runners win!")
- end
- end
- function explosions()
- tfm.exec.displayParticle(0,locationx,locationy,0.5,0.5,0.5,0.5,nil)
- tfm.exec.displayParticle(0,locationx,locationy,-0.5,-0.5,-0.5,-0.5,nil)
- tfm.exec.displayParticle(2,locationx,locationy,3,-3,3,-3,nil)
- tfm.exec.displayParticle(2,locationx,locationy,-3,3,-3,3,nil)
- tfm.exec.displayParticle(0,locationx,locationy,-0.5,0.5,-0.5,0.5,nil)
- tfm.exec.displayParticle(0,locationx,locationy,0.5,-0.5,0.5,-0.5,nil)
- tfm.exec.displayParticle(2,locationx,locationy,1,-3,1,-3,nil)
- tfm.exec.displayParticle(2,locationx,locationy,1,1,3,1,nil)
- tfm.exec.displayParticle(2,locationx,locationy,-1,3,-1,3,nil)
- tfm.exec.displayParticle(2,locationx,locationy,-1,-1,-3,-1,nil)
- tfm.exec.displayParticle(5,locationx,locationy,0.5,0.5,0.5,0.5,nil)
- tfm.exec.displayParticle(5,locationx,locationy,-0.5,-0.5,-0.5,-0.5,nil)
- tfm.exec.displayParticle(5,locationx,locationy,-0.5,0.5,-0.5,0.5,nil)
- tfm.exec.displayParticle(5,locationx,locationy,0.5,-0.5,0.5,-0.5,nil)
- tfm.exec.explosion(locationx, locationy, 40, 40, false)
- end
- function canShoot()
- for n,player in pairs(tfm.get.room.playerList) do
- if data[n].spawnLimit<1 and data[n].role=="Death" then
- ui.addTextArea(12, "\n<p align='center'>"..text[n].youCanAttack, n, 270, 23, 240, 36, 0x00a611, 0x338500, 0.6, true)
- end
- if not (data[n].spawnLimit<1) and data[n].role=="Death" then
- ui.addTextArea(12, "\n<p align='center'>"..text[n].youCanNotAttack, n, 270, 23, 240, 36, 0x802c2c, 0x6e0000, 0.6, true)
- end
- if data[n].spawnLimit<1 and data[n].role=="Runner" then
- ui.addTextArea(12, "\n<p align='center'>"..text[n].youCanUsePowerups, n, 270, 23, 240, 36, 0x00a611, 0x338500, 0.6, true)
- end
- if not (data[n].spawnLimit<1) and data[n].role=="Runner" then
- ui.addTextArea(12, "\n<p align='center'>"..text[n].youCanNotUsePowerups, n, 270, 23, 240, 36, 0x802c2c, 0x6e0000, 0.6, true)
- end
- end
- end
- function removeObjectAfterTime()
- for k, v in ipairs(toDespawn) do
- if os.time() > v[2] then
- tfm.exec.removeObject(v[1])
- table.remove(toDespawn, k)
- end
- end
- end
- function eventLoop()
- lag=0
- removeObjectAfterTime()
- if mice<2 then
- ui.addTextArea(202, "<p align='center'><R><b><font size='20'>You need at least 2 people to play. ", nil, 137, 166, 471, 122, 0x404040, 0x000000, 1, true)
- elseif mice>1 then
- ui.removeTextArea(202,nil)
- wonCoundown=wonCountDown+0.5
- ui.addTextArea(13, "<font size='20'>"..math.floor(time).." / 120s", nil, 316, 73, 251, 32, 0x324650, 0x000000, 0, true)
- canShoot()
- for n,player in pairs(tfm.get.room.playerList) do
- data[n].spawnLimit=data[n].spawnLimit-0.5
- if tfm.get.room.playerList[n].y>100 and data[n].role=="Death" then
- tfm.exec.movePlayer(n,150,30,false,0,0,false)
- elseif tfm.get.room.playerList[n].y<100 and data[n].role=="Runner" then
- tfm.exec.movePlayer(n,70,300,false,0,0,false)
- elseif tfm.get.room.playerList[n].x>600 and time<5 then
- tfm.exec.killPlayer(n)
- tfm.exec.movePlayer(n,150,tfm.get.room.playerList[n].y,false,0,0,false)
- tfm.exec.respawnPlayer(n)
- end
- if data[n].spawnLimit==0 then
- ui.removeTextArea(2,nil)
- system.bindMouse(n, true)
- ui.removeTextArea(11,n)
- end
- end
- time=time+.5
- if time==120 then
- tfm.exec.newGame(maps[math.random(#maps)])
- print("Deaths win!")
- time=-0.5
- elseif time==0 then
- for n,player in pairs(tfm.get.room.playerList) do
- findRoles(n)
- end
- elseif time==5 or time==10 then
- for n,player in pairs(tfm.get.room.playerList) do
- ui.removeTextArea(0,nil)
- ui.removeTextArea(2,nil)
- system.bindMouse(n, true)
- ui.removeTextArea(133,n)
- end
- end
- end
- end
- function eventKeyboard(n, key, down, x,y)
- if key==65 or key==37 then
- data[n].facing=-85
- elseif key==39 or key==68 then
- data[n].facing=85
- end
- if time>3 then
- if key==32 and data[n].role=="Runner" and data[n].spawnLimit<0 then
- ui.addTextArea(11, "<b><font size='30'><font color='#F0F000'>"..text[n].superJump, n, x-50, y-50, 379, 67, 0x324650, 0x000000, 0, false)
- tfm.exec.displayParticle(0,x,y,0.5,0.5,0.5,0.5,nil)
- tfm.exec.displayParticle(0,locationx,locationy,-0.5,-0.5,-0.5,-0.5,nil)
- tfm.exec.displayParticle(2,locationx,locationy,3,-3,3,-3,nil)
- tfm.exec.displayParticle(2,locationx,locationy,-3,3,-3,3,nil)
- tfm.exec.displayParticle(0,x,y,-0.5,0.5,-0.5,0.5,nil)
- tfm.exec.displayParticle(0,x,y,0.5,-0.5,0.5,-0.5,nil)
- tfm.exec.displayParticle(2,x,y,1,-3,1,-3,nil)
- tfm.exec.displayParticle(2,x,y,1,1,3,1,nil)
- tfm.exec.displayParticle(2,x,y,-1,3,-1,3,nil)
- tfm.exec.displayParticle(2,x,y,-1,-1,-3,-1,nil)
- tfm.exec.displayParticle(5,x,y,0.5,0.5,0.5,0.5,nil)
- tfm.exec.displayParticle(5,x,y,-0.5,-0.5,-0.5,-0.5,nil)
- tfm.exec.displayParticle(5,x,y,-0.5,0.5,-0.5,0.5,nil)
- tfm.exec.displayParticle(5,x,y,0.5,-0.5,0.5,-0.5,nil)
- tfm.exec.movePlayer(n,x,y,false,0,-80,false)
- tfm.exec.displayParticle(0,x,y,0.5,0.5,0.5,0.5,nil)
- tfm.exec.displayParticle(0,locationx,locationy,-0.5,-0.5,-0.5,-0.5,nil)
- tfm.exec.displayParticle(10,locationx,locationy,3,-3,3,-3,nil)
- tfm.exec.displayParticle(10,locationx,locationy,-3,3,-3,3,nil)
- tfm.exec.displayParticle(10,x,y,-0.5,0.5,-0.5,0.5,nil)
- tfm.exec.displayParticle(10,x,y,0.5,-0.5,0.5,-0.5,nil)
- tfm.exec.displayParticle(2,x,y,1,-3,1,-3,nil)
- tfm.exec.displayParticle(10,x,y,1,1,3,1,nil)
- tfm.exec.displayParticle(12,x,y,-1,3,-1,3,nil)
- tfm.exec.displayParticle(12,x,y,-1,-1,-3,-1,nil)
- tfm.exec.displayParticle(5,x,y,0.5,0.5,0.5,0.5,nil)
- tfm.exec.displayParticle(5,x,y,-0.5,-0.5,-0.5,-0.5,nil)
- tfm.exec.displayParticle(5,x,y,-0.5,0.5,-0.5,0.5,nil)
- tfm.exec.displayParticle(5,x,y,0.5,-0.5,0.5,-0.5,nil)
- tfm.exec.bindKeyboard(n, 32, false, false)
- tfm.exec.addShamanObject(17,x,y,60,50,-10,true)
- data[n].spawnLimit=3.5
- data[n].ableToShoot=0
- elseif (key==40 or key==Down) and data[n].spawnLimit<0 then
- ui.addTextArea(11, "<b><font size='30'><font color='#F0F000'>"..text[n].speed, n, x-50, y-50, 379, 67, 0x324650, 0x000000, 0, false)
- tfm.exec.displayParticle(0,x,y,0.5,0.5,0.5,0.5,nil)
- tfm.exec.displayParticle(0,locationx,locationy,-0.5,-0.5,-0.5,-0.5,nil)
- tfm.exec.displayParticle(2,locationx,locationy,3,-3,3,-3,nil)
- tfm.exec.displayParticle(2,locationx,locationy,-3,3,-3,3,nil)
- tfm.exec.displayParticle(0,x,y,-0.5,0.5,-0.5,0.5,nil)
- tfm.exec.displayParticle(0,x,y,0.5,-0.5,0.5,-0.5,nil)
- tfm.exec.displayParticle(2,x,y,1,-3,1,-3,nil)
- tfm.exec.displayParticle(2,x,y,1,1,3,1,nil)
- tfm.exec.displayParticle(2,x,y,-1,3,-1,3,nil)
- tfm.exec.displayParticle(2,x,y,-1,-1,-3,-1,nil)
- tfm.exec.displayParticle(5,x,y,0.5,0.5,0.5,0.5,nil)
- tfm.exec.displayParticle(5,x,y,-0.5,-0.5,-0.5,-0.5,nil)
- tfm.exec.displayParticle(5,x,y,-0.5,0.5,-0.5,0.5,nil)
- tfm.exec.displayParticle(5,x,y,0.5,-0.5,0.5,-0.5,nil)
- tfm.exec.movePlayer(n,x,y,false,data[n].facing,0,true)
- tfm.exec.displayParticle(0,x,y,0.5,0.5,0.5,0.5,nil)
- tfm.exec.displayParticle(0,locationx,locationy,-0.5,-0.5,-0.5,-0.5,nil)
- tfm.exec.displayParticle(10,locationx,locationy,3,-3,3,-3,nil)
- tfm.exec.displayParticle(10,locationx,locationy,-3,3,-3,3,nil)
- tfm.exec.displayParticle(10,x,y,-0.5,0.5,-0.5,0.5,nil)
- tfm.exec.displayParticle(10,x,y,0.5,-0.5,0.5,-0.5,nil)
- tfm.exec.displayParticle(2,x,y,1,-3,1,-3,nil)
- tfm.exec.displayParticle(10,x,y,1,1,3,1,nil)
- tfm.exec.displayParticle(12,x,y,-1,3,-1,3,nil)
- tfm.exec.displayParticle(12,x,y,-1,-1,-3,-1,nil)
- tfm.exec.displayParticle(5,x,y,0.5,0.5,0.5,0.5,nil)
- tfm.exec.displayParticle(5,x,y,-0.5,-0.5,-0.5,-0.5,nil)
- tfm.exec.displayParticle(5,x,y,-0.5,0.5,-0.5,0.5,nil)
- tfm.exec.displayParticle(5,x,y,0.5,-0.5,0.5,-0.5,nil)
- data[n].spawnLimit=3.5
- data[n].ableToShoot=0
- end
- end
- end
- function eventTextAreaCallback(id,n,a)
- if a=="close" then
- ui.removeTextArea(18,n)
- ui.removeTextArea(19,n)
- ui.removeTextArea(110,n)
- ui.removeTextArea(25,n)
- elseif a=="help" then
- ui.addTextArea(110, "", n, 498, 165, 266, 217, 0x324650, 0x000000, 1, true)
- ui.addTextArea(18, "<font size='15'><font face='calibri'>"..text[n].help, n, 504, 172, 254, 179, 0x000000, 0x000000, 1, true)
- ui.addTextArea(19, "<p align='center'><font size='13'><a href='event:close'>"..text[n].close, n, 504, 338, 254, 36, 0x000000, 0xffffff, 1, true)
- elseif a=="credits" then
- ui.addTextArea(18, "<p align='center'><font size='16'><font face='verdana'><J>"..text[n].credits, n, 504, 142, 254, 194, 0x4f4132, 0x695743, 1, true)
- ui.addTextArea(19, "<p align='center'><font size='13'><a href='event:close'>"..text[n].close, n, 504, 338, 254, 36, 0x4f4132, 0x30291a, 1, true)
- elseif a=="commands" then
- ui.addTextArea(18, "<p align='center'><font size='14'><font face='verdana'>"..text[n].commands, n, 545, 111, 220, 238, 0x50498c, 0x05014f, 1, true)
- ui.addTextArea(19, "<p align='center'><font size='13'><a href='event:close'>Close", n, 545, 346, 220, 36, 0x284391, 0x0f0759, 1, true)
- elseif a=="rules" then
- ui.addTextArea(18, "<p align='center'><u><font size='17'><font face='calibri'>"..text[n].rules, n, 562, 132, 201, 230, 0xab0000, 0xff4545, 1, true)
- ui.addTextArea(19, "<p align='center'><font size='13'><a href='event:close'>"..text[n].close, n, 562, 329, 201, 36, 0xa60000, 0xff0000, 1, true)
- elseif a=="profile" then
- ui.addTextArea(110, "<p align='center'><font size='12'><font color='#000000'><font face='calibri'>"..n, n, 551, 89, 233, 278, 0xffd900, 0x075214, 1, true)
- ui.addTextArea(18, "<p align='left'><font size='13'><font face='calibri'><font color='#FFFFFF'> Points: "..data[n].points.." <br><br>Wins as death: <br><br>Wins as runner:", n, 557, 136, 105, 226, 0x966a03, 0x294d12, 1, true)
- ui.addTextArea(19, "<p align='left'><font size='13'><font face='calibri'><font color='#FFFFFF'> Description\n\n", n, 675, 136, 104, 226, 0x966a03, 0x294d12, 1, true)
- ui.addTextArea(25, "<p align='center'><font size='13'><a href='event:close'><font color='#505050'>"..text[n].close, n, 551, 368, 233, 36, 0xffd900, 0x075214, 1, true)
- end
- end
- function eventPlayerDied(n)
- if data[n].role=="Runner" then
- runner=runner-1
- print(runner)
- end
- if runner<1 then
- tfm.exec.newGame(maps[math.random(#maps)])
- for n,player in pairs(tfm.get.room.playerList) do
- ui.addTextArea(133, "<b><font size='40'><font color='#d40000'>"..text[n].deathsWin, n, 296, 282, 351, 189, 0xd41717, 0x000000, 0, true)
- tfm.exec.chatMessage(text[n].deathsWin,n)
- if data[n].role=="Death" then
- data[n].points=data[n].points+3
- end
- end
- wonCountDown=-5
- print("hi")
- end
- if death<1 then
- tfm.exec.newGame(maps[math.random(#maps)])
- tfm.exec.disableAutoShaman(true)
- time=0
- for n,player in pairs(tfm.get.room.playerList) do
- wonCountdown=-5
- changeCurrentRole()
- data[n].role="Runner"
- end
- data[names[math.floor(math.random(mice))]].role="Death"
- end
- end
- print(death)
- print(runner)
- print(mice)
- function eventPlayerLeft(n)
- mice=mice-1
- if data[n].role=="Runner" then
- runner=runner-1
- elseif data[n].role=="Death" then
- death=death-1
- end
- end
- for n,player in pairs(tfm.get.room.playerList) do
- data[n].pointsAndScore=data[n].points.." "..data[n].name
- end
- function eventSummoningEnd(n,id,x,y,angle,t)
- tfm.exec.removeObject(t.id)
- end
Advertisement
Add Comment
Please, Sign In to add comment