×

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
  • /
  • Lua Kodları Tartışma & Yardımlaşma Başlığı
« ‹ 275 / 388 › »
Lua Kodları Tartışma & Yardımlaşma Başlığı
Enesxfbxpro
« Censeur »
1408464780000
    • Enesxfbxpro#0000
    • Profil
    • Derniers messages
    • Tribu
#5481
  0
Mhmtcrazy a dit :
Enesxfbxpro a dit :
Mhmtcrazy a dit :
FFA'nın Lua Kodu Ne ? Lütfen Shamousey'in Açtığı Konuyu Göstermeyin Onu Denedim ama Yapamadım

Kopyala yapıştır damı yapamadın?

Edit: Arkadaşlar şu an LEAGUE OF LEGENDS oyununu kodluyorum. Ancak biraz yardıma ihtiyacım var. Yardımcı olacak lütfen oyundan ulaşsın.

Oyundan bir resim, (lütfen çalmayınız)

http://i.imgur.com/Yu8F6Oq.png

Benim Lua'da Senin Gibi Bir Usta Olabilmek İçin Ne Yapmam Gerek 1 Cümlede Anlatabilir misin ?

Bu konuya, edizin konularına ve rehber konularına bak. Tüm kodları didik didik incele. Öncelikle kolay şeylerden başla, mesela market gibi şeylerden başlama.
Zekakolik
« Citoyen »
1408528260000
    • Zekakolik#0000
    • Profil
    • Derniers messages
#5482
  0
x={cheese=function(n) tfm.exec.giveCheese(n) end,
meep=function(n) tfm.exec.giveMeep(n) end,
fly=function(n)
function eventKeyboard(name,key,down,x,y)
if key == 32 then
if canFly then
tfm.exec.movePlayer(name,0,0,true,0,-50,false)
end
end
end
end}
p={}
shop=[[<BV><p align='center'><B><TI>Shop</TI></B></p>
<B><J>Meep (75 peynir)<N><a href='event:buy meep 75'>
[Satın Al]</a></B>
<B><J>Uçma (500 peynir)<N><a href='event:buy fly 500'>
[Satın Al] </a><B>
<B><J>Peynir (25 peynir)<N><a href='event:buy cheese 25'>
[Satın Al]</a></B>
]]

function eventNewPlayer(n)
p[n]={coin=500}
end

for n in pairs (tfm.get.room.playerList) do
eventNewPlayer(n)
end

function eventPlayerWon(n)
p[n].coin=p[n].coin+100
ui.updateTextArea(2002,"<TI><B><N>Peyniriniz : <BV>"..p[n].coin,n)
end

function eventChatCommand(n,cmd)
if cmd:lower()=="market" then
o={x=5,y=27,w=300,h=150}
ui.addTextArea(2000,shop,n,o.x,o.y,o.w,o.h,1,1,0.8,true)
ui.addTextArea(2001,"<TI><B><R><a href='event:close'>[Kapat]",n,o.x+o.w-70,o.y+o.h-25,nil,nil,1,1,0,true)
ui.addTextArea(2002,"<TI><B><N>Peyniriniz : <BV>"..p[n].coin,n,o.x,o.y+o.h-25,nil,nil,1,1,0,true)
end
end

function eventTextAreaCallback(id,n,cb)
args={}
for arg in cb:gmatch("%S+") do
table.insert(args,arg)
end
if cb=="close" then
ui.removeTextArea(2000,n)
ui.removeTextArea(2001,n)
ui.removeTextArea(2002,n)
end
if args[1]=="buy" and p[n].coin >= tonumber(args[3]) then
p[n].coin=p[n].coin-args[3]
ui.updateTextArea(2002,"<TI><B><N>Peyniriniz : <BV>"..p[n].coin,n)
if args[2]=="cheese" then
x.cheese(n)
elseif args[2]=="meep" then
x.meep(n)
elseif args[2]=="fly" then
x.fly(n)
end
end
end


Nerede hata yaptım?

Dernière modification le 1408528320000
Enesxfbxpro
« Censeur »
1408534440000
    • Enesxfbxpro#0000
    • Profil
    • Derniers messages
    • Tribu
#5483
  0
Zekakolik a dit :
x={cheese=function(n) tfm.exec.giveCheese(n) end,
meep=function(n) tfm.exec.giveMeep(n) end,
fly=function(n)
function eventKeyboard(name,key,down,x,y)
if key == 32 then
if canFly then
tfm.exec.movePlayer(name,0,0,true,0,-50,false)
end
end
end
end}
p={}
shop=[[<BV><p align='center'><B><TI>Shop</TI></B></p>
<B><J>Meep (75 peynir)<N><a href='event:buy meep 75'>
[Satın Al]</a></B>
<B><J>Uçma (500 peynir)<N><a href='event:buy fly 500'>
[Satın Al] </a><B>
<B><J>Peynir (25 peynir)<N><a href='event:buy cheese 25'>
[Satın Al]</a></B>
]]

function eventNewPlayer(n)
p[n]={coin=500}
end

for n in pairs (tfm.get.room.playerList) do
eventNewPlayer(n)
end

function eventPlayerWon(n)
p[n].coin=p[n].coin+100
ui.updateTextArea(2002,"<TI><B><N>Peyniriniz : <BV>"..p[n].coin,n)
end

function eventChatCommand(n,cmd)
if cmd:lower()=="market" then
o={x=5,y=27,w=300,h=150}
ui.addTextArea(2000,shop,n,o.x,o.y,o.w,o.h,1,1,0.8,true)
ui.addTextArea(2001,"<TI><B><R><a href='event:close'>[Kapat]",n,o.x+o.w-70,o.y+o.h-25,nil,nil,1,1,0,true)
ui.addTextArea(2002,"<TI><B><N>Peyniriniz : <BV>"..p[n].coin,n,o.x,o.y+o.h-25,nil,nil,1,1,0,true)
end
end

function eventTextAreaCallback(id,n,cb)
args={}
for arg in cb:gmatch("%S+") do
table.insert(args,arg)
end
if cb=="close" then
ui.removeTextArea(2000,n)
ui.removeTextArea(2001,n)
ui.removeTextArea(2002,n)
end
if args[1]=="buy" and p[n].coin >= tonumber(args[3]) then
p[n].coin=p[n].coin-args[3]
ui.updateTextArea(2002,"<TI><B><N>Peyniriniz : <BV>"..p[n].coin,n)
if args[2]=="cheese" then
x.cheese(n)
elseif args[2]=="meep" then
x.meep(n)
elseif args[2]=="fly" then
x.fly(n)
end
end
end


Nerede hata yaptım?

Kodu yapan kişiye sor?


Edit: Luamı bozuldu?

Init Error : Ediz.lua:274: [string "Enesxfbxpro.lua"]:192: unfinished long comment

Dernière modification le 1408540200000
Vampirellax
« Citoyen »
1408541820000
    • Vampirellax#0000
    • Profil
    • Derniers messages
    • Tribu
#5484
  0
Merhaba kabile evinde ffa açmak istiyorum 260 da vermişsiniz o kodda drag atmıyor haberiniz olsun yardım edenler Teşşekkür Ederim .. :)
Dogangun
« Citoyen »
1408544220000
    • Dogangun#0000
    • Profil
    • Derniers messages
    • Tribu
#5485
  0
Vampirellax a dit :
Merhaba kabile evinde ffa açmak istiyorum 260 da vermişsiniz o kodda drag atmıyor haberiniz olsun yardım edenler Teşşekkür Ederim .. :)

FFA'yı kodla açmana gerek yok.

/module #deathmatch
Ustadharak
« Citoyen »
1408544520000
    • Ustadharak#0000
    • Profil
    • Derniers messages
    • Tribu
#5486
  0
Forumda sıfırdan Lua öğreten kaynak eksiği var. Bazı scriptleri inceliyorum yamalı bohça misali oradan buradan buldukları scriptlerin kombine edilmesi ile yapılmış. Benim düşünceme göre neyin ne olduğu temellerinden başlayarak öğretilmeli. Minioyun yapıyorsunuz eyvallah ama neyin ne olduğunu bilerek yazarsanız hem daha eğlenceli olur hem de yapabileceklerinizin sayısı artar. Yakında programlama makaleleri paylaşacağım takipte kalın.
Ttrabzonlee
« Citoyen »
1408555020000
    • Ttrabzonlee#0000
    • Profil
    • Derniers messages
#5487
  0
Vampirellax a dit :
Merhaba kabile evinde ffa açmak istiyorum 260 da vermişsiniz o kodda drag atmıyor haberiniz olsun yardım edenler Teşşekkür Ederim .. :)

al kardeşim :) kod benim değil ama bi yerden bulmuştum :D
Kod a dit :


tfm.exec.disableAutoNewGame(true)
tfm.exec.disableAutoShaman(true)
players={}
toDespawn={}
function eventNewPlayer(name)
for i,key in ipairs({32,40,83}) do
tfm.exec.bindKeyboard(name,key,true,true)
end
players[name]={
timestamp=os.time(),
offsets={x=2, y=10}
}
end

function eventKeyboard(name,key,down,x,y)
if (key==32 or key==40 or key==83) and not tfm.get.room.playerList[name].isDead and started then
if players[name].timestamp < os.time()-1000 then
local id
if tfm.get.room.playerList[name].isFacingRight then
id=tfm.exec.addShamanObject(19,x+players[name].offsets.x,y+players[name].offsets.y)
else
id=tfm.exec.addShamanObject(20,x+players[name].offsets.x,y+players[name].offsets.y)
end
players[name].timestamp=os.time()
table.insert(toDespawn,{os.time(),id})
end
end
end

function eventChatCommand(name,command)
local arg={}
for argument in command:gmatch("[^%s]+") do
table.insert(arg,argument)
end
if arg[1]=="off" then
if tonumber(arg[2]) and tonumber(arg[3]) then
players[name].offsets.x=tonumber(arg[2])
players[name].offsets.y=tonumber(arg[3])
else
players[name].offsets.x=2
players[name].offsets.y=10
end
tfm.exec.chatMessage("Offset'iniz değişti X:"..players[name].offsets.x.." Y:"..players[name].offsets.y,name)
end
end

function eventNewGame()
started=false
end

function eventLoop(time,remaining)
if time >= 3000 and not started then
started=true
end
if remaining<=0 then
end
for i,cannon in ipairs(toDespawn) do
if cannon[1] <= os.time()-3000 then
tfm.exec.removeObject(cannon[2])
table.remove(toDespawn,i)
end
end
end

function eventPlayerDied(name)
local i=0
local n
for pname,player in pairs(tfm.get.room.playerList) do
if not player.isDead then
i=i+1
n=pname
end
end
if i==0 then
elseif i==1 then
tfm.exec.giveCheese(n)
tfm.exec.playerVictory(n)
tfm.exec.setGameTime(5)
end
end

for name,player in pairs(tfm.get.room.playerList) do
eventNewPlayer(name)
end

Zekakolik
« Citoyen »
1408562220000
    • Zekakolik#0000
    • Profil
    • Derniers messages
#5488
  0
Ttrabzonlee a dit :
Vampirellax a dit :
Merhaba kabile evinde ffa açmak istiyorum 260 da vermişsiniz o kodda drag atmıyor haberiniz olsun yardım edenler Teşşekkür Ederim .. :)

al kardeşim :) kod benim değil ama bi yerden bulmuştum :D
Kod a dit :


tfm.exec.disableAutoNewGame(true)
tfm.exec.disableAutoShaman(true)
players={}
toDespawn={}
function eventNewPlayer(name)
for i,key in ipairs({32,40,83}) do
tfm.exec.bindKeyboard(name,key,true,true)
end
players[name]={
timestamp=os.time(),
offsets={x=2, y=10}
}
end

function eventKeyboard(name,key,down,x,y)
if (key==32 or key==40 or key==83) and not tfm.get.room.playerList[name].isDead and started then
if players[name].timestamp &lt; os.time()-1000 then
local id
if tfm.get.room.playerList[name].isFacingRight then
id=tfm.exec.addShamanObject(19,x+players[name].offsets.x,y+players[name].offsets.y)
else
id=tfm.exec.addShamanObject(20,x+players[name].offsets.x,y+players[name].offsets.y)
end
players[name].timestamp=os.time()
table.insert(toDespawn,{os.time(),id})
end
end
end

function eventChatCommand(name,command)
local arg={}
for argument in command:gmatch("[^%s]+") do
table.insert(arg,argument)
end
if arg[1]=="off" then
if tonumber(arg[2]) and tonumber(arg[3]) then
players[name].offsets.x=tonumber(arg[2])
players[name].offsets.y=tonumber(arg[3])
else
players[name].offsets.x=2
players[name].offsets.y=10
end
tfm.exec.chatMessage("Offset'iniz değişti X:"..players[name].offsets.x.." Y:"..players[name].offsets.y,name)
end
end

function eventNewGame()
started=false
end

function eventLoop(time,remaining)
if time &gt;= 3000 and not started then
started=true
end
if remaining&lt;=0 then
end
for i,cannon in ipairs(toDespawn) do
if cannon[1] &lt;= os.time()-3000 then
tfm.exec.removeObject(cannon[2])
table.remove(toDespawn,i)
end
end
end

function eventPlayerDied(name)
local i=0
local n
for pname,player in pairs(tfm.get.room.playerList) do
if not player.isDead then
i=i+1
n=pname
end
end
if i==0 then
elseif i==1 then
tfm.exec.giveCheese(n)
tfm.exec.playerVictory(n)
tfm.exec.setGameTime(5)
end
end

for name,player in pairs(tfm.get.room.playerList) do
eventNewPlayer(name)
end



Bu Shamousey'in.:P
Yelkenkaya
« Citoyen »
1408564440000
    • Yelkenkaya#0000
    • Profil
    • Derniers messages
#5489
  0
Bi Mini Oyun fikri buldumda kodlamayı pek bilmiorum yardım edebilecek varmı forumdan oyundan msj atsın geri dönerim
Enesxfbxpro
« Censeur »
1408564860000
    • Enesxfbxpro#0000
    • Profil
    • Derniers messages
    • Tribu
#5490
  0
yelkenkaya a dit :
Bi Mini Oyun fikri buldumda kodlamayı pek bilmiorum yardım edebilecek varmı forumdan oyundan msj atsın geri dönerim

Oyundan ulaş, yardımcı olurum.
Vampirellax
« Citoyen »
1408565640000
    • Vampirellax#0000
    • Profil
    • Derniers messages
    • Tribu
#5491
  0
Verdiğiniz FFA kodunda map değişmiyor kabile evinde FFA savaşımı olur :D
Enesxfbxpro
« Censeur »
1408565820000
    • Enesxfbxpro#0000
    • Profil
    • Derniers messages
    • Tribu
#5492
  0
Vampirellax a dit :
Verdiğiniz FFA kodunda map değişmiyor kabile evinde FFA savaşımı olur :D

Shamousey'in verdiği koduda kopyala yapıştır yapamıyorsan ne diyim size...



Arkadaşlar, ben yeni oyunda farelerin 10 saniye sonra doğmasını istiyorum. Bunu nasıl yapabilirim.
Yelkenkaya
« Citoyen »
1408569000000
    • Yelkenkaya#0000
    • Profil
    • Derniers messages
#5493
  0
rastgele birine sihir gücü verme tek maplık (sıralamaya görede olabilir) acil olursa cok iyi olur şimdiden teşekür
Benbirkralm
« Citoyen »
1408572840000
    • Benbirkralm#0000
    • Profil
    • Derniers messages
    • Tribu
#5494
  0
@Enesxfbxpro
Öncelikle bir değer belirle ardından loop ile her saniye arttır. 10 olunca respawn'la.
Enesxfbxpro
« Censeur »
1408572900000
    • Enesxfbxpro#0000
    • Profil
    • Derniers messages
    • Tribu
#5495
  0
Benbirkralm a dit :
@Enesxfbxpro
Öncelikle bir değer belirle ardından loop ile her saniye arttır. 10 olunca respawn'la.

Çok teşekkür ederim!

Edit : Sanırsam dediğimi yanlış anladın. Yeni bir oyun başladığında fareler olmayacak, 10 saniye sonra olacak.

Dernière modification le 1408575720000
Vampirellax
« Citoyen »
1408605120000
    • Vampirellax#0000
    • Profil
    • Derniers messages
    • Tribu
#5496
  0
tfm.exec.disableAutoNewGame(true)
tfm.exec.disableAutoShaman(true)
players={}
toDespawn={}
function eventNewPlayer(name)
for i,key in ipairs({32,40,83}) do
tfm.exec.bindKeyboard(name,key,true,true)
end
players[name]={
timestamp=os.time(),
offsets={x=2, y=10}
}
end
maps={521833,401421,541917,541928,541936,541943,527935,559634,559644,888052,878047,885641,770600,770656,772172,891472,589736,589800,589708,900012,901062,754380,901337,901411,907870,910078,1190467,1252043,1124380,1016258,1252299,1255902,1256808,986790,1285380,1271249,1255944,1255983,1085344,1273114,1276664,1279258,1286824,1280135,1280342,1284861,1287556,1057753,1196679,1288489,1292983,1298164,1298521,1293189,1296949,1308378,1311136,1314419,1314982,1318248,1312411,1312589,1312845,1312933,1313969,1338762,1339474,1349878,1297154,644588,1351237,1354040,1354375,1362386,1283234,1370578,1306592,1360889,1362753,1408124,1407949,1407849,1343986,1408028,1441370,1443416,1389255,1427349,1450527,1424739,869836,1459902,1392993,1426457,1542824,1533474,1561467,1563534,1566991,1587241,1416119,1596270,1601580,1525751,1582146,1558167,1420943,1466487,1642575,1648013,1646094,1393097,1643446,1545219,1583484,1613092,1627981,1633374,1633277,1633251,1585138,1624034,1616785,1625916,1667582,1666996,1675013,1675316,1531316,1665413,1681719,1699880,1688696,623770,1727243,1531329,1683915,1689533,1738601,3756146,912118,3326933,3722005,3566478,1456622,1357994,1985670,1884075,1708065,1700322,2124484,3699046,2965313,4057963,4019126,3335202,2050466}


function eventKeyboard(name,key,down,x,y)
if (key==32 or key==40 or key==83) and not tfm.get.room.playerList[name].isDead and started then
if players[name].timestamp < os.time()-1000 then
local id
if tfm.get.room.playerList[name].isFacingRight then
id=tfm.exec.addShamanObject(19,x+players[name].offsets.x,y+players[name].offsets.y)
else
id=tfm.exec.addShamanObject(20,x+players[name].offsets.x,y+players[name].offsets.y)
end
players[name].timestamp=os.time()
table.insert(toDespawn,{os.time(),id})
end
end
end

function eventChatCommand(name,command)
local arg={}
for argument in command:gmatch("[^%s]+") do
table.insert(arg,argument)
end
if arg[1]=="off" then
if tonumber(arg[2]) and tonumber(arg[3]) then
players[name].offsets.x=tonumber(arg[2])
players[name].offsets.y=tonumber(arg[3])
else
players[name].offsets.x=2
players[name].offsets.y=10
end
tfm.exec.chatMessage("Offsets changed to X:"..players[name].offsets.x.." Y:"..players[name].offsets.y,name)
end
end

function eventNewGame()
started=false
end

function eventLoop(time,remaining)
if time >= 3000 and not started then
started=true
end
if remaining<=0 then
end
for i,cannon in ipairs(toDespawn) do
if cannon[1] <= os.time()-3000 then
tfm.exec.removeObject(cannon[2])
table.remove(toDespawn,i)
end
end
end


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

for name,player in pairs(tfm.get.room.playerList) do
eventNewPlayer(name)
end
Vampirellax
« Citoyen »
1408605180000
    • Vampirellax#0000
    • Profil
    • Derniers messages
    • Tribu
#5497
  0
Arkadaşlar bunu açıyorum kabile evinde süre 00:00 olunca map değişmiyor yine kabile evine geçiyor lütfen bi yardım edin. :(
Enesxfbxpro
« Censeur »
1408608900000
    • Enesxfbxpro#0000
    • Profil
    • Derniers messages
    • Tribu
#5498
  0
Vampirellax a dit :
Arkadaşlar bunu açıyorum kabile evinde süre 00:00 olunca map değişmiyor yine kabile evine geçiyor lütfen bi yardım edin. :(

Daha kopyala yapıştır yapamıyorsun susak! Shamousey in konusundakini kopyalayacaksın luana yapıştıracaksın ne var burda

tfm.exec.disableAutoNewGame(true)
tfm.exec.disableAutoShaman(true)
players={}
toDespawn={}
maps={521833,401421,541917,541928,541936,541943,527935,559634,559644,888052,878047,885641,770600,770656,772172,891472,589736,589800,589708,900012,901062,754380,901337,901411,907870,910078,1190467,1252043,1124380,1016258,1252299,1255902,1256808,986790,1285380,1271249,1255944,1255983,1085344,1273114,1276664,1279258,1286824,1280135,1280342,1284861,1287556,1057753,1196679,1288489,1292983,1298164,1298521,1293189,1296949,1308378,1311136,1314419,1314982,1318248,1312411,1312589,1312845,1312933,1313969,1338762,1339474,1349878,1297154,644588,1351237,1354040,1354375,1362386,1283234,1370578,1306592,1360889,1362753,1408124,1407949,1407849,1343986,1408028,1441370,1443416,1389255,1427349,1450527,1424739,869836,1459902,1392993,1426457,1542824,1533474,1561467,1563534,1566991,1587241,1416119,1596270,1601580,1525751,1582146,1558167,1420943,1466487,1642575,1648013,1646094,1393097,1643446,1545219,1583484,1613092,1627981,1633374,1633277,1633251,1585138,1624034,1616785,1625916,1667582,1666996,1675013,1675316,1531316,1665413,1681719,1699880,1688696,623770,1727243,1531329,1683915,1689533,1738601,3756146,912118,3326933,3722005,3566478,1456622,1357994,1985670,1884075,1708065,1700322,2124484,3699046,2965313,4057963,4019126,3335202,2050466}

function eventNewPlayer(name)
for i,key in ipairs({32,40,83}) do
tfm.exec.bindKeyboard(name,key,true,true)
end
players[name]={
timestamp=os.time(),
offsets={x=2, y=10}
}
end

function eventKeyboard(name,key,down,x,y)
if (key==32 or key==40 or key==83) and not tfm.get.room.playerList[name].isDead and started then
if players[name].timestamp < os.time()-1000 then
local id
if tfm.get.room.playerList[name].isFacingRight then
id=tfm.exec.addShamanObject(19,x+players[name].offsets.x,y+players[name].offsets.y)
else
id=tfm.exec.addShamanObject(20,x+players[name].offsets.x,y+players[name].offsets.y)
end
players[name].timestamp=os.time()
table.insert(toDespawn,{os.time(),id})
end
end
end

function eventChatCommand(name,command)
local arg={}
for argument in command:gmatch("[^%s]+") do
table.insert(arg,argument)
end
if arg[1]=="off" then
if tonumber(arg[2]) and tonumber(arg[3]) then
players[name].offsets.x=tonumber(arg[2])
players[name].offsets.y=tonumber(arg[3])
else
players[name].offsets.x=2
players[name].offsets.y=10
end
tfm.exec.chatMessage("Offsets changed to X:"..players[name].offsets.x.." Y:"..players[name].offsets.y,name)
end
end

function eventNewGame()
started=false
end

function eventLoop(time,remaining)
if time >= 3000 and not started then
started=true
end
if remaining<=0 then
tfm.exec.newGame(maps[math.random(#maps)])
end
for i,cannon in ipairs(toDespawn) do
if cannon[1] <= os.time()-3000 then
tfm.exec.removeObject(cannon[2])
table.remove(toDespawn,i)
end
end
end

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

for name,player in pairs(tfm.get.room.playerList) do
eventNewPlayer(name)
end

tfm.exec.newGame(maps[math.random(#maps)])
Enesxfbxpro
« Censeur »
1408614360000
    • Enesxfbxpro#0000
    • Profil
    • Derniers messages
    • Tribu
#5499
  0
Basit bir market kodu; (oyununuzda teşekkür etmeden kullanmayın. !market ile açılır.)






p={}
function eventNewPlayer(n)
p[n]={para=0}
end

for n in pairs(tfm.get.room.playerList) do
eventNewPlayer(n)
end

function eventPlayerWon(n)


p[n].para=p[n].para+1
end

function eventChatCommand(n,cmd)
if cmd =="market" then
ui.addTextArea(30,"<br><br><br><B><N><p align='center'>Paran: "..p[n].para.." MP</p> <J><N><br><br><N>Eşyalarımızda %50 indirim bulunmaktadır!<br><br>Meep = Size patlatma gücü verir.Almak için !meep yazınız. Sadece 15 MP fiyatına! <br><br>Peynir = Peynir size yuvaya girmeniz için peynir verir. !peynir ile alırsınız. 50 MP Fiyatına",n,211,75,390,250,0x31454F,0x27373F,1,true)
ui.addTextArea(31,"<p align='center'><J><B>MARKET",n,211,75,390,17,0x31454F,0x27373F,1,true)
ui.addTextArea(32,"<a href='event:close'><J><B><p align='center'>KAPAT",n,211,320,390,17,0x31454F,0x27373F,1,true)
elseif cmd=="peynir" and p[n].para>=50 then
tfm.exec.giveCheese(n)
p[n].para=p[n].para-50
end
end


function eventTextAreaCallback(id,n,cb)
if cb=="close" then
ui.removeTextArea(30,n)
ui.removeTextArea(31,n)
ui.removeTextArea(32,n)
end
end
Imicos
« Citoyen »
1408614480000
    • Imicos#0000
    • Profil
    • Derniers messages
#5500
  0
Teşekkürler Enes çok ihtiyacım vardı ^_^
  • Forums
  • /
  • Transformice
  • /
  • Modules
  • /
  • Lua Kodları Tartışma & Yardımlaşma Başlığı
« ‹ 275 / 388 › »
© Atelier801 2018

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

Version 1.27