Jump to content

Watercolor dont work


youpit

Recommended Posts

resourceRoot is unexisting, you don't define it anywhere, you can do one of the following:

local resourceRoot = getResourceRootElement(getThisResource())
addEventHandler('onClientResourceStart', resourceRoot, 
function() 
setWaterColor ( 0, 185, 255, 255 )
end 
)

or

addEventHandler('onClientResourceStart', getResourceRootElement(getThisResource()), 
function() 
setWaterColor ( 0, 185, 255, 255 )
end 
)

Link to comment

..... the color D'ont change

The exact codes is?

local resourceRoot = getResourceRootElement(getThisResource())
 
addEventHandler('onClientResourceStart', resourceRoot,
 
function()
 
  setWaterColor(255,56,192,192)
 
end
 
)

Meta

<meta>
<info author="." description="."/>
 
<script src="script.lua"/>
</meta>

Link to comment
resourceRoot is unexisting, you don't define it anywhere, you can do one of the following:
local resourceRoot = getResourceRootElement(getThisResource())
addEventHandler('onClientResourceStart', resourceRoot, 
function() 
setWaterColor ( 0, 185, 255, 255 )
end 
)

or

addEventHandler('onClientResourceStart', getResourceRootElement(getThisResource()), 
function() 
setWaterColor ( 0, 185, 255, 255 )
end 
)

Redundant. getResourceRootElement() will work just fine by itself.

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