View difference between Paste ID: PEgadkD6 and Lhik2Ap4
SHOW: | | - or go back to the newest paste.
1
admin="Mousetat"
2
3
4
5
tfm.exec.disableAutoNewGame(true)
6
tfm.exec.disableAfkDeath(true)
7
tfm.exec.disableAutoShaman(true)
8
tfm.exec.disableAutoScore(true)
9
tfm.exec.newGame("@6411544")
10-
-- stopped at line 144.
10+
11
players={}--respawn place is 400,320
12
p={}
13
timestamp=os.time()
14
numplayers=0
15
16
begin=false
17
answerer="lol"
18
questioner="lol"
19
question="lol"
20
ans="lol"
21
new=false
22
restart=false
23
choose=false
24
start=true
25
choosey=false
26
skip=false
27
message=""
28
others={}
29
summonobject=false
30
timestamplol={}
31
answererold=""
32
one=false
33
34
truth={}--you can follow the format 'truth[number]="question"' 
35
truth[1]="Who is your crush in this game?"
36
truth[2]="What is your favourite food?"
37
truth[3]="Who is you model/favourite person in game?"
38
truth[4]="What games do you play besides Transformice?"
39
truth[5]="What would you like to be when you grow up?"
40
truth[6]="Have you sucked your thumb before?"
41
truth[7]="What brand of phone do you have currently?"
42
truth[8]="Have you ever farted in front of your friends or teachers in real life?"
43
truth[9]="If you could hack transformice, what would you do?"
44-
truth[15]="Why do you like your current crush in real life, in personality terms AND physical terms? If you have no crush, then tell us why you hate the person you currently hate in real life, in personality terms."
44+
45
truth[11]="Why do you like Transformice?"
46
truth[12]="What do you dislike/hate most about yourself, whether in personality or physically?"
47
truth[13]="What do you love most about yourself, whether in personality or physically?"
48-
dare[1]="I dare you go into EN/EN2 room 2 and spam: I AM A GUMMY BEAR!I AM A GUMMY BEAR!I AM A GUMMY BEAR!"
48+
49
truth[15]="Why do you like your current crush in real life, in personality terms AND physical terms?" 
50
truth[16]="Tell us why you hate the person you currently hate in real life, in personality terms."
51-
dare[4]="I dare you go into EN/EN2 room 1 and spam: www.sex.com www.sex.com www.sex.com www.sex.com www.sex.com www.sex.com"
51+
52
53
dare={}--you can follow the format 'dare[number]="Dare"' 
54
dare[1]="I dare you go into EN/EN2 room 2 and spam this message 10 times: I AM A GUMMY BEAR!I AM A GUMMY BEAR!I AM A GUMMY BEAR!"
55
dare[2]="I dare you whisper a moderator a swear word."
56-
dare[9]="I dare you go into any #utility room with at least 5 people in it and crash the room."
56+
57
dare[4]="I dare you go into EN/EN2 room 1 and spam this message 10 times: I'M FLOODING REPORT ME!"
58-
dare[11]="I dare you to disconnect and connect right now."
58+
59
dare[6]="I dare you create an account similar to that of an online moderator and use that account to whisper to the online moderator: Hallo buddy!"
60-
dare[13]="I dare you to waste all your selfies right now on yourself, if you have any balls to do it via trade"
60+
61
dare[8]="I dare you take a picture of your real life face and send it to everyone to see."
62
dare[9]="I dare you go into any #utility room with at least 3 people in it and crash the room."
63
dare[10]="I dare you give me, the questioner, every ball you have in your inventory, if you have any."
64
dare[11]="I dare you to disconnect and reconnect right now."
65-
p[name]={questioners=false, admin=false, spectator=true}
65+
66
dare[13]="I dare you to give all your selfies to me right now, if you have any balls to do it via trade"
67
dare[14]="I dare you complete this map without cheating!"
68
dare[15]="I dare you type 'I LOVE YOU (username)' 30 times to a username in room/tribe in room chat or in tribe chat."
69
dare[16]="I dare you kiss me, the questioner, 20 times :)"
70-
ui.addPopup(999,0,"<p align = 'center'><font size='50' face='impact'>Truth or Dare</font></p><font size='30' color='#FF0000'><b>Rules</b></font>\nEvery game, everyone will have the chance to be the Asker. On the first popup as an asker, u can click 'Yes' to randomize a answerer, or 'No' to type a particular person in room. This is similar for almost all other popups, where 'Yes' is for random and 'No' is for typing out yourself. There are currently <b>10</b> random truths and <b>10</b> random dares, so if you have any feedback feel free to tell me, Mousetat.\n<b><font size='30' color='#FFFF00'>COMMANDS</font>\n!join to join the game if you are spectating or you just came into the room.\n!watch to be a spectator and get ignored in the game.\n!s to be shaman(although it is strongly not advised to do so)\n!respawn to respawn yourself.\n!admin <username> to admin a person(admins only)\n!c to speak to all(admins only)\n!restart to restart game if bugged(admins only)\n!skip to skip a person's turn(admins only)\n!help to see this popup again</b>",nil,100,20,600,true)
70+
dare[17]="I dare you marry your closest friend, if u are not already married"
71
72
function eventNewPlayer(name)
73
ui.addTextArea(1,"<b><p align = 'center'><font size='30'>Type !join to join the game.</font></p></b>",name,50,355,700,40,0x324650,0x212F36,0.8,true)
74
p[name]={questioners=false, admin=false, spectator=true, ban=false}
75
end
76
77
function eventNewGame()
78-
p[name]={questioners=false, admin=false, spectator=true}
78+
79
ui.addPopup(999,0,"<p align = 'center'><font size='50' face='impact'>Truth or Dare</font></p><font size='30' color='#FF0000'><b>Rules</b></font>\nEvery game, everyone will have the chance to be the Asker. On the first popup as an asker, u can click 'Yes' to randomize a answerer, or 'No' to type a particular person in room. This is similar for almost all other popups, where 'Yes' is for random and 'No' is for typing out yourself. There are currently <b>10</b> random truths and <b>10</b> random dares, so if you have any feedback feel free to tell me, Mousetat.\n<b><font size='30' color='#FFFF00'>COMMANDS</font>\n!join to join the game if you are spectating or you just came into the room.\n!watch to be a spectator and get ignored in the game.\n!s to be shaman(although it is strongly not advised to do so)\n!new to get a new answerer(asker only)\n!admin <username> to admin a person(admins only)\n!c to speak to all(admins only)\n!restart to restart game if bugged(admins only)\n!skip to skip a person's turn(admins only)\n!help to see this popup again</b>",nil,100,20,600,true)
80
answerer=""
81
questioner=""
82
begin=false
83
start=true
84
numplayers=0
85
count=1
86
one=false
87
for name,player in pairs(tfm.get.room.playerList) do
88
p[name]={questioners=false, admin=false, spectator=true, ban=false}
89
players[count]=name
90
timestamp=os.time()
91
numplayers=numplayers+1
92
count=count+1
93
p[name].spectator=false
94
p[name].questioners=false
95
if name==admin then
96
p[name].admin=true
97
end
98
end
99
print(numplayers)
100
system.disableChatCommandDisplay("c", hidden)
101
system.disableChatCommandDisplay("admin", hidden)
102
system.disableChatCommandDisplay("restart", hidden)
103
end
104
105
function eventChatCommand(name,command)
106
local IDList = {}
107
if command=="s" then
108
tfm.exec.setShaman(name)
109
elseif command=="mods" then
110
message=""
111
for k,v in pairs(tfm.get.room.playerList) do
112-
elseif command=="watch" then
112+
if p[k].admin==true then
113
message=message..tostring(k)..", "
114
end
115
end
116
ui.updateTextArea(1, "<p align='center'><b><font size='15'>The moderators are: "..string.sub(message,1,-3)..".</font></b></p>", name)
117
118-
ui.addPopup(999,0,"<p align = 'center'><font size='50' face='impact'>Truth or Dare</font></p><font size='30' color='#FF0000'><b>Rules</b></font>\nEvery game, everyone will have the chance to be the Asker. On the first popup as an asker, u can click 'Yes' to randomize a answerer, or 'No' to type a particular person in room. This is similar for almost all other popups, where 'Yes' is for random and 'No' is for typing out yourself. There are currently <b>10</b> random truths and <b>10</b> random dares, so if you have any feedback feel free to tell me, Mousetat.\n<b><font size='30' color='#FFFF00'>COMMANDS</font>\n!join to join the game if you are spectating or you just came into the room.\n!watch to be a spectator and get ignored in the game.\n!s to be shaman(although it is strongly not advised to do so)\n!respawn to respawn yourself.\n!admin <username> to admin a person(admins only)\n!c to speak to all(admins only)\n!restart to restart game if bugged(admins only)\n!skip to skip a person's turn(admins only)\n!help to see this popup again</b>",nil,100,20,600,true)
118+
elseif command=="new" and name==questioner then
119
tfm.exec.movePlayer(answerer,400,320,false,0,0,false)
120
answererold=answerer
121
answerer=""
122
choose=true
123
elseif command=="join" and p[name].spectator==true then
124
if p[name].ban==false then
125
ui.updateTextArea(1, "<p align='center'><b><font size='30'>"..name.." joined the game! :D</font></b></p>", nil)
126
tfm.exec.respawnPlayer(name)
127
tfm.exec.movePlayer(name,400,320,false,0,0,false)
128
numplayers=numplayers+1
129
players[numplayers]=name
130
p[name].spectator=false
131
elseif p[name].ban==true then
132-
if timestamp < os.time()-10000 and begin==false then
132+
ui.updateTextArea(1, "<p align='center'><b><font size='30'>You have been banned, so u cannot join the game :(</font></b></p>", name)
133
end
134
elseif command=="skip" and p[name].admin==true then
135
timestamp=os.time()
136
skip=true
137
elseif command:sub(0,1) == "c" and p[name].admin==true then
138
	message=command:sub(3)
