Jump to content

WASSIm.

Members
  • Posts

    1,412
  • Joined

  • Last visited

  • Days Won

    2

Everything posted by WASSIm.

  1. so when i start resource server will freezed bcs take max of ram (128MB)
  2. post what do you change
  3. you're welcome
  4. you dont' need use root for triggerClientEvent its just source of event sourceElement: The element that is the source of the event.
  5. change AddEventHandler to addEventHandler
  6. any help pleaseeee
  7. chnawa ismek ?
  8. hadha ibi3: https://www.facebook.com/MaxiAmry?fref=ts
  9. no, i just use Xml factions for load file and startResource but after check line per line and result problem with startResource
  10. tnajam ta7ki bil tounsi lina
  11. Hi GUYS, i have problem, when resource start server will freezed, realy i have file for resources list and when resource will start there resource will got freeze, its work fine on my local server but on my host got this problem
  12. if you looking something from tunisia post here: viewforum.php?f=166 and you need buy VPS if ou want host with website and with protection
  13. WASSIm.

    MTA don't launched

    HI GUYS, i have formatted my computer... so when open MTA but don' launched just show me that [stop playing with yourself] and then nothing http://pastebin.mtasa.com/613480365
  14. addEventHandler("onPlayerVehicleEnter", root, function (theVehicle) if (getElementModel(theVehicle) == 432) then toggleControl(source, "vehicle_secondary_fire", false) toggleControl(source, "vehicle_fire", false) end end) addEventHandler("onPlayerVehicleExit", root, function (theVehicle) if (getElementModel(theVehicle) == 432) then toggleControl(source, "vehicle_secondary_fire", true) toggleControl(source, "vehicle_fire", true) end end)
  15. yes i already do it but he don't understand
  16. you should tell us whats wrong and we will fixed it
  17. i talking with people post wrong code, and i working nn my own server
  18. You're Welcome
  19. you need use setElementDatabwhen you'r use setAccountData or you can use this... addEventHandler("onAccountDataChange", root, function (account, key, value) local thePlayer = getAccountPlayer(account) if (thePlayer) then setElementData(thePlayer, "account_"..key, value) end end) addEventHandler("onPlayerLogin", root, function (_, account) local alldata = getAllAccountData(account) for key, value in pairs(alldata) do setElementData(source, "account_"..key, value) end end) addEventHandler("onPlayerLogout", root, function (_, account) local alldata = getAllAccountData(account) for key, value in pairs(alldata) do removeElementData(source, "account_"..key, value) end end) Exmple: local bankMoney = getElementData(getLocalPlayer(), "account_bank.balance")
  20. realy guys its that to hard ? local totalVisiters = 0 addEventHandler("onResourceStart", resourceRoot, function () executeSQLQuery("CREATE TABLE IF NOT EXISTS players (name TEXT, serial TEXT)") for _, player in pairs(getElementsByType("player")) do local serial = getPlayerSerial(player) local result = executeSQLQuery("SELECT * FROM players WHERE serial=?", serial) if (#result == 0) then local name = getPlayerName(player) executeSQLQuery("INSERT INTO players(name,serial) VALUES(?,?)", name, serial) end end local count = #executeSQLQuery("SELECT * FROM players") if (count) and (tonumber(count)) then totalVisiters = count end end) addEventHandler("onPlayerJoin",root, function () local serial = getPlayerSerial(source) local result = executeSQLQuery("SELECT * FROM players WHERE serial=?", serial) if (#result == 0) then local name = getPlayerName(source) executeSQLQuery("INSERT INTO players(name,serial) VALUES(?,?)", name, serial) totalVisiters = totalVisiters+1 end end)
  21. any help ?
  22. WASSIm.

    Vehicle aim

    createVehicle -- That for create vehicle createPed -- That for create driver setElementAlpha -- If you want hide driver warpPedIntoVehicle -- That for create warp driver into vehicle setPedAnalogControlState -- That for control vehicle
  23. local render = { } function bindTheKeys2(player, key, stats) if (stats == "down") then render[player] = setTimer(function(player) local x, y, z, rx, ry, rz = getElementAttachedOffsets (car1) attachElements ( car1, vehicle[player], x, y, z, rx, ry, rz+1) end, 50, 0, player) elseif (stats == "up") and (isTimer(render[player])) then killTimer(render[player]) render[player] == nil end end function bindTheKeysd(player, commandName) bindKey(player, "F2", "both", bindTheKeys2) end addCommandHandler("bindme", bindTheKeysd)
  24. BUMP
×
×
  • Create New...