-
Posts
1,390 -
Joined
-
Last visited
-
Days Won
1
Everything posted by HunT
-
Ok now I understand Tnx Type dxDrawText( "dxDrawText", 100, 350, 300, 350, tocolor(255,255,0), 1, myFont ) myFont = dxCreateFont( "myFont.ttf", 20 ) or local myLabel = guiCreateLabel( 100, 300, 400, 50, "GUI label", false ) myFont = guiCreateFont( "myFont.ttf", 20 ) guiSetFont( myLabel, myFont ) Ok
-
Hi All. It's possible set the custom font in Scoreboard? (dxScoreboard) I'm fail scripter with this no work: fontNames = { "default", "default-bold", "clear", "arial", "sans","pricedown", "bankgothic", "diploma", "beckett","myFont"} myFont = dxCreateFont( "myFont.ttf") and setting : defaultSettings = { ["useanimation"] = true, ["toggleable"] = false, ["showserverinfo"] = true, ["showgamemodeinfo"] = true, ["showteams"] = true, ["usecolors"] = true, ["drawspeed"] = 1.5, ["scale"] = 1, ["columnfont"] = "myFont", ["contentfont"] = "myFont", ["teamfont"] = "myFont", ["serverinfofont"] = "myFont", please help and Tnx
-
i Never use The "UP" but i realy need info about the visible nos ever . . .Tnx and sorry
-
I Have other problem i add the spec. number in the nos,but the nos image destroy on finish the nos (epic eng sorry ) This is image with nos : and this is with nos finish : This is the client from race_nos2 (c_main.lua) g_Me = getLocalPlayer() g_Root = getRootElement() g_ResRoot = getResourceRootElement() g_ScreenSize = { guiGetScreenSize() } local isEditingPosition = false c_NitroUpgradeID = 1010 g_Nos = 0 c_NosMax = 100 g_IsHoldingFire = false g_NosState = false g_NosStartTick = 0 g_ShowGauge = false g_VehicleModelID = nil g_NosRechargeTimer = nil g_NosRefillState = false g_RefillStartTick = 0 g_Settings = { DisplayGauge = true, GaugePosition = { g_ScreenSize[1] - 318, g_ScreenSize[2] - 126 }, ControlStyle = "normal", SustainOnPickup = true, NosDuration = 40, NosRechargeDelay = 40, NosRechargeDuration = 15, KeepNosOnPlayerWasted = false, KeepNosOnVehicleChange = false }; -- stops the NOS recharge timer function DisposeTimer() g_NosRefillState = false if g_NosRechargeTimer ~= nil then killTimer(g_NosRechargeTimer) g_NosRechargeTimer = nil end end function Dispose() alert("Resetting NOS...") g_Nos = 0 g_NosState = true g_VehicleModelID = nil NosStop() DisposeTimer() end function SaveVehicleNos(vehicle, sync) setElementData(vehicle, "nos", g_Nos, sync or false) end function RestoreVehicleNos() local vehicle = getPedOccupiedVehicle(g_Me) if vehicle then local vehNos = getElementData(vehicle, "nos", false) if vehNos then g_Nos = vehNos end end end function SetupEvents() alert("Re-binding events") removeEventHandler("onClientResourceStop", g_ResRoot, Dispose) removeEventHandler("onClientMapStopping", g_Me, Dispose) removeEventHandler("onClientPlayerFinish", g_Me, Dispose) addEventHandler("onClientResourceStop", g_ResRoot, Dispose) addEventHandler("onClientMapStopping", g_Me, Dispose) addEventHandler("onClientPlayerFinish", g_Me, Dispose) end addEventHandler("onClientResourceStart", g_ResRoot, function() alert("onClientResourceStart") label = guiCreateLabel(0, 0, 200, 40, "Click anywhere on the screen to\nchange gauge position", false) guiSetFont(label, "default-bold-small") guiSetVisible(label, false) loadSettingsFromFile() triggerServerEvent("onRequestNosSettings", g_Me) bindKey("vehicle_fire", "both", ToggleNOS) bindKey("vehicle_secondary_fire", "both", ToggleNOS) g_ShowGauge = true SetupEvents() RestoreVehicleNos() end ) addEventHandler("onClientMapStarting", g_Me, function() alert("onClientMapStarting") g_Nos = 0 g_NosState = false g_VehicleModelID = nil g_NosRefillState = false end ) function NosStart() local vehicle = getPedOccupiedVehicle(g_Me) if not vehicle then return end addVehicleUpgrade(vehicle, c_NitroUpgradeID) setControlState("vehicle_fire", true) g_NosState = true g_NosStartTick = getTickCount() end function NosStop() local vehicle = getPedOccupiedVehicle(g_Me) if not vehicle then return end removeVehicleUpgrade(vehicle, c_NitroUpgradeID) setControlState("vehicle_fire", false) g_NosState = false SaveVehicleNos(vehicle, true) end g_HandleNosControl = { -- hybrid-style NOS : fire once to start NOS, fire again to stop hybrid = function(state) if state == "down" then g_IsHoldingFire = true if not g_NosState then if g_Nos > 0 then NosStart() end else NosStop() end else g_IsHoldingFire = false end end, -- NFS-style NOS : hold fire to start NOS, release to stop nfs = function(state) if state == "down" then g_IsHoldingFire = true if g_Nos > 0 then NosStart() end else g_IsHoldingFire = false NosStop() end end, -- Default game style : press fire to start. normal = function(state) if state == "down" then g_IsHoldingFire = true if not g_NosState then if g_Nos > 0 then NosStart() end end else g_IsHoldingFire = false end end } function ToggleNOS(key, state) if isEditingPosition then return end local vehicle = getPedOccupiedVehicle(g_Me) if not vehicle then return end -- We don't want a passenger to control NOS, to avoid inconsistent states. local driver = getVehicleOccupant(vehicle, 0) if driver ~= g_Me then return end g_HandleNosControl[g_Settings.ControlStyle](state) end addEvent("onClientScreenFadedIn", true) addEventHandler("onClientScreenFadedIn", g_Root, function() SetupEvents() g_ShowGauge = true end ) addEvent("onClientScreenFadedOut", true) addEventHandler("onClientScreenFadedOut", g_Root, function () g_ShowGauge = false end ) function StartNosRechargeTimer() DisposeTimer() if g_Settings.NosRechargeDelay > 0 then alert("Starting gradual refill in "..g_Settings.NosRechargeDelay.." seconds.") g_NosRechargeTimer = setTimer(StartGradualRefillNos, g_Settings.NosRechargeDelay * 1000, 1, c_NosMax) elseif g_Settings.NosRechargeDelay == 0 then alert("Refilling NOS to max.") RefillNos(c_NosMax) end end function ConsumeNos() if not g_NosState then return end local vehicle = getPedOccupiedVehicle(g_Me) if not vehicle then return end local driver = getVehicleOccupant(vehicle, 0) if driver ~= g_Me then return end local nitro = getVehicleUpgradeOnSlot(vehicle, 8) if not (type(nitro) == "number" and nitro ~= 0) then return end local ConsumptionRate = c_NosMax / (FPSAvg * g_Settings.NosDuration) if g_Nos > 0 then --outputDebugString("OnConsume: State="..tostring(g_NosState).."; NOS="..g_Nos.."; Diff="..tostring(getTickCount() - g_NosStartTick).."; Fps Avg="..FPSAvg) g_Nos = g_Nos - ConsumptionRate if getTickCount() - g_NosStartTick > 20000 then NosStart() end
-
Work Tnx U are the Best AiboForcen
-
Hi All. i need help for the position nos This is 1280x960 (i want this ) And This is 800 x 800 ( Facepalm ) File Client : g_Settings = { DisplayGauge = true, GaugePosition = { g_ScreenSize[1] * 0.75, g_ScreenSize[2] * 0.87 }, ControlStyle = "normal", SustainOnPickup = true, NosDuration = 40, NosRechargeDelay = 40, NosRechargeDuration = 15, KeepNosOnPlayerWasted = true, KeepNosOnVehicleChange = true }; and dxDrawImage(g_Settings.GaugePosition[1], g_Settings.GaugePosition[2], 100, 100, "img/nos_gauge.png", 0, 0, 0, color) dxDrawImage(g_Settings.GaugePosition[1] + 45, g_Settings.GaugePosition[2] + 41, 10, 40, "img/nos_arrow.png", nosangle, 0, -11, tocolor(255, 255, 255)) Help please
-
Yep Tnx But with dxCreateScreenSource or what?
-
other image. The rettangle is not object -.- . . .no id no object . . .nothing.
-
why with shader element is possible made this? dxCreateScreenSource . . .ehmm idk
-
hi all . . .i need info about this element : the map is race-5lap8track in default maps resource race. what is? fadeCamera ?? setCameraMatrix?? and rettangle? help me please. The map have only .map and meta.xml without script.
-
Hi all . . .i have the lag problem on /refresh the resources Example i add ONE map or script in resources,enter in server and refresh the resources,but the server freeze EVERY TIME for 7/10 seconds. Why????? I remember in 1.0.5 max 1 second for this or nothing. IDK : |
-
But is possible call the "number fps" from the resource race_fps?
-
LoL realy Tnx. But This function work under 20 fps? Ok test and add else outputChatBox.
-
Tnx 60% of players in mta lag with shader effect.With this panel is possible select or no. My idea is onClientGuiClick check the fps. Example under 20 fps dont enable the function . . But is very hard for me i'm little scripter. (sorry for bad english i reply with telephone)
-
Shader Panel By PRO|Hunterix This panel active the shader water and shader vehicle or nothing on player join. (Better in Race Mode) --------------------------------------- Download Here https://community.multitheftauto.com/index.php?p= ... ls&id=3011 Panel By PRO|Race Community Main Panel Water enable effect Vehicle enable effect Close effect Warning : Many kids download my scripts and open the local server with tag PRO| (example PRO|Race 3.0 facepalm) The original server is : PRO|Race 24/7 1.1 Tnx For Download.
-
OMG u are epic Benox. Name server for play? Rate 100/10 Awesome
-
function loadMap( resource ) for id, player in ipairs( getElementsByType ( "player" ) ) do accountname = getAccountName (getPlayerAccount(player)) if isObjectInACLGroup ( "user." .. accountname, aclGetGroup ( "Admin" ) ) then createBlipAttachedTo ( player, 0, 5, hivicolor[1], hivicolor[2], hivicolor[3] ) else createBlipAttachedTo ( player, 0, 3, nillcolor[1], nillcolor[2], nillcolor[3] ) end end end function blips() setTimer(loadMap,500,1,source) end addEventHandler("onPlayerSpawn",getRootElement(),blips) Anyway i use this for admin Blip function setAdminBlip(player) local theAccount=getPlayerAccount(player) if theAccount then local accountName = getAccountName(theAccount) if isObjectInACLGroup ( "user." .. accountName, aclGetGroup ( "Admin" ) ) then createBlipAttachedTo ( player, 0, 3, 255, 100, 0, 255, 0, 99999 ) end end end function spawnAdmin() setTimer(setAdminBlip,500,1,source) end addEventHandler("onPlayerSpawn",getRootElement(),spawnAdmin) Server Side
-
Give me the example pls. im new in scriptint csmit195, thx, ill try to use resources Sorry but now job . . Later i give u the code no problem. (reply with iphone)
-
Call The Function loadMap With setTimer and event "onPlayerSpawn"
-
Server Faker PRO|RACE 24/7 3.0 IP/Port 190.140.174.162:22010 This idiot Download my Panels in Community (Shop Panel & Adim Panel) and open the server and use my name. Sure is home server,please close him.Tnx.
-
delete the file client in MTA San Andreas 1.1 / mods /deathmatch / resource (delete all resources) And Test (99% work)
-
But the script work and have the setTimer function etc. . . I have the problem for replace the png's in editor_gui example. I replace this with this in editor_gui But onPlayerSpawn show this Why??
-
Hi All. I need help for made the custom blips Radar for admins and clans . . . but i'm confuse The script work with : createBlipAttachedTo ( player, 5, 2, 0, 0, 0, 255, 0, 99999 ) and addEventHandler("onPlayerSpawn",getRootElement(),blipAdmins) But no replace the png's in editor_gui. Show the original blips Why??? Tnx for support.