Jump to content

plzhelp


[S.K]

Recommended Posts

Posted

what is wrong here

marker = createMarker( 1355.4749755859, 251.35711669922, 19.5546875, "corona",2,0,255,0) 
  
addEventHandler("onClientMarkerHit",marker, 
function() 
    local vh = getPedOccupiedVehicle ( source ) 
    vehicles = ( 217, 499 ) 
    nm = tonumber ( math.random( #vehicles ) ) 
    setElementModel ( vh, nm )   
end) 

  • Replies 62
  • Created
  • Last Reply

Top Posters In This Topic

Posted
what is wrong here
marker = createMarker( 1355.4749755859, 251.35711669922, 19.5546875, "corona",2,0,255,0) 
  
addEventHandler("onClientMarkerHit",marker, 
function() 
    local vh = getPedOccupiedVehicle ( source ) 
    vehicles = ( 217, 499 ) 
    nm = tonumber ( math.random( #vehicles ) ) 
    setElementModel ( vh, nm )   
end) 

[lua] [lua]marker = createMarker( 1355.4749755859, 251.35711669922, 19.5546875, "corona",2,0,255,0)

The wrong is the bad explanation , what are you trying to do ?

Posted
marker = createMarker( 1355.4749755859, 251.35711669922, 19.5546875, "corona",2,0,255,0) 
vehicles = (217, 499) 
  
addEventHandler("onClientMarkerHit", marker, 
function(player) 
     if getElementType(player) == "player" and player == localPlayer then 
          local vh = getPedOccupiedVehicle(player) 
          if vh then 
               setElementModel(vh, math.random(#vehicles)) 
          end 
     end 
end) 

Posted

ok tell what is wrong at this

function createaMarker () 
 createMarker (1948.5617675781, -1711.0710449219, 13.546875,) 
end 
addEventHandler("onClientResourceRoot", root, createaMarker) 
 function guiSetOn () 
 guiSetVisible(youWindowVariableHere, true) 
 showCursor(true) 
end 
addEventHandler("onClientMarkerHit", root, guiSetOn) 

Posted
ok tell what is wrong at this
function createaMarker () 
 createMarker (1948.5617675781, -1711.0710449219, 13.546875,) 
end 
addEventHandler("onClientResourceRoot", root, createaMarker) 
 function guiSetOn () 
 guiSetVisible(youWindowVariableHere, true) 
 showCursor(true) 
end 
addEventHandler("onClientMarkerHit", root, guiSetOn) 

marker = createMarker(1948.5617675781, -1711.0710449219, 13.546875) 
  
addEventHandler("onClientMarkerHit", marker, 
function(player) 
     if player == localPlayer then 
          guiSetVisible(youWindowVariableHere, true) 
          showCursor(true) 
     end 
end) 

Posted
marker = createMarker( 1355.4749755859, 251.35711669922, 19.5546875, "corona",2,0,255,0) 
vehicles = (217, 499) 
  
addEventHandler("onClientMarkerHit", marker, 
function(player) 
     if getElementType(player) == "player" and player == localPlayer then 
          local vh = getPedOccupiedVehicle(player) 
          if vh then 
               setElementModel(vh, math.random(#vehicles)) 
          end 
     end 
end) 

Wrong.

local marker = createMarker( 1355.4749755859, 251.35711669922, 19.5546875, "corona", 2, 0, 255, 0 ); 
  
addEventHandler( "onClientMarkerHit", marker, 
    function( ele ) 
        if ( getElementType( ele ) == 'player' and ele == localPlayer then 
            local vehicle = getPedOccupiedVehicle( ele ); 
            if ( vehicle ) then 
                setElementModel( vehicle, math.random( 217, 499 ) ); 
            end 
        end 
    end 
) 

Posted
marker = createMarker( 1355.4749755859, 251.35711669922, 19.5546875, "corona",2,0,255,0) 
vehicles = (217, 499) 
  
addEventHandler("onClientMarkerHit", marker, 
function(player) 
     if getElementType(player) == "player" and player == localPlayer then 
          local vh = getPedOccupiedVehicle(player) 
          if vh then 
               setElementModel(vh, math.random(#vehicles)) 
          end 
     end 
end) 

Wrong.

local marker = createMarker( 1355.4749755859, 251.35711669922, 19.5546875, "corona", 2, 0, 255, 0 ); 
  
addEventHandler( "onClientMarkerHit", marker, 
    function( ele ) 
        if ( getElementType( ele ) == 'player' and ele == localPlayer then 
            local vehicle = getPedOccupiedVehicle( ele ); 
            if ( vehicle ) then 
                setElementModel( vehicle, math.random( 217, 499 ) ); 
            end 
        end 
    end 
) 

Wrong.

local marker = createMarker( 1355.4749755859, 251.35711669922, 19.5546875, "corona", 2, 0, 255, 0 ); 
  
addEventHandler( "onClientMarkerHit", marker, 
    function( ele ) 
        if ( getElementType( ele ) == 'player' and ele == localPlayer ) then 
            local vehicle = getPedOccupiedVehicle( ele ); 
            if ( vehicle ) then 
                setElementModel( vehicle, math.random( 400, 611 ) ); 
            end 
        end 
    end 
) 

Posted
marker = createMarker( 1355.4749755859, 251.35711669922, 19.5546875, "corona",2,0,255,0) 
vehicles = (217, 499) 
  
addEventHandler("onClientMarkerHit", marker, 
function(player) 
     if getElementType(player) == "player" and player == localPlayer then 
          local vh = getPedOccupiedVehicle(player) 
          if vh then 
               setElementModel(vh, math.random(#vehicles)) 
          end 
     end 
end) 

Wrong.

local marker = createMarker( 1355.4749755859, 251.35711669922, 19.5546875, "corona", 2, 0, 255, 0 ); 
  
addEventHandler( "onClientMarkerHit", marker, 
    function( ele ) 
        if ( getElementType( ele ) == 'player' and ele == localPlayer then 
            local vehicle = getPedOccupiedVehicle( ele ); 
            if ( vehicle ) then 
                setElementModel( vehicle, math.random( 217, 499 ) ); 
            end 
        end 
    end 
) 

Wrong.

local marker = createMarker( 1355.4749755859, 251.35711669922, 19.5546875, "corona", 2, 0, 255, 0 ); 
  
addEventHandler( "onClientMarkerHit", marker, 
    function( ele ) 
        if ( getElementType( ele ) == 'player' and ele == localPlayer ) then 
            local vehicle = getPedOccupiedVehicle( ele ); 
            if ( vehicle ) then 
                setElementModel( vehicle, math.random( 400, 611 ) ); 
            end 
        end 
    end 
) 

I just fixed the code you posted, I didn't change anything that the OP wanted to change later. Forgot to put '(', though.

Posted
ok how can i add NEw features to admin panel now

I am afraid that your knowledge won't allow you to add new features to it. Better write extensions instead.

Posted
ok how can i add NEw features to admin panel now

I am afraid that your knowledge won't allow you to add new features to it. Better write extensions instead.

Dont get it

Posted
ok how can i add NEw features to admin panel now

I am afraid that your knowledge won't allow you to add new features to it. Better write extensions instead.

Dont get it

It means you don't know how to script such stuff.

Posted

no i not like this kind scripts this is when you write /wanted then you get wanted i need a script if a player kill or try to kill him get wanted automatically

Posted
no i not like this kind scripts this is when you write /wanted then you get wanted i need a script if a player kill or try to kill him get wanted automatically

This is just an example of usage for these function, you can do whatever you want with them.

if you want it for when kill player or when player get damage you have to use these event onPlayerWasted and onPlayerDamage.

Posted
  
function playerWanted ( attacker, weapon, bodypart, loss ) 
 if ( attacker ) then 
 setPlayerWantedLevel ( attacker, getPlayerWantedLevel(attacker) +1  ) 
end 
end 
addEventHandler("onPlayerDamage", root, playerWanted) 
  

Untested, and this is the last time i'll make it for you

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.

×
×
  • Create New...