[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [Nel] Enabling Water Pools in Client
From: |
Daniel Miller |
Subject: |
RE: [Nel] Enabling Water Pools in Client |
Date: |
Tue, 26 Feb 2002 12:30:30 +0100 |
I've observed some odd behaviour relating to the water - sometiimes its
there and sometimes its not...
- Try compiling in different modes and see if it starts working. (one of the
guys on the Ryzom team has a problem in certain build modes)
- Behaviour may be different on different machines but this remains to be
confirmed. (I've seen problems on some machines but I can't guarantee that
they were running the same executables as the machines that run OK)
We haven't looked into how to make the problem repeatable yet - when we do
we'll fix it.
Cheers
-----Original Message-----
From: address@hidden [mailto:address@hidden Behalf Of
Nicolas Vizerie
Sent: Tuesday, February 26, 2002 11:32 AM
To: address@hidden
Cc: address@hidden
Subject: Re: [Nel] Enabling Water Pools in Client
Hi Robert,
The way you proceed seems correct. Well, for now, you have to create a water
pool the way the object viewer does, since it isn't exposed by the user
interface for now. One is provided as the default if you don't create one,
however. Note that you can also edit the water pool in the object viewer and
save it, so just do a serial on the water pool then.
You must also be sure that the normal of the water is pointing towards
positives z when you create it, it can't work otherwise and will either
display nothing or garbage.
Here's the complete process anyway:
- Create a convex polygon in the x-y plane where your water surface is. Note
that the way it is tesselated force you to make it intersect the border of
the object containing the water.
- Assign it a NeL water material (see
\nel\tools\3d\plugin_max\nel_water_material.txt for details)
- Apply mapping coordinates to the surface if you use a diffuse map.
At this point you can see the surface by selecting it and clicking 'View the
scene'. A GeForce 3 or better is needed to get the water looking good, other
versions will be done later (older card are supported, but with no bump)
If you want waves on your surface :
- Create a wave maker (Geometry / NeL tools / Wave maker)
- Assign it the same ID than the water surfaces it must create waves in
- Go to the object viewer.
- Edit the water pool properties to get the waves you want (and eventually
save it). Note that a water pool is shared by several water surfaces (to
allow waves propagating from one surface to another). Waves can only be seen
when near the viewer, so you may need to adjust the parameter 'Water Unit
Size' to a higher value.
- Export the shapes and the instance groups.
Then you load it in the client, the way you did, and it should work :
UInstanceGroup *ig =
UInstanceGroup::createInstanceGroup(std::string("water.ig"));
ig->addToScene(*scene);
// setup the water pool then...
If this doesn't work, you could also check wether the shapes are found.
Hope it helps
Regards,
Nicolas Vizerie
----- Original Message -----
From: "Robert Bjarnason" <address@hidden>
To: <address@hidden>
Sent: Tuesday, February 26, 2002 12:58 PM
Subject: [Nel] Enabling Water Pools in Client
> Hi,
>
> I've been trying to get a Water Pool to work
> in a client app that is based on the Snowballs
> client. I've spent a lot of time trying to
> figure this out, my pool works fine in the
> object viewer, but not when I load it into
> the client along with the WaveMaker shape.
>
> One thing I noticed is that CWaterModel::registerBasic()
> is not called, I tried adding CScene::registerBasics ();
> and then the CWaterModel is registered... But
> no pool appears...
>
> Is it possible to enable the Water Pools using
> the UDriver concept or should I set up my Driver
> more like the ObjectViewer does it?
>
> Here is how I create the WaterPoolManager after
> and Instance Group with a WaterShape and WaveMakerShape
> has been loaded and added to the Scene:
>
> WaterPoolManager = &NL3D::GetWaterPoolManager();
>
> NL3D::CWaterPoolManager::CWaterHeightMapBuild whmb;
> whmb.ID = 0;
> whmb.Name = "Water01";
> whmb.Size = 256;
> whmb.FilterWeight = 3.0f;
> whmb.UnitSize = 0.3f;
> whmb.WavesEnabled = true;
> whmb.WaveIntensity = 1.5f;
> whmb.WavePeriod = 0.05f;
> whmb.WaveRadius = 3;
> whmb.BorderWaves = true;
> whmb.Damping = 0.99f;
>
> WaterPoolManager->createWaterPool(whmb);
> WaterPoolManager->setBlendFactor(dynamic_cast<IDriver*> (Driver), 0.1f);
>
> Any hints would be appreciated...
>
> Thanks,
> Robert Bjarnason
> address@hidden
>
>
> _______________________________________________
> Nel mailing list
> address@hidden
> http://www.nevrax.org/mailman/listinfo.cgi/nel
>
_______________________________________________
Nel mailing list
address@hidden
http://www.nevrax.org/mailman/listinfo.cgi/nel