Jump to content

Windows


Controlled

Recommended Posts

see that tis exmple how remove texture of vehicle from EngineApplyShaderToModel

myShader = dxCreateShader( "hello.fx" ) 
  
addEventHandler("onClientVehicleEnter", root, 
    function(thePlayer, seat) 
        local theVehicle = source 
        if seat == 0 and thePlayer == localPlayer then 
            engineApplyShaderToWorldTexture( myShader, "vehiclegrunge256", theVehicle ) 
            engineApplyShaderToWorldTexture( myShader, "?emap*", theVehicle ) 
        end 
    end 
) 
  
addEventHandler("onClientVehicleExit", root, 
    function(thePlayer, seat) 
        local theVehicle = source 
        if seat == 0 and thePlayer == localPlayer then 
            engineRemoveShaderFromWorldTexture( myShader, "vehiclegrunge256", theVehicle ) 
            engineRemoveShaderFromWorldTexture( myShader, "?emap*", theVehicle ) 
        end 
    end 
) 

Link to comment
see that tis exmple how remove texture of vehicle from EngineApplyShaderToModel
myShader = dxCreateShader( "hello.fx" ) 
  
addEventHandler("onClientVehicleEnter", root, 
    function(thePlayer, seat) 
        local theVehicle = source 
        if seat == 0 and thePlayer == localPlayer then 
            engineApplyShaderToWorldTexture( myShader, "vehiclegrunge256", theVehicle ) 
            engineApplyShaderToWorldTexture( myShader, "?emap*", theVehicle ) 
        end 
    end 
) 
  
addEventHandler("onClientVehicleExit", root, 
    function(thePlayer, seat) 
        local theVehicle = source 
        if seat == 0 and thePlayer == localPlayer then 
            engineRemoveShaderFromWorldTexture( myShader, "vehiclegrunge256", theVehicle ) 
            engineRemoveShaderFromWorldTexture( myShader, "?emap*", theVehicle ) 
        end 
    end 
) 

Any idea on how to make a shader for this?

Link to comment

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