Jump to content

dudeks

Members
  • Posts

    45
  • Joined

  • Last visited

Everything posted by dudeks

  1. Still nothing. In newest driver same. Now I've got a window with Nvidia Optimus With all this drivers i have this: Anyone have solutions?EDIT: ok it's some cef issue https://bugs.mtasa.com/view.php?id=9219
  2. Hello. I can't run MTA on 1920x1080 resolution in borderless window. In other resolution works, but in this nope. Got only black screen, but it's ready for input (console > quit works). MTADiag: https://pastebin.mtasa.com/137671302
  3. Hello. I can't run MTA on 1920x1080 resolution in borderless window. In other resolution works, but in this nope. Got only black screen, but it's ready for input (console > quit works). MTADiag: https://pastebin.mtasa.com/137671302
  4. Hello. I have a little problem. Can't append a html element in my local site. function cef_create(window_code) executeBrowserJavascript(browser, 'createWindow("'..window_code..'");') end addEvent("cef_create", true) addEventHandler("cef_create", root, cef_create) local div = "\ \ " setTimer(function() cef_create(div) end, 3000, 1) <script src="http://mta/local/jquery.js" type="text/javascript"></script> <script type="text/javascript"> function createWindow(code) { $('body').append(code); } </script> I've got an error, and details of it: How to fix it?
  5. dudeks

    db* functions

    I've just updated my first post. Function query didn't work after queryUpdate that I post in 1st post. query function is: function query(query, ret) local query = dbQuery(mysql, query) local result, rows, id = dbPoll(query, -1) if result then if ret then return true, result, rows else return true, false, rows end else outputServerLog("MYSQL ERROR: "..rows.." | "..id) dbFree(query) return false, false, false end return false, false, false end In query function i've not using this, I wrote my gamemode sometime ago and can't use it now.
  6. dudeks

    db* functions

    Hello. After 1.5 update I was change mysql functions from module to inbuilt functions and have one problem. dbQuery function works only once and returns a data after start the script. Later? Returns nil and nope, nope, nope. I've writen function queryUpdate to auto-update row in table. After use of this, my function query isn't working. dbQuery(mysql, 'UPDATE `accounts` SET `playerHumanity`=?, `gamePoints`=?, `lastLogin`=?, `premiumPoints`=?, `playerPosition`=?,`playerBlood`=?, `lastIP`=?,`playerGroupID`=?, `playerName`=?, `playerItems`=?, `playerThirsty`=?, `playerPain`=?, `playerHungry`=?, `playerLegs`=?, `playerTemperature`=?, `lastQuitType`=?, `playerModel`=?, `playerEnergy`=?, `playerHands`=?, `playerBleeding`=? WHERE `characterID`=11', "0", "0", "CURRENT_DATE", "0", "93.08;-219.28;1.85;0;0", "12000", "86.63.94.152", "0", "dudeks", "|||BANDAGE,1;BANDAGE,1;PAINKILLER,1||", "100", "0", "100", "0", "36.599998474121", "Quit", "73", "100", "0", "0") Is it too long? Any solutions?
  7. So... Due to update with CEF We need to change it. What you think about it?
  8. Nope, it's not it. I mean using local .php files in CEF, now we can use .html files only.
  9. Hello. How to use local php files in web browsers? .php extension is not allowed in meta.xml file, is other way to use it? Need to be local for executing events from browser in client.
  10. dudeks

    Connection timedout

    http://pastebin.mtasa.com/417209115
  11. dudeks

    Connection timedout

    Hello. Since two days I have a problem connecting to any server. Still displays the message 'connection lost'. http://scr.hu/1jfv/nvgrg Once redirected to a page with tips, I did them all and still did not help. Getting that done: - The newly installed MTA - The newly installed GTA - I changed my anti-virus - I turned off the firewall - I installed the latest patch of MTA - With coercion also installed a new operating system
  12. Witam. Mam dosyć dziwny dla mnie problem z nazwijmy to 'nieuczciwą konkurencją'. Ów osobnicy z innych serwerów nieznanym JESZCZE dla mnie sposobem dodają swoje komendy na serwer, utrudniają rozgrywkę innym graczom poprzez masowe zabijanie ich, rozstawianie przed nimi namiotów czy też podmienianie wszystkich pojazdów na jakiś konkretny model. Zasób runcode usunięty (przez który jako tako mogli by coś dodać). Przeszukałem każdy zasób z serwera pod względem nazw tych komend, dodałem zabezpieczenie poprzez onPlayerCommand, też nic. Przy wyszukiwaniu w zasobach 'loadstring' - aktywny zasób który to używa to 'admin' (jakaś dziura? obejście uprawnień?) przy wydarzeniu 'aExecute'. Czekam na jakieś rozwiązanie mojego problemu. Pozdrawiam.
  13. Rozwiązanie z pętla dla mnie i dla rozwoju mojego skryptu jest lepsze. langStrings = { ["Polski"] = { ["CHOOSED_LANG"] = "Wybrałeś język: $1!", ["LOGIN_LAST_VISIT"] = "Ostatnio na serwerze byłeś $1-$2-$3 o godzinie $4:$5", ... } ... } Sprawdza się bardzo dobrze, nawet jeżeli argumentów jest więcej niż jeden, lub ułożenie argumentów w innym języku się zmienia.
  14. Właśnie string.format mi nie wystarczy, chcę zrobić gamemode nie tylko w języku polskim, dlatego czasem argumenty będą w innej kolejności wynikające z innego ułożenia zdania. A co do twojej pierwszej propozycji, miałem coś podobnego, działało. Myślałem, że da się to zrobić jakoś lepiej
  15. Witam. Myślę nad pewną rzeczą, teoretycznie wiem jak ją zrobić, ale w praktyce z tym już gorzej. Potrzebuję zamienić w stringu pewną rzecz w klamrach na wartość z tablicy. Pokażę to na przykładzie, najprościej będzie to wytłumaczyć. local table = { ["cos"] = "Wygrałeś", ["money"] = 1000 } Teraz ze stringu: local str = "GRATULACJE! {cos} {money} Ma być: local str = "GRATULACJE! Wygrałeś 1000 Pozdrawiam i czekam na jakieś sugestie co do wykonania tego, kod, inne...
  16. dudeks

    Errors in server

    Actually it's: MTA:SA Server v1.3.3-release-5610 I can't update it now.
  17. dudeks

    Errors in server

    Hi there. I have a problem with some errors in the console. They are spamming in console, but do not know where they are. ERROR: [string "-- CONFIG..."]:26: attempt to compare number with boolean ERROR: [string "-- CONFIG..."]:26: attempt to compare number with boolean
  18. Are you using this module? https://wiki.multitheftauto.com/wiki/Modules/MTA-MySQL If it's not work, try to use your code local lastLogin = tostring(mysql:result(lastLoginData, 1, 1)) In my test with using MTA-MySQL module. lastLoginData = mysql:query("SELECT `lastlogin` FROM `accounts` WHERE `id`='1'") print(tostring("test1")) local lastLogin = tostring(lastLoginData:result(1, 1)) print(tostring("test2")) outputChatBox(lastLogin, getRootElement(), 255, 0, 0) print(tostring("test3")) if (tostring(lastLogin) == tostring(mysql_null())) then -- but this isnt working print(tostring("lastlogin == mysql_null")) else print(tostring("lastlogin ~= mysql_null")) end print("lastLoginData: "..tostring(lastLoginData)) print("lastLogin: "..tostring(lastLogin)) print("mysql_null: "..tostring(mysql_null())) test1 test2 test3 lastlogin ~= mysql_null lastLoginData: MySQL result (#107) lastLogin: gsgsg mysql_null: userdata: 038C0138 Is you query working?
  19. mysql:result(lastLoginData, 1, 1) Change to: lastLoginData:result(1, 1) And mysql:null() to mysql_null()
  20. if mysql:num_rows(accountCheckQuery)>0 then is bad use if accountCheckQuery:num_rows() > 0 then all: local accountCheckQuery = mysql:query(accountCheckQueryStr) if accountCheckQuery:num_rows() > 0 then accountData = mysql_fetch_assoc(accountCheckQuery) accountCheckQuery:free_result()
  21. Hai. I have a problem. ped = createPed(qtable[k]["defskin"], charpos[i].x, charpos[i].y, charpos[i].z) setElementInterior(ped, 1) setElementDimension(ped, dim) local sx, sy = getScreenFromWorldPosition(charpos[i].x, charpos[i].y, charpos[i].z) qtable[k]["chartext"] = guiCreateLabel(sx, sy, 150, 200, qtable[k]["name"].."\nCzas online: "..qtable[k]["onlinetime"], false) getScreenFromWorldPosition always return false. http://i.imgur.com/bvwQC.jpg
  22. Hello. I had a problem with guiCreateStaticImage. 1 pixel border on the left side of image is a 1 pixel border size from image right side, why? Image width: 319 and height: 400. image = guiCreateStaticImage((sx/2) - 319, (sy/2)-200, 319, 400, "img.PNG", false, rootimg)
  23. Rozwiązanie problemu okazało się być banalne. Nie tworze pojazdów ani teamów jako osobną funkcję z resourcestartem. Mam jedną funkcję i w niej mam wczytywanie, wozy wczytywały się przed teamami, więc nie miało skąd pobrać danych. Wystarczyło (w moim przypadku) zamienić: vehicles.loadOnStart() team.loadTeams() na team.loadTeams() vehicles.loadOnStart()
×
×
  • Create New...