Jump to content

help again


golanu21

Recommended Posts

Posted
local x, y, z = 1361.099609375, -1658.7998046875, 12.39999961853 
fixmark = createMarker ( x, y, z, "cylinder", 3, 0, 255, 0, 255 ) 
function fixveh ( thePlayer )  
local theVehicle = getPedOccupiedVehicle (thePlayer) 
money = getPlayerMoney ( thePlayer ) 
if (money) > 4999 then 
fixVehicle ( theVehicle ) 
takePlayerMoney ( thePlayer, 5000 ) 
end 
end 
addEventHandler ( "onMarkerHit", fixmark, fixveh ) 

not work. no errors .. nothing

XajVsWV.png

168_zps269f1907.gif[Dev]BloWnRPG - We BloW the World [1%]168_zps269f1907.gif

Posted (edited)
local x, y, z = 1361.099609375, -1658.7998046875, 12.39999961853 
fixmark = createMarker ( x, y, z, "cylinder", 3, 0, 255, 0, 255 ) 
  
function fixveh ( hitElement) 
    if getElementType(hitElement) == "vehicle" then 
     local thePlayer= getVehicleOccupant(hitElement) 
        local money = getPlayerMoney ( thePlayer ) 
        if (money) >= 5000 then 
        fixVehicle ( hitElement) 
        takePlayerMoney ( thePlayer, 5000 ) 
        end 
    end 
end 
addEventHandler ( "onMarkerHit", fixmark, fixveh ) 

Edited by Guest

Diet with russian vodka, lose 3 days in one week !

Posted
not work... the marker is created but when i hit it , nothing

Try again i've fix it

Diet with russian vodka, lose 3 days in one week !

Posted
not work... the marker is created but when i hit it , nothing

Try again i've fix it

no, is not working

XajVsWV.png

168_zps269f1907.gif[Dev]BloWnRPG - We BloW the World [1%]168_zps269f1907.gif

Posted
when is need to put : server side or client side ?

Server. It works for me

Diet with russian vodka, lose 3 days in one week !

Posted

wtf .. i pput it in server side, but his took my money and then give me this error

[13:27:05] WARNING: Gamemode\fixveh.lua:9: Bad argument @ 'fixVehicle'

XajVsWV.png

168_zps269f1907.gif[Dev]BloWnRPG - We BloW the World [1%]168_zps269f1907.gif

Posted
wtf .. i pput it in server side, but his took my money and then give me this error

[13:27:05] WARNING: Gamemode\fixveh.lua:9: Bad argument @ 'fixVehicle'

Copy the code again

Diet with russian vodka, lose 3 days in one week !

Posted
local x, y, z = 1361.099609375, -1658.7998046875, 12.39999961853 
fixmark = createMarker ( x, y, z, "cylinder", 3, 0, 255, 0, 255 ) 
addEventHandler ( 
    'onMarkerHit', fixmark, 
    function ( hitElement ) 
        if (getElementType( hitElement ) == 'player' ) and getPedOccupiedVehicle( hitElement ) and getPlayerMoney( hitElement  >=5000) then 
        takePlayerMoney( hitElement, 5000) 
        fixVehicle(getPedOccupiedVehicle(hitElement)) 
        outputChatBox('** Vehicle Fixed **', hitElement, 255, 255, 0) 
    end 
end 
) 

My ingame nickname : Ops!

-DeathMatch GameMode By Ops! : 5%

Posted
blazy Code should work.

+1

But, If it wasn't working with you, Try this :

local x, y, z = 1361.099609375, -1658.7998046875, 12.39999961853 
fixmark = createMarker ( x, y, z, "cylinder", 3, 0, 255, 0, 255 ) 
  
function fixveh ( hitElement) 
    if getElementType(hitElement) == "vehicle" then 
     local thePlayer= getVehicleOccupant(hitElement) 
        local money = getPlayerMoney ( thePlayer ) 
        if (money) >= 5000 then 
        setElementHealth ( hitElement, 1000 ) 
        takePlayerMoney ( thePlayer, 5000 ) 
        end 
    end 
end 
addEventHandler ( "onMarkerHit", fixmark, fixveh ) 

" Keep Thinking Different . " - Steve Jops

--------------------

Don't send me PMs asking for help, I Won't reply !

Posted
fixVehicle Works Good :?!!

I know that, But it's not working for him for some reason !

So i thought it may work that way ...

" Keep Thinking Different . " - Steve Jops

--------------------

Don't send me PMs asking for help, I Won't reply !

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...