×

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
  • /
  • Documentação PT-BR
1 / 6 › »
Documentação PT-BR
Niunzin
« Citoyen »
1381174140000
    • Niunzin#0000
    • Profil
    • Derniers messages
    • Tribu
#1
  0
Sumário
String = Texto, deve ser utilizado entre ". Exemplo: "Olá mundo!"
Int = Número, usa-se sem ". Exemplo: 1
Boolean = O famoso "verdadeiro ou falso", deve se utilizar true para verdadeiro e false para falso. Exemplo: true

========================================
##### Versão 0.15
========================================


========================================
##### Eventos
========================================


[url=]eventChatCommand[/url](String playerName, String message)
[•] Esse evento ocorrerá quando os jogadores digitarem uma mensagem que comece com « ! » no chat.

==================================================

[url=]eventEmotePlayed[/url](String playerName, Int emoteId)
[•] Esse evento ocorrerá quando um jogador executar uma emoção.

==================================================

[url=]eventFileLoaded[/url](String fileName, String file)
[•] Esse evento ocorrerá quando um arquivo for carregado.

==================================================

[url=]eventFileSaved[/url](String fileName)
[•] Esse evento ocorrerá quando um arquivo for salvo.

==================================================

[url=]eventKeyboard[/url](String playerName, Int keyCode, Boolean down, Int xPlayerPosition, Int yPlayerPosition)
[•] Esse evento ocorrerá quando o jogador pressionar uma tecla.
* Nota: requer bindKeyboard

==================================================

[url=]eventMouse[/url](String playerName, Int xMousePosition, Int yMousePosition)
[•] Esse evento ocorrerá quando um jogador clicar com o mouse.
* Nota: requer bindMouse

==================================================

[url=]eventLoop[/url](Int currentTime, Int timeRemaining)
[•] Esse evento ocorre a cada 500 milissegundos.

==================================================

[url=]eventNewGame[/url]()
[•] Evento que ocorre no início de um novo jogo.

==================================================

[url=]eventNewPlayer[/url](String playerName)
[•] Esse evento ocorrerá quando um jogador entrar na sala.

==================================================

[url=]eventPlayerDataLoaded[/url](String playerName, String data)
[•] Esse evento ocorrerá quando um dado for carregado.

==================================================

[url=]eventPlayerDied[/url](String playerName)
[•] Esse evento ocorrerá quando um jogador morrer.

==================================================

[url=]eventPlayerGetCheese[/url](String playerName)
[•] Esse evento ocorrerá quando um jogador pegar o queijo.

==================================================

[url=]eventPlayerLeft[/url](String playerName)
[•] Esse evento ocorrerá quando um jogador sair da sala.

==================================================

[url=]eventPlayerVampire[/url](String playerName)
[•] Esse evento ocorrerá quando um jogador tornar-se vampiro.

==================================================

[url=]eventPlayerWon[/url](String playerName)
[•] Esse evento ocorrerá quando um jogador ganhar a rodada.

==================================================

[url=]eventPlayerRespawn[/url](String playerName)
[•] Esse evento ocorrerá quando um jogador renascer.

==================================================

[url=]eventPopupAnswer[/url](Int popupId, String playerName, String answer)
[•] Esse evento ocorrerá quando um jogador responder a um popup.

==================================================

[url=]eventSummoningStart[/url](String playerName, Int ObjectType, Int xPosition, Int yPosition, Int angle)
[•] Esse evento ocorrerá quando um jogador iniciar uma invocação.

==================================================

[url=]eventSummoningCancel[/url](String playerName)
[•] Esse evento ocorrerá quando um jogador cancelar uma invocação.

==================================================

[url=]eventSummoningEnd[/url](String playerName, Int ObjectType, Int xPosition, Int yPosition, Int angle, Int xSpeed, Int ySpeed, Int ObjectType, Table other)
[•] Esse evento ocorrerá quando um jogador terminar uma invocação.

==================================================

[url=]eventTextAreaCallback[/url](Int textAreaId, String playerName, String callback)
[•] Esse evento ocorrerá quando um jogador clicar num texto. Exemplo : <a href="event:callbackString">Clique aqui</a>. Se a referência escolhida começar com '#clear' a textarea será limpada.


========================================
##### Funções
========================================


