×

Langue

Fermer
Atelier 801
  • Forums
  • Dev Tracker
  • Connexion
    • English Français
      Português do Brasil Español
      Türkçe Polski
      Magyar Română
      العربية Skandinavisk
      Nederlands Deutsch
      Bahasa Indonesia Русский
      中文 Filipino
      Lietuvių kalba 日本語
      Suomi עברית
      Italiano Česky
      Hrvatski Slovensky
      Български Latviešu
      Estonian
  • Langue
  • Forums
  • /
  • Transformice
  • /
  • Archives
  • /
  • Seção Editor de Mapas e Modules
  • /
  • [Lua] Peça scripts aqui!
« ‹ 121 / 133 › »
[Lua] Peça scripts aqui!
Mikaelly
« Citoyen »
1590354900000
    • Mikaelly#8464
    • Profil
    • Derniers messages
    • Tribu
#2401
  0
um script q tem tipo q mata o coronaviros kkkkkkkkkkkkk
Mad
« Héliaste »
1590355020000
    • Mad#3134
    • Profil
    • Derniers messages
    • Tribu
#2402
  0
Mikaelly a dit :
alguem pode cria 1 script pra tira do tedio

do que seria ?
Mikaelly
« Citoyen »
1590449880000
    • Mikaelly#8464
    • Profil
    • Derniers messages
    • Tribu
#2403
  0
Mad a dit :
Mikaelly a dit :
alguem pode cria 1 script pra tira do tedio

do que seria ?


se q sabe um bem top
Mikaelly
« Citoyen »
1590605100000
    • Mikaelly#8464
    • Profil
    • Derniers messages
    • Tribu
#2404
  0
existe alguma lista de todos os scripts que existe?
Mad
« Héliaste »
1590614640000
    • Mad#3134
    • Profil
    • Derniers messages
    • Tribu
#2405
  0
hmm vou tentar da uma olhada
Gamedroit
« Citoyen »
1590619440000
    • Gamedroit#3347
    • Profil
    • Derniers messages
    • Tribu
#2406
  1
Twistzaok a dit :
Willflash_gd a dit :
onde eu clicar queria que um sp invertido aparecece

foi o mais próximo que eu consegui chegar

Velocidade definida a partir da distância do rato - Quanto mais longe, maior
Code Lua

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
local playerName = 'Lucasrslv#0000' -- Mude para seu nome
local distance = 100 -- Define a distância em que o anti-espirito vai agir

system.bindMouse(playerName)

eventMouse = function(player, x, y)
tfm.exec.displayParticle(12, x, y)
for k,v in next, tfm.get.room.playerList do
local moveItY,moveItX = true,true
local vx,vy = 0,0
if v.x < x and v.x > x - distance then
vx = (x - v.x)/1.5
elseif v.x > x and v.x < x + distance then
vx = (x - v.x)/1.5
else
moveItX = false
end
if v.y < y and v.y > y - distance then
vy = (y - v.y)/1.5
elseif v.y > y and v.y < x + distance then
vy = (y - v.y)/1.5
else
moveItY = false
end
if moveItY and moveItX then
tfm.exec.movePlayer(k, 0, 0, false, vx, vy, false)
end
end
end

Velocidade fixa
Code Lua

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
local playerName = 'Lucasrslv#0000' -- Mude para seu nome
local distance = 100 -- Define a distância em que o anti-espirito vai agir
local velocity = 50 -- Velocidade do impulso

system.bindMouse(playerName)

eventMouse = function(player, x, y)
tfm.exec.displayParticle(12, x, y)
for k,v in next, tfm.get.room.playerList do
local moveItY,moveItX = true,true
local vx,vy = 0,0
if v.x < x and v.x > x - distance then
vx = velocity
elseif v.x > x and v.x < x + distance then
vx = -velocity
else
moveItX = false
end
if v.y < y and v.y > y - distance then
vy = velocity
elseif v.y > y and v.y < x + distance then
vy = -velocity
else
moveItY = false
end
if moveItY and moveItX then
tfm.exec.movePlayer(k, 0, 0, false, vx, vy, false)
end
end
end

