Struct spn_rust_bot::api::ipc::IpcSelfInfo
source · [−]#[repr(C)]#[repr(align(4))]pub struct IpcSelfInfo {
pub segment_radius: f32,
pub mass: f32,
pub sight_radius: f32,
pub consume_radius: f32,
pub start_frame: u32,
pub current_frame: u32,
pub speed: f32,
pub max_step_angle: f32,
pub consumed_natural_food: f32,
pub consumed_food_hunted_by_self: f32,
pub consumed_food_hunted_by_others: f32,
}
Expand description
IPC representation of one’s own snake and current world parameters.
Fields
segment_radius: f32
Radius of your snake’s segments
mass: f32
Your Snake’s current mass
sight_radius: f32
Radius around your snake’s head in which you can see food and segments
consume_radius: f32
Radius around your snake’s head in which food is consumed.
start_frame: u32
Frame number when your snake was spawned
current_frame: u32
Current frame number
speed: f32
Distance per step
max_step_angle: f32
Maximum direction change in this step
consumed_natural_food: f32
Amount of “naturally” spawned food your snake consumed
consumed_food_hunted_by_self: f32
Amount of food you consumed and that was created from snakes you killed
consumed_food_hunted_by_others: f32
Amount of food you consumed and that was created from snakes others killed (carrion)
Auto Trait Implementations
impl RefUnwindSafe for IpcSelfInfo
impl Send for IpcSelfInfo
impl Sync for IpcSelfInfo
impl Unpin for IpcSelfInfo
impl UnwindSafe for IpcSelfInfo
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more