139
	ui.updateTextArea(1, "<p align='center'><b><font size='15' color='#ED67EA'>[~Moderation] "..message.."</font></b></p>", nil)
140
elseif command=="restart" and p[name].admin==true then
141
tfm.exec.newGame("@6411544")
142
elseif command:sub(0,5)=="watch" and p[name].admin==true then
143-
if p[hname].spectator==false then
143+
if command:sub(7)=="" then
144
p[name].spectator=true
145
numplayers=numplayers-1
146
ui.updateTextArea(1, "<p align='center'><b><font size='30'>"..name.." is now a spectator :(</font></b></p>", nil)
147
if name==questioner or name==answerer then
148
questioner=""
149
answerer=""
150
tfm.exec.movePlayer(questioner,400,320,false,0,0,false)
151
tfm.exec.movePlayer(answerer,400,320,false,0,0,false)
152
timestamp=os.time()
153
skip=true
154
end
155
for i=1,#players do
156
if players[i]==name then table.remove(players,i)
157
end
158
end
159
else
160
message=command:sub(7)
161
message=string.upper(message:sub(0,1))..message:sub(2)
162
for k,v in pairs(tfm.get.room.playerList) do
163
if k==message and p[k].spectator==false then
164
if k==questioner or k==answerer then
165
skip=true
166
timestamp=os.time()
167
end
168
p[k].spectator=true
169
numplayers=numplayers-1
170
ui.updateTextArea(1, "<p align='center'><b><font size='30'>"..k.." is now a spectator :(</font></b></p>", nil)
171
for i=1,#players do
172
if players[i]==k then table.remove(players,i)
173
end
174
end
175
end
176
end
177
end
178
elseif command=="respawn" then
179
tfm.exec.respawnPlayer(name)
180
elseif command=="help" then
181-
if choose==true then
181+
ui.addPopup(999,0,"<p align = 'center'><font size='50' face='impact'>Truth or Dare</font></p><font size='30' color='#FF0000'><b>Rules</b></font>\nEvery game, everyone will have the chance to be the Asker. On the first popup as an asker, u can click 'Yes' to randomize a answerer, or 'No' to type a particular person in room. This is similar for almost all other popups, where 'Yes' is for random and 'No' is for typing out yourself. There are currently <b>10</b> random truths and <b>10</b> random dares, so if you have any feedback feel free to tell me, Mousetat.\n<b><font size='30' color='#FFFF00'>COMMANDS</font>\n!join to join the game if you are spectating or you just came into the room.\n!watch to be a spectator and get ignored in the game.\n!s to be shaman(although it is strongly not advised to do so)\n!new to get a new answerer(asker only)\n!admin <username> to admin a person(admins only)\n!c to speak to all(admins only)\n!restart to restart game if bugged(admins only)\n!skip to skip a person's turn(admins only)\n!help to see this popup again</b>",name,100,20,600,true)
182
elseif command:sub(0,3)=="ban" and p[name].admin==true then
183
message=command:sub(5)
184
message=string.upper(message:sub(0,1))..message:sub(2)
185
for k,v in pairs(tfm.get.room.playerList) do
186
if message==k then
187-
	if questioner==answerer or tfm.get.room.playerList[answerer].isDead or p[answerer].spectator==true then
