Jump to content

OrbTanT

Members
  • Posts

    226
  • Joined

  • Last visited

Everything posted by OrbTanT

  1. usar root para avisar quem abandonou a gang, não vai transmitir o outputChatBox para todos os jogadores do server?
  2. OrbTanT

    table help

    Hello, I do not understand much of table, the truth is that this is the first time that I am trying to use a, someone could help me, as I can make it work or what the error the table. I wanted to make the function working as follows, each time, he sends for the outputChatBox, one of the cars that are in the table randomly Marker = createMarker(2471.04, 921.19, 9.5, "cylinder", 2.0, 0, 255, 0, 150) Blip = createBlip(2471.04, 921.19, 10.82, 55) vehicleIDS = {594, 606, 607, 611, 584, 608, 435, 450, 591, 539, 441, 464, 501, 465, 564, 472, 473, 493, 595, 484, 430, 453, 452, 446, 454, 581, 509, 481, 462, 521, 463, 510, 522, 461, 448, 468, 586, 425, 520} function transfender() outputChatBox("A transportadora está pedindo 50.000$ por "..getVehicleNameFromModel(math.random(#vehicleIDS)).." !", thePlayer, 255, 255, 255, false) end setTimer( transfender, 1000, 0)
  3. OrbTanT

    money park

    Appears on the screen that the player is not in colRectangle, the more no can check if the player has entered or exited the colRectangle local ColMoney = createColRectangle ( 2057.1384277344, -1258.0145263672, -185, 110 ) addEventHandler("onColShapeHit", ColMoney, function(elem) outputChatBox("A "..getElementType(elem).." entered in the money colshape !") end) addEventHandler("onColShapeLeave", ColMoney, function(elem) outputChatBox("A "..getElementType(elem).." left in the money colshape !") end) addEventHandler( "onResourceStart", resourceRoot, function() setTimer(colShapeMoney, 1000, 0) outputChatBox("Resource started, timer is ticking ...") end ) function colShapeMoney() local players = getElementsWithinColShape(ColMoney, "player") outputChatBox(#players.." player(s) inside the colshape ...") for k, player in ipairs(players) do givePlayerMoney(player, 3) outputChatBox("Gave $3 to "..getPlayerName(player)) end end
  4. OrbTanT

    money park

    Nothing happens. And without errors in debug.
  5. OrbTanT

    money park

    I am trying to make a place where, if the players are within the ColRectangle he iram win every 1 second money, can someone tell me why it is not working, or the error, not errors in debugscript. local ColMoney = createColRectangle ( 2057.1384277344, -1258.0145263672, -185, 110 ) function moneyzone ( thePlayer, matchingDimension ) local detection = isElementWithinColShape ( thePlayer, ColMoney ) if ( detection ) then givePlayerMoney( thePlayer, 3 ) end end function timer ( thePlayer ) setTimer( moneyzone, 1000, 1 ) end addEventHandler ( "onColShapeHit", getRootElement(), moneyzone )
  6. I am using this script to the text the administrator, emerge in the middle of the screen, more when another admin also uses, he writes the text on top of an text, how do I put, when digitize new text, he destroy the old text and displays the new? function announceScript(player, cmd, ...) local accountname = getAccountName(getPlayerAccount(player)) if ( hasObjectPermissionTo ( player, "command.mute", true ) ) then local playerName = getPlayerName(player):gsub("#%x%x%x%x%x%x", "") for id, players in ipairs(getElementsByType("player")) do local message = table.concat({...}," ") local textChat = textCreateDisplay () local textItem = textCreateTextItem( message, 0.5, 0.15, 2, 255,255 ,255 , 255, 3.2, "center", "Top", 255) textDisplayAddText ( textChat, textItem ) textDisplayAddObserver ( textChat, players ) timer = setTimer ( textDestroyTextItem, 5000, 1, textItem ) timers = setTimer ( textDestroyDisplay, 5000, 1, textChat ) end else outputChatBox(getPlayerName(player) .."#FF0000Você precisa estar logado como administrador para usar este comando!",player,255,255,255,true) end end addCommandHandler("@@", announceScript)
  7. Great idea, Even if it is possible to find out the ip, still yes would more difficult to discover.
  8. OrbTanT

    EXP script

    thanks, Nightfury =)
  9. OrbTanT

    EXP script

    How can I save the XPs and LVLs when the player exits the game and load, xp and lvl when you enter. exports.scoreboard:scoreboardAddColumn("EXP") exports.scoreboard:scoreboardAddColumn("Level") function level () for index, player in ipairs ( getElementsByType "player" ) do setElementData( player, "Level", "lvl 1") setElementData( player, "EXP", 0) end end addEventHandler("onPlayerLogin", getRootElement(), level) function levelup (ammo, killer, weapon, bodypart) local XP = getElementData(killer, "EXP") local LVL = getElementData(killer, "Level") if killer and killer ~=source then setElementData(killer, "EXP", tonumber(XP)+10) if tonumber(XP) == 100 then setElementData(killer, "Level", "lvl 2") elseif tonumber(XP) == 200 then setElementData(killer, "Level", "lvl 3") elseif tonumber(XP) == 300 then setElementData(killer, "Level", "lvl 4") elseif tonumber(XP) == 400 then setElementData(killer, "Level", "lvl 5") elseif tonumber(XP) == 500 then setElementData(killer, "Level", "lvl 6") elseif tonumber(XP) == 600 then setElementData(killer, "Level", "lvl 7") elseif tonumber(XP) == 700 then setElementData(killer, "Level", "lvl 8") elseif tonumber(XP) == 800 then setElementData(killer, "Level", "lvl 9") elseif tonumber(XP) == 900 then setElementData(killer, "Level", "lvl 10") end end end addEventHandler("onPlayerWasted", getRootElement(), levelup)
  10. OrbTanT

    EXP script

    Yes I am trying to use, your Resource, more i do not understand very well, how should I use to create the level and exp
  11. OrbTanT

    EXP script

    Is not working, create a column "level" more does not show the level of the player, right way to use setElementData? exports [ "scoreboard" ]:addScoreboardColumn ( "Level", 4 ) addCommandHandler ( "mylevel", function ( player, theLevel ) for index, player in ipairs ( getElementsByType "player" ) do local account = getAccountData ( player ) local theLevel = 1 local myExp = setAccountData ( account, player) setElementData ( player, "Level", theLevel ) end end )
  12. OrbTanT

    EXP script

    How can I leave on the scoreboard, the value of "Level". exports [ "scoreboard" ]:addScoreboardColumn ( "Level", 4 ) function level ( player, Level ) for index, player in ipairs ( getElementsByType "player" ) do local account = getAccountData ( player ) local Level = 1 local myExp = setAccountData ( account, player) end end MUST have some errors, first time with getAccountData and setAccountData.
  13. OrbTanT

    EXP script

    I can create the script only exporting functions, or do I have to have the resource of EXP_system
  14. OrbTanT

    EXP script

    Good, this is the first time that I am messing with experience, and I would like to know how can I use the function of resource exp_system Castillo, I have to download the exp_system for using or only export the functions?
  15. OrbTanT

    pickup Timer

    No, respawn 0, for he does not disappear and set a time to add the vest when it is at the up.
  16. OrbTanT

    pickup Timer

    How put a time in pickup, for when the player is at the up of the pickup, every 30 seconds he of the collect for the player. I tried to add the time more I had no result. pickup1 = createPickup ( 2511.323, -1688.844, 13.549, 1, 15, 0 ) addEventHandler("onPickupHit", pickup1, function (player) local playerTeam = getPlayerTeam(player) if (playerTeam) then local r, g, b = getTeamColor(playerTeam) local aR, aG, aB = getRadarAreaColor(GROVE) if (r == aR) and (g == aG) and (b == aB) then outputChatBox("", player, 0, 0, 0, true) else outputChatBox("#F4A460[AVISO]#F08080 Você não faz parte desta gang.", player, 0, 0, 0, true) cancelEvent() end else outputChatBox("#F4A460[AVISO]#F08080 Você não faz parte desta gang.", player, 0, 0, 0, true) cancelEvent() end end)
  17. I am using a map with the cars, out of the area and within the area
  18. This script is presenting the following error that I can't solve, when it is out of the gang and outside the area he does not enter the vehicle, and message appears, More was to occur only when entering or not in vehicle that are within the area addEventHandler("onVehicleStartEnter", getRootElement(), function (player) local playerTeam = getPlayerTeam(player) if (playerTeam) then local r, g, b = getTeamColor(playerTeam) local aR, aG, aB = getRadarAreaColor(GROVE) if (r == aR) and (g == aG) and (b == aB) then outputChatBox("", player, 0, 0, 0, true) else outputChatBox("#F4A460[AVISO]#F08080 Este veiculo pertence a gang Grove Street.", player, 0, 0, 0, true) cancelEvent() end else outputChatBox("#F4A460[AVISO]#F08080 Este veiculo pertence a gang Grove Street.", player, 0, 0, 0, true) cancelEvent() end end)
  19. OrbTanT

    pickup hit

    I tried to use this script, more is not working client function onPickupHitShow ( thePlayer ) local pickupType = getPickupType ( source ) local x, y, z = getElementPosition(localPlayer) if (pickupType == 1) then fxAddSparks( x, y, z, x+10, y+10, z+10) end end addEventHandler ( "onPickupHit", getRootElement(), onPickupHitShow ) server c4 = createPickup ( 2511.323, -1688.844, 13.549, 1, 15, 0 ) addEventHandler("onPickupHit", c4, function (player) local playerTeam = getPlayerTeam(player) if (playerTeam) then local r, g, b = getTeamColor(playerTeam) local aR, aG, aB = getRadarAreaColor(GROVE) if (r == aR) and (g == aG) and (b == aB) then outputChatBox("", player, 0, 0, 0, true) else outputChatBox("#F4A460[AVISO]#F08080 Você não faz parte desta gang.", player, 0, 0, 0, true) cancelEvent() end else outputChatBox("#F4A460[AVISO]#F08080 Você não faz parte desta gang.", player, 0, 0, 0, true) cancelEvent() end end)
  20. OrbTanT

    pickup hit

    It is possible to put some kind of effect on pickup in version 1.3.5
×
×
  • Create New...