[][src]Struct sulis_state::Location

pub struct Location {
    pub x: i32,
    pub y: i32,
    pub area_id: String,
    pub area_width: i32,
    pub area_height: i32,
}

Fields

x: i32y: i32area_id: Stringarea_width: i32area_height: i32

Implementations

impl Location[src]

pub fn new(x: i32, y: i32, area: &Area) -> Location[src]

pub fn from_point(p: Point, area: &Area) -> Location[src]

pub fn to_point(&self) -> Point[src]

pub fn move_to(&mut self, x: i32, y: i32)[src]

pub fn coords_valid(&self, x: i32, y: i32) -> bool[src]

pub fn is_in(&self, area_state: &AreaState) -> bool[src]

pub fn is_in_area_id(&self, id: &str) -> bool[src]

Trait Implementations

impl Clone for Location[src]

impl Debug for Location[src]

impl Eq for Location[src]

impl PartialEq<Location> for Location[src]

impl StructuralEq for Location[src]

Auto Trait Implementations

impl RefUnwindSafe for Location

impl Send for Location

impl Sync for Location

impl Unpin for Location

impl UnwindSafe for Location

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<Q, K> Equivalent<K> for Q where
    K: Borrow<Q> + ?Sized,
    Q: Eq + ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 
[src]