187+
ui.updateTextArea(1, "<p align='center'><b><font size='15' color='#ED67EA'>[~Moderation] "..message.." has been banned for 9999 hours.</font></b></p>", nil)
188
p[message].ban=true
189
p[message].spectator=true
190
tfm.exec.killPlayer(k)
191
numplayers=numplayers-1
192
end
193
end
194
elseif command:sub(0,5)=="unban" and p[name].admin==true then
195
message=command:sub(7)
196-
elseif choosey==true then
196+
197
for k,v in pairs(tfm.get.room.playerList) do
198
if message==k then
199
ui.updateTextArea(1, "<p align='center'><b><font size='15' color='#ED67EA'>[~Moderation] "..message.." has been unbanned.</font></b></p>", nil)
200
p[message].ban=false
201
p[message].spectator=false
202
tfm.exec.respawnPlayer(k)
203
numplayers=numplayers+1
204
end
205
end
206
elseif command:sub(0,5)=="admin" and p[name].admin==true then
207
message=command:sub(7)
208
message=string.upper(message:sub(0,1))..message:sub(2)
209
for k,v in pairs(tfm.get.room.playerList) do
210
if message==k then
211
ui.updateTextArea(1, "<p align='center'><b><font size='15' color='#ED67EA'>[~Moderation] "..message.." is now a moderator. Congrats!</font></b></p>", nil)
212
p[message].admin=true
213
end
214
end
215
end
216
end
217
218
function eventLoop(time,remaining)
219
local IDList={}
220
for id, object in pairs(tfm.get.room.objectList) do 
221
table.insert(IDList, id)
222
end
223
for i, id in pairs(IDList) do
224
if others[id].summonobject==true and timestamplol[id]<os.time()-3000 then
225
tfm.exec.removeObject(id)
226
others[id].summonobject=false
227
end
228
end
229
if numplayers<2 then
230
one=true
231
else
232
one=false
233
end
234
if one==true then
235
ui.updateTextArea(1, "<p align='center'><b><font size='15'>Minimum of 2 players are needed for this game to proceed.</font></b></p>", nil)
236
timestamp=os.time()-4000
237
elseif timestamp < os.time()-10000 and begin==false then
238
timestamp=os.time()
239
begin=true
240
restart=false
241
ui.updateTextArea(1, "<p align='center'><b><font size='30'>Let's Begin the Game! </font></b></p>", nil)
242
for name,player in pairs(tfm.get.room.playerList) do
243
tfm.exec.movePlayer(name,400,320,false,0,0,false)
244
end
245
elseif timestamp < os.time()-5000 and begin==false then
246
local i=1
247
local long=""
248
local hname=""
249
while i<=numplayers do
250
hname=players[i]
251
if p[hname].spectator==false and tfm.get.room.playerList[hname].isDead==false then
252
long=long..tostring(players[i])..", "
253
end
254
i=i+1
255
end
256
ui.updateTextArea(1, "<p align='center'><b><font size='15'>The participating players are: "..string.sub(long,1,-3)..".</font></b></p>", nil)
257
elseif timestamp < os.time()-3000 and begin==false and restart==true then
258
ui.updateTextArea(1, "<p align='center'><b><font size='20'>Since everyone had their turn, I'll restart the game...", nil)
259
end
260
if begin==true then
261
if timestamp < os.time()-3000 and start==true then
262
tfm.exec.movePlayer(questioner,400,320,false,0,0,false)
263
tfm.exec.movePlayer(answerer,400,320,false,0,0,false)
264
answerer=""
265
questioner=""
266
local j=1
267
local i=0
268
while j<=numplayers do
269
pname=players[j]
270
if p[pname].questioners==false and tfm.get.room.playerList[pname].isDead==false and p[pname].spectator==false then
271
i=i+1
272-
			question=truth[math.random(1,15)]