acontece que você poderia ter feito algo mais simples

Code Lua

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
for k,v in next, tfm.get.room.playerList do
local moveItY,moveItX = true,true
local vx,vy = 0,0
if v.x < x and v.x > x - distance then
vx = velocity
elseif v.x > x and v.x < x + distance then
vx = -velocity
else
moveItX = false
end
if v.y < y and v.y > y - distance then
vy = velocity
elseif v.y > y and v.y < x + distance then
vy = -velocity
else
moveItY = false
end
if moveItY and moveItX then
tfm.exec.movePlayer(k, 0, 0, false, vx, vy, false)
end

poderia ser substituído por
Code Lua

1
2
3
4
5
-- x, y = coordenadas (número inteiro)
-- power = poder da explosão (lembrando que ela é invisível por isso ainda deve se usar o tfm.exec.displayParticle) (número inteiro)
-- radius = raio do alcance da explosão (número inteiro)
-- onlyMice = se for true apenas afeta os ratos, se for false afeta ratos e objetos do shaman (booleano: true/false (verdadeiro/falso))
tfm.exec.explosion(x, y, power, radius, onlyMice)

Mad a dit :
queria criar um module,por enquanto ando aprendendo um pouco de código lua porem so sei fazer textos ate agora ._.''
Existe algum script que faz os outros ratos morrerem quando algum rato entra na toca?

Code Lua

1
2
3
4
5
6
7
8
-- cria a função do evento "Player Get Cheese " (jogador pegou o queijo)
function eventPlayerGetCheese(playerName) -- playerName = argumento recebido com o nome do jogador
for index, data in next, tfm.get.room.playerList do -- caminhar dentro da lista de jogadores sendo index nome e data alguns valores
if not data.isDead then -- verificar se o jogador está vivo
tfm.exec.killPlayer(index) -- matar o jogador vivo
end
end
end

Dernière modification le 1590619680000
Gamedroit
« Citoyen »
1590619620000
    • Gamedroit#3347
    • Profil
    • Derniers messages
    • Tribu
#2407
  0
... delete please ... bug

Dernière modification le 1590619680000
Melph
« Sénateur »
1590621900000
    • Melph#7124
    • Profil
    • Derniers messages
    • Tribu
#2408
  0
Contistente3 a dit :
Twistzaok a dit :
Willflash_gd a dit :
onde eu clicar queria que um sp invertido aparecece

foi o mais próximo que eu consegui chegar

Velocidade definida a partir da distância do rato - Quanto mais longe, maior
Code Lua

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
local playerName = 'Lucasrslv#0000' -- Mude para seu nome
local distance = 100 -- Define a distância em que o anti-espirito vai agir

system.bindMouse(playerName)

eventMouse = function(player, x, y)
tfm.exec.displayParticle(12, x, y)
for k,v in next, tfm.get.room.playerList do
local moveItY,moveItX = true,true
local vx,vy = 0,0
if v.x < x and v.x > x - distance then
vx = (x - v.x)/1.5
elseif v.x > x and v.x < x + distance then
vx = (x - v.x)/1.5
else
moveItX = false
end
if v.y < y and v.y > y - distance then
vy = (y - v.y)/1.5
elseif v.y > y and v.y < x + distance then
vy = (y - v.y)/1.5
else
moveItY = false
end
if moveItY and moveItX then
tfm.exec.movePlayer(k, 0, 0, false, vx, vy, false)
end
end
end

Velocidade fixa
Code Lua

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
local playerName = 'Lucasrslv#0000' -- Mude para seu nome
local distance = 100 -- Define a distância em que o anti-espirito vai agir
local velocity = 50 -- Velocidade do impulso

