Lua Snippets |
0 | ||
Animaljamvid a dit : You need profile cheese. Anyhow if it doesn't work you probably got banned and now you don't remember it. |
![]() ![]() « Citoyen » 1387556700000
| 0 | ||
well thats sad for me D: ive only gotten two warnings i never knew i got banned DD: |
![]() ![]() « Citoyen » 1388778840000
| 0 | ||
a dit : You can compair two elements (score.compair(element1, element2)) and the function will return to the biggest one or if they are equal each other , it will return them both. |
![]() ![]() « Censeur » 1388780280000
| 0 | ||
Abdeltif a dit : Not really necessary, plus why'd you put that in a table and store it in a variable, lol. |
![]() ![]() « Citoyen » 1388780520000
| 0 | ||
Safwanrockz a dit : Because I have more in my files and I don't want to share it ^^ That's why :p (Also I love the thing.thing that's why omo) This can be used in tfm, like it compairs the score of two players when the admin do !compare name1 name2 and do something to the one who have more , or if you have a private score system ect ... |
![]() ![]() « Citoyen » 1391447640000
| 0 | ||
Can get the codes now, ty ^^ |
![]() « Citoyen » 1393705980000
| 0 | ||
Hey. Could someone make a code for only one mouse can teleport with a mouse click please, thanks! |
![]() ![]() « Censeur » 1393706460000
| 0 | ||
Epicsouris a dit : Edit "Epicsouris" if you want another. a dit : |
![]() ![]() « Citoyen » 1394476620000
| 0 | ||
Hi, could you explain to me why this code does not work? code a dit : Sorry for annotations in french. When i say "don't work", it's only the latter function doesn't work, it kills the shaman before 10 seconds if the shamanes spawn a item. Thank's and sorry for my english ! ;) |
![]() ![]() « Censeur » 1394478060000
| 0 | ||
Luffylxl a dit : The currentTime variable is a local variable for eventLoop, which you also used in eventSummoningEnd, hence it doesn't work. |
![]() ![]() « Citoyen » 1394549760000
| 0 | ||
Thank's for your help. A new question, I want to make some sort of moderation, which has a command for only her, but don't understand why it doen't work. code a dit : Can you help me ? EDIT : I'm sorry, I found the solution. =) |
![]() ![]() « Citoyen » 1394651520000
| 0 | ||
Luffylxl a dit : The player you are binding the keys for is the key of the value in for loops, the metatables work like this : a dit : And removing the value argument, it will become : a dit : There are two ways to fix your script , the first is to make the names of players as keys if you want the for loops stay as they are , we can simply make thier values as anything(string, number, boolean, table, nil...): a dit : Or we can add the value argument to the two for loops, and change the first argument of tfm.exec.bindKeyboard function into the name of the second argument in the for loop : a dit : I hope this was usefull enough ;) -- Hex my posts are mega long and boring to read. |
![]() ![]() « Censeur » 1394656860000
| 0 | ||
Abdeltif a dit : Luffylxl a dit : Regardless, your explanation was pretty useful. |
![]() ![]() « Citoyen » 1394746320000
| 0 | ||
Anyway I thank you for your explanations that can help others. But I noticed my fault before and i corrected that with the same way : a dit : But thank you for trying to help me, it's always nice to hear. =) PS : Sorry again for my english, i'm french. |
![]() ![]() « Citoyen » 1395055980000
| 0 | ||
Luffylxl a dit : Your welcome Safwanrockz a dit : I know, a wall of text for nothing ;-; |
![]() ![]() « Citoyen » 1395598440000
| 0 | ||
You can explain to me why this code applies only to the last survivor ? a dit : Thank's. ;) |
![]() 1395612360000
| | ||
[Modéré par Bolinboy, raison : double post] |
0 | ||
How could you respawn only 1 specific mouse on a map? And how could you only make 1 mouse fly? [quote= function eventNewPlayer(name) tfm.exec.bindKeyboard(name,32,true,true) end for name,player in pairs(tfm.get.room.playerList) do eventNewPlayer(name) end function eventKeyboard(name,key,down,x,y) if key==32 then tfm.exec.movePlayer(name,0,0,true,0,-50,false) end end [/quote] I tried this but it dosen't work :/ |
![]() ![]() « Citoyen » 1395615180000
| 0 | ||
Luffylxl a dit : Indeed I can First it counts the number of the survived players and sets the variable n to the LAST player in the loop that is alive. If there is only 1 survival The variable n will refer to his name , ofcorse , because he is the FIRST and THE LAST survival. so he get cheese and win, and a new game starts. Why do you need explanation in this ? Also, the argument "name" is useless and it doens't refer to the last survival, it simply does nothing if there is more than 1 person alive. |
![]() ![]() « Censeur » 1395655380000
| 0 | ||
Badmanb a dit : Use this (!respawn Name) a dit : Badmanb a dit : There are several solutions for this, the easiest way to do it is to only bind the keyboard to the specific user you want. a dit : |