About the new talkbacks, can we edit the groups directly with this?
Or for us this just to get the data for a group?Code:/** * \brief Returns a pointer to the group specification of a mesh group. * \param hMesh mesh handle * \param idx group index (>=0) * \return pointer to mesh group specification (or NULL if idx out of range) * \note \b MESHGROUP is a structure that contains the components of the * group, including vertex list, index list, texture and material index. * \note This method can be used to edit the a mesh group directly (for geometry * animation, texture animation, etc.) * \note This function should only be applied to device-independent meshes, * such as mesh templates. * \note For device-dependent mesh instances (such as returned by * \ref VESSEL::GetDevMesh) use \ref oapiEditMeshGroup instead. * \sa oapiEditMeshGroup */ OAPIFUNC MESHGROUP *oapiMeshGroup (MESHHANDLE hMesh, DWORD idx); OAPIFUNC MESHGROUP *oapiMeshGroup (DEVMESHHANDLE hMesh, DWORD idx);
Never mind that.
So I managed to come up with something that works.... sometimes. I think the "core" is good, but there's some issues to work out: doesn't work in D3D9, it updates after the first frame (instead of before) and it's still missing the "reset" part for when the visuals are re-created during the simulation. Other than that it does what it was expected. I've redone the talkback.dds texture to have bigger talkback "labels", and I'm using panel R13L for testing as it already has all the talkback groups in the correct place and they use the talkback.dds texture, so I just had to tweak the UVs of those groups in the mesh to lineup correctly.
---------- Post added at 03:13 PM ---------- Previous post was at 03:07 AM ----------
Talkback status report: fixed 2 of the 3 problems above, but it still doesn't work in D3D9. The problem seems to be the call to oapiMeshGroupEx (to get the current UVs), as it returns trash in D3D9 but works as expected in MOGE. If I use oapiMeshGroup it goes BUM in both clients.