pub struct ObjectData {
pub name: String,
pub user_type: String,
pub x: f32,
pub y: f32,
pub rotation: f32,
pub visible: bool,
pub shape: ObjectShape,
pub properties: Properties,
/* private fields */
}Expand description
Raw data belonging to an object. Used internally and for tile collisions.
Also see the TMX docs.
Fields§
§name: StringThe name of the object, which is arbitrary and set by the user.
user_type: StringThe type of the object, which is arbitrary and set by the user.
x: f32The X coordinate of this object in pixels.
y: f32The Y coordinate of this object in pixels.
rotation: f32The clockwise rotation of this object around (x,y) in degrees.
visible: boolWhether the object is shown or hidden.
shape: ObjectShapeThe object’s shape.
properties: PropertiesThe object’s custom properties as set by the user.
Implementations§
Source§impl ObjectData
impl ObjectData
Trait Implementations§
Source§impl Clone for ObjectData
impl Clone for ObjectData
Source§fn clone(&self) -> ObjectData
fn clone(&self) -> ObjectData
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ObjectData
impl Debug for ObjectData
Source§impl PartialEq for ObjectData
impl PartialEq for ObjectData
impl StructuralPartialEq for ObjectData
Auto Trait Implementations§
impl Freeze for ObjectData
impl RefUnwindSafe for ObjectData
impl Send for ObjectData
impl Sync for ObjectData
impl Unpin for ObjectData
impl UnwindSafe for ObjectData
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more