system.bindMouse(playerName)

eventMouse = function(player, x, y)
tfm.exec.displayParticle(12, x, y)
for k,v in next, tfm.get.room.playerList do
local moveItY,moveItX = true,true
local vx,vy = 0,0
if v.x < x and v.x > x - distance then
vx = velocity
elseif v.x > x and v.x < x + distance then
vx = -velocity
else
moveItX = false
end
if v.y < y and v.y > y - distance then
vy = velocity
elseif v.y > y and v.y < x + distance then
vy = -velocity
else
moveItY = false
end
if moveItY and moveItX then
tfm.exec.movePlayer(k, 0, 0, false, vx, vy, false)
end
end
end

acontece que você poderia ter feito algo mais simples

Code Lua

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
for k,v in next, tfm.get.room.playerList do
local moveItY,moveItX = true,true
local vx,vy = 0,0
if v.x < x and v.x > x - distance then
vx = velocity
elseif v.x > x and v.x < x + distance then
vx = -velocity
else
moveItX = false
end
if v.y < y and v.y > y - distance then
vy = velocity
elseif v.y > y and v.y < x + distance then
vy = -velocity
else
moveItY = false
end
if moveItY and moveItX then
tfm.exec.movePlayer(k, 0, 0, false, vx, vy, false)
end

poderia ser substituído por
Code Lua

1
2
3
4
5
-- x, y = coordenadas (número inteiro)
-- power = poder da explosão (lembrando que ela é invisível por isso ainda deve se usar o tfm.exec.displayParticle) (número inteiro)
-- radius = raio do alcance da explosão (número inteiro)
-- onlyMice = se for true apenas afeta os ratos, se for false afeta ratos e objetos do shaman (booleano: true/false (verdadeiro/falso))
tfm.exec.explosion(x, y, power, radius, onlyMice)

Mad a dit :
queria criar um module,por enquanto ando aprendendo um pouco de código lua porem so sei fazer textos ate agora ._.''
Existe algum script que faz os outros ratos morrerem quando algum rato entra na toca?

Code Lua

1
2
3
4
5
6
7
8
-- cria a função do evento "Player Get Cheese " (jogador pegou o queijo)
function eventPlayerGetCheese(playerName) -- playerName = argumento recebido com o nome do jogador
for index, data in next, tfm.get.room.playerList do -- caminhar dentro da lista de jogadores sendo index nome e data alguns valores
if not data.isDead then -- verificar se o jogador está vivo
tfm.exec.killPlayer(index) -- matar o jogador vivo
end
end
end

mas ele queria um anti-espirito ?
Gamedroit
« Citoyen »
1590623820000
    • Gamedroit#3347
    • Profil
    • Derniers messages
    • Tribu
#2409
  0
Twistzaok a dit :
Contistente3 a dit :
Twistzaok a dit :
Willflash_gd a dit :
onde eu clicar queria que um sp invertido aparecece

foi o mais próximo que eu consegui chegar

Velocidade definida a partir da distância do rato - Quanto mais longe, maior
Code Lua

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
local playerName = 'Lucasrslv#0000' -- Mude para seu nome
local distance = 100 -- Define a distância em que o anti-espirito vai agir

system.bindMouse(playerName)

eventMouse = function(player, x, y)
tfm.exec.displayParticle(12, x, y)
for k,v in next, tfm.get.room.playerList do
local moveItY,moveItX = true,true
local vx,vy = 0,0
if v.x < x and v.x > x - distance then
vx = (x - v.x)/1.5
elseif v.x > x and v.x < x + distance then
vx = (x - v.x)/1.5
else
moveItX = false
end
if v.y < y and v.y > y - distance then
vy = (y - v.y)/1.5
elseif v.y > y and v.y < x + distance then
vy = (y - v.y)/1.5
else
moveItY = false
end
if moveItY and moveItX then
tfm.exec.movePlayer(k, 0, 0, false, vx, vy, false)
end
end
end