272+
273
j=j+1
274
end
275
if i>0 then
276
eventTruthOrDare()
277
else
278
local j=1
279
while j<=numplayers do
280
local name=players[j]
281
p[name].questioners=false
282-
			question=dare[math.random(1,13)]
282+
283
end
284
restart=true
285
timestamp=os.time()
286
begin=false
287
end
288
end
289
if choose==true and one==false then
290
	rand=math.random(1,numplayers)
291
	print(questioner)
292
	answerer=players[rand]
293
	print(answerer)
294
	print(p[answerer].spectator)
295
	if questioner==answerer or tfm.get.room.playerList[answerer].isDead or p[answerer].spectator==true or answerer==answererold then
296
	ui.updateTextArea(1, "<p align='center'><b><font size='30'>Randomizing...</font></b></p>", nil)
297
	tfm.exec.movePlayer(answerer,400,320,false,0,0,false)
298
	answerer=""
299
	else
300
	choose=false
301
	ui.updateTextArea(1, "<b><font size='15'>"..answerer.." is now the answerer! Waiting to pick truth or dare...</font></b>", nil)
302
	ui.addPopup(3,1,"You are the answerer! Do you want Truth? If No, you will choose Dare!",answerer,250,50,300,true)
303
	end
304
elseif choosey==true and one==false then
305
	rand=math.random(1,numplayers)
