mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
Fix highlighting non-collectibles
This commit is contained in:
parent
177f331259
commit
f8283116a8
@ -173,7 +173,16 @@ impl PlayState for SessionState {
|
||||
(None, None)
|
||||
}
|
||||
};
|
||||
self.scene.set_select_pos(select_pos);
|
||||
// Only highlight collectables
|
||||
self.scene.set_select_pos(select_pos.filter(|sp| {
|
||||
self.client
|
||||
.borrow()
|
||||
.state()
|
||||
.terrain()
|
||||
.get(*sp)
|
||||
.map(|b| b.is_collectible())
|
||||
.unwrap_or(false)
|
||||
}));
|
||||
|
||||
// Handle window events.
|
||||
for event in global_state.window.fetch_events(&mut global_state.settings) {
|
||||
|
Loading…
Reference in New Issue
Block a user