Jump to content

Baseplate

Members
  • Posts

    1,417
  • Joined

  • Last visited

Everything posted by Baseplate

  1. I remember myonlake posting this once, so yeah here you go mate.
  2. Baseplate

    Vehicles

    I'll bump this as I still need some help.
  3. Baseplate

    Vehicles

    executeSQLQuery("INSERT INTO vehUpgrades (accName, id, upgrades)", accName, carID, "empty") I'm not sure about the "empty" value, with what should I replace it? (I wanted to make an independant table for the upgrades, so I've changed it a bit).
  4. Baseplate

    Vehicles

    [2015-06-09 12:43:17] ERROR: [server]\vehicles\server.lua:63: bad argument #1 to 'ipairs' (table expected, got nil)
  5. Baseplate

    Vehicles

    I didn't post the full code, it is right in my actual code.
  6. Baseplate

    Vehicles

    function spawnDespawnCar(p, carName) local accName = getAccountName(getPlayerAccount(p)) local carID = getVehicleModelFromName(carName) local result = executeSQLQuery("SELECT * FROM vehicles WHERE accName=? and ID=?", accName, carID) if (not getElementData (p,"System.Vehicle")) then local upgrades = fromJSON(result[1]["upgrades"]) local veh = createVehicle(...) addVehicleUpgrade(veh, upgrades) setElementData (p, "System.Vehicle", veh) outputChatBox("Your car has been spawned!", p, 0, 255, 0) elseif (getElementData (p, "System.Vehicle")) then local nveh = getElementData (p, "System.Vehicle") outputChatBox("Your car has been despawned!", p, 0, 255, 0) local nups = toJSON(getVehicleUpgrades(nveh)) destroyElement(nveh) executeSQLQuery("UPDATE vehicles SET upgrades=? WHERE accName=? AND id=?", nups, accName, carID) setElementData (p, "System.Vehicle", false) end end addEvent("spawnDespawnCar", true) addEventHandler("spawnDespawnCar", root, spawnDespawnCar) I'm having problems saving and getting some upgrades of the car to SQLite, I'm quite new to JSON functions and I guess that I'm not getting it right.
  7. The server seems cool, and the administration team seems to be friendly. Good luck guys!
  8. I like the fact how he claims he scripted for CSG when he barely does shit except being a dictator lol.
  9. Works like a charm, thanks a lot for helping.
  10. --Client function openPanel(result4) for h=1,#result4 do guiGridListClear(manageGridList) row = guiGridListAddRow(manageGridList) guiGridListSetItemText(manageGridList, row, 1, result4[h]["accName"], false, false) guiGridListSetItemText(manageGridList, row, 2, result4[h]["rank"], false, false) end addEvent("openGroupPanel", true) addEventHandler("openGroupPanel", root, openPanel) --Server executeSQLQuery("CREATE TABLE IF NOT EXISTS groupMembers (groupName TEXT, accName TEXT, rank TEXT)") function openServerPanel(thePlayer) local accName = getAccountName(getPlayerAccount(thePlayer)) local group = getElementData(thePlayer, "Group") local result4 = executeSQLQuery("SELECT * FROM groupMembers WHERE groupName=?", group) triggerClientEvent(thePlayer, "openGroupPanel", thePlayer, result4) end The problem; as when I open the gridlist it only displays the last result found. P.S: I obviously didn't post all of the code, just the part that isn't working properly.
  11. Gta-IS? Islamic State? t7eb tda55al de3ech bessif? Good luck mate!
  12. Been a while since I last posted here, but that ban reason, is the most professional thing I've ever seen, give that owner a medal for his professionalism! Besides, why did I read the bloody ban reason in some mexican accent? Weird.. Anyways, it is fine, get used to it mate.
  13. Baseplate

    FPS Drops

    Gonna bump this, been waiting for more than a week down here..
  14. Baseplate

    FPS Drops

    Hello, while I'm playing MTA 1.4, it came to my attention that my FPS keeps dropping from time to another, even though I didn't install any mods and my PC isn't that old.. http://pastebin.mtasa.com/580389860 -- This is the paste of MTADiag.
  15. ViRuZ, he said "on quit", I don't think that element data do save on quit. Minotaur ignore him please, you've got many options to save score, either account data (setAccountData and getAccountData), XML, or SQL.
  16. I want to talk to you. All what you have to do is to go. After the 1st of August, Pyro hosting will offer only paid hosting. Judging from your grammar, yeah, seems legit.
  17. Baseplate

    BUG

    The source of onMarkerHit event is the marker that was hit, you should use onMarkerHit parameters. local Marker = createMarker ( 2048.68848, 1474.93945, 9.67188, "cylinder", 10.0, 155, 0, 0, 150) -- Isn't 10 as a size kinda too much? function elLoco(hElement) setPlayerWantedLevel(hElement, 3) end addEventHandler ("onMarkerHit", Marker, elLoco)
  18. No offence taken mate besides, I had nothing to do and I just felt like helping.
  19. function showGUI_Handler() guiSetVisible(GUIEditor.window[1], not guiGetVisible(GUIEditor.window[1])) end bindKey("F4", "down", showGUI_Handler) This also should do the trick.
  20. ki nebda ena mawjoud, yezzi fih el 5ir.
×
×
  • Create New...