306
	questioner=players[rand]
307
	print(questioner)
308
	print(p[questioner].questioners)
309
	print(p[questioner].spectator)
310
	if p[questioner].questioners==false and tfm.get.room.playerList[questioner].isDead==false and p[questioner].spectator==false then
311
		choosey=false
312
		p[questioner].questioners=true
313
		ui.updateTextArea(1, "<b><font size='15'>"..questioner.." is now the asker! Waiting to pick an answerer...</font></b>", nil)
314
		ui.addPopup(1,1,"Do you want a random Answerer? If <b>No</b>, you will have to type in your Answerer's username",questioner,250,50,300,true)
315
	else 
316
		ui.updateTextArea(1, "<p align='center'><b><font size='30'>Randomizing...</font></b></p>", nil)
317
		tfm.exec.movePlayer(questioner,400,320,false,0,0,false)
318
		questioner=""
319
	end
320
end
321
if skip==true then
322
ui.updateTextArea(1, "<p align='center'><b><font size='30'>Skipping turn...</font></b></p>", nil)
323
tfm.exec.movePlayer(questioner,400,320,false,0,0,false)
324
tfm.exec.movePlayer(answerer,400,320,false,0,0,false)
325
answerer=""
326
questioner=""
327
if timestamp < os.time()-3000 then
328
start=true
329
skip=false
330
end
331
end
332
tfm.exec.movePlayer(questioner,120,120,false,0,0,false)
333
tfm.exec.movePlayer(answerer,680,120,false,0,0,false)
334
end
335
end
336
337
function eventTruthOrDare()
338
	start=false
339
	ui.removeTextArea(2)
340
	ui.removeTextArea(3)
341
	choosey=true
342
343
end
344
345
function eventPopupAnswer(id, name, answer)
346
	if id==1 and name==questioner then
347
		if answer=="yes" then
348
			answererold=""
349
			choose=true
350
		elseif answer=="no" then
351
			ui.addPopup(2,2,"Who do you want to be the answerer?",questioner,250,50,300,true)
352
		end
353
	elseif id==2 and name==questioner then
354
		x=1
355
		found=false
