Anubhav Posted October 12, 2014 Share Posted October 12, 2014 Ok today I created my first shader from a tutorial. Now how should I load it? I am realy newbie in shaders please help me! Shader type: Ambient shader How I solved it: addEventHandler( "onClientResourceStart", resourceRoot, function() local s, t = dxCreateShader ( "ambient.fx" ) if not s then outputChatBox( "Shader couldn't be created! \"{SMILIES_PATH}/icon_sad.gif\" alt=\"\" title=\"Sad\" />" ) else outputChatBox( "Shader was created. Using technique " .. t ) engineApplyShaderToWorldTexture ( s, "sitem16" ) end end ) Link to comment
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now