[url=]print[/url](String something)
[•] Exibe um texto. (apenas para quem executou o comando)

==================================================

system.[url=]exit[/url]()
[•] Desativa o script lua que está rodando.

==================================================

system.[url=]newTimer[/url](Function callback, Int time, Int loop, Object arg1, Object arg2, Object arg3, Object arg4)
[•] Cria um novo cronômetro. Return the new timer id. Use system.removeTimer(timerId) to stop a timer.

==================================================

system.[url=]removeTimer[/url](Int timerId)
[•] Remove um cronômetro.

==================================================

system.[url=]loadFile[/url](Int fileNumber)
[•] Carrega um arquivo. Permite carrega-lo em um limite de 10 minutos entre outro carregamento. Retorna true se começou a carregar...

==================================================

system.[url=]saveFile[/url](String data, Int fileNumber)
[•] Salva um arquivo. Permite salvar em um limite de 10 minutos entre outro salvamento. Retorna true se começou a salvar.

==================================================

system.[url=]loadPlayerData[/url](String playerName)
[•] Carrega um dado do jogador nesse módulo.

==================================================

system.[url=]savePlayerData[/url](String playerName, String data)
[•] Salva um dado para o jogador nesse módulo.

system.[url=]disableChatCommandDisplay[/url](String command, Boolean yes)
[•] Esconde um comando (iniciado por « ! ») digitado no chat.

==================================================

system.[url=]bindMouse[/url](String playerName, Boolean yes)
[•] Habilita o jogador para participar dos eventos com o mouse.

==================================================

debug.[url=]disableEventLog[/url](Boolean yes)
[•] Desativa as anotações dos eventos.

==================================================

debug.[url=]disableTimerLog[/url](Boolean yes)
[•] Desativa as anotações dos cronômetros.

==================================================

ui.[url=]addPopup[/url](Int id, Int type, String text, String targetPlayer, Int x, Int y, Int width, Boolean fixedPos (false))
[•] Adiciona um popup. Tipos de popup : 0 (simples), 1 (sim ou não), 2 (o jogador digita). Se targetPlayer for NIL (nulo), irá enviar para todos os jogadores.

==================================================

ui.[url=]addTextArea[/url](Int id, String text, String targetPlayer, Int x, Int y, Int width, Int height, Int backgroundColor, Int borderColor, Float backgroundAlpha, Boolean fixedPos (false))
[•] Adiciona um campo de texto. Se targetPlayer for NIL (nulo), irá enviar para todos os jogadores.

==================================================

ui.[url=]updateTextArea[/url](Int id, String targetPlayer, String text)
[•] Atualiza um campo de texto. Se targetPlayer for NIL (nulo), irá enviar para todos os jogadores.

==================================================

ui.[url=]removeTextArea[/url](Int id, String targetPlayer)
[•] Remove um campo de texto. Se targetPlayer for NIL (nulo), irá enviar para todos os jogadores.

==================================================

tfm.exec.[url=]addConjuration[/url](Int xPosition, Int yPosition, Int timeInMillis)
[•] Adiciona uma conjuração no mapa.

==================================================

tfm.exec.[url=]addShamanObject[/url](Int ObjectId, Int xPosition, Int yPosition, Int angle, Int xSpeed, Int ySpeed, Boolean ghost)
[•] Adiciona um objeto de shaman no mapa.

==================================================

tfm.exec.[url=]bindKeyboard[/url](String playerName, Int keyCode, Boolean down, Boolean yes)
[•] Habilita o jogador a participar dos eventos de teclas.

==================================================

tfm.exec.[url=]chatMessage[/url](String message, String playerName)
[•] Envia uma mensagem para todos os jogadores da sala. Se playerName não for nulo (NIL), irá enviar para o jogador especificado.
* NOTA: ESTE COMANDO FOI DESABILITADO!

==================================================

tfm.exec.[url=]disableAfkDeath[/url](Boolean yes)
[•] Desativa morte por estar ausente.

==================================================

tfm.exec.[url=]disableAllShamanSkills[/url](Boolean yes)
[•] Desativa habilidades do shaman.

==================================================

tfm.exec.[url=]disableAutoNewGame[/url](Boolean yes)
[•] Desativa novos jogos automaticamente.

==================================================

tfm.exec.[url=]disableAutoScore[/url](Boolean yes)
[•] Desativa a pontuação dos jogadores.

