pinned : gpc.pinned,
uos : pri.ui_operations(gs, gpc, ipc)?,
moveable : gpc.moveable(),
+ facehint : pri.facehint(gpc),
occregion,
};
dbgc!(pri, ipc, gpc, r);
}
}
+ pub fn facehint(&self, gpc: &GPiece) -> Option<FaceId> {
+ match self.occulted {
+ PriOcculted::Visible(_) => Some(gpc.face),
+ PriOcculted::Occulted | PriOcculted::Displaced(..) => None,
+ }
+ }
+
pub fn pos_zlevel<'r>(&'r self, gpc: &'r GPiece) -> (Pos, &'r ZLevel) {
use PriOcculted as PO;
match &self.occulted {
pub struct PreparedPieceState {
pub pos: Pos,
pub svg: Html,
+ pub facehint: Option<FaceId>,
pub held: Option<PlayerId>,
pub z: ZCoord,
pub zg: Generation,