mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
Fill in entity_count in metrics
This commit is contained in:
@ -170,8 +170,7 @@ fn swap_inventory_loadout(
|
|||||||
}
|
}
|
||||||
|
|
||||||
fn swap_loadout(slot_a: EquipSlot, slot_b: EquipSlot, loadout: &mut Loadout) {
|
fn swap_loadout(slot_a: EquipSlot, slot_b: EquipSlot, loadout: &mut Loadout) {
|
||||||
// Ensure that the slots are not the same (somehow the voxygen does this
|
// Ensure that the slots are not the same
|
||||||
// occasionsally)
|
|
||||||
if slot_a == slot_b {
|
if slot_a == slot_b {
|
||||||
warn!("Tried to swap equip slot with itself");
|
warn!("Tried to swap equip slot with itself");
|
||||||
return;
|
return;
|
||||||
|
@ -446,6 +446,9 @@ impl Server {
|
|||||||
});
|
});
|
||||||
self.metrics.chonks_count.set(chonk_cnt as i64);
|
self.metrics.chonks_count.set(chonk_cnt as i64);
|
||||||
self.metrics.chunks_count.set(chunk_cnt as i64);
|
self.metrics.chunks_count.set(chunk_cnt as i64);
|
||||||
|
|
||||||
|
let entity_count = self.state.ecs().entities().join().count();
|
||||||
|
self.metrics.entity_count.set(entity_count as i64);
|
||||||
}
|
}
|
||||||
//self.metrics.entity_count.set(self.state.);
|
//self.metrics.entity_count.set(self.state.);
|
||||||
self.metrics
|
self.metrics
|
||||||
|
Reference in New Issue
Block a user