==================================================

tfm.exec.[url=]disableAutoShaman[/url](Boolean yes)
[•] Desativa a seleção automática de shamans.

==================================================

tfm.exec.[url=]disableAutoTimeLeft[/url](Boolean yes)
[•] Desativa o tempo restante automático.

==================================================

tfm.exec.[url=]displayParticle[/url](Int particleId, Int xPosition, Int yPosition, Float xSpeed, Float ySpeed, Float xAcceleration, Float yAcceleration, String targetPlayer)
[•] Adiciona uma partícula. Se targetPlayer for NIL, isso será enviado para todos os jogadores.

==================================================

tfm.exec.[url=]explosion[/url](Int xPosition, Int yPosition, Int power, Int distance, Boolean miceOnly)
[•] Executa uma explosão.

==================================================

tfm.exec.[url=]giveCheese[/url](String playerName)
[•] Dá queijos para um jogador específico.

==================================================

tfm.exec.[url=]giveMeep[/url](String playerName)
[•] Dá o poder de Meep para o jogador especificado.

==================================================

tfm.exec.[url=]killPlayer[/url](String playerName)
[•] Mata o jogador especificado.

==================================================

tfm.exec.[url=]moveObject[/url](Int ObjectId, Int xPosition, Int yPosition, Boolean offSet, Int xSpeed, Int ySpeed, Boolean offSet)
[•] Define a posição e a velocidade de um objeto.

==================================================

tfm.exec.[url=]movePlayer[/url](String playerName, Int xPosition, Int yPosition, Boolean offSet, Int xSpeed, Int ySpeed, Boolean offSet)
[•] Define a posição e a velocidade de um jogador.

==================================================

tfm.exec.[url=]newGame[/url](String mapCode)
[•] Executa um novo jogo. Use : 6 (vanilla), @42583 (mapa comum), #4 (categoria de mapa permanente), se começar com '<' lê um xml.

==================================================

tfm.exec.[url=]playerVictory[/url](String playerName)
[•] Dá a vitória para o jogador especificado.

==================================================

tfm.exec.[url=]removeObject[/url](Int ObjectId)
[•] Remove a physical Object.

==================================================

tfm.exec.[url=]respawnPlayer[/url](String playerName)
[•] Revive o jogador especificado.

==================================================

tfm.exec.[url=]setNameColor[/url](String playerName, Int color)
[•] Altera a cor do jogador especificado.
Exemplo de cor: 0x000000 (preto)
Usa-se 0x no lugar de #.

==================================================

tfm.exec.[url=]setPlayerScore[/url](String playerName, Int score, Boolean add)
[•] Define a pontuação do jogador especificado.

==================================================

tfm.exec.[url=]setRoomMaxPlayers[/url](Int maxPlayers)
[•] Define o número máximo de jogadores na sala.

==================================================

tfm.exec.[url=]setShaman[/url](String playerName)
[•] Define um shaman.

==================================================

tfm.exec.[url=]setTimeLeft[/url](Int seconds, Boolean init)
[•] Define o tempo restante de jogo.

==================================================

tfm.exec.[url=]setUIMapName[/url](String text)
[•] Define o texto do nome do mapa.

==================================================

tfm.exec.[url=]setUIShamanName[/url](String text)
[•] Define o texto do nome do shaman.

==================================================

tfm.exec.[url=]setVampirePlayer[/url](String playerName)
[•] Torna o jogador especificado em um vampiro.

==================================================

tfm.exec.[url=]snow[/url](Int seconds (60), Int snowballPower (10))
[•] Faz nevar.


========================================
##### Árvore LUA
========================================


_G
ipairs
[url=]ui[/url]
updateTextArea
removeTextArea
addPopup
addTextArea
[url=]math[/url]
deg
fmod
random
asin
max
modf
log10
floor
cosh
ldexp
log
pow
randomseed
frexp
abs
tanh
acos
atan2
tan
min
ceil
sinh
sqrt
huge
rad
sin
exp
cos
atan
pi
pcall
assert
tonumber
rawequal
[url=]table[/url]
maxn
foreachi
concat
remove
insert
foreach
sort
getn
[url=]tfm[/url]
[url=]exec[/url]
playerVictory
removeObject
respawnPlayer
disableAutoTimeLeft
disableAfkDeath
disableAutoScore
disableAutoNewGame
movePlayer
setPlayerScore
setShaman
setGameTime
explosion
addShamanObject
setUIMapName
chatMessage
setUIShamanName
giveCheese
setNameColor
killPlayer
snow
disableAutoShaman
setVampirePlayer
giveMeep
setRoomMaxPlayers
moveObject
bindKeyboard
addConjuration
newGame
displayParticle