Velocidade fixa
Code Lua

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
local playerName = 'Lucasrslv#0000' -- Mude para seu nome
local distance = 100 -- Define a distância em que o anti-espirito vai agir
local velocity = 50 -- Velocidade do impulso

system.bindMouse(playerName)

eventMouse = function(player, x, y)
tfm.exec.displayParticle(12, x, y)
for k,v in next, tfm.get.room.playerList do
local moveItY,moveItX = true,true
local vx,vy = 0,0
if v.x < x and v.x > x - distance then
vx = velocity
elseif v.x > x and v.x < x + distance then
vx = -velocity
else
moveItX = false
end
if v.y < y and v.y > y - distance then
vy = velocity
elseif v.y > y and v.y < x + distance then
vy = -velocity
else
moveItY = false
end
if moveItY and moveItX then
tfm.exec.movePlayer(k, 0, 0, false, vx, vy, false)
end
end
end

acontece que você poderia ter feito algo mais simples

Code Lua

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
for k,v in next, tfm.get.room.playerList do
local moveItY,moveItX = true,true
local vx,vy = 0,0
if v.x < x and v.x > x - distance then
vx = velocity
elseif v.x > x and v.x < x + distance then
vx = -velocity
else
moveItX = false
end
if v.y < y and v.y > y - distance then
vy = velocity
elseif v.y > y and v.y < x + distance then
vy = -velocity
else
moveItY = false
end
if moveItY and moveItX then
tfm.exec.movePlayer(k, 0, 0, false, vx, vy, false)
end

poderia ser substituído por
Code Lua

1
2
3
4
5
-- x, y = coordenadas (número inteiro)
-- power = poder da explosão (lembrando que ela é invisível por isso ainda deve se usar o tfm.exec.displayParticle) (número inteiro)
-- radius = raio do alcance da explosão (número inteiro)
-- onlyMice = se for true apenas afeta os ratos, se for false afeta ratos e objetos do shaman (booleano: true/false (verdadeiro/falso))
tfm.exec.explosion(x, y, power, radius, onlyMice)

Mad a dit :
queria criar um module,por enquanto ando aprendendo um pouco de código lua porem so sei fazer textos ate agora ._.''
Existe algum script que faz os outros ratos morrerem quando algum rato entra na toca?

Code Lua

1
2
3
4
5
6
7
8
-- cria a função do evento "Player Get Cheese " (jogador pegou o queijo)
function eventPlayerGetCheese(playerName) -- playerName = argumento recebido com o nome do jogador
for index, data in next, tfm.get.room.playerList do -- caminhar dentro da lista de jogadores sendo index nome e data alguns valores
if not data.isDead then -- verificar se o jogador está vivo
tfm.exec.killPlayer(index) -- matar o jogador vivo
end
end
end

mas ele queria um anti-espirito ?

ah, eu tô pensando em coisas antigas .... kkkk ou eu tô confuso mas eu creio que antigamente o spirit vermelho tinha mais força que o spirit comum
Mad
« Héliaste »
1590632160000
    • Mad#3134
    • Profil
    • Derniers messages
    • Tribu
#2410
  0
muito obg pelo script :)

eu não preciso colocar o nick de nenhum jogador certo ?
Kataigida
« Citoyen »
1590761880000
    • Kataigida#9234
    • Profil
    • Derniers messages
#2411
  0
pokeluavillage ainda existe?
Mikaelly
« Citoyen »
1590763800000
    • Mikaelly#8464
    • Profil
    • Derniers messages
    • Tribu
#2412
  0
mano alguem me passa script de enigma
Jp_darkuss
« Citoyen »
1590951540000
    • Jp_darkuss#4806
    • Profil
    • Derniers messages
#2413
  0
Mikaelly a dit :
mano alguem me passa script de enigma

Eu tenho esse qui faz a um tempo


