
1LoL1
Members-
Posts
944 -
Joined
-
Last visited
Everything posted by 1LoL1
-
setPlayerNametagShowing
-
addEventHandler("onPlayerLogin", getRootElement(), function (_, acc) if getAccountData(acc, "wb") then outputChatBox("Welcome back!") else setAccountData(acc, "wb", "test") outputChatBox("Welcome new player!") end end)
-
Try this but start in 800x600 resolution. x, y = guiGetScreenSize() rx, ry = (x/800), (y/600) image = guiCreateStaticImage(rx*640, ry*360, rx*1980, ry*1280, "login_bg.png",false)
-
dbExec ( sql, "CREATE TABLE IF NOT EXISTS selling (userid INT(6) UNSIGNED AUTO_INCREMENT PRIMARY KEY, item VARCHAR(30), amount INT(6), price INT(6))" )
-
Post the "onSpawnPoliceOfficerLS"
-
can any one help me to make a custom group shader skin
1LoL1 replied to darbka2002's topic in Scripting
local players = getPlayerTeam(source) if players and getTeamFromName("DX") == players then setElementModel(source, id) else setElementModel(source, 0) -
It's marker not market. marker = createMarker( x, y, z, "cylinder", 1.5, 255, 255, 0, 170 ) addCommandHandler("move", function () moveObject(marker, 1500, x, y, z) end)
-
What is function open?
-
He used in all setAccountData so why givePlayerMoney? and setAccountData data is saved in account.
-
Try this: addEventHandler("onPlayerChat", getRootElement(), function(msg, type) if type == 0 then cancelEvent() local r, g, b = getPlayerNametagColor(source) local msg = msg:gsub("#%x%x%x%x%x%x", "") outputChatBox(string.gsub(getPlayerName(source),"#%x%x%x%x%x%x","")..": #FFFFFF"..msg, getRootElement(), r, g, b, true) outputServerLog( "CHAT: " .. name .. ": " .. msg ) end end))
-
Try this: local g_Vehicle = getPedOccupiedVehicle( localPlayer ) local nitro = tostring(getVehicleNitroLevel(g_Vehicle))
-
addCommandHandler("go", function (source) if isObjectInACLGroup("user."..getAccountName(getPlayerAccount(source)),aclGetGroup("Group")) then setElementPosition(x, y, z) else outputChatBox("text...", source, 255, 255, 255, true) end)
-
i used this too but save or load not work
-
Hello, i tried save and load with executeSQLQuery but idk why not work. Errors / Warnings: Warning: Bad argument @ 'getAccountName' [Expected account at argument 1, got player] Error: Database query failed: no such column: false addEventHandler("onPlayerQuit", getRootElement(), function () if isGuestAccount(getPlayerAccount(source)) then return end local account = getAccountName(getPlayerAccount(source)) local TEST1 = (getElementData(source, "TEST1") or 0) local TEST2 = (getElementData(source, "TEST2") or 0) local TEST3 = (getElementData(source, "TEST3") or 0) local searchForAPlayer = executeSQLQuery("SELECT TEST1, TEST2, TEST3 FROM Avengers WHERE Account = ?", account) if #searchForAPlayer == 0 then executeSQLQuery("INSERT INTO Avengers (Account, TEST1, TEST2, TEST3) VALUES (?, ?, ?, ?)", account, TEST1, TEST2, TEST13) else executeSQLQuery("UPDATE Avengers SET TEST1 = ?, TEST2 = ?, TEST3 = ? WHERE Account = ?", TEST1, TEST2, TEST3, account) end end) addEventHandler ("onPlayerLogin", getRootElement(), function () local account = getAccountName(source) local searchForAPlayer = executeSQLQuery("SELECT TEST1, TEST2, TEST3 FROM Avengers WHERE Account = ?", account) if #searchForAPlayer == 1 then setElementData(source, "TEST1", searchForAPlayer["TEST1"]) setElementData(source, "TEST2", searchForAPlayer["TEST2"]) setElementData(source, "TEST3", searchForAPlayer["TEST3"]) end end)
-
No you can't if i'am wrong so sorry. But you can use setElementFrozen if not work then idk sorry.
-
Errors/Warnings in /debugscript 3?
-
Hello, can anyone help me why i have this error? ERROR: attempt to index local 'q' (a userdata value) function whenPlayerChangeNick(_, newNick) local newNick = removeHexColorCode(newNick) local serial = getPlayerSerial(source) local q = dbQuery(database,"SELECT * FROM Nick WHERE Serial = ?", serial) local poll, rows = dbPoll(q, -1) if (rows == 1) then local actualNicks = q["Nicks"].nicks if string.find(actualNicks, newNick) then else local addNewNick = actualNicks .. ", " .. newNick dbExec(database, "UPDATE Nick SET Nicks = ? WHERE Serial = ?", addNewNick, serial) end end end addEventHandler("onPlayerChangeNick", getRootElement(), whenPlayerChangeNick)