[url=]enum[/url]
[url=]emote[/url]
sit : 8
facepaw : 7
laugh : 1
sleep : 6
angry : 4
confetti : 9
clap : 5
cry : 2
kiss : 3
dance : 0
[url=]shamanObject[/url]
bomb : 23
arrow : 0
trampoline : 7
balloon : 28
box : 2
rune : 32
snowBall : 34
board : 4
littleBox : 1
cannon : 19
ball : 6
anvil : 10
iceCube : 54
littleBoard : 3
[url=]get[/url]
[url=]misc[/url]
apiVersion : [irá retornar a versão atual da API dos módulus)
transformiceVersion : [irá retornar a versão atual do Transformice)
bouboumVersion : [irá retornar a versão atual do Bouboum)
[url=]room[/url]
community : -
currentMap : 0
maxPlayers : 50
ObjectList
name : -
playerList
isJumping
title : 0
y : 0
x : 0
isDead
look : 1;0,0,0,0,0,0,0,0,0
isShaman
vx : 0
score : 0
inHardMode
vy : 0
movingRight
hasCheese
registrationDate : 0
playerName : Tigrounette
hasTribe
movingLeft
isFacingRight
isVampire
movingRight
pairs
[url=]os[/url]
difftime
time
date
xpcall
type
error
[url=]string[/url]
len
find
gmatch
byte
dump
reverse
upper
format
rep
lower
sub
gsub
match
char
[url=]debug[/url]
disableEventLog
disableTimerLog
tostring
print
next
[url=]system[/url]
exit
bindMouse
disableChatCommandDisplay
removeTimer
newTimer
loadFile
saveFile
Mister
« Citoyen »
1381174260000
    • Mister#3773
    • Profil
    • Derniers messages
#2
  0
Eba Tradução!

@Edit:
Os "Analfainglês" pira :P
Thogabrielll
« Citoyen »
1381174260000
    • Thogabrielll#0000
    • Profil
    • Derniers messages
    • Tribu
#3
  0
Ficou muito boa e facil de entender
Pop
« Censeur »
1381174500000
    • Pop#0095
    • Profil
    • Derniers messages
    • Tribu
#4
  0
Obrigado niun ^-^
Brazucastens
« Citoyen »
1381174620000
    • Brazucastens#0000
    • Profil
    • Derniers messages
#5
  0
Obrigado pela tradução. c:
Rodrigo
« Citoyen »
1381174740000
    • Rodrigo#5542
    • Profil
    • Derniers messages
    • Tribu
#6
  0
Só acho que o Chatmessage faz muita falta... Eles deveriam colocar algum prefixo para indicar que é minigame, assim eles poderiam liberar o chat message e os games ficariam melhores.
Niunzin
« Citoyen »
1381174740000
    • Niunzin#0000
    • Profil
    • Derniers messages
    • Tribu
#7
  0
Imagina gente, qualquer falha é só me avisarem ^^
Fluffyshine
« Citoyen »
1381174740000
    • Fluffyshine#0000
    • Profil
    • Derniers messages
    • Tribu
#8
  0
Cnpj a dit :
Só acho que o Chatmessage faz muita falta... Eles deveriam colocar algum prefixo para indicar que é minigame, assim eles poderiam liberar o chat message e os games ficariam melhores.

looool boa ideia, isso deveria ser considerado pelos admins :o
Thogabrielll
« Citoyen »
1381174860000
    • Thogabrielll#0000
    • Profil
    • Derniers messages
    • Tribu
#9
  0
Niunzin a dit :
Imagina gente, qualquer falha é só me avisarem ^^

A arvore Lua é como que deve ser organizado o script?
Mister
« Citoyen »
1381174860000
    • Mister#3773
    • Profil
    • Derniers messages
#10
  0
Cnpj a dit :
Só acho que o Chatmessage faz muita falta... Eles deveriam colocar algum prefixo para indicar que é minigame, assim eles poderiam liberar o chat message e os games ficariam melhores.

