Jump to content

Vision

Members
  • Posts

    405
  • Joined

  • Last visited

Posts posted by Vision

  1. É o seguinte, a idéia deste script é que. quando estou fazendo o download do server eu consigo usar o comando

    /moto para pegar a moto ou um outro veiculo.

    depois que eu termino o download do servidor ele bloqueia o comando, dando o aviso de que não posso usar mais o comando

    Pois é, dificil entender, tu pede ajuda em uma coisa e depois quer outra? confuso. Boa sorte ai.

  2. function onJoin() 
    setElementData ( source, "DownMOD", true ) 
    end 
    addEventHandler("onPlayerJoin",root,onJoin) 
      
    function onDownloadFinish() 
    setElementData ( client, "DownMOD", false ) 
    end 
    addEvent("DownLoad",true) 
    addEventHandler("DownLoad",root,onDownloadFinish) 
    

    Tenta ai, e também tinha um "apóstrofo" no segundo argumento do setElementData na linha 48.

  3. local radioOn = false 
      
    function turnRadio ( command ) 
        if ( command == 'radioon' and not radioOn ) then 
            setRadioChannel ( 0 ); 
            song = playSound ( 'http://www.181.fm/stream/asx/181-power.asx', true ); 
            radioOn = true; 
        elseif ( command == 'radiooff' and radioOn ) then 
            stopSound ( song ); 
            radioOn = false; 
        end 
    end 
    addCommandHandler ( 'radioon', turnRadio ); 
    addCommandHandler ( 'radiooff', turnRadio ); 
    

  4. Try this:

    function guji ( hitElement ) 
       triggerClientEvent ( hitElement, "okno", source ) 
    end 
    addEventHandler("onMarkerHit", markerpracy, guji) 
    

  5. He wants to disable only the main chat

    local chat = true 
      
    function chatDis(thePlayer) 
       local accName = getAccountName ( getPlayerAccount ( thePlayer ) ) 
       if isObjectInACLGroup ("user."..accName, aclGetGroup ( "Admin" ) ) then 
        outputChatBox("#E3E8B7The chat has been disabled by "..getPlayerName(thePlayer)..".",root,255, 255, 255, true) 
        chat = false 
       end     
    end 
    addCommandHandler("chatoff", chatDis) 
      
    function chatEn(thePlayer) 
        local accName = getAccountName ( getPlayerAccount ( thePlayer ) ) 
        if isObjectInACLGroup ("user."..accName, aclGetGroup ( "Admin" ) ) then 
            outputChatBox("#E3E8B7The chat has been enabled by "..getPlayerName(thePlayer)..".",root,255, 255, 255, true) 
            chat = true 
        end 
    end 
    addCommandHandler("chaton", chatEn) 
      
    function onChat ( _, messageType ) 
        if ( messageType == 0 and not chat ) then 
            cancelEvent ( ) 
        end 
    end 
    addEventHandler ( "onPlayerChat", root, onChat ) 
    

    Try this.

  6. local timer 
    local engineState = false 
      
    function toggleEngine ( ) 
        local checkPlayerVehicle = getPedOccupiedVehicle ( localPlayer ) 
        if ( checkPlayerVehicle and getVehicleController ( checkPlayerVehicle ) == localPlayer ) then 
            local checkState = getVehicleEngineState ( checkPlayerVehicle ) 
            timer = setTimer ( 
                function ( ) 
                    setVehicleEngineState ( checkPlayerVehicle, not checkState ) 
                    outputChatBox ( ( checkState and 'OFF' or 'ON' ) ) 
                    engineState = false 
                end, 3000, 1 
            ) 
            engineState = true 
        end 
    end 
    bindKey ( 'I', 'down', toggleEngine ) 
      
    bindKey ( 'I', 'up', 
        function ( ) 
            if ( engineState ) then 
                if ( isTimer ( timer ) ) then 
                    killTimer ( timer ) 
                end 
                engineState = false 
            end 
        end 
    ) 
    

    Try this.

  7. ----------------------------------------------------- 
    -- script  Bases Area 51 MTA:SA Gang War 
    -- @author EufraT & TAPL 
    -- @update 28/1/2014 
    ----------------------------------------------------- 
      
    radararea2 = createRadarArea( 110.91990, 1800.89435, 200, 145, 255, 255, 255, 225 ) 
    createBlip(279.40317, 1831.25439, 7.72656,62) 
    marker2 = createMarker(298.98865, 1815.90613, 3.71094,"cylinder",2,0,0,255,255)   
    Maverick = createVehicle ( 487, 251.64256286621,1920.413574218817,640630722046 ) 
      
     addCommandHandler ( "comprar", 
    function ( player ) 
    local money = getPlayerMoney ( player ) 
    local playerTeam = getPlayerTeam ( player ) 
        if ( not playerTeam ) then 
            return 
        end 
    local r, g, b = getTeamColor ( playerTeam ) 
    local teamMates = getPlayersInTeam ( playerTeam ) 
            if(isElementWithinMarker(player,marker2)) and ( money > 1000000 )  then 
             takePlayerMoney ( player, 1000000 ) 
             setRadarAreaColor ( radararea2, r, g, b, 999 ) 
             outputChatBox ( "#FFF000 [bASE] #FF0000 Voce comprou base a base Area 51 por $1000000", player, 0, 0, 0, true ) 
            for _, v in ipairs(teamMates) do 
            outputChatBox ( "#FFF000 [bASE] #FF0000 Sua gang comprou a base #00FF00 Area 51!", v, 0, 0, 0, true ) 
            end 
            else 
            outputChatBox ( "#FFF000 [bASE] #FF0000 Voce precisa estar no centro do checkpoint e $1000000", player, 0, 0, 0, true ) 
            end 
            end) 
    

    Try this.

  8. function antinj ( p, _, jacked ) 
        local occupied = getVehicleOccupant ( source ) 
        if ( occupied == jacked ) then 
            cancelEvent() 
            outputChatBox("Tā nav labi darīt!", p ) 
        end 
    end 
    addEventHandler ( "onVehicleStartEnter", getRootElement(), antinj ) 
    

    Try this.

×
×
  • Create New...