356
		answer=string.upper(answer:sub(0,1))..answer:sub(2)
357
		while x<=numplayers do
358
		print(players[x])
359
			if answer==players[x] then
360
			answerer=answer
361
			if questioner==answerer or tfm.get.room.playerList[answerer].isDead or p[answerer].spectator==true then
362
			answerer=""
363
			found=false
364
			else
365
			ui.updateTextArea(1, "<b><font size='15'>"..answerer.." is now the answerer! Waiting to pick Truth or Dare...</font></b>", nil)
366
			ui.addPopup(3,1,"You are the answerer! Do you want Truth? If <b>No</b>, you will choose Dare!",answerer,250,50,300,true)
367
			found=true
368
			end
369
			end
370
			x=x+1
371
		end
372
		if found==false then
373
			ui.addPopup(2,2,"There is no such answerer in the room. Type out the exact username of your answerer.",questioner,250,50,300,true)
374
		end
375
	elseif id==3 and name==answerer then	
376
		if answer=="yes" then
377
			ui.updateTextArea(1, "<b><font size='15'>"..answerer.." has picked Truth! Waiting for question from "..questioner.."...</font></b>", nil)	
378
			ui.addPopup(4,1,"Do you want a random Truth question? If <b>No</b>, you will have to submit a question.",questioner,250,50,300,true)
379
		elseif answer=="no" then
380
			ui.updateTextArea(1, "<b><font size='15'>"..answerer.." has picked Dare! Waiting for a dare from "..questioner.."...</font></b>", nil)
381
			ui.addPopup(5,1,"Do you want a random Dare? If <b>No</b>, you will have to submit a Dare.",questioner,250,50,300,true)
382
				
383
		end
384
	elseif id==4 and name==questioner then
385
		if answer=="yes" then
386
			question=truth[math.random(1,16)]
387
			ui.updateTextArea(1, "<b><font size='15'>"..questioner.." has randomed a Truth question! Waiting for "..answerer.." to respond...</font></b>", nil)	
388
			ui.addTextArea(2,"<b><font size='20'>Truth: "..question.."</font></b>",nil,165,20,470,120,0x324650,0x212F36,0.8,true)
389
			ui.addPopup(8,2,"<b>Type your Truth answer below</b>",answerer,250,175,300,true)
390
			--need to ask if questioner is satisfied with answer
391
		elseif answer=="no" then
392
			ui.addPopup(6,2,"Type your Truth question below.",questioner,250,50,300,true)
393
		end
394
	elseif id==5 and name==questioner then
395
		if answer=="yes" then
396
			question=dare[math.random(1,17)]
397
			ui.updateTextArea(1, "<b><font size='15'>"..questioner.." has randomed a Dare question! Waiting for "..answerer.." to respond...</font></b>", nil)	
398
			ui.addTextArea(2,"<b><font size='20'>Dare: "..question.."</font></b>",nil,165,20,470,120,0x324650,0x212F36,0.8,true)
399
			ui.addPopup(9,1,"<b><font size='15'>Do what "..questioner.."dares you to do! If you click 'yes' you will promise that you will do your dare!</font><b>",answerer,250,175,300,true)
400
		elseif answer=="no" then
401
			ui.addPopup(7,2,"Type your Dare below.",questioner,250,50,300,true)
402
		end
403
	elseif id==6 and name==questioner then
404
		question=answer
405
		ui.updateTextArea(1, "<b><font size='15'>"..questioner.." has typed a Truth question! Waiting for "..answerer.." to respond...</font></b>", nil)	
406
		ui.addTextArea(2,"<b><font size='20'>Truth: "..question.."</font></b>",nil,165,20,470,120,0x324650,0x212F36,0.8,true)
407
		ui.addPopup(8,2,"Type your Truth answer below",answerer,250,175,300,true)
408
	elseif id==7 and name==questioner then
409
		question=answer
410
		ui.updateTextArea(1, "<b><font size='15'>"..questioner.." has typed a Dare question! Waiting for "..answerer.." to respond...</font></b>", nil)	
411
		ui.addTextArea(2,"<b><font size='15'>Dare: "..question.."</font></b>",nil,165,20,470,120,0x324650,0x212F36,0.8,true)
