Hi!
With upcoming update very close and with "The next update will definitely introduce true ocean waves (including new boat behaviour of course)" i wonder if API is ready to handle the following scenario:
I use a plugin to make a boat to follow automatic route (Ferry Travel). This internally is handled by moving (teleport) the boat along some predefined route (points defined by x,z coordinate). For y axis (water level) is more ore less around 90 (depend on boat type - rowboat, sailboat, have different values).
Now questions:
- With new wave mechanic where water in a some point x,z will be dynamic (other than static 90) how i will determine correct height via API to know where to teleport a boat in a new point at surface of water?
So wee need some sort of API to can calculate real height of water (with wave corrections) in some point x,z.
Moreover this is not enough, because different boat size sink in water different depth (rowboat versus sailboat) so we need a real API function to obtain "correct" Z value so vehicle (rowboat,sailboat,etc.) can be teleported on valid,"naturally" point x,z at surface of water.
Now i move vehicle with some code like:
Vector3f target= new Vector3f(point.x,waterlevel,point.y); // target position <-- Here new API must called to get actual water level by type of vehicle
// make vehicle to look toward new target position but only if distance is greater than a min value (default 3)
Current movement of rowboat is on flat water level. So first align vehicle to target and latter move. But with real wave ... i see this like more steps:
- First align direction of vehicle to desired direction
- Second move vehicle in new location
- Last step normalize rotation (keeping aligned direction) to naturally fit current wave (this i think need to be addressed via API too!)
red51 i hope you will take in account this API additions (if is not yet some method who can achieve this scope) for new release.
Thx in advance!