Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --300,80,150,200
- tfm.exec.setGameTime(3,true)
- dp={}
- roles={0,1}
- maps={7489629}
- data={}
- text={}
- lang={}
- players={}
- ids={
- 0,
- 0,
- 0,
- 0
- }
- alive=0
- lang.en={
- menu="Menu",
- profile2="Profile",
- help2="Help",
- help="In #kidnapper the goal of the game is for protectors to catch the mouse with the bomb before the mouse gets to the hole. The mouse with the bomb can use attacks to shield off protectors.",
- wins="Total Wins",
- wins_Bomber="Wins As Kidnapper",
- wins_Protector="Wins As Protector",
- close="Close",
- health=100,
- bomber_Wins="Kidnapper Wins!",
- protector_Wins="Protectors Win!",
- powerups2="Powerups",
- powerup1="[Normal Attack]</J> Is activated by pressing space. Only works for Protectors when they are near the bomber.",
- powerup2="[Mega Jump]</J> Is activated by the down arrow.",
- mouseStolen="kidnapped the mouse!",
- buy="Buy",
- bought="Equip",
- unequip="Unequip",
- shop="Shop",
- points="Points",
- notEnough="Not enough points!"
- }
- for _, s in next, {'AutoTimeLeft', 'PhysicalConsumables', 'AfkDeath', 'AutoShaman', 'AutoNewGame'} do
- tfm.exec['disable' .. s]()
- end
- function Dp(name)
- name = name:sub(1,1):upper()..name:sub(2):lower()
- for i,dp in ipairs(dp) do
- if name==dp then
- return true
- end
- end
- return false
- end
- function inv1(n)
- if data[n].shopItems.lightningMouse==1 then
- data[n].buy1="</a><VP><a href='event:equip1'>"..text[n].bought
- end
- end
- function stolen(n)
- data[n].p=player
- data[n].stolen="<R>"..data[n].p.."<J> "..text[n].mouseStolen
- tfm.exec.chatMessage(data[n].stolen,n)
- end
- function particles(x,y)
- tfm.exec.displayParticle(9,x,y+10,-0.4,0.1,0.2,0.3,nil)
- tfm.exec.displayParticle(9,x,y+10,-0.6,0.2,0.6,0.2,nil)
- tfm.exec.displayParticle(9,x,y+10,-0.8,0.3,0.8,0.1,nil)
- tfm.exec.displayParticle(9,x,y+10,0.4,0.4,-0.4,0.3,nil)
- tfm.exec.displayParticle(9,x,y+10,0.6,0.5,-0.6,0.2,nil)
- tfm.exec.displayParticle(9,x,y+10,0.8,0.6,-0.8,0.1,nil)
- end
- function bigJump(n,x,y)
- tfm.exec.movePlayer(n,0,0,false,0,-80,true)
- tfm.exec.displayParticle(3,x-5,y+10,-0.8,0,0,0,n)
- tfm.exec.displayParticle(3,x+5,y+10,0.8,0,0,0,n)
- tfm.exec.displayParticle(3,x-10,y+10,-1.7,0,0,0,n)
- tfm.exec.displayParticle(3,x+10,y+10,1.7,0,0,0,n)
- particles(x,y)
- end
- function identifyBomber(n)
- if data[n].role==0 then
- tfm.exec.setNameColor(n,0x00FF00)
- tfm.exec.movePlayer(n,1023,432,false,0,50,false)
- elseif data[n].role==1 then
- tfm.exec.setNameColor(n,0xFF0000)
- end
- end
- function countAlive()
- alive=0
- for n,player in pairs(tfm.get.room.playerList) do
- if tfm.get.room.playerList[n].isDead==false then
- alive=alive+1
- end
- end
- end
- function removeWinner()
- ui.removeTextArea(20,nil)
- ui.removeTextArea(30,nil)
- ui.removeTextArea(40,nil)
- ui.removeTextArea(50,nil)
- ui.removeTextArea(60,nil)
- ui.removeTextArea(19,nil)
- end
- function win(n)
- if tfm.get.room.playerList[n].isDead==false and data[n].role==0 then
- data[n].wins=data[n].wins+1
- data[n].points=data[n].points+7
- data[n].wins_Protector=data[n].wins_Protector+1
- end
- end
- function insertName(n)
- table.insert(players,n)
- end
- function setLang(n)
- text[n]=lang[tfm.get.room.playerList[n].community] or lang.en
- end
- function setData(n)
- data[n]=
- {
- wins=0,
- role=0,
- health=100,
- spawn=1,
- wins_Protector=0,
- wins_Bomber=0,
- p="",
- stolen="",
- shopItems={propellerMouse=0,greenMouse=0,lightningMouse=0,tigerMouse=0},
- buy1=text[n].buy,
- buy2=text[n].buy,
- buy3=text[n].buy,
- buy4=text[n].buy,
- using="1651b5bc86d.png",
- points=1220
- }
- end
- function chooseRole()
- for n,player in pairs(tfm.get.room.playerList) do
- data[n].role=0
- end
- player=players[math.random(#players)]
- data[player].role=1
- player=""..player
- end
- function bindKeyboard(n)
- for i=0,150 do
- tfm.exec.bindKeyboard(n,i,true,true)
- end
- end
- function showMenu(n)
- ui.addTextArea(0, "<p align='center'><font face='calibri'><a href='event:menu2'>"..text[n].menu, n, 10, 30, 42, 20, 0x000001, 0xFFFFFF, 1, true)
- end
- function showMenu2(n)
- ui.addTextArea(0, "<p align='center'><font face='calibri'><a href='event:Menu'>"..text[n].menu.." </a>| <a href='event:Help'>"..text[n].help2.."</a> | <a href='event:Profile'>"..text[n].profile2.."</a> | <a href='event:Powerups'>"..text[n].powerups2.."</a> | <a href='event:Shop'>"..text[n].shop, n, 10, 30, 210, 20, 0x000001, 0xffffff, 1, true)
- end
- function removeImage(n)
- tfm.exec.removeImage(id1)
- tfm.exec.removeImage(id2)
- tfm.exec.removeImage(id3)
- tfm.exec.removeImage(id4)
- end
- function removeShop(n)
- for i=1020,1050 do
- ui.removeTextArea(i,n)
- end
- end
- function showHealth(n)
- ui.addTextArea(-3, "", n, 319, 27, 100, 18, 0xffffff, 0xffffff, 1, true)
- ui.addTextArea(-1, "", n, 319, 27, data[n].health, 18, 0x1aff00, 0x1aff00, 1, true)
- ui.addTextArea(-2, "<p align='center'><b><font color='#000000'>"..data[n].health.."%", n, 345, 27, 54, 18, 0x324650, 0x000000, 0, true)
- end
- function displayTab(n,info,subject)
- ui.addTextArea(2, "", n, 262, 72, 360, 290, 0x331f15, 0x331f15, 1, true)
- ui.addTextArea(3, "", n, 262, 125, 4, 180, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(5, "", n, 295, 72, 290, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(4, "", n, 618, 125, 4, 180, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(6, "", n, 295, 358, 295, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1, "<p align='center'><font face='calibri'><font size='17'><b>#KIDNAPPER - "..subject.."</b></font></font><font size='14'>\n\n"..info, n, 271, 80, 342, 270, 0x1b262b, 0x131c21, 1, true)
- ui.addTextArea(7, "<p align='center'><font size='13'><a href='event:close'>"..text[n].close.."</a></font>", n, 272, 330, 339, 20, 0x324650, 0x324650, 1, true)
- end
- function profile(n,info)
- ui.addTextArea(2, "", n, 262, 72, 268, 290, 0x331f15, 0x331f15, 1, true)
- ui.addTextArea(3, "", n, 262, 120, 4, 180, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(5, "", n, 295, 72, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(4, "", n, 526, 120, 4, 180, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(6, "", n, 295, 358, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1, "<p align='center'><font face='calibri'><font size='17'><b>"..n.."</b></font></font></p><font size='14'>\n<font face='calibri'>\n"..info, n, 270, 82, 252, 270, 0x1b262b, 0x131c21, 1, true)
- ui.addTextArea(7, "<p align='center'><font size='13'><a href='event:close'>"..text[n].close.."</a></font>", n, 272, 330, 248, 20, 0x324650, 0x324650, 1, true)
- end
- function profile2(n,info,l)
- ui.addTextArea(2, "", l, 262, 72, 268, 290, 0x331f15, 0x331f15, 1, true)
- ui.addTextArea(3, "", l, 262, 120, 4, 180, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(5, "", l, 295, 72, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(4, "", l, 526, 120, 4, 180, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(6, "", l, 295, 358, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1, "<p align='center'><font face='calibri'><font size='17'><b>"..n.."</b></font></font></p><font size='14'>\n<font face='calibri'>\n"..info, l, 270, 82, 252, 270, 0x1b262b, 0x131c21, 1, true)
- ui.addTextArea(7, "<p align='center'><font size='13'><a href='event:close'>"..text[l].close.."</a></font>", l, 272, 330, 248, 20, 0x324650, 0x324650, 1, true)
- end
- function close(n)
- for i=1,7 do
- ui.removeTextArea(i,n)
- end
- end
- function nearBomber(n,x,y,p)
- if ((tfm.get.room.playerList[n].x<tfm.get.room.playerList[p].x+100 and tfm.get.room.playerList[n].x<tfm.get.room.playerList[p].x) and tfm.get.room.playerList[n].y<tfm.get.room.playerList[p].y+50 and tfm.get.room.playerList[n].y>tfm.get.room.playerList[p].y-50) and not (n==p) and data[p].health>0 and tfm.get.room.playerList[n].isFacingRight==true then
- tfm.exec.movePlayer(p,0,0,false,operation[math.random(#operation)],operation[math.random(#operation)],true)
- data[p].health=data[p].health-12.5
- tfm.exec.displayParticle(1,x,y,0.2,0,0.2,0,nil)
- tfm.exec.displayParticle(1,x,y,0.4,0,0.4,0,nil)
- tfm.exec.displayParticle(1,x,y,0.6,0,0.6,0,nil)
- tfm.exec.displayParticle(1,x,y,0.8,0,0.8,0,nil)
- tfm.exec.displayParticle(1,x,y,1,0,1,0,nil)
- tfm.exec.displayParticle(1,x,y-10,0.2,0,0.2,0,nil)
- tfm.exec.displayParticle(1,x,y-10,0.4,0,0.4,0,nil)
- tfm.exec.displayParticle(1,x,y-10,0.6,0,0.6,0,nil)
- tfm.exec.displayParticle(1,x,y-10,0.8,0,0.8,0,nil)
- tfm.exec.displayParticle(1,x,y-10,1,0,1,0,nil)
- tfm.exec.displayParticle(1,x,y+10,0.2,0,0.2,0,nil)
- tfm.exec.displayParticle(1,x,y+10,0.4,0,0.4,0,nli)
- tfm.exec.displayParticle(1,x,y+10,0.6,0,0.6,0,nil)
- tfm.exec.displayParticle(1,x,y+10,0.8,0,0.8,0,nil)
- tfm.exec.displayParticle(1,x,y+10,1,0,1,0,nil)
- end
- if ((tfm.get.room.playerList[n].x>tfm.get.room.playerList[p].x-100 and tfm.get.room.playerList[n].x>tfm.get.room.playerList[p].x) and tfm.get.room.playerList[n].y<tfm.get.room.playerList[p].y+50 and tfm.get.room.playerList[n].y>tfm.get.room.playerList[p].y-50) and not (n==p) and data[p].health>0 and tfm.get.room.playerList[n].isFacingRight==false then
- tfm.exec.movePlayer(p,0,0,false,operation[math.random(#operation)],operation[math.random(#operation)],true)
- data[p].health=data[p].health-12.5
- tfm.exec.displayParticle(1,x,y,-0.2,0,-0.2,0,nil)
- tfm.exec.displayParticle(1,x,y,-0.4,0,-0.4,0,nil)
- tfm.exec.displayParticle(1,x,y,-0.6,0,-0.6,0,nil)
- tfm.exec.displayParticle(1,x,y,-0.8,0,-0.8,0,nil)
- tfm.exec.displayParticle(1,x,y,-1,0,-1,0,nil)
- tfm.exec.displayParticle(1,x,y-10,-0.2,0,-0.2,0,nil)
- tfm.exec.displayParticle(1,x,y-10,-0.4,0,-0.4,0,nil)
- tfm.exec.displayParticle(1,x,y-10,-0.6,0,-0.6,0,nil)
- tfm.exec.displayParticle(1,x,y-10,-0.8,0,-0.8,0,nil)
- tfm.exec.displayParticle(1,x,y-10,-1,0,-1,0,nil)
- tfm.exec.displayParticle(1,x,y+10,-0.2,0,-0.2,0,nil)
- tfm.exec.displayParticle(1,x,y+10,-0.4,0,-0.4,0,nli)
- tfm.exec.displayParticle(1,x,y+10,-0.6,0,-0.6,0,nil)
- tfm.exec.displayParticle(1,x,y+10,-0.8,0,-0.8,0,nil)
- tfm.exec.displayParticle(1,x,y+10,-1,0,-1,0,nil)
- end
- if data[p].health<1 then
- tfm.exec.killPlayer(p)
- end
- end
- operation={-110,110}
- function nearProtector(n,p,x,y)
- if not (n==p) and data[p].health>0 and data[n].health>0 then
- tfm.exec.displayParticle(13,x,y,-0.2,0.1,-0.2,0.1,nil)
- tfm.exec.displayParticle(13,x,y,-0.4,0,-0.4,0,nil)
- tfm.exec.displayParticle(13,x,y,-0.6,0,-0.6,0,nil)
- tfm.exec.displayParticle(3,x,y,-0.8,0,-0.8,0,nil)
- tfm.exec.displayParticle(3,x,y,-8,0,-1,0,nil)
- tfm.exec.displayParticle(3,x,y-10,-0.2,0.1,-0.2,0.1,nil)
- tfm.exec.displayParticle(13,x,y-10,-0.4,0,-0.4,0,nil)
- tfm.exec.displayParticle(13,x,y-10,-0.6,0,-0.6,0,nil)
- tfm.exec.displayParticle(13,x,y-10,-0.8,0,-0.8,0,nil)
- tfm.exec.displayParticle(13,x,y-10,-1,0,-1,0,nil)
- tfm.exec.displayParticle(13,x,y+10,-0.2,0.1,-0.2,0.1,nil)
- tfm.exec.displayParticle(13,x,y+10,-0.4,0,-0.4,0,nli)
- tfm.exec.displayParticle(13,x,y+10,-0.6,0,-0.6,0,nil)
- tfm.exec.displayParticle(13,x,y+10,-0.8,-0.1,-0.8,-0.1,nil)
- tfm.exec.displayParticle(13,x,y+10,-1,0,-1,0,nil)
- tfm.exec.displayParticle(13,x,y,0.2,0,0.2,0,nil)
- tfm.exec.displayParticle(13,x,y,0.4,0,0.4,0,nil)
- tfm.exec.displayParticle(13,x,y,0.6,0,0.6,0,nil)
- tfm.exec.displayParticle(13,x,y,0.8,0,0.8,0,nil)
- tfm.exec.displayParticle(13,x,y,1,0,1,0,nil)
- tfm.exec.displayParticle(13,x,y-10,0.2,0.1,0.2,0.1,nil)
- tfm.exec.displayParticle(13,x,y-10,0.4,0,0.4,0,nil)
- tfm.exec.displayParticle(13,x,y-10,0.6,0,0.6,0,nil)
- tfm.exec.displayParticle(13,x,y-10,0.8,0,0.8,0,nil)
- tfm.exec.displayParticle(13,x,y-10,1,0,1,0,nil)
- tfm.exec.displayParticle(13,x,y+10,0.2,0,0.2,0,nil)
- tfm.exec.displayParticle(13,x,y+10,0.4,0,0.4,0,nli)
- tfm.exec.displayParticle(13,x,y+10,0.6,0,0.6,0,nil)
- tfm.exec.displayParticle(3,x,y+10,0.8,0,0.8,0,nil)
- tfm.exec.displayParticle(3,x,y+10,8,0,1,0,nil)
- end
- if (tfm.get.room.playerList[n].x<tfm.get.room.playerList[p].x+70 and tfm.get.room.playerList[n].x>tfm.get.room.playerList[p].x-70 and tfm.get.room.playerList[n].y<tfm.get.room.playerList[p].y+30 and tfm.get.room.playerList[n].y>tfm.get.room.playerList[p].y-30) and not (n==p) and data[p].health>0 and data[n].health>0 then
- data[n].health=data[n].health-12.5
- tfm.exec.movePlayer(n,0,0,false,operation[math.random(#operation)],operation[math.random(#operation)],true)
- end
- if data[n].health<1 then
- tfm.exec.killPlayer(n)
- end
- end
- for n,player in pairs(tfm.get.room.playerList) do
- bindKeyboard(n)
- setLang(n)
- insertName(n)
- setData(n)
- showMenu(n)
- table.insert(dp,n)
- end
- chooseRole()
- for n,player in pairs(tfm.get.room.playerList) do
- identifyBomber(n)
- end
- function allInfo(n)
- bindKeyboard(n)
- setLang(n)
- insertName(n)
- setData(n)
- showMenu(n)
- identifyBomber(n)
- table.insert(dp,n)
- end
- function eventNewGame()
- players={}
- for n,player in pairs(tfm.get.room.playerList) do
- insertName(n)
- end
- chooseRole()
- countAlive()
- removeWinner()
- for n,player in pairs(tfm.get.room.playerList) do
- identifyBomber(n)
- data[n].health=100
- stolen(n)
- end
- id=tfm.exec.addImage(data[player].using,"$"..player, -40, -25)
- end
- function eventTextAreaCallback(txt, n, a)
- removeImage(n)
- if a=="Menu" then
- showMenu(n)
- elseif a=="menu2" then
- showMenu2(n)
- elseif a=="Help" then
- displayTab(n,text[n].help,text[n].help2)
- elseif a=="close" then
- close(n)
- removeImage(n)
- removeShop(n)
- elseif a=="Profile" then
- profile(n,text[n].wins..": <J>"..data[n].wins.."\n\n</J>"..text[n].wins_Bomber..": <J>"..data[n].wins_Bomber.."\n\n</J>"..text[n].wins_Protector..": <J>"..data[n].wins_Protector.."</J>\n\n"..text[n].points..": <J>"..data[n].points)
- elseif a=="Powerups" then
- displayTab(n,"<J>"..text[n].powerup1.."\n\n<J>"..text[n].powerup2,text[n].powerups2)
- elseif a=="Shop" then
- shop(n)
- elseif a=="buy1" and data[n].points>=80 then
- data[n].buy1="</a><G><a href='event:unequip1'>"..text[n].unequip
- data[n].using="1651ca2b636.png"
- data[n].shopItems.propellerMouse=1
- data[n].points=data[n].points-80
- shop1(n)
- elseif a=="buy2" and data[n].points>=150 then
- data[n].buy2="</a><G><a href='event:unequip2'>"..text[n].unequip
- data[n].using="1651ca29934.png"
- data[n].points=data[n].points-150
- shop2(n)
- elseif a=="buy1" and not (data[n].points>=80) then
- tfm.exec.chatMessage("<R>"..text[n].notEnough,n)
- elseif a=="buy3" and data[n].points>=200 then
- data[n].buy3="</a><G><a href='event:unequip3'>"..text[n].unequip
- data[n].using="1651ca27c02.png"
- data[n].points=data[n].points-200
- shop3(n)
- elseif a=="buy2" and not (data[n].points>=300) then
- tfm.exec.chatMessage("<R>"..text[n].notEnough,n)
- elseif a=="buy4" and data[n].points>=300 then
- data[n].buy4="</a><G><a href='event:unequip4'>"..text[n].unequip
- data[n].points=data[n].points-300
- data[n].using="1651ca26129.png"
- shop4(n)
- elseif a=="buy3" and not (data[n].points>=200) then
- tfm.exec.chatMessage("<R>"..text[n].notEnough,n)
- elseif a=="buy4" and not (data[n].points>=150) then
- tfm.exec.chatMessage("<R>"..text[n].notEnough,n)
- elseif a=="unequip1" then
- data[n].using="1651b5bc86d.png"
- data[n].buy1="</a><VP><a href='event:equip1'>"..text[n].bought
- shop(n)
- elseif a=="unequip2" then
- data[n].using="1651b5bc86d.png"
- data[n].buy2="</a><VP><a href='event:equip2'>"..text[n].bought
- shop(n)
- elseif a=="unequip3" then
- data[n].using="1651b5bc86d.png"
- data[n].buy3="</a><VP><a href='event:equip3'>"..text[n].bought
- shop(n)
- elseif a=="unequip4" then
- data[n].using="1651b5bc86d.png"
- data[n].buy4="</a><VP><a href='event:equip4'>"..text[n].bought
- shop(n)
- elseif a=="equip1" then
- data[n].using="1651ca2b636.png"
- data[n].buy1="</a><G><a href='event:unequip1'>"..text[n].unequip
- shop1(n)
- elseif a=="equip2" then
- data[n].using="1651ca29934.png"
- data[n].buy2="</a><G><a href='event:unequip2'>"..text[n].unequip
- shop2(n)
- elseif a=="equip3" then
- data[n].using="1651ca27c02.png"
- data[n].buy3="</a><G><a href='event:unequip3'>"..text[n].unequip
- shop3(n)
- elseif a=="equip4" then
- data[n].using="1651ca26129.png"
- data[n].buy4="</a><G><a href='event:unequip4'>"..text[n].unequip
- shop4(n)
- end
- end
- function eventNewPlayer(n)
- allInfo(n)
- end
- function eventLoop(time,timeRemaining)
- for n,player in pairs(tfm.get.room.playerList) do
- data[n].spawn=data[n].spawn+0.5
- showHealth(n)
- end
- if timeRemaining<=0 then
- tfm.exec.newGame(maps[math.random(#maps)])
- end
- end
- function eventKeyboard(n, k, d, x, y)
- if k==32 and data[n].role==0 and data[n].spawn>0 and tfm.get.room.playerList[n].isDead==false then
- nearBomber(n,x,y,player)
- data[n].spawn=-1
- elseif k==32 and data[n].role==1 and data[n].spawn>0 and tfm.get.room.playerList[n].isDead==false then
- data[n].spawn=-1.5
- player=player
- for n in pairs(tfm.get.room.playerList) do
- nearProtector(n,player,tfm.get.room.playerList[player].x,tfm.get.room.playerList[player].y)
- end
- elseif k==3 and data[n].spawn>0 then
- data[n].spawn=-2
- player=player
- bigJump(n,x,y)
- elseif k==112 then
- end
- end
- function eventPlayerDied(n)
- for n,player in pairs(tfm.get.room.playerList) do
- win(n)
- end
- countAlive()
- data[n].health=0
- if data[n].role==1 then
- for n,player in pairs(tfm.get.room.playerList) do
- ui.addTextArea(20, "", n, 262, 172, 268, 66, 0x331f15, 0x331f15, 1, true)
- ui.addTextArea(30, "", n, 262, 191, 4, 26, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(50, "", n, 300, 172, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(40, "", n, 526, 192, 4, 26, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(60, "", n, 300, 234, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(19, "<p align='center'><font size='20'><VP>"..text[n].protector_Wins, n, 270, 182, 252, 44, 0x1b262b, 0x131c21, 1, true)
- tfm.exec.setGameTime(5,true)
- end
- end
- end
- function eventMouse(playerName,x,y)
- print("<VP>X</VP><N>:</N><J> "..x.."</J><VP> Y</VP><N>:</N><J> "..y)
- end
- system.bindMouse("Fuzzyfirsdog#0000", true)
- function eventPlayerGetCheese(n)
- if data[n].role==1 then
- data[n].wins=data[n].wins+1
- data[n].wins_Bomber=data[n].wins_Bomber+1
- data[n].points=data[n].points+10
- tfm.exec.setGameTime(10,true)
- for n,player in pairs(tfm.get.room.playerList) do
- ui.addTextArea(20, "", n, 262, 172, 268, 66, 0x331f15, 0x331f15, 1, true)
- ui.addTextArea(30, "", n, 262, 191, 4, 26, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(50, "", n, 300, 172, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(40, "", n, 526, 192, 4, 26, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(60, "", n, 300, 234, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(19, "<p align='center'><font size='20'><R>"..text[n].bomber_Wins, n, 270, 182, 252, 44, 0x1b262b, 0x131c21, 1, true)
- if not (data[n].role==1) then
- tfm.exec.killPlayer(n)
- end
- end
- end
- end
- system.disableChatCommandDisplay("p",true)
- function eventChatCommand(l,c)
- if c=="p" then
- profile(l,text[l].wins..": <J>"..data[l].wins.."\n\n</J>"..text[l].wins_Bomber..": <J>"..data[l].wins_Bomber.."\n\n</J>"..text[l].wins_Protector..": <J>"..data[l].wins_Protector)
- end
- if c:sub(0,1)=="p" and Dp(c:sub(3))then
- n = c:sub(3,3):upper()..c:sub(4):lower()
- profile2(n,text[l].wins..": <J>"..data[n].wins.."\n\n</J>"..text[l].wins_Bomber..": <J>"..data[n].wins_Bomber.."\n\n</J>"..text[l].wins_Protector..": <J>"..data[n].wins_Protector.."</J>\n\n"..text[l].points..": <J>"..data[n].points,l)
- end
- end
- function shop(n)
- ui.addTextArea(1020, "", n, 113, 58, 643, 260, 0x331f15, 0x331f15, 1, true)
- ui.addTextArea(1021, "", n, 296, 314, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1022, "", n, 113, 111, 4, 151, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1023, "", n, 752, 111, 4, 151, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1024, "", n, 296, 58, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1025, "<p align='center'><font size='20'><VP>", n, 122, 68, 626, 240, 0x1b262b, 0x131c21, 1, true)
- ui.addTextArea(1026, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/300", n, 154, 94, 100, 100, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1027, "<p align='center'><b><a href='event:buy1'>"..data[n].buy1, n, 153, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1028, "<p align='center'><b><a href='event:buy2'>"..data[n].buy2, n, 309, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1029, "<p align='center'><b><a href='event:buy3'>"..data[n].buy3, n, 468, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1030, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/200", n, 617, 94, 100, 100, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1031, "<p align='center'><b><a href='event:buy4'>"..data[n].buy4, n, 617, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1032, "<p align='center'><font size='13'><a href='event:close'>"..text[n].close.."</a></font>", n, 125, 285, 620, 20, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1033, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/80", n, 309, 94, 100, 100, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1034, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/150", n, 468, 94, 100, 100, 0x324650, 0x324650, 1, true)
- id4=tfm.exec.addImage("1651ca2b636.png", "&1", 153, 115, n)
- id3=tfm.exec.addImage("1651ca29934.png", "&2", 312, 110, n)
- id2=tfm.exec.addImage("1651ca27c02.png", "&3", 467, 110, n)
- id1=tfm.exec.addImage("1651ca26129.png", "&4", 617, 110, n)
- end
- function shop1(n)
- ui.addTextArea(1020, "", n, 113, 58, 643, 260, 0x331f15, 0x331f15, 1, true)
- ui.addTextArea(1021, "", n, 296, 314, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1022, "", n, 113, 111, 4, 151, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1023, "", n, 752, 111, 4, 151, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1024, "", n, 296, 58, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1025, "<p align='center'><font size='20'><VP>", n, 122, 68, 626, 240, 0x1b262b, 0x131c21, 1, true)
- ui.addTextArea(1026, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/300", n, 154, 94, 100, 100, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1027, "<p align='center'><b><a href='event:buy1'>"..data[n].buy1, n, 153, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1028, "", n, 309, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1029, "", n, 468, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1030, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/200", n, 617, 94, 100, 100, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1031, "", n, 617, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1032, "<p align='center'><font size='13'><a href='event:close'>"..text[n].close.."</a></font>", n, 125, 285, 620, 20, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1033, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/80", n, 309, 94, 100, 100, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1034, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/150", n, 468, 94, 100, 100, 0x324650, 0x324650, 1, true)
- id4=tfm.exec.addImage("1651ca2b636.png", "&1", 153, 115, n)
- id3=tfm.exec.addImage("1651ca29934.png", "&2", 312, 110, n)
- id2=tfm.exec.addImage("1651ca27c02.png", "&3", 467, 110, n)
- id1=tfm.exec.addImage("1651ca26129.png", "&4", 617, 110, n)
- end
- function shop2(n)
- ui.addTextArea(1020, "", n, 113, 58, 643, 260, 0x331f15, 0x331f15, 1, true)
- ui.addTextArea(1021, "", n, 296, 314, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1022, "", n, 113, 111, 4, 151, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1023, "", n, 752, 111, 4, 151, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1024, "", n, 296, 58, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1025, "<p align='center'><font size='20'><VP>", n, 122, 68, 626, 240, 0x1b262b, 0x131c21, 1, true)
- ui.addTextArea(1026, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/300", n, 154, 94, 100, 100, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1027, "", n, 153, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1028, "<p align='center'><b><a href='event:buy2'>"..data[n].buy2, n, 309, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1029, "", n, 468, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1030, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/200", n, 617, 94, 100, 100, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1031, "", n, 617, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1032, "<p align='center'><font size='13'><a href='event:close'>"..text[n].close.."</a></font>", n, 125, 285, 620, 20, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1033, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/80", n, 309, 94, 100, 100, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1034, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/150", n, 468, 94, 100, 100, 0x324650, 0x324650, 1, true)
- id4=tfm.exec.addImage("1651ca2b636.png", "&1", 153, 115, n)
- id3=tfm.exec.addImage("1651ca29934.png", "&2", 312, 110, n)
- id2=tfm.exec.addImage("1651ca27c02.png", "&3", 467, 110, n)
- id1=tfm.exec.addImage("1651ca26129.png", "&4", 617, 110, n)
- end
- function shop3(n)
- ui.addTextArea(1020, "", n, 113, 58, 643, 260, 0x331f15, 0x331f15, 1, true)
- ui.addTextArea(1021, "", n, 296, 314, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1022, "", n, 113, 111, 4, 151, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1023, "", n, 752, 111, 4, 151, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1024, "", n, 296, 58, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1025, "<p align='center'><font size='20'><VP>", n, 122, 68, 626, 240, 0x1b262b, 0x131c21, 1, true)
- ui.addTextArea(1026, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/300", n, 154, 94, 100, 100, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1027, "", n, 153, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1028, "", n, 309, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1029, "<p align='center'><b><a href='event:buy3'>"..data[n].buy3, n, 468, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1030, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/200", n, 617, 94, 100, 100, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1031, "", n, 617, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1032, "<p align='center'><font size='13'><a href='event:close'>"..text[n].close.."</a></font>", n, 125, 285, 620, 20, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1033, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/80", n, 309, 94, 100, 100, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1034, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/150", n, 468, 94, 100, 100, 0x324650, 0x324650, 1, true)
- id4=tfm.exec.addImage("1651ca2b636.png", "&1", 153, 115, n)
- id3=tfm.exec.addImage("1651ca29934.png", "&2", 312, 110, n)
- id2=tfm.exec.addImage("1651ca27c02.png", "&3", 467, 110, n)
- id1=tfm.exec.addImage("1651ca26129.png", "&4", 617, 110, n)
- end
- function shop4(n)
- ui.addTextArea(1020, "", n, 113, 58, 643, 260, 0x331f15, 0x331f15, 1, true)
- ui.addTextArea(1021, "", n, 296, 314, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1022, "", n, 113, 111, 4, 151, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1023, "", n, 752, 111, 4, 151, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1024, "", n, 296, 58, 198, 4, 0x6b4231, 0x6b4231, 1, true)
- ui.addTextArea(1025, "<p align='center'><font size='20'><VP>", n, 122, 68, 626, 240, 0x1b262b, 0x131c21, 1, true)
- ui.addTextArea(1026, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/300", n, 154, 94, 100, 100, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1027, "", n, 153, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1028, "", n, 309, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1029, "", n, 468, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1030, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/200", n, 617, 94, 100, 100, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1031, "<p align='center'><b><a href='event:buy4'>"..data[n].buy4, n, 617, 238, 100, 23, 0x324650, 0x12191c, 1, true)
- ui.addTextArea(1032, "<p align='center'><font size='13'><a href='event:close'>"..text[n].close.."</a></font>", n, 125, 285, 620, 20, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1033, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/80", n, 309, 94, 100, 100, 0x324650, 0x324650, 1, true)
- ui.addTextArea(1034, "\n\n\n\n\n\n<p align='center'>"..data[n].points.."/150", n, 468, 94, 100, 100, 0x324650, 0x324650, 1, true)
- id4=tfm.exec.addImage("1651ca2b636.png", "&1", 153, 115, n)
- id3=tfm.exec.addImage("1651ca29934.png", "&2", 312, 110, n)
- id2=tfm.exec.addImage("1651ca27c02.png", "&3", 467, 110, n)
- id1=tfm.exec.addImage("1651ca26129.png", "&4", 617, 110, n)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement