Jump to content

sanyisasha

Members
  • Posts

    65
  • Joined

  • Last visited

Everything posted by sanyisasha

  1. If the player in AFK, change her dimension. Then when he is back, make it back to the normal dimension. What you need: setElementDimension -- To invisibility effect. setTimer -- create it if the player in "stand" movestate, and kill if the movestate is changed. getPedMoveState -- if is it "stand", then he is maybe AFK.
  2. sanyisasha

    $ to €

    Use a simple operator. Like this: local mymoney = 300 -- In dollar local newmoney = mymoney*0.86 -- 1$ is 0.86 € outputChatBox("$"..mymoney.." is €"..newmoney) --output: $300 is €258
  3. Hello guys. It is posible to make concave square with dxDraw? Now i mean with a "simple" dxDrawRectangle. Like this: Why? I want to make a panel like warframe, but i don't know how to make a concave rectangle Example: http://kephost.com/images/2015/11/01/0qiKrhg.jpg
  4. OOP: https://wiki.multitheftauto.com/wiki/OOP My example is more usefull. Element = { create = createElement, setPosition = setElementPosition, ... }
  5. Eh. I make a project today like this
  6. Loops: for i=1,10 do --todo end for i=10,1,-1 do --todo end for i,v in pairs(a) do --todo end
  7. It's "OOP" in MTA Lua. Example: local functions = { create = function(var1,var2) ... end, delete = function(var1,var2,var3) ... end} local created = functions.create(var1,var2)
  8. Hello guys. Anyone can send me a few FACEBOOK group with mta scripting content? [ENGLISH] I can't search it for myself, bcs facebook only found my country groups... Thanks ^^
  9. Fixed. addEvent("getHandlerSelf",true) addEventHandler("getHandlerSelf",getRootElement(),function(handler) DB = handler end)
  10. Then it's not your fault. It's the script fault. Leave a comment, to fix.
  11. Hmmm... My question: Why you want use createObject on ped?
  12. Hi. I have a resource structure: resource -server1.lua --function getHandler()... -server2.lua --function getUsernameByID()... So. The getMySQLHandler return the dbConnect handler. If i use it in another resource, like "resource2", it's working fine. But if i wanna use it in server2.lua, i can't call it. I tried exports.core:getHandler(), core:getHandler(), getHandler()... But always i get an error: except db-connection, get boolean. How can i "self" cast the "getHandler()" in server2.lua? Thanks for the help ^^
  13. Eh But the simple query is too lagy with much data for i,v in ipairs(vehs) do dbExec(DB,"UPDATE vehs SET x='"..x.."',y='"..y.."',z='"..z.."',rotx='"..rotx.."',roty='"..roty.."',rotz='"..rotz.."' WHERE id='"..v["id"].."'") end End i want to use like: for i,v in ipairs(vehs) do sql = sql.."UPDATE vehs SET x='"..x.."',y='"..y.."',z='"..z.."',rotx='"..rotx.."',roty='"..roty.."',rotz='"..rotz.."' WHERE id='"..v["id"]..'";" end dbExec(sql)
  14. Szia. Szerintem nem éri meg, főleg az árak miatt. "RP: Custom Car Names" Vagyis külön kocsi nevek. Ez 5 perc meló, és ezért kérnek el 11$-t. Nekem meg egy profi rendszerért nem akartak fizetni 5000Ft-ot
  15. Hello. I want to create a function, what save all to my database. That's easy. But i want to use the "multi query". An example: "UPDATE table SET ... WHERE ...; UPDATE table SET ...2 WHERE ...2 [...] My problem: The MTA always say: Syntax error. Like if i use the old php mysql, with query | multi_query. So: It's posible to use mysql in multiquery? So sorry for worst english
×
×
  • Create New...