Paul Thomas Posted February 7, 2010 Share Posted February 7, 2010 Not sure if anyone else had a problem but I couldn't hide the waterplane. I tend to set the waterplane first and then paint terrain. Extremely difficult to do with the underwater effect once I had finished painting around the water. I fixed this by changing a few things in the environment_waterplane.lua file: Remove "fw.renderer:SetWater(1)" from the object:Refresh() portion and place the "fw.renderer:SetWater(1)" under "object.model:SetKey("wavespeed","1.0") (or anywhere, just out of object:Refresh() but you can't remove it completely). Within object:SetKey(key,value) add this before "else": elseif key == "hidden" then if value == "1" then fw.renderer:SetWater(0) elseif value == "0" then fw.renderer:SetWater(1) end Hope this helps anyone. At the moment I'm unsure if the property grid changes the text to lowercase, else you may have to change it to "Hidden." I had changed my default property grid so I don't exactly remember how it was before. My default property grid for "Hidden" is: group:AddProperty("hidden", PROPERTY_BOOL, "", "Hide") I have to refresh the editor after changing the default property grid or it doesn't show up after saving. Not sure if it's just me or not. Quote Link to comment Share on other sites More sharing options...
Paul Thomas Posted February 7, 2010 Author Share Posted February 7, 2010 If your fw.renderer.DrawShadowText() isn't exposed to Lua (remove {hidden} for lugi.generator) and you want to use this function just add this (a fairly simple copy): function DrawShadowText(text, x, y) SetColor(Vec4(0, 0, 0, 1)) DrawText(text, x+1, y+1) SetColor(Vec4(1, 1, 1, 1)) DrawText(text, x, y) SetColor(Vec4(1, 1, 1, 1)) end I also added these lines within "constants/engine_const.lua" --Blending BLEND_NONE=0 BLEND_ALPHA=1 BLEND_LIGHT=2 BLEND_SHADE=3 BLEND_MOD2X=4 Didn't see it in any other Lua file. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.