Code Lua

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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
local adm= {""} -- << Bote seu nome com a # aqui entre as aspas
local players= {}
local get= 1 -- << Bote aqui quantos pontos cada vai ganhar
local canAnswer= false
local canAsk= true
local pergunta, resposta= "", ""
do
ui.addTextArea(0, "<font color='#000000' size='14'><b><p align='center'>Enigma</p></b><font>", nil, 150, 50, 500, 100, 0xCCCCCC, 0x000000, 0.95, true)
ui.addTextArea(1, "<font color='#000000' size='12'><b><p align='center'>Placar</p></b><font>", nil, 250, 160, 300, 100, 0xCCCCCC, 0x000000, 0.95, true)
ui.addTextArea(2, "<font color='#DD5555'><b><a href='event:open'>Painel</a></b></font>", adm[1], 10, 370, nil, nil, nil, nil, 0.8, true)
for pos, i in next, tfm.get.room.playerList do
table.insert(players, {
["nome"]= pos,
["pontos"]= 0
})
end
system.disableChatCommandDisplay()
end
eventChatCommand= function(player, c)
if (c=="reset" and player== adm[1]) then
ui.updateTextArea(0, "<font color='#000000' size='14'><b><p align='center'>Enigma</p></b><font>", nil)
canAnswer= false
canAsk= true
end
end
local verificar= function()
local a= 0
for i in next, tfm.get.room.playerList do
a= a + 1
end
return a
end
local placar= function(player, table)
local trade1, trade2= {}, {}
for pos in ipairs(players) do
if (player== players[pos].nome) then
players[pos].pontos= players[pos].pontos + get
table[pos].pontos= table[pos].pontos
end
end
for i= 1, #table - 1 do
for k= 1, #table - 1 do
if (table[k].pontos< table[k + 1].pontos) then
trade1, trade2= table[k], table[k + 1]
table[k]= trade2
table[k + 1]= trade1
end
end
end
ui.updateTextArea(1, "<font color='#000000' size='12'><b><p align='center'>Placar</p></b>\n\n"..table[1].nome..": "..table[1].pontos.."\n"..table[2].nome..": "..table[2].pontos.."\n"..table[3].nome..": "..table[3].pontos, nil)
end
eventNewPlayer= function(player)
table.insert(players, {
["nome"]= player,
["pontos"]= 0
})
ui.addTextArea(0, "<font color='#000000' size='14'><b><p align='center'>Enigma</p></b><font>", player, 150, 50, 500, 100, 0xCCCCCC, 0x000000, 0.95, true)
ui.addTextArea(1, "<font color='#000000' size='12'><b><p align='center'>Placar</p></b><font>", player, 250, 160, 300, 100, 0xCCCCCC, 0x000000, 0.95, true)
end
eventTextAreaCallback= function(_, _, callback)
if (callback=="open" and canAsk== true and verificar()>= 4) then
ui.addPopup(0, 2, "Digite a pergunta:", adm[1], 300, 170, nil, true)
else
print("<b>Você não pode iniciar o jogo pelos possíveis motivos</b>:\n\n1- Os jogadores não responderam sua pergunta\n2- Não há pessoas o suficiente no jogo (6 ou mais).\n\nPara resetar o jogo, use !reset.")
end
end
eventPopupAnswer= function(id, _, res)
if (id== 0 and canAsk== true) then
pergunta= res
ui.addPopup(1, 2, "Digite a resposta:", adm[1], 300, 170, nil, true)
elseif (id== 1 and canAsk== true) then
resposta= res
canAsk= false
canAnswer= true
ui.updateTextArea(0, "<font color='#000000' size='14'><p align='center'><b>Enigma</b>\n\n"..pergunta.."</p><font>", nil)
end
end
eventChatMessage= function(player, message)
if (message== resposta and canAnswer== true) then
pergunta="", ""
canAnswer= false
ui.updateTextArea(0, "<font color='#000000' size='14'><p align='center'><b>Enigmas</b>\n\nO jogador <b>"..player.."</b> acertou a resposta: "..string.format("%q", resposta).."</p><font>")
resposta=""
canAsk= true
placar(player, players)
end
end


