Jump to content

Castillo

Retired Staff
  • Posts

    21,935
  • Joined

  • Last visited

  • Days Won

    6

Everything posted by Castillo

  1. Yes, you can disable the anti cheats individually from the "mtaserver.conf" file. You can get the anti cheat IDs from here: https://wiki.multitheftauto.com/wiki/Anticheat
  2. Castillo

    Staff Mode

    Try: setPlayerTeam ( player, getTeamFromName ( "staff" ) )
  3. Castillo

    Staff Mode

    setElementData ( Player, "class", staff) Your argument is "player" not "Player". Also, staff should be "staff".
  4. I sent you a PM with a possible fix.
  5. I don't see 'parts' getting defined in the code you posted, you should post the whole thing.
  6. Where is 'parts' defined?
  7. Castillo

    Garage id

    Can you give me the position?
  8. I can see few valhalla leaked scripts there.
  9. You can change that in the settings of the resource.
  10. I really don't get how someone can confuse GTA San Andreas with GTA V
  11. Obviously not, that's GTA Online ( GTA V ).
  12. dxDrawRectangle(x-widthPadding,y+heightPadding,nameLength,fontHeight-heightPadding*2,rectangleColor,false) Proba con ese.
  13. Castillo

    A Problem

    function MarkerHit( thePlayer ) if getElementType( thePlayer ) == "player" then Change: if getElementType( thePlayer ) == "player" then to: if ( localPlayer == thePlayer ) then
  14. setObjectScale Remember that this function will not resize the object collision.
  15. -- Settings variables local textFont = "default-bold" -- The font of the tag text local textScale = 1 -- The scale of the tag text local heightPadding = 1 -- The amount of pixels the tag should be extended on either side of the vertical axis local widthPadding = 1 -- The amount of pixels the tag should be extended on either side of the horizontal axis local xOffset = 8 -- Distance between the player blip and the tag local textAlpha = 255 -- Other variables local floor = math.floor local w, h = guiGetScreenSize ( ) function drawMapStuff ( ) if isPlayerMapVisible ( ) then local team = getPlayerTeam ( localPlayer ) if ( team ) then local sx, sy, ex, ey = getPlayerMapBoundingBox ( ) -- Map positions local mw,mh = ( ex - sx ), ( sy - ey ) -- Map width/height local cx,cy = ( sx + ex ) / 2, ( sy + ey ) / 2 -- Center position of the map local ppuX, ppuY = ( mw / 6000 ), ( mh / 6000 ) -- Pixels per unit local fontHeight = dxGetFontHeight ( textScale, textFont ) -- Height of the specified font local yOffset = ( fontHeight / 2 ) -- How much pixels the tag should be offsetted at for _, player in ipairs ( getPlayersInTeam ( team ) ) do local px, py = getElementPosition ( player ) -- Player's position local x = floor ( cx + px * ppuX + xOffset ) -- X for the nametag local y = floor ( cy + py * ppuY - yOffset ) -- Y for the nametag local pname = getPlayerName ( player ) -- Player name local nameLength = dxGetTextWidth ( pname, textScale, textFont ) -- Width of the playername local r, g, b = getPlayerNametagColor ( player ) -- Player's nametag color dxDrawText ( pname, x, y, x + nameLength, y + fontHeight, tocolor ( r, g, b, textAlpha ), textScale, textFont, "left", "top", false, false, true, true ) end end end end addEventHandler ( "onClientRender", getRootElement(), drawMapStuff )
  16. Set a 1 second timer to set the animation.
  17. The problem was that you were comparing a string with a number, since 'pedid' in your command is a string, not a number.
  18. function getPedById ( id ) if ( id ) then local peds = getElementsByType ( "ped" ) for _, v in pairs ( peds ) do local d = getElementData ( v, "ped_id__" ) if ( d == tonumber ( id ) ) then return v end end end end Try that one.
  19. And you are setting the "ped_id__" element data?
  20. Castillo

    A Problem

    triggerServerEvent("learnbox", getRootElement()) Change that getRootElement ( ) to localPlayer.
×
×
  • Create New...