Jump to content

Baseplate

Members
  • Posts

    1,417
  • Joined

  • Last visited

Everything posted by Baseplate

  1. marker = createMarker(1949, -1705, 13,"corona",2,0,255,0) addEventHandler("onClientMarkerHit",marker, function(hitElement) local vh = getPedOccupiedVehicle (hitElement) vehicles = {462} nm = tonumber ( math.random( #vehicles ) ) setElementModel ( vh, nm ) end) The source of onClientMarkerHit is the maker itself, use hitElement instead.
  2. Please, don't compare yourself to denny, and that resource is called votemanager.
  3. And why people should trust you?
  4. Ken 3andi modem topnet sagem, jareb username admin w passwrod admin.
  5. Make a table of hospitals coordinates, try to use getDistanceBetween3D between the hospital and player's position, then spawn the player there.
  6. Baseplate

    Users

    viewtopic.php?f=148&t=36847
  7. Baseplate

    Users

    First question, check out internal.db with SQLite browser. 2nd question, compile your client files or use fileDelete.
  8. We apologize, but we don't give any free servers anymore, you may get a free server for 48hrs tho!
  9. Baseplate

    Helping

    Emm, how to fix it then?
  10. Baseplate

    Helping

    s.lua function fixThisVehicle(driver, mechanic) if (getPedOccupiedVehicleSeat(driver) == 0) and (getTeamName(getPlayerTeam(mechanic)) == "Mechanic") then if (getPedOccupiedVehicleSeat(mechanic) > 1) then outputChatBox("You should enter near the driver to fix the vehicle!", mechanic, 255, 0, 0) end if (getPedOccupiedVehicleSeat(mechanic) == 1) then if (getElementHealth(getPedOccupiedVehicle(driver)) > 999) then outputChatBox("You don't need to repair this vehicle", mechanic, 255, 0, 0) elseif (getElementHealth(getPedOccupiedVehicle(driver)) < 1000) then local price = math.floor(1000 - getElementHealth(getPedOccupiedVehicle(driver))) if (getPlayerMoney(driver) < price) then outputChatBox("The driver have not enough money!", mechanic, 255, 0, 0) else outputChatBox("Your vehicle has been repaired for $"..price.." by "..getPlayerName(mechanic), driver, 0, 200, 0) outputChatBox("You repaired "..getPlayerName(driver).." for $"..price, mechanic, 0, 255, 0) fixVehicle(getPedOccupiedVehicle(driver)) takePlayerMoney(driver, price) givePlayerMoney(mechanic, price) for k, v in ipairs({"accelerate", "enter_exit", "handbrake"}) do toggleControl(driver,v,false) end setControlState(driver, "handbrake", true) end end end end end addEvent("fixTheVehicle", true) addEventHandler("fixTheVehicle", root, fixThisVehicle) c.lua addEventHandler("onClientGUIClick", root, function() if (source == yesMech) then triggerServerEvent("fixTheVehicle", localPlayer) guiSetVisible(mechPanel, false) showCursor(false) elseif (source == noMech) then guiSetVisible(mechPanel, false) showCursor(false) end end ) This is my current code, when I press on the "yesMech" button nothing happens.
  11. function createbTeam() bTeam = createTeam("Bodyguard", 255, 255, 255) end addEventHandler ("onResourceStart", resourceRoot, createbTeam) function payday() local players = getPlayersInTeam (bTeam) for _, v in ipairs ( players ) do mon = math.random ( 10000, 25000 ) givePlayerMoney(players, money) outputChatBox("Here is your payement.You can continue protecting to earn more. You got $ "..mon, players, 255, 255, 0) end end setTimer(payday, 1200000, 0)
  12. loop through all the players in the bodyguard team then give them the money. getPlayersInTeam givePlayerMoney
  13. Baseplate

    Statistics

    GUIEditor = { tab = {}, window = {}, tabpanel = {}, label = {} } GUIEditor.window[1] = guiCreateWindow(555, 297, 565, 436, "Panel Hráča", false) guiSetVisible(GUIEditor.window[1], false) -- You forgot to make the gui invisible guiWindowSetMovable(GUIEditor.window[1], false) guiWindowSetSizable(GUIEditor.window[1], false) GUIEditor.tabpanel[1] = guiCreateTabPanel(9, 25, 546, 401, false, GUIEditor.window[1]) GUIEditor.tab[1] = guiCreateTab("Štatistiky", GUIEditor.tabpanel[1]) GUIEditor.label[1] = guiCreateLabel(83, 41, 190, 18, "Typ", false, GUIEditor.tab[1]) guiSetFont(GUIEditor.label[1], "default-bold-small") guiLabelSetColor(GUIEditor.label[1], 0, 126, 254) GUIEditor.label[2] = guiCreateLabel(273, 41, 190, 18, "Hodnota", false, GUIEditor.tab[1]) guiSetFont(GUIEditor.label[2], "default-bold-small") guiLabelSetColor(GUIEditor.label[2], 0, 126, 254) GUIEditor.label[3] = guiCreateLabel(83, 153, 190, 18, "Výrhy", false, GUIEditor.tab[1]) GUIEditor.label[4] = guiCreateLabel(83, 125, 190, 18, "Úmrtia", false, GUIEditor.tab[1]) GUIEditor.label[5] = guiCreateLabel(83, 97, 190, 18, "Peniaze", false, GUIEditor.tab[1]) GUIEditor.label[6] = guiCreateLabel(83, 69, 190, 18, "Body", false, GUIEditor.tab[1]) GUIEditor.label[7] = guiCreateLabel(273, 125, 190, 18, "", false, GUIEditor.tab[1]) GUIEditor.label[8] = guiCreateLabel(273, 97, 190, 18, "", false, GUIEditor.tab[1]) GUIEditor.label[9] = guiCreateLabel(273, 69, 190, 18, "", false, GUIEditor.tab[1]) GUIEditor.label[10] = guiCreateLabel(273, 153, 190, 18, "", false, GUIEditor.tab[1]) GUIEditor.label[11] = guiCreateLabel(246, 283, 267, 19, "www.webstranka.tk", false, GUIEditor.tab[1]) guiSetFont(GUIEditor.label[11], "default-bold-small") GUIEditor.label[12] = guiCreateLabel(83, 181, 190, 18, "Nahraný Čas", false, GUIEditor.tab[1]) GUIEditor.label[13] = guiCreateLabel(273, 181, 190, 18, "", false, GUIEditor.tab[1]) addEventHandler("onClientRender", root, function() local playermoney = getPlayerMoney (localPlayer) -- next time use localPlayer instead of source in client side scripts local playerpoints = getElementData(localPlayer,"Points") local playertime = getElementData(localPlayer,"Playtime") local playerwins = getElementData(localPlayer,"Wins") local playerdeaths = getElementData(localPlayer,"Deaths") guiSetText (GUIEditor.label[9], "" .. playerpoints .. "") guiSetText (GUIEditor.label[8], "" .. playermoney .. "") guiSetText (GUIEditor.label[7], "" .. playerdeaths .. "") guiSetText (GUIEditor.label[10], "" .. playerwins .. "") guiSetText (GUIEditor.label[13], "" .. playertime .. "") end ) addEventHandler("onClientRender", root, function() dxDrawLine(628, 408, 925, 408, tocolor(255, 255, 255, 255), 1, true) dxDrawLine(628, 493, 925, 493, tocolor(255, 255, 255, 255), 1, true) dxDrawLine(628, 465, 925, 465, tocolor(255, 255, 255, 255), 1, true) dxDrawLine(628, 438, 925, 438, tocolor(255, 255, 255, 255), 1, true) dxDrawLine(762, 383, 762, 553, tocolor(255, 255, 255, 255), 1, true) dxDrawLine(628, 523, 925, 523, tocolor(255, 255, 255, 255), 1, true) end ) function guiToggleVisible () -- You had some issues here, fixed. guiSetVisible(GUIEditor.window[1], not guiGetVisible(GUIEditor.window[1])) showCursor(guiGetVisible(GUIEditor.window[1])) end bindKey ( "F1", "down", guiToggleVisible ) Read the comments.
  14. Besides, the internet speed on Tunisia is slow, you may lagg everywhere.
  15. And Axel is a guy who can be trusted.
×
×
  • Create New...