Ma-Shell Posted January 21, 2017 Share Posted January 21, 2017 Are you using any other posteffects? If so, the order in which they are executed is important. It looks like in the first picture your image is darkened after applying the rain and in the second the darkening happens before applying the rain. Quote Link to comment Share on other sites More sharing options...
burgelkat Posted January 21, 2017 Share Posted January 21, 2017 no, i tested it with no post effect too. The same effect then Quote Link to comment Share on other sites More sharing options...
macklebee Posted January 21, 2017 Share Posted January 21, 2017 If you are using a trigger based on collision, the effect is being added more than once to the camera post effect stack. You need to add a boolean check to prevent the effect from being added more than once. example: Script.rain = false ... ... ... function Script:Change() if self.rain==false then self.rain = true self.camera:AddPostEffect("Shaders/PostEffects/Rain.shader") end end Edit - Same problem here: http://www.leadwerks.com/werkspace/topic/15421-clearposteffects-making-graphics-go-crazy/#entry103394 Quote Win7 64bit / Intel i7-2600 CPU @ 3.9 GHz / 16 GB DDR3 / NVIDIA GeForce GTX 590 LE / 3DWS / BMX / Hexagon macklebee's channel Link to comment Share on other sites More sharing options...
burgelkat Posted January 21, 2017 Share Posted January 21, 2017 It is solved thanks to Macklebee 2 Quote Link to comment Share on other sites More sharing options...
Marcousik Posted February 10, 2017 Share Posted February 10, 2017 Here is a try with inside rain collision, I made today: Edit To make this I just let about 200 or more box with Mass set to 1 with invisible material falling over the player in a randomized area: This will be used as shape for roof collision. Attach a sprite /billboard with the rain Material. Then an emitter at collision()/position for water splatsch. After colliding just put the same box over the player again and again..... The problem I found is that after 10 minutes or more it will be "Error: Run out of lua memory" I checked that the game RAM would be bigger and bigger with time. The material applied to the sprite seems to be essential in this. Seems that using a alpha texture is unfortunately too expensive. I used finally a very thin sprite with a default material shader Model/flat/default - Alpha setting + Z-sort. Seems to be the less expensive for best graphic results. Edit: Solved with collectgarbage() added in main() Now it looks like this: 1 3 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.