Concordo
Fluffyshine
« Citoyen »
1381174860000
    • Fluffyshine#0000
    • Profil
    • Derniers messages
    • Tribu
#11
  0
Thogabrielll a dit :
A arvore Lua é como que deve ser organizado o script?

Não... são todos as funções em forma de árvore+condições, não sei explicar direito.
Niunzin
« Citoyen »
1381175040000
    • Niunzin#0000
    • Profil
    • Derniers messages
    • Tribu
#12
  0
Thogabrielll a dit :
A arvore Lua é como que deve ser organizado o script?

É as funções, vou dar um exemplo:

http://i.imgur.com/UFszf8U.png
Então dentro da função tfm, tem a função exec, que tem a função playerVictory
tfm.exec.playerVictory

Cnpj a dit :
Só acho que o Chatmessage faz muita falta... Eles deveriam colocar algum prefixo para indicar que é minigame, assim eles poderiam liberar o chat message e os games ficariam melhores.

E sem HTML, só com as cores do chat.
Thogabrielll
« Citoyen »
1381175040000
    • Thogabrielll#0000
    • Profil
    • Derniers messages
    • Tribu
#13
  0
Niunzin a dit :
É as funções, vou dar um exemplo:

Então dentro da função tfm, tem a função exec, que tem a função playerVictory
tfm.exec.playerVictory

E sem HTML, só com as cores do chat.

Entendi +- mesmo assim ty
Niunzin
« Citoyen »
1381175040000
    • Niunzin#0000
    • Profil
    • Derniers messages
    • Tribu
#14
  0
Thogabrielll a dit :
Entendi +- mesmo assim ty

Essa árvore é cada classe e o que tem dentro dela...
Rodrigo
« Citoyen »
1381175160000
    • Rodrigo#5542
    • Profil
    • Derniers messages
    • Tribu
#15
  0
Niunzin a dit :
É as funções, vou dar um exemplo:

Então dentro da função tfm, tem a função exec, que tem a função playerVictory
tfm.exec.playerVictory

E sem HTML, só com as cores do chat.

Acho que não teria problemas em usar o html, mas também não sou contra de removê-lo e adicionar o chatmessage.
Niunzin
« Citoyen »
1381175160000
    • Niunzin#0000
    • Profil
    • Derniers messages
    • Tribu
#16
  0
Cnpj a dit :
Acho que não teria problemas em usar o html, mas também não sou contra de removê-lo e adicionar o chatmessage.

Com HTML o pessoal ia dar um <br> e simular uma mensagem falsa do mesmo jeito x.x
Rodrigo
« Citoyen »
1381175280000
    • Rodrigo#5542
    • Profil
    • Derniers messages
    • Tribu
#17
  0
Niunzin a dit :
Com HTML o pessoal ia dar um &lt;br&gt; e simular uma mensagem falsa do mesmo jeito x.x

Ahh verdade, nem pensei nisso.
Tente sugerir aos admins de colocar um prefixo e bloquear o html. Tipo assim: [LUA] ou [GAME] e seguido do chatmessage.
Squalleze
« Citoyen »
1381175520000
    • Squalleze#0000
    • Profil
    • Derniers messages
    • Tribu
#18
  0
get
misc
apiVersion : 0.11
transformiceVersion : 1.95

Bom eu acho que a gente ta na verção 1.111 ^^

Eu sei ta errado no do Tig tambêm :P
Niunzin
« Citoyen »
1381176060000
    • Niunzin#0000
    • Profil
    • Derniers messages
    • Tribu
#19
  0
Squalleze a dit :
get
misc
apiVersion : 0.11
transformiceVersion : 1.95

Bom eu acho que a gente ta na verção 1.111 ^^

Eu sei ta errado no do Tig tambêm :P

Ah, é só um exemplo do valor que vai retornar xD
Makosear
« Citoyen »
1381176060000
    • Makosear#0000
    • Profil
    • Derniers messages
#20
  0
Poderia fixar esse tópico não?
  • Forums
  • /
  • Transformice
  • /
  • Archives
  • /
  • Seção Editor de Mapas e Modules
  • /
  • Documentação PT-BR
1 / 6 › »
© Atelier801 2018

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

Version 1.27