pub fn ensure_has_sent_carried_item(
    commands: Commands<'_, '_>,
    query: Query<'_, '_, (Entity, &Inventory, Option<&LastSentSelectedHotbarSlot>)>,
)Expand description
A system that makes sure that LastSentSelectedHotbarSlot is in sync with
Inventory::selected_hotbar_slot.
This is necessary to make sure that ServerboundSetCarriedItem is sent in
the right order, since it’s not allowed to happen outside of a tick.