
X-SHADOW
Members-
Posts
721 -
Joined
-
Last visited
Everything posted by X-SHADOW
-
i realey recomanded to learn https://wiki.multitheftauto.com/wiki/Main_Page
-
lol now i like you code better then mine i should wrok like you did i so mutch love it
-
i know Kenix but still work error or not its work perfectly
-
function DXdraw() --Variables sWidth, sHeight = guiGetScreenSize() moneycount=getPlayerMoney(getLocalPlayer()) money= 'Cash>' ..moneycount dxDrawText(tostring">tostring (money),sWidth-450,sHeight-500,sWidth-7,sHeight-57,tocolor(255,0,0,220),1.0,"pricedown","right","top",false,false,false) -- Money DX text end addEventHandler("onClientRender", getRootElement(), DXdraw) function hudChanger2 () showPlayerHudComponent ( "money", true ) end addEventHandler( "onClientPlayerJoin", getRootElement(), hudChanger2 ) Updated !!
-
oh sorry Man and You're Welcome
-
no this well make his name with out hex colors
-
-- remove color coding from string function removeColorCoding (name) return type(name)=="string" and string.gsub(name, "#%x%x%x%x%x%x", "") or name end -- getPlayerName with color coding removed local _getPlayerName = getPlayerName function getPlayerName(player) if type(player) == "string" then return removeColorCoding(player) end return removeColorCoding (_getPlayerName(player)) end Lua Tags Bug !
-
not like that in your gamemode open scoreboard with tab and dont remove you hand form tab and pess right mouse the mouse will show to you click on something like near restor defults i forget the name and select what cloro you want and press save and Vola ! you change it
-
so the probelm is not set the element or the event wrong or what ? i dont see any error with getElementData
-
1 show to full error 2- i hope the administrion fix the Lua syntax error so i can help you
-
you can use removeEvnetHandler
-
the image not shown and what bars ??
-
i know i can Make them 10 sec but its Nice to be with mta some players dosnt know how to script
-
local tab = { ['Los Santos'] = 'LS'; ['Las Venturas'] = 'LV'; ['San Fierro'] = 'SF'; } function chatbox(text, msgtype) local account = getAccountName(getPlayerAccount(source)) local name = getPlayerName(source) local playerX, playerY, playerZ = getElementPosition ( source ) local playerZoneName = getZoneName ( playerX, playerY, playerZ,true ) if playerZoneName == 'Los Santos' or playerZoneName == 'Las Venturas' or playerZoneName == 'San Fierro' then playerZoneName = tab[ playerZoneName ] else playerZoneName = 'None' end if (msgtype == 0) then outputChatBox("(".. playerZoneName ..")".. name ..":".. text, root, 255, 255, 255, true) end end cancelEvent ( ) cancelEvent( ) addEventHandler("onPlayerChat", root, chatbox) if you are runing freeromm stop it and run stealth and test the script
-
local tab = { ['Los Santos'] = 'LS'; ['Las Venturas'] = 'LV'; ['San Fierro'] = 'SF'; } function chatbox(text, msgtype) local account = getAccountName(getPlayerAccount(source)) local name = getPlayerName(source) local playerX, playerY, playerZ = getElementPosition ( source ) local playerZoneName = getZoneName ( playerX, playerY, playerZ,true ) if playerZoneName == 'Los Santos' or playerZoneName == 'Las Venturas' or playerZoneName == 'San Fierro' then playerZoneName = tab[ playerZoneName ] else playerZoneName = 'None' end if (msgtype == 0) then outputChatBox("(".. playerZoneName ..")".. name ..":".. text, root, 255, 255, 255, true) end end cancelEvent ( ) addEventHandler("onPlayerChat", root, chatbox) is there any errors shown to you ? if there are then post it here
-
yes we should wait for administration to fix it lol
-
i cant help forum syntax error always
-
for i, team in ipairs">ipairs ( getElementsByType ( 'team' ) ) do synatx error
-
--serverSide---- exports.scoreboard:scoreboardAddColumn("FPS") ----clientSide---- local root = getRootElement() localPlayer = getLocalPlayer() local counter = 0 local starttick local currenttick addEventHandler("onClientRender",root, function() if not starttick then starttick = getTickCount() end counter = counter + 1 currenttick = getTickCount() if currenttick - starttick >= 1000 then setElementData(localPlayer, "FPS", counter) counter = 0 starttick = false end end ) fpstable = {} function averageFPS() avgseconds = 10 for i = 0, avgseconds do if i+1 <= avgseconds then fpstable[i+1] = fpstable[i] end fpstable[0] = getElementData(localPlayer, "FPS") end totalframes = 0 for k, v in pairs(fpstable) do if v ~= false then totalframes = totalframes + v end end avgfps = math.round(totalframes / avgseconds, 0) setElementData(localPlayer, "avgfps", avgfps) end setTimer(averageFPS, 1000, 0) function math.round(number, decimals, method) decimals = decimals or 0 local factor = 10 ^ decimals if (method == "ceil" or method == "floor") then return math[method](number * factor) / factor else return tonumber(("%."..decimals.."f"):format(number)) end end