mirror of
https://github.com/italicsjenga/agb.git
synced 2024-12-24 00:31:34 +11:00
Fix spellings in object.rs
This commit is contained in:
parent
6274827f58
commit
0d6e6c709c
2
.vscode/settings.json
vendored
2
.vscode/settings.json
vendored
|
@ -58,6 +58,7 @@
|
||||||
"optimise",
|
"optimise",
|
||||||
"optimised",
|
"optimised",
|
||||||
"Optimiser",
|
"Optimiser",
|
||||||
|
"optimises",
|
||||||
"Paks",
|
"Paks",
|
||||||
"paletted",
|
"paletted",
|
||||||
"prioritised",
|
"prioritised",
|
||||||
|
@ -73,6 +74,7 @@
|
||||||
"SRAM",
|
"SRAM",
|
||||||
"subcrates",
|
"subcrates",
|
||||||
"subpat",
|
"subpat",
|
||||||
|
"synchronisation",
|
||||||
"syscall",
|
"syscall",
|
||||||
"syscalls",
|
"syscalls",
|
||||||
"THUMBV",
|
"THUMBV",
|
||||||
|
|
|
@ -26,7 +26,7 @@ use attributes::*;
|
||||||
|
|
||||||
/// Include this type if you call `get_object_controller` in impl block. This
|
/// Include this type if you call `get_object_controller` in impl block. This
|
||||||
/// helps you use the right lifetimes and doesn't impl Sync (using from two
|
/// helps you use the right lifetimes and doesn't impl Sync (using from two
|
||||||
/// "threads" without syncronisation is not safe), but sending to another
|
/// "threads" without synchronisation is not safe), but sending to another
|
||||||
/// "thread" is safe.
|
/// "thread" is safe.
|
||||||
#[derive(Clone, Copy)]
|
#[derive(Clone, Copy)]
|
||||||
struct ObjectControllerReference<'a> {
|
struct ObjectControllerReference<'a> {
|
||||||
|
@ -314,7 +314,7 @@ impl TagMap {
|
||||||
|
|
||||||
/// Gets a tag associated with the name. A tag in aseprite refers to a
|
/// Gets a tag associated with the name. A tag in aseprite refers to a
|
||||||
/// sequence of sprites with some metadata for how to animate it. You should
|
/// sequence of sprites with some metadata for how to animate it. You should
|
||||||
/// call this in a constant context so it is evalulated at compile time. It
|
/// call this in a constant context so it is evaluated at compile time. It
|
||||||
/// is inefficient to call this elsewhere.
|
/// is inefficient to call this elsewhere.
|
||||||
/// ```rust,no_run
|
/// ```rust,no_run
|
||||||
/// # #![no_std]
|
/// # #![no_std]
|
||||||
|
@ -376,7 +376,7 @@ impl Tag {
|
||||||
unsafe { slice::from_raw_parts(self.sprites, self.len) }
|
unsafe { slice::from_raw_parts(self.sprites, self.len) }
|
||||||
}
|
}
|
||||||
|
|
||||||
/// A single sprite refered to by index in the animation sequence.
|
/// A single sprite referred to by index in the animation sequence.
|
||||||
#[must_use]
|
#[must_use]
|
||||||
pub const fn sprite(&self, idx: usize) -> &'static Sprite {
|
pub const fn sprite(&self, idx: usize) -> &'static Sprite {
|
||||||
if idx >= self.len {
|
if idx >= self.len {
|
||||||
|
@ -667,7 +667,7 @@ struct ObjectInner {
|
||||||
}
|
}
|
||||||
|
|
||||||
struct ObjectControllerStatic {
|
struct ObjectControllerStatic {
|
||||||
_free_affine_matricies: Vec<u8>,
|
_free_affine_matrices: Vec<u8>,
|
||||||
free_object: Vec<u8>,
|
free_object: Vec<u8>,
|
||||||
shadow_oam: Vec<Option<ObjectInner>>,
|
shadow_oam: Vec<Option<ObjectInner>>,
|
||||||
z_order: Vec<u8>,
|
z_order: Vec<u8>,
|
||||||
|
@ -680,7 +680,7 @@ impl ObjectControllerStatic {
|
||||||
shadow_oam: (0..128).map(|_| None).collect(),
|
shadow_oam: (0..128).map(|_| None).collect(),
|
||||||
z_order: (0..128).collect(),
|
z_order: (0..128).collect(),
|
||||||
free_object: (0..128).collect(),
|
free_object: (0..128).collect(),
|
||||||
_free_affine_matricies: (0..32).collect(),
|
_free_affine_matrices: (0..32).collect(),
|
||||||
sprite_controller: SpriteControllerInner::new(),
|
sprite_controller: SpriteControllerInner::new(),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1033,7 +1033,7 @@ impl<'a> Object<'a> {
|
||||||
self
|
self
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Sets the z priority of the sprite. Higher priority will be dislayed
|
/// Sets the z priority of the sprite. Higher priority will be displayed
|
||||||
/// above background layers with lower priorities. No change will be seen
|
/// above background layers with lower priorities. No change will be seen
|
||||||
/// until [ObjectController::commit] is called.
|
/// until [ObjectController::commit] is called.
|
||||||
pub fn set_priority(&mut self, priority: Priority) -> &mut Self {
|
pub fn set_priority(&mut self, priority: Priority) -> &mut Self {
|
||||||
|
|
Loading…
Reference in a new issue