Jump to content

setWaterColor


Pinda

Recommended Posts

Posted

Meta

<meta>
<info gamemodes="race" type="map" name="Assassin's Bum Life" author="Assassin natuurlijk" version="1.0.0" />
<map src="Assassin-BumLife.map" dimension="0" />
<script src="client.lua" type="client" />
<settings>
<setting name="#skins" value='[ "cj" ]' />
<setting name="#maxplayers" value="[ 128 ]" />
<setting name="#gamespeed" value="[ 1 ]" />
<setting name="#ghostmode" value='[ "false" ]' />
<setting name="#time" value="12:0" />
<setting name="#vehicleweapons" value='[ "false" ]' />
<setting name="#minplayers" value="[ 0 ]" />
<setting name="#weather" value="[ 0 ]" />
<setting name="#gravity" value="[ 0.008000 ]" />
<setting name="#waveheight" value="[ 0 ]" />
<setting name="#respawntime" value="[ 5 ]" />
<setting name="#locked_time" value="[ false ]" />
<setting name="#duration" value="[ 1800 ]" />
<setting name="#respawn" value='[ "timelimit" ]' />
settings>
meta>

and client.lua

red,green,blue,alpha=0,255,0,0
addEventHandler("onClientResourceStart",getResourceRootElement(),function()
setWaterColor(red,green,blue,alpha)
end)

what i did wrong ?

Posted

Any chance you could be any less specific? The excess of detail smothers me. :P

Do NOT PM ME for help unless invited. - New MTA Script Editor

Scripting help "etiquette": understandable language, relevant code (ALL code if unsure), [Lua] tags, error messages with line numbers. Super simple stuff.

Posted

i think after he open map in editor the water color isnt changing (as script isn't fired up, just map loaded, am i right?)

OR

he want to have possibility of chaning water color in map editor.

i bet on 1 option anyway

Multi theft auto tools - replace cars and peds, move your map or compile your Lua files online!

programista php rzeszów

Need free webhosting for your small site? PM me. Need help with portforwarding? PM me. Do not PM me asking for help with scripting.

Having problems with port forwarding? Send me pm, I can do whole thing for you using TeamViewer (already helped about 20 people, no worries)!

Posted
i think after he open map in editor the water color isnt changing (as script isn't fired up, just map loaded, am i right?)

OR

he want to have possibility of chaning water color in map editor.

i bet on 1 option anyway

im not stupid so option 2 can go away xD

ok, for the detail.

i create a map, and because 1.0.0 editor has so many bugs, it crashes a lot of times. so i already edited the meta and added a client, (mods\deathmatch\resources).

when i open the editor again, i open the map. no change of water color. and when i try to test it. it wouldnt load.

Edit

is it even possible to load a client.lua in the map editor ?

Posted

f8

login your_login your_pass

start your_resource

Multi theft auto tools - replace cars and peds, move your map or compile your Lua files online!

programista php rzeszów

Need free webhosting for your small site? PM me. Need help with portforwarding? PM me. Do not PM me asking for help with scripting.

Having problems with port forwarding? Send me pm, I can do whole thing for you using TeamViewer (already helped about 20 people, no worries)!

Posted

omg you are creating maps, scripts etc etc, and you dont know what resource is??!!??!!

https://wiki.multitheftauto.com/

https://wiki.multitheftauto.com/wiki/Resources

Multi theft auto tools - replace cars and peds, move your map or compile your Lua files online!

programista php rzeszów

Need free webhosting for your small site? PM me. Need help with portforwarding? PM me. Do not PM me asking for help with scripting.

Having problems with port forwarding? Send me pm, I can do whole thing for you using TeamViewer (already helped about 20 people, no worries)!

Posted

Geez, have you refreshed the list? Just write refresh on console.

If not, check the resource again. And look for messages during the refresh.

XX3 is gone. This is my new name. :3

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