pub struct VmLocation {
  pub world: bool,
  pub front: bool,
  pub child: bool,
  pub layer: u32,
}

#[allow(unused)]
impl VmLocation {
  pub fn new() -> Self {
    Self {
      world: true,
      front: false,
      child: false,
      layer: 0,
    }
  }
  pub fn new_ui() -> Self {
    Self {
      world: false,
      front: false,
      child: false,
      layer: 30,
    }
  }
  pub fn new_child(layer: u32) -> Self {
    Self {
      world: true,
      front: false,
      child: true,
      layer,
    }
  }
  pub fn new_child_ui(layer: u32) -> Self {
    Self {
      world: false,
      front: false,
      child: true,
      layer,
    }
  }
  pub fn new_front() -> Self {
    Self {
      world: true,
      front: true,
      child: false,
      layer: 0,
    }
  }
  pub fn new_ui_front() -> Self {
    Self {
      world: false,
      front: true,
      child: false,
      layer: 30,
    }
  }
  pub fn new_child_front(layer: u32) -> Self {
    Self {
      world: true,
      front: true,
      child: true,
      layer,
    }
  }
  pub fn new_child_ui_front(layer: u32) -> Self {
    Self {
      world: false,
      front: true,
      child: true,
      layer,
    }
  }
}
