Jump to content

Castillo

Retired Staff
  • Posts

    21,935
  • Joined

  • Last visited

  • Days Won

    6

Everything posted by Castillo

  1. Why would you need to use "onClientPlayerDamage"?
  2. Castillo

    help

    You're welcome.
  3. Castillo

    is this true?

    But server side scripts never get downloaded.
  4. No, it won't be synchronized, for that, you need to create the weapon on all clients, set their state on all clients, and so on.
  5. Castillo

    help

    That's because you are checking a non-existant variable to set the color. local sx,sy = guiGetScreenSize ( ) addEventHandler ( "onClientRender", root, function ( ) local playerHealth = math.floor ( getElementHealth ( localPlayer ) ) local playerArmor = math.floor ( getPedArmor ( localPlayer ) ) local hour, minutes = getTime ( ) local money = getPlayerMoney ( ) local wanted = getPlayerWantedLevel ( ) -------------------- health local hx1, hy1, hx2, hy2 = sx*(1205.0/1440),sy*(157.0/900),sx*(232.0/1440),sy*(27.0/900) local hx3, hy3, hx4, hy4 = sx*(1209.0/1440),sy*(161.0/900),playerHealth*sx*(224.0/1440)/100,sy*(19.0/900) local hx5, hy5, hx6, hy6 = sx*(1302.0/1440),sy*(150.0/900),sx*(40.0/1440),sy*(40.0/900) -------------------- Armor local ax1, ay1, ax2, ay2 = sx*(1205.0/1440),sy*(197.0/900),sx*(232.0/1440),sy*(27.0/900) local ax3, ay3, ax4, ay4 = sx*(1209.0/1440),sy*(201.0/900),playerArmor*sx*(224.0/1440)/100,sy*(19.0/900) local ax5, ay5, ax6, ay6 = sx*(1310.0/1440),sy*(202.0/900),sx*(23.0/1440),sy*(20.0/900) --------------------time local tx1, ty1, tx2, ty2 = sx*(1205.0/1440),sy*(235.0/900),sx*(232.0/1440),sy*(27.0/900) local tx5, ty5, tx6, ty6 = sx*(1310.0/1440),sy*(238.0/900),sx*(20.0/1440),sy*(20.0/900) --------------------money local mx1, my1, mx2, my2 = sx*(1205.0/1440),sy*(275.0/900),sx*(232.0/1440),sy*(27.0/900) local mx5, my5, mx6, my6 = sx*(1310.0/1440),sy*(278.0/900),sx*(20.0/1440),sy*(20.0/900) --------------------wanted local wx1, wy1, wx2, wy2 = sx*(1205.0/1440),sy*(315.0/900),sx*(232.0/1440),sy*(27.0/900) local wx5, wy5, wx6, wy6 = sx*(1310.0/1440),sy*(314.0/900),sx*(20.0/1440),sy*(20.0/900) local HealthColor = math.max(playerHealth - 250, 0)/750 local HealthColorMath = -510*(HealthColor^2) local rh, gh = math.max(math.min(HealthColorMath + 255*HealthColor + 255, 255), 0), math.max(math.min(HealthColorMath + 765*HealthColor, 255), 0) local ArmorColor = math.max(playerArmor - 250, 0)/750 local ArmorColorMath = -510*(ArmorColor^2) local ra, ga = math.max(math.min(ArmorColorMath + 255*ArmorColor + 255, 255), 0), math.max(math.min(ArmorColorMath + 765*ArmorColor, 255), 0) if ( playerHealth ) then dxDrawRectangle(hx1, hy1, hx2, hy2,tocolor(0,0,0,150),false) dxDrawRectangle(hx3, hy3, hx4, hy4,tocolor(rh,gh,0,170),false) --dxDrawImage(hx5-150, hy5+1, hx6, hy6,"images/health.png",0.0,0.0,0.0,tocolor(255,255,255,255),false) dxDrawText(""..tostring(currenthealth).."%",hx3+100, hy3-2, hx4, hy4,tocolor(255,255,255,255),1.6,"sans","left","top",false,false,false) end if ( playerArmor ) then dxDrawRectangle(ax1, ay1, ax2, ay2,tocolor(0,0,0,150),false) dxDrawRectangle(ax3, ay3, ax4, ay4,tocolor(ra,ga,0,170),false) dxDrawImage(ax5-150, ay5+1, ax6, ay6,"images/armor.png",0.0,0.0,0.0,tocolor(255,255,255,255),false) dxDrawText(""..tostring(currentarmor).."%",ax3+100, ay3-2, ax4, ay4,tocolor(255,255,255,255),1.6,"sans","left","top",false,false,false) end if ( hour ) then dxDrawRectangle(tx1, ty1, tx2, ty2,tocolor(0,0,0,150),false) dxDrawImage(tx5-150, ty5+1, tx6, ty6,"images/time.png",0.0,0.0,0.0,tocolor(255,255,255,255),false) dxDrawText(""..tostring(hour)..":"..tostring(minutes).."",tx1+100, ty1+2, tx2, ty4,tocolor(255,255,255,255),1.6,"sans","left","top",false,false,false) end if ( money ) then dxDrawRectangle(mx1, my1, mx2, my2,tocolor(0,0,0,150),false) dxDrawImage(mx5-150, my5+1, mx6, my6,"images/money.png",0.0,0.0,0.0,tocolor(255,255,255,255),false) dxDrawText("$"..tostring(money).."",mx1+100, my1+2, mx2, my4,tocolor(255,255,255,255),1.6,"sans","left","top",false,false,false) end if ( wanted ) then dxDrawRectangle(wx1, wy1, wx2, wy2,tocolor(0,0,0,150),false) dxDrawImage(wx5-150, wy5+1, wx6, wy6,"images/health.png",0.0,0.0,0.0,tocolor(255,255,255,255),false) dxDrawText(""..tostring(wanted).."",wx1+100, wy1+2, wx2, wy4,tocolor(255,255,255,255),1.6,"sans","left","top",false,false,false) end end )
  6. Castillo

    help

    What do you mean by "nothing"? could you at least explain the problem?
  7. Castillo

    is this true?

    That's a lie, server side scripts don't get downloaded, they run only on the server.
  8. Castillo

    question

    local ids = { [ 1008 ] = true, [ 1009 ] = true, [ 1010 ] = true } local sx,sy = guiGetScreenSize() local enableVehicleHealth = true local enableFuelHealth = true local enableSpeedMeter = true local enablegps = true local enablelock = true local enableengine= true local enablenitro = true addEvent( "onClientSwitchDamageMeter" ) addEventHandler( "onClientSwitchDamageMeter", root, function ( state ) enableVehicleHealth = state end ) addEvent( "onClientSwitchFuelMeter" ) addEventHandler( "onClientSwitchFuelMeter", root, function ( state ) enableFuelHealth = state end ) addEvent( "onClientSwitchSpeedMeter" ) addEventHandler( "onClientSwitchSpeedMeter", root, function ( state ) enableSpeedMeter = state end ) addEventHandler( "onClientRender", root, function() local theVehicle = getPedOccupiedVehicle ( localPlayer ) if ( theVehicle ) then local nitro = getVehicleUpgradeOnSlot ( theVehicle, 8 ) local spx, spy, spz = getElementVelocity( theVehicle ) local kphSpeed = ( spx^2 + spy^2 + spz^2 ) ^ 0.5 * 1.61 * 100 local mphSpeed = ( spx^2 + spy^2 + spz^2 ) ^ 0.5 * 100 local vehiclespeed = mphSpeed local vehicleHealth = ( getElementHealth( theVehicle ) ) local vehicleFuel = getElementData( theVehicle, "vehicleFuel" ) if ( enableVehicleHealth ) and ( enableFuelHealth ) and ( vehicleFuel ) then hx1, hy1, hx2, hy2 = sx*(1155.0/1440),sy*(857.0/900),sx*(232.0/1440),sy*(27.0/900) hx3, hy3, hx4, hy4 = sx*(1159.0/1440),sy*(861.0/900),vehicleHealth/10*sx*(224.0/1440)/100,sy*(19.0/900) hx5, hy5, hx6, hy6 = sx*(1260.0/1440),sy*(860.0/900),sx*(26.0/1440),sy*(26.0/900) elseif not ( vehicleFuel ) and ( enableVehicleHealth ) or ( enableVehicleHealth ) and not ( enableFuelHealth ) then hx1, hy1, hx2, hy2 = sx*(1155.0/1440),sy*(857.0/900),sx*(232.0/1440),sy*(27.0/900) hx3, hy3, hx4, hy4 = sx*(1159.0/1440),sy*(861.0/900),vehicleHealth/10*sx*(224.0/1440)/100,sy*(19.0/900) hx5, hy5, hx6, hy6 = sx*(1260.0/1440),sy*(860.0/900),sx*(26.0/1440),sy*(26.0/900) end if ( enableFuelHealth ) and ( enableVehicleHealth ) and ( vehicleFuel ) then fx1, fy1, fx2, fy2 = sx*(1155.0/1440),sy*(817.0/900),sx*(232.0/1440),sy*(27.0/900) fx3, fy3, fx4, fy4 = sx*(1159.0/1440),sy*(821.0/900),vehicleFuel*sx*(224.0/1440)/100,sy*(19.0/900) fx5, fy5, fx6, fy6 = sx*(1260.0/1440),sy*(820.0/900),sx*(30.0/1440),sy*(30.0/900) elseif ( vehicleFuel ) and ( enableFuelHealth ) and not ( enableVehicleHealth ) then fx1, fy1, fx2, fy2 = sx*(1155.0/1440),sy*(817.0/900),sx*(232.0/1440),sy*(27.0/900) fx3, fy3, fx4, fy4 = sx*(1159.0/1440),sy*(821.0/900),vehicleFuel*sx*(224.0/1440)/100,sy*(19.0/900) fx5, fy5, fx6, fy6 = sx*(1260.0/1440),sy*(820.0/900),sx*(26.0/1440),sy*(26.0/900) end if ( enableSpeedMeter ) then sx1, sy1, sx2, sy2 = sx*(1155.0/1440),sy*(777.0/900),sx*(232.0/1440),sy*(27.0/900) sx3, sy3, sx4, sy4 = sx*(1159.0/1440),sy*(781.0/900),vehiclespeed/1.5*sx*(224.0/1440)/100,sy*(19.0/900) sx5, sy5, sx6, sy6 = sx*(1260.0/1440),sy*(780.0/900),sx*(26.0/1440),sy*(26.0/900) local upgrades = getVehicleUpgrades ( theVehicle ) local playerX, playerY, playerZ = getElementPosition ( localPlayer ) local playerZoneName = getZoneName ( playerX, playerY, playerZ ) local currenthealth = math.floor(vehicleHealth/10) if ( vehicleHealth ) then vehHealthColor = math.max(vehicleHealth - 250, 0)/750 vehHealthColorMath = -510*(vehHealthColor^2) rh, gh = math.max(math.min(vehHealthColorMath + 255*vehHealthColor + 255, 255), 0), math.max(math.min(vehHealthColorMath + 765*vehHealthColor, 255), 0) end if ( vehicleFuel ) then theFuel = ( vehicleFuel * 10 ) vehFuelColor = math.max(theFuel - 250, 0)/750 vehFuelthColorMath = -510*(vehFuelColor^2) rf, gf = math.max(math.min(vehFuelthColorMath + 255*vehFuelColor + 255, 255), 0), math.max(math.min(vehFuelthColorMath + 750*vehFuelColor, 255), 0) end if ( vehiclespeed ) then theSpeed = ( vehiclespeed * 6.5 ) vehSpeedColor = math.max(theSpeed - 250 , 0)/750 vehSpeedColorMath = -510*(vehSpeedColor^2) rs, gs = math.max(math.min(vehSpeedColorMath + 255*vehSpeedColor + 0, 255), 0), math.max(math.min(vehSpeedColorMath + 750*vehSpeedColor, 255), 0) end if ( enableVehicleHealth ) then dxDrawRectangle(hx1, hy1, hx2, hy2,tocolor(0,0,0,150),false) dxDrawRectangle(hx3, hy3, hx4, hy4,tocolor(rh,gh,0,170),false) dxDrawImage(hx5-150, hy5-2, hx6, hy6,"images/health.png",0.0,0.0,0.0,tocolor(255,255,255,0),false) dxDrawText(""..tostring(currenthealth).."%",hx3+100, hy3-2, hx4, hy4,tocolor(255,255,255,255),1.6,"sans","left","top",false,false,false) end if ( enableFuelHealth ) and ( vehicleFuel ) then dxDrawRectangle(fx1, fy1, fx2, fy2,tocolor(0,0,0,150),false) dxDrawRectangle(fx3, fy3, fx4, fy4,tocolor(rf,gf,0,170),false) dxDrawImage(fx5-150, fy5-5, fx6, fy6,"images/fuel.png",0.0,0.0,0.0,tocolor(255,255,255,255),false) dxDrawText(""..tostring(vehicleFuel).."%",fx3+100, fy3-2, fx4, fy4,tocolor(255,255,255,255),1.6,"sans","left","top",false,false,false) end if ( enableSpeedMeter ) then dxDrawRectangle(sx1, sy1, sx2, sy2,tocolor(0,0,0,150),false) dxDrawRectangle(sx3, sy3, sx4, sy4,tocolor(rs,gs,0,170),false) dxDrawText(math.ceil(kphSpeed).." Kmh / "..math.ceil(mphSpeed).." Mph",sx*(1120/1440),sy*(779/900),sx*(1435.0/1440),sy*(857.0/900),tocolor(255,255,255,255),1.6,"sans","center","top",false,false,false) end if ( enablegps ) and ( getVehicleEngineState ( theVehicle) ) then dxDrawText(""..tostring(playerZoneName).."",sx*(1158/1440),sy*(745.0/900),sx*(1435.0/1440),sy*(850.0/900),tocolor(255,255,255,255),1.6,"sans","left","top",false,false,false) else dxDrawText("Off",sx*(1158/1440),sy*(745.0/900),sx*(1435.0/1440),sy*(850.0/900),tocolor(255,255,255,255),1.6,"sans","left","top",false,false,false) end if ( enablelock ) and ( isVehicleLocked( theVehicle ) ) or ( getElementData( theVehicle, "vehicleLocked" ) ) then dxDrawImage(sx*(1390.0/1440),sy*(817.0/900),sx*(26.0/1440),sy*(26.0/900),"images/lock.png",0.0,0.0,0.0,tocolor(250,255,255,255),false) else dxDrawImage(sx*(1390.0/1440),sy*(817.0/900),sx*(26.0/1440),sy*(26.0/900),"images/lock.png",0.0,0.0,0.0,tocolor(0,0,0,170),false) end if ( enablenitro ) and ( ids [ nitro ] ) then dxDrawImage(sx*(1390.0/1440),sy*(857.0/900),sx*(26.0/1440),sy*(26.0/900),"images/light.png",0.0,0.0,0.0,tocolor(250,255,255,255),false) else dxDrawImage(sx*(1390.0/1440),sy*(857.0/900),sx*(26.0/1440),sy*(26.0/900),"images/light.png",0.0,0.0,0.0,tocolor(0,0,0,170),false) end if ( enableengine ) and ( getVehicleEngineState ( theVehicle) ) then dxDrawImage(hx5-150, hy5-2, hx6, hy6,"images/health.png",0.0,0.0,0.0,tocolor(255,255,255,255),false) dxDrawImage(sx5-150, sy5-2, sx6, sy6,"images/speed.png",0.0,0.0,0.0,tocolor(255,255,255,255),false) dxDrawImage(sx5-150, sy5-35, sx6, sy6,"images/gps.png",0.0,0.0,0.0,tocolor(255,255,255,255),false) else dxDrawImage(hx5-150, hy5-2, hx6, hy6,"images/health.png",0.0,0.0,0.0,tocolor(0,0,0,170),false) dxDrawImage(sx5-150, sy5-2, sx6, sy6,"images/speed.png",0.0,0.0,0.0,tocolor(0,0,0,170),false) dxDrawImage(sx5-150, sy5-35, sx6, sy6,"images/gps.png",0.0,0.0,0.0,tocolor(0,0,0,170),false) end end end end )
  9. Castillo

    question

    Post your full code.
  10. Castillo

    question

    You mean if he has the nitro upgrade, show an image? if so, use: local ids = { [ 1008 ] = true, [ 1009 ] = true, [ 1010 ] = true } local nitro = getVehicleUpgradeOnSlot ( theVehicle, 8 ) if ( ids [ nitro ] ) then -- Has nitro end Not sure if it works.
  11. Castillo

    help

    local sx,sy = guiGetScreenSize ( ) addEventHandler ( "onClientRender", root, function ( ) local playerHealth = math.floor ( getElementHealth ( localPlayer ) ) local playerArmor = math.floor ( getPedArmor ( localPlayer ) ) local hour, minutes = getTime ( ) local money = getPlayerMoney ( ) local wanted = getPlayerWantedLevel ( ) -------------------- health local hx1, hy1, hx2, hy2 = sx*(1205.0/1440),sy*(157.0/900),sx*(232.0/1440),sy*(27.0/900) local hx3, hy3, hx4, hy4 = sx*(1209.0/1440),sy*(161.0/900),playerHealth*sx*(224.0/1440)/100,sy*(19.0/900) local hx5, hy5, hx6, hy6 = sx*(1302.0/1440),sy*(150.0/900),sx*(40.0/1440),sy*(40.0/900) -------------------- Armor local ax1, ay1, ax2, ay2 = sx*(1205.0/1440),sy*(197.0/900),sx*(232.0/1440),sy*(27.0/900) local ax3, ay3, ax4, ay4 = sx*(1209.0/1440),sy*(201.0/900),playerArmor*sx*(224.0/1440)/100,sy*(19.0/900) local ax5, ay5, ax6, ay6 = sx*(1310.0/1440),sy*(202.0/900),sx*(23.0/1440),sy*(20.0/900) --------------------time local tx1, ty1, tx2, ty2 = sx*(1205.0/1440),sy*(235.0/900),sx*(232.0/1440),sy*(27.0/900) local tx5, ty5, tx6, ty6 = sx*(1310.0/1440),sy*(238.0/900),sx*(20.0/1440),sy*(20.0/900) --------------------money local mx1, my1, mx2, my2 = sx*(1205.0/1440),sy*(275.0/900),sx*(232.0/1440),sy*(27.0/900) local mx5, my5, mx6, my6 = sx*(1310.0/1440),sy*(278.0/900),sx*(20.0/1440),sy*(20.0/900) --------------------wanted local wx1, wy1, wx2, wy2 = sx*(1205.0/1440),sy*(315.0/900),sx*(232.0/1440),sy*(27.0/900) local wx5, wy5, wx6, wy6 = sx*(1310.0/1440),sy*(314.0/900),sx*(20.0/1440),sy*(20.0/900) if ( playerHealthcolor ) then HealthColor = math.max(playerHealth - 250, 0)/750 HealthColorMath = -510*(HealthColor^2) rh, gh = math.max(math.min(HealthColorMath + 255*HealthColor + 255, 255), 0), math.max(math.min(HealthColorMath + 765*HealthColor, 255), 0) end if ( playerArmorcolor ) then ArmorColor = math.max(playerArmor - 250, 0)/750 ArmorColorMath = -510*(ArmorColor^2) ra, ga = math.max(math.min(ArmorColorMath + 255*ArmorColor + 255, 255), 0), math.max(math.min(ArmorColorMath + 765*ArmorColor, 255), 0) end if ( playerHealth ) then dxDrawRectangle(hx1, hy1, hx2, hy2,tocolor(0,0,0,150),false) dxDrawRectangle(hx3, hy3, hx4, hy4,tocolor(rh,gh,0,170),false) dxDrawImage(hx5-150, hy5+1, hx6, hy6,"images/health.png",0.0,0.0,0.0,tocolor(255,255,255,255),false) dxDrawText(""..tostring(currenthealth).."%",hx3+100, hy3-2, hx4, hy4,tocolor(255,255,255,255),1.6,"sans","left","top",false,false,false) end if ( playerArmor ) then dxDrawRectangle(ax1, ay1, ax2, ay2,tocolor(0,0,0,150),false) dxDrawRectangle(ax3, ay3, ax4, ay4,tocolor(ra,ga,0,170),false) dxDrawImage(ax5-150, ay5+1, ax6, ay6,"images/armor.png",0.0,0.0,0.0,tocolor(255,255,255,255),false) dxDrawText(""..tostring(currentarmor).."%",ax3+100, ay3-2, ax4, ay4,tocolor(255,255,255,255),1.6,"sans","left","top",false,false,false) end if ( hour ) then dxDrawRectangle(tx1, ty1, tx2, ty2,tocolor(0,0,0,150),false) dxDrawImage(tx5-150, ty5+1, tx6, ty6,"images/time.png",0.0,0.0,0.0,tocolor(255,255,255,255),false) dxDrawText(""..tostring(hour)..":"..tostring(minutes).."",tx1+100, ty1+2, tx2, ty4,tocolor(255,255,255,255),1.6,"sans","left","top",false,false,false) end if ( money ) then dxDrawRectangle(mx1, my1, mx2, my2,tocolor(0,0,0,150),false) dxDrawImage(mx5-150, my5+1, mx6, my6,"images/money.png",0.0,0.0,0.0,tocolor(255,255,255,255),false) dxDrawText("$"..tostring(money).."",mx1+100, my1+2, mx2, my4,tocolor(255,255,255,255),1.6,"sans","left","top",false,false,false) end if ( wanted ) then dxDrawRectangle(wx1, wy1, wx2, wy2,tocolor(0,0,0,150),false) dxDrawImage(wx5-150, wy5+1, wx6, wy6,"images/health.png",0.0,0.0,0.0,tocolor(255,255,255,255),false) dxDrawText(""..tostring(wanted).."",wx1+100, wy1+2, wx2, wy4,tocolor(255,255,255,255),1.6,"sans","left","top",false,false,false) end end )
  12. Castillo

    question

    addEventHandler ( "onClientRender", root, function ( ) local theVehicle = getPedOccupiedVehicle ( localPlayer ) if ( theVehicle ) then local color = ( isVehicleLocked ( theVehicle ) and tocolor(250,255,255,255) or tocolor(0,0,0,170) ) dxDrawImage(0,0,0,0,"images/lock.png",0.0,20,20,color,false) end end ) And what do you mean by "have nitro"?
  13. Because the script converts it. @Sasuke: Yes, it should work.
  14. What do you mean by "it can be converted"? the function only accepts seconds as ban time. @Sasuke: Multiply your "timeToBan" by 60.
  15. I helped him via P as Jaysd said, I wouldn't have posted that if I didn't help him at all.
  16. It'll sync with the server if you set it client side.
  17. But that is useless, because the banPlayer function uses seconds, not minutes.
  18. Castillo

    Help

    You're welcome.
  19. Your problem was that the function outputChatBox has an argument to use color codes, but it's disabled by default, so you must enable it ( last argument ).
  20. Where do you get: "timeBan" from?
  21. He's talking about adding more pickups to the race game mode. @NooP: At "race_client.lua": g_ModelForPickupType = { nitro = 2221, repair = 2222, vehiclechange = 2223 } To add a new one, you do: g_ModelForPickupType = { nitro = 2221, repair = 2222, vehiclechange = 2223, newname = 2224 } Same on "edf/edf.lua", "edf/edf_client.lua". And on "edf/race.edf", you gotta change this line I think: "type" type="selection:nitro,repair,vehiclechange" description="The type of pickup. Can repair the vehicle, add a Nitro, or change the player's vehicle" default="nitro" /> To something like this: "type" type="selection:nitro,repair,vehiclechange,newname" description="The type of pickup. Can repair the vehicle, add a Nitro, or change the player's vehicle" default="nitro" /> And then on "race_server.lua": addEvent('onPlayerPickUpRacePickup') addEvent('onPlayerPickUpRacePickupInternal', true) addEventHandler('onPlayerPickUpRacePickupInternal', g_Root, function(pickupID, respawntime) if checkClient( false, source, 'onPlayerPickUpRacePickupInternal' ) then return end local pickup = g_Pickups[table.find(g_Pickups, 'id', pickupID)] local vehicle = g_Vehicles[source] if not pickup or not vehicle then return end if respawntime and tonumber(respawntime) >= 50 then table.insert(unloadedPickups, pickupID) clientCall(g_Root, 'unloadPickup', pickupID) TimerManager.createTimerFor("map"):setTimer(ServerLoadPickup, tonumber(respawntime), 1, pickupID) end if pickup.type == 'repair' then fixVehicle(vehicle) elseif pickup.type == 'nitro' then addVehicleUpgrade(vehicle, 1010) elseif pickup.type == 'vehiclechange' then if getElementModel(vehicle) ~= tonumber(pickup.vehicle) then clientCall(source, 'alignVehicleWithUp') setVehicleID(vehicle, pickup.vehicle) setVehiclePaintjobAndUpgrades(vehicle, pickup.paintjob, pickup.upgrades) clientCall(source, 'vehicleChanging', g_MapOptions.classicchangez, tonumber(pickup.vehicle)) end end triggerEvent('onPlayerPickUpRacePickup', source, pickupID, pickup.type, pickup.vehicle) end ) You make your new pickup type to do whatever you want.
  22. That resource will cause the same problem as he mentioned, I know this because it happened on my server, and so far, couldn't find a way to fix this, so maybe you should wait for the MTA downloadFile function.
  23. executeSQLDropTable ( "userpanel" )
  24. To convert seconds to minutes, use this: theTimeBan = math.floor ( tonumber ( timeBan ) / 60 )
×
×
  • Create New...