×

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
  • /
  • Modules
  • /
  • [Module API] Errors
« ‹ 3 / 17 › »
[Module API] Errors
Safwanrockz
« Censeur »
1383391860000
    • Safwanrockz#0095
    • Profil
    • Derniers messages
    • Tribu
#41
  0
Mousechris a dit :
addImage("http://imgur.com/u0xEIsk", "?1", 0, 0)
tfm.exec.disableAutoNewGame(true)
maps={0,1,2,3,4,5,6,7,8,9,10}

function eventLoop(time,remaining)
if remaining<=0 then
tfm.exec.newGame(maps[math.random(#maps)])
end
end

function eventPlayerDied()
local i=0
for n,player in pairs(tfm.get.room.playerList) do
if not player.isDead then
i=i+1
end
end
if i==0 then
tfm.exec.newGame(maps[math.random(#maps)])
end
end

[•] Init Error : transformice.lua:1: attempt to call nil

what did I do wrong

Shamousey a dit :
• tfm.exec.addImage() and tfm.exec.removeImage() are disabled due to potential abuse with inappropriate images.

 
Epicshawty
« Citoyen »
1383440220000
    • Epicshawty#0000
    • Profil
    • Derniers messages
    • Tribu
#42
  0
Safwanrockz a dit :
 

No, I believe he was getting his goal to a # room, not a script but he did something wrong,

It's supposed to be tfm.exec.addImage(stuff)

Not sure about the http://imgur stuff
Shamousey
« Consul »
1383443820000
    • Shamousey#0095
    • Profil
    • Derniers messages
    • Tribu
#43
  0
Epicshawty a dit :
Not sure about the http://imgur stuff

You just need to use the file name and extension, in this case it'd be "u0xEIsk.jpg".
Mikuhl
« Citoyen »
1383488220000
    • Mikuhl#3311
    • Profil
    • Derniers messages
    • Tribu
#44
  0
Shamousey a dit :
You just need to use the file name and extension, in this case it'd be "u0xEIsk.jpg".

I dont see why the restricted it to imgur, because imgur goes down sometimes and then your whole module is littered with "This image does not exist!" and you can just upload bad images to imgur anyway so its not like restricting it combats people putting bad images in modules.
Shamousey
« Consul »
1383490680000
    • Shamousey#0095
    • Profil
    • Derniers messages
    • Tribu
#45
  0
Jaackster a dit :
I dont see why the restricted it to imgur, because imgur goes down sometimes and then your whole module is littered with "This image does not exist!" and you can just upload bad images to imgur anyway so its not like restricting it combats people putting bad images in modules.

http://i.imgur.com/IndxZS3.png
He works in mysterious ways.
Livcorish
« Citoyen »
1383498720000
    • Livcorish#0000
    • Profil
    • Derniers messages
#46
  0
This is so helpful *-*
Makinit
« Citoyen »
1383559260000
    • Makinit#0095
    • Profil
    • Derniers messages
    • Tribu
#47
  0
Jaackster a dit :
I dont see why the restricted it to imgur

I guess this is because allowing arbitrary URLs would enable people to do things that might be considered harmful, like logging IP addresses.
Thewildnes
« Citoyen »
1383681780000
    • Thewildnes#0000
    • Profil
    • Derniers messages
    • Tribu
#48
  0
[•] Init Error : [string "transformice.lua"]:1: '=' expected
:(
Hophipmice
« Citoyen »
1383682260000
    • Hophipmice#0000
    • Profil
    • Derniers messages
    • Tribu
#49
  0
Thewildnes a dit :
[•] Init Error : [string "transformice.lua"]:1: '=' expected
:(

It's either you spelt the word end or a word wrong
or
give us the script so we can see.
Safwanrockz
« Censeur »
1383682560000
    • Safwanrockz#0095
    • Profil
    • Derniers messages
    • Tribu
#50
  0
Thewildnes a dit :
[•] Init Error : [string "transformice.lua"]:1: '=' expected
:(

We can't just define the error and fix it from two words, you should give us the script that's having that error.
Thewildnes
« Citoyen »
1383989340000
    • Thewildnes#0000
    • Profil
    • Derniers messages
    • Tribu
#51
  0
function eventLoop(time,remaining)
if remanining == 3 then
ui.addTextArea(1,"<font size='60'>Hello</font>",all, 160, 140,2000,0,0,0)

Not working.
Issey
« Citoyen »
1383998160000
    • Issey#0000
    • Profil
    • Derniers messages
#52
  0
Thewildnes a dit :

Not working.

a dit :
function eventLoop(time,remaining)
if remaining == 3 then
ui.addTextArea(1,"<font size='60'>Hello</font>",all, 160, 140,2000,0,0,0)
end

you misspelled temaining on the second line and you didn't end the eventLoop function
Thewildnes
« Citoyen »
1384008060000
    • Thewildnes#0000
    • Profil
    • Derniers messages
    • Tribu
#53
  0
Issey a dit :
you misspelled temaining on the second line and you didn't end the eventLoop function

Not working :(
Shamousey
« Consul »
1384016880000
    • Shamousey#0095
    • Profil
    • Derniers messages
    • Tribu
#54
  0
Thewildnes a dit :
function eventLoop(time,remaining)
if remanining == 3 then
ui.addTextArea(1,"&lt;font size='60'&gt;Hello&lt;/font&gt;",all, 160, 140,2000,0,0,0)

Not working.

You didn't end the function or the if statement. all isn't a valid target, if you want it to be visible to everyone make it nil. The arguments in eventLoop use milliseconds and only run every half a second (12000, 11500, 11000, etc.), it'll never hit 3.
Thewildnes
« Citoyen »
1384020480000
    • Thewildnes#0000
    • Profil
    • Derniers messages
    • Tribu
#55
  0
Shamousey a dit :
You didn't end the function or the if statement. all isn't a valid target, if you want it to be visible to everyone make it nil. The arguments in eventLoop use milliseconds and only run every half a second (12000, 11500, 11000, etc.), it'll never hit 3.

Thanks Sham
Zyx
« Censeur »
1384025340000
    • Zyx#8690
    • Profil
    • Derniers messages
#56
  0
Whats this error?

Init Error : [string "transformice.lua"]:1: unexpected symbol
Hophipmice
« Citoyen »
1384025580000
    • Hophipmice#0000
    • Profil
    • Derniers messages
    • Tribu
#57
  0
Swirlfire a dit :
Whats this error?

Init Error : [string "transformice.lua"]:1: unexpected symbol

code?
Zyx
« Censeur »
1384025820000
    • Zyx#8690
    • Profil
    • Derniers messages
#58
  0
Hophipmice a dit :
code?

:

a dit :
print(<<"Hi, welcome to snowball! This isn't a approved nor offical minigame, and it's only run in Tribe Houses. Have fun!">>)

tfm.exec.newGame
if start then

tfm.exec.setShaman(nil)
if nil then

table = {

(game, lava, kill, jump, shaman)

tfm.exec.message(It's now your turn, playername -- !")

ui.Popup.set("Welcome to snowball! This is a game where you have to avoid blocks that have unexcpected lava in them. If the shaman dies when crossing, one mouse goes and then on and on.")

end
end

This is NOT my code, and my friend asked me to test it.
Hophipmice
« Citoyen »
1384025820000
    • Hophipmice#0000
    • Profil
    • Derniers messages
    • Tribu
#59
  0
Swirlfire a dit :
print("Hi, welcome to snowball! This isn't a approved nor offical minigame, and it's only run in Tribe Houses. Have fun!")

tfm.exec.newGame
if start then

tfm.exec.setShaman(nil)
if nil then

table = {

(game, lava, kill, jump, shaman)

tfm.exec.message("It's now your turn, playername -- !")

ui.Popup.set("Welcome to snowball! This is a game where you have to avoid blocks that have unexcpected lava in them. If the shaman dies when crossing, one mouse goes and then on and on.")

end
end

This is NOT my code, and my friend asked me to test it.

print(<<"Hi, welcome to snowball! This isn't a approved nor offical minigame, and it's only run in Tribe Houses. Have fun!">>)

What on earth are the &lt;&lt; and &gt;&gt; for...
Tailtong
« Citoyen »
1384025820000
    • Tailtong#0000
    • Profil
    • Derniers messages
    • Tribu
#60
  0
What on earth is anything in that code for, actually?
  • Forums
  • /
  • Transformice
  • /
  • Modules
  • /
  • [Module API] Errors
« ‹ 3 / 17 › »
© Atelier801 2018

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

Version 1.27