Changing Water Plane Height

fatcoder2

16-02-2010 01:52:53

In my project, the water level can raise or lower, so I need to be able to change the water plane height (y axis) each frame.

I have tried using setPosition each frame to pass in a different y value, however doing this causes the entire water plane to centre around the origin (0,0) and it stays there unless the camera is moving. I have tried passing in the water plane's current x,z position along with my new y position, but this makes no difference. If I move the camera around, then it looks good. But as soon as I stop the camera moving, the water plane goes back to the origin (usually disappearing off screen). This behaviour only happens when trying to call setPosition each frame. Is this a bug in Hydrax or am I just doing something wrong?

archangel92

11-04-2010 17:26:25

same problem

alexxu

14-04-2010 13:57:03

you can look at the HydraxDemo.hdx
and modify the parameters
#Main options field
<vector3>Position=-5000x100x-5000 ...
in it 100 means the height of water,you can change it ,of course,this is the manual ways to change the water level.if you want to change in the application.you may use the I/Ostream to rewrite this file.
all this is my own opinion :)

archangel92

16-04-2010 19:52:15

anybody please help)
it's look like:
1) normal water level, everything is allright

2) water rising - on




all in all it's look like

what's the problem might be?

archangel92

12-05-2010 18:38:56

can anybody help?