That is because you are calling unwrap
on a feature:
let b = state.map[1][1].feature.unwrap().interact(&mut state.player);
Signature of unwrap
is:
fn unwrap(self) -> T
That means you are moving the value out of that Option
(but you don't want that), what you want is take a reference and call interact
of that:
let b = state.map[1][1].feature.get_ref().interact(&mut state.player);