1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
teamcolor = {}
addhook("spawn" ,"playerspawn")
function playerspawn(id)
if player(id,"team") == 1 then
teamcolor[id] = "\169255025000"
else
teamcolor[id] = "\169050150255"
end
end
timer(math.random(3000,5000),"naheztalking","",0)
function naheztalking()
local playerlist = player(0,"tableliving")
for _,id in pairs(playerlist) do
local nahezspeaks = math.random(1,7)
if nahezspeaks == 1 then
msg(""..teamcolor[id].."nahez: hey")
return 1
else
if nahezspeaks == 2 then
msg(""..teamcolor[id].."nahez: hello")
return 1
else
if nahezspeaks == 3 then
msg(""..teamcolor[id].."nahez: test")
return 1
else
if nahezspeaks == 4 then
msg(""..teamcolor[id].."nahez: hhhh")
return 1
else
if nahezspeaks == 5 then
msg(""..teamcolor[id].."nahez: asfaf")
return 1
else
if nahezspeaks == 6 then
msg(""..teamcolor[id].."nahez: gfdgfd")
return 1
else
if nahezspeaks == 7 then
msg(""..teamcolor[id].."nahez: eyffdsa")
return 1
end
end
end
end
end
end
end
end
end
the only problem im facing is the "id" thing in the timer! the bot is speaking in different "teamcolor" than the team he really is in...
Edit: sorry if i had some stupid scripting mistakes im still new to it, and sorry for my bad english.