Jump to content

RaceUnit

Members
  • Posts

    19
  • Joined

  • Last visited

RaceUnit's Achievements

Square

Square (6/54)

0

Reputation

  1. Its the old WTF radar(someone stole it), it was leaked to community but was removed from there also after some hours... So you cant have it. Thanks for the information, that means no one can use that radar? Why does TG and other servers?
  2. RaceUnit

    [REQ] Radar

    Hey, I'm looking for the radar that many servers use, like TG, DT, IP, and more, you can see it on this pic: Please give my the link of the download, it will be great! Thanks, and sorry for the bad English, i'm Dutch.
  3. I doesn't have any trigger, can you help my with that?
  4. Hello, I have an race server, it shows in the corner: the map, nextmap and spectators, but if i set a nextmap it will stay on "Random". This is my code: -----------------Spectators local player = getLocalPlayer() local root = getRootElement () local Spectators = {} setElementData ( player, "Spectator", "" ) local scrX, scrY = guiGetScreenSize() repair=true ------------------ function start () setTimer ( checkTarget, 1000, 0 ) end addEventHandler ( "onClientResourceStart", getResourceRootElement(), start ) ------------------ function checkTarget ( ) local target = getCameraTarget () local car = getPedOccupiedVehicle ( player ) if not ( car ) then car = "noCar" end if ( target ) then setElementData ( player, "Spectator", target ) else setElementData ( player, "Spectator", "" ) end Spectators = {} for i,v in ipairs( getElementsByType ( "player" ) ) do if ( v ~= player ) then local vTarget = getElementData ( v, "Spectator" ) if ( vTarget == car ) then table.insert(Spectators,v) end end end end ------------------ g_Root = getRootElement() g_ResRoot = getResourceRootElement(getThisResource()) g_Me = getLocalPlayer() g_ArmedVehicleIDs = table.create({ 425, 447, 520, 430, 464, 432 }, true) g_WaterCraftIDs = table.create({ 539, 460, 417, 447, 472, 473, 493, 595, 484, 430, 453, 452, 446, 454 }, true) g_ModelForPickupType = { nitro = 2221, repair = 2222, vehiclechange = 2223 } g_HunterID = 425 g_NextMap = "Random" g_Checkpoints = {} g_Pickups = {} g_VisiblePickups = {} g_Objects = {} function setNextMap ( mapname ) g_NextMap = mapname end addEvent ( "setNextMap", true ) addEventHandler ( "setNextMap", getRootElement(), setNextMap ) 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 function setNextNil ( dis ) g_NextMap = "Random" end addEvent ( "setNextNil", true ) addEventHandler ( "setNextNil", getRootElement(), setNextNil ) function hudSet () local screenWidth, screenHeight = guiGetScreenSize() dxDrawColorText ('Next: ' .. g_NextMap, 2+1, screenHeight - dxGetFontHeight(1, 'bankgothic')/2+1, 100+1, 100+1, tocolor ( 0, 0, 0, 255 ), 0.6, 'bankgothic', 0.6, 'left') dxDrawColorText ('#FF9900Next: #FFFFFF' .. g_NextMap, 2, screenHeight - dxGetFontHeight(1, 'bankgothic')/2, 100, 100, tocolor ( 255, 255, 255, 255 ), 0.6, 'bankgothic', 0.6, 'left') if (g_MapInfo) then dxDrawColorText ('Map: ' .. g_MapInfo.name, 2+1, screenHeight - dxGetFontHeight(2, 'bankgothic')/2+1, 100+1, 100+1, tocolor ( 0, 0, 0, 255 ), 0.6, 'bankgothic', 0.6, 'left') dxDrawColorText ('#FF9900Map: #FFFFFF' .. g_MapInfo.name, 2, screenHeight - dxGetFontHeight(2, 'bankgothic')/2, 100, 100, tocolor ( 255, 255, 255, 255 ), 0.6, 'bankgothic', 0.6, 'left') else dxDrawColorText ('Map: N/A', 2+1, screenHeight - dxGetFontHeight(2, 'bankgothic')/2.1, 100, 100, tocolor ( 0, 0, 0, 255 ), 0.6, 'bankgothic', 0.6, 'left') dxDrawColorText ('#FF9900Map: #FFFFFFRandom', 2, screenHeight - dxGetFontHeight(2, 'bankgothic')/2+1, 100+1, 100+1, tocolor ( 255, 255, 255, 255 ), 0.6, 'bankgothic', 0.6, 'left') end dxDrawColorText ('Spectators: ' .. #Spectators, 2+1, screenHeight - dxGetFontHeight(3, 'bankgothic')/2+1, 100+1, 100+1, tocolor ( 0, 0, 0, 255 ), 0.6, 'bankgothic', 0.6, 'left') dxDrawColorText ('#FF9900Spectators: #FFFFFF' .. #Spectators, 2, screenHeight - dxGetFontHeight(3, 'bankgothic')/2, 100, 100, tocolor ( 255, 255, 255, 255 ), 0.6, 'bankgothic', 0.6, 'left') end Con someone help my? Regards, RaceUnit.
  5. On my server it won't work, there is someone spectating my but is just say "None.". Can anyone help my?
  6. Okay, thanks! I did'nt know this, but i found an other spectators script which is open-source. Thanks for the information!
  7. Hello, I have downloaded the resource Spectators, and want to change the colour off the text but i can't, the code is like this: Anybody know how to change the colour? Or obfuscate the code? Regards, RaceUnit.
  8. Thanks! I'll will try it; iknow i use three same variables, but it was to test. edit: I'll tryd this code; but then the FPS won't work.. local iFPS = 0 local iFrames = 0 local iStartTick = getTickCount() function GetFPS( ) return iFPS end addEventHandler( 'onClientRender', root, function() iFrames = iFrames + 1 if getTickCount() - iStartTick >= 1000 then iFPS = iFrames iFrames = 0 iStartTick = getTickCount() end end ) addEventHandler('onClientResourceStart', g_ResRoot, function() g_Players = getElementsByType('player') fadeCamera(false,0.0) -- create GUI local screenWidth, screenHeight = guiGetScreenSize() g_dxGUI = { ranknum = dxText:create('', screenWidth - 60, screenHeight - 95, false, 'bankgothic', 2, 'right'), ranksuffix = dxText:create('', screenWidth - 40, screenHeight - 86, false, 'bankgothic', 1), checkpoint = dxText:create('', screenWidth - 15, screenHeight - 54, false, 'bankgothic', 0.8, 'right'), timepassed = dxText:create('0:00:00', screenWidth - 10, screenHeight - 25, false, 'bankgothic', 0.7, 'right'), mapdisplay = dxText:create('SPECTATORS: null', 2, screenHeight - dxGetFontHeight(2.3, 'bankgothic')/2, false, 'bankgothic', 0.55, 'left'), fpsdisplay = dxText:create('FPS: 0', 2, screenHeight - dxGetFontHeight(1.5, 'bankgothic')/2, false, 'bankgothic', 0.55, 'left'), mapdisplay = dxText:create('MAP: none', 2, screenHeight - dxGetFontHeight(0.7, 'bankgothic')/2, false, 'bankgothic', 0.55, 'left') } g_dxGUI.fpsdisplay:text(GetFPS())
  9. I have try that, but i don't know how to inplent in my label, this is what i have: g_dxGUI = { ranknum = dxText:create('', screenWidth - 60, screenHeight - 95, false, 'bankgothic', 2, 'right'), ranksuffix = dxText:create('', screenWidth - 40, screenHeight - 86, false, 'bankgothic', 1), checkpoint = dxText:create('', screenWidth - 15, screenHeight - 54, false, 'bankgothic', 0.8, 'right'), timepassed = dxText:create('0:00:00', screenWidth - 10, screenHeight - 25, false, 'bankgothic', 0.7, 'right'), mapdisplay = dxText:create('SPECTATORS: null', 2, screenHeight - dxGetFontHeight(2.3, 'bankgothic')/2, false, 'bankgothic', 0.55, 'left'), mapdisplay = dxText:create('FPS: null', 2, screenHeight - dxGetFontHeight(1.5, 'bankgothic')/2, false, 'bankgothic', 0.55, 'left'), mapdisplay = dxText:create('MAP: none', 2, screenHeight - dxGetFontHeight(0.7, 'bankgothic')/2, false, 'bankgothic', 0.55, 'left') } I want to change the "null" into the FPS.
  10. I did make two labels, but i don't know how to parse the FPS in the label, i already have a FPS scoreboard resource.
  11. Thanks, it worked! But can someone explain my how to show the FPS and spectators above the mapname?
  12. But i have seen some servers that have map name coloured.
  13. Now i cant see anything; i have this: g_dxGUI = { ranknum = dxText:create('1', screenWidth - 60, screenHeight - 95, false, 'bankgothic', 2, 'right'), ranksuffix = dxText:create('st', screenWidth - 40, screenHeight - 86, false, 'bankgothic', 1), checkpoint = dxText:create('0/0', screenWidth - 15, screenHeight - 54, false, 'bankgothic', 0.8, 'right'), timepassed = dxText:create('0:00:00', screenWidth - 10, screenHeight - 25, false, 'bankgothic', 0.7, 'right'), mapdisplay = dxText:create('Map: none', 2, screenHeight - dxGetFontHeight(0.7, 'bankgothic')/2, false, 'bankgothic', tocolor ( 255, 0, 0, 255 ), 0.5, 'left') }
  14. I know that, but how to change the colour, here is part off my code: g_dxGUI = { ranknum = dxText:create('1', screenWidth - 60, screenHeight - 95, false, 'bankgothic', 2, 'right'), ranksuffix = dxText:create('st', screenWidth - 40, screenHeight - 86, false, 'bankgothic', 1), checkpoint = dxText:create('0/0', screenWidth - 15, screenHeight - 54, false, 'bankgothic', 0.8, 'right'), timepassed = dxText:create('0:00:00', screenWidth - 10, screenHeight - 25, false, 'bankgothic', 0.7, 'right'), mapdisplay = dxText:create('Map: none', 2, screenHeight - dxGetFontHeight(0.7, 'bankgothic')/2, false, 'bankgothic', 0.5, 'left') } And i want 2 more lines; one with the FPS off the player and one with the spectators.
×
×
  • Create New...