412
		ui.addPopup(9,1,"<b><font size='15'>Do what "..questioner.."dares you to do! If you click 'yes' you will promise that you will do your dare!</font><b>",answerer,250,175,300,true)
413
	elseif id==8 and name==answerer then
414
		ans = answer
415
		ui.addTextArea(3,"<b><font size='20'>Answer: "..ans.."</font></b>",nil,165,140,470,120,0x324650,0x212F36,0.8,true)
416
		ui.updateTextArea(1, "<b><font size='15'>"..answerer.." has answered the question! Waiting for "..questioner.." to rate the answer</font></b>", nil)	
417
		ui.addPopup(10,1,"<b><font size='15'>Are you satisfied with the answer?",questioner,250,50,300,true)
418
	elseif id==9 and name==answerer then
419
		if answer=="yes" then
420
			ui.addTextArea(3,"<b><font size='20'>I, "..answerer..", accepts the challenge and promises to do the dare.</font></b>",nil,165,140,470,120,0x324650,0x212F36,0.8,true)
421
			ui.updateTextArea(1, "<b><font size='15'>"..answerer.." is a warrior! Starting new game...</font></b>", nil)	
422
			timestamp=os.time()
423
			answerer=""
424
			questioner=""
425
			start=true
426
			for name,player in pairs(tfm.get.room.playerList) do
427
			tfm.exec.movePlayer(name,400,320,false,0,0,false)
428
			end			
429
		elseif answer=="no" then
430
			ui.updateTextArea(1, "<b><font size='15'>"..answerer.." is a coward! Starting new game...</font></b>", nil)	
431
			ui.addTextArea(3,"<b><font size='20'>I, "..answerer..", am a coward so I don't dare to do what you dared me to do.</font></b>",nil,165,140,470,120,0x324650,0x212F36,0.8,true)
432
			timestamp=os.time()
433
			answerer=""
434
			questioner=""
435
			start=true
436
			for name,player in pairs(tfm.get.room.playerList) do
437
			tfm.exec.movePlayer(name,400,320,false,0,0,false)
438
			end			
439
		end
440
	elseif id==10 and name==questioner then
441
		if answer=="yes" then
442
			ui.updateTextArea(1, "<b><font size='15'>"..questioner.." is a satisfied with the answer! Starting new game...</font></b>", nil)
443
			timestamp=os.time()
444
			answerer=""
445
			questioner=""
446
			start=true
447
			for name,player in pairs(tfm.get.room.playerList) do
448
			tfm.exec.movePlayer(name,400,320,false,0,0,false)
449
			end
450
		elseif answer=="no" then
451
			ui.updateTextArea(1, "<b><font size='15'>"..questioner.." is a not satisfied with the answer...:( Starting new game...</font></b>", nil)
452
			timestamp=os.time()
453
			answerer=""
454
			questioner=""
455
			start=true			
456
			for name,player in pairs(tfm.get.room.playerList) do
457
			tfm.exec.movePlayer(name,400,320,false,0,0,false)
458
			end
459
		end
460
	end
461
end
462
463
function eventPlayerLeft(name)
464
numplayers=numplayers-1
465
ui.updateTextArea(1, "<p align='center'><b><font size='15'>"..name.." left the room... What a coward!</font></b></p>", nil)
466
if questioner==name or answerer==name then
467
timestamp=os.time()
468
skip=true
469
end
470
for i=1,#players do
471
if players[i]==name then table.remove(players,i)
472
end
473
end
474
end
475
476
function eventPlayerDied(name)
477
if p[name].spectator==false then
478
tfm.exec.respawnPlayer(name)
479
end
480
if p[name].ban==true then
481
timestamp=os.time()
482
skip=true
483
end
484
end
485
486
function eventPlayerWon(playerName,timeElapsed)
487
tfm.exec.respawnPlayer(playerName)
488
end
489
490
function eventSummoningEnd(playerName, objectType, xPosition, yPosition, angle, xSpeed, ySpeed, other)
491
492
timestamplol[other.id]=os.time()
493
others[other.id]={summonobject=true}
494
end