Is there a Text3D that always points towards camera?

Hello, I was wondering if there would be a Text3D object (not ui), that would always point itself towards camera? By this I mean something like if I want to put a name on top of a character or making floating damage numbers from a hit, the text is kind of unreadable from bad angle.

I suppose I could adjust the nodes angle on every single update, but I was wondering if there is a way to combine billboards with Text3D.

edit: This at least works when called on every update, but maybe there are better ones:

    Quaternion camRot = cameraNode_->GetWorldRotation();
    for(Urho3D::Node* node : textNodes_)
        node->SetWorldRotation( camRot );

I would just make a component for that. For example, that’s exactly what’s being done in my UpgradeMachine component.

Using components definitely seems smarter way to accomplish this than having to keep a list of nodes which may or may not exist anymore in next update.

Is Text3D::SetFaceCameraMode() not sufficient? Options are enumerated in the FaceCameraMode enum, with default of FC_NONE.

1 Like

This definitely seems like what I was looking for. I figured there would be some very simple way to set the rotation according to camera. Thank you for pointing the function out.