Se o nome dos jogadores for muito grande buga o placar ;-;

Funcionamento:

- Tem um botão chamado "Painel", você clica e vai aparecer uma tela pedindo a pergunta e a resposta.
- Para responder, basta simplesmente o jogador digitar no chat.
- Para resetar, use o comando !reset, é necessário para fazer a próxima pergunta.

OBS: só funciona se tiver na sala 6 pessoas ou mais.
Mariavitoria
« Citoyen »
1590972540000
    • Mariavitoria#8123
    • Profil
    • Derniers messages
    • Tribu
#2414
  0
Script que possa colocar no cafofo com um mapa labirinto habilitado no modo escuro e que venha escrito alguma coisa aleatória em alguma parte do mapa.
Gamedroit
« Citoyen »
1591042020000
    • Gamedroit#3347
    • Profil
    • Derniers messages
    • Tribu
#2415
  0
Mariavitoria a dit :
Script que possa colocar no cafofo com um mapa labirinto habilitado no modo escuro e que venha escrito alguma coisa aleatória em alguma parte do mapa.

Seja mais específica, o Labirinto deve conter começo e fim (toca e queijo)? Quais seriam as frases? O mapa do Labirinto deve ser gerado pelo próprio código ou seria um mapa exportado por um jogador?

Dernière modification le 1591042140000
Jp_darkuss
« Citoyen »
1591046100000
    • Jp_darkuss#4806
    • Profil
    • Derniers messages
#2416
  0
Contistente3 a dit :
Mariavitoria a dit :
Script que possa colocar no cafofo com um mapa labirinto habilitado no modo escuro e que venha escrito alguma coisa aleatória em alguma parte do mapa.

Seja mais específica, o Labirinto deve conter começo e fim (toca e queijo)? Quais seriam as frases? O mapa do Labirinto deve ser gerado pelo próprio código ou seria um mapa exportado por um jogador?

Eu entendi que era só deixar a tela num "modo escuro" e ela trocaria com /np code. Só não tentei porque não tive muito tempo no pc hoje e um pouco de preguiça, nem sei por onde começar kkkk

@edit: não sei o que ela quiz dizer com "coisa escrita aleatória no mapa", thinking...

Dernière modification le 1591046160000
Hallonin
« Consul »
1591110540000
    • Hallonin#0000
    • Profil
    • Derniers messages
    • Tribu
#2417
  0
Eu queria um script que passasse todos os mapas de eventos somente evento, quem puder fazer ficaria muitooooo grato <3
Guiguipelesi
« Citoyen »
1591112940000
    • Guiguipelesi#0000
    • Profil
    • Derniers messages
    • Tribu
#2418
  0
Algum script que os jogadores possam regular sua cn pois o script que voce me mando da cn ta saindo meio fraca se regula acredito que possa fica melhor tipo no module #deathmatch.
Luquinhanns
« Citoyen »
1591115100000
    • Luquinhanns#0000
    • Profil
    • Derniers messages
#2419
  0
o script da cn ficou quase igual eu queria jp porem quero coloca a cn do lado da cabeça do rato e possivel?
Cross
« Citoyen »
1591115280000
    • Cross#0781
    • Profil
    • Derniers messages
    • Tribu
#2420
  0
tem algum script que eu possa tira o shan do mapa?
  • Forums
  • /
  • Transformice
  • /
  • Archives
  • /
  • Seção Editor de Mapas e Modules
  • /
  • [Lua] Peça scripts aqui!
« ‹ 121 / 133 › »
© Atelier801 2018

Equipe Conditions Générales d'Utilisation Politique de Confidentialité Contact

Version 1.27