[][src]Struct spherro::Force

pub struct Force {
    pub x: f32,
    pub y: f32,
    pub power: f32,
    pub r: f32,
}

Fields

x: f32y: f32power: f32r: f32

Methods

impl Force[src]

pub fn new(x: f32, y: f32, power: f32, r: f32) -> Force[src]

impl Force[src]

pub fn pos(&self) -> Vector2f[src]

Trait Implementations

impl From<Force> for JsValue[src]

impl RefFromWasmAbi for Force[src]

type Abi = u32

The wasm ABI type references to Self are recovered from.

type Anchor = Ref<'static, Force>

The type that holds the reference to Self for the duration of the invocation of the function that has an &Self parameter. This is required to ensure that the lifetimes don't persist beyond one function call, and so that they remain anonymous. Read more

impl WasmDescribe for Force[src]

impl FromWasmAbi for Force[src]

type Abi = u32

The wasm ABI type that this converts from when coming back out from the ABI boundary. Read more

impl IntoWasmAbi for Force[src]

type Abi = u32

The wasm ABI type that this converts into when crossing the ABI boundary. Read more

impl OptionFromWasmAbi for Force[src]

impl OptionIntoWasmAbi for Force[src]

impl RefMutFromWasmAbi for Force[src]

type Abi = u32

Same as RefFromWasmAbi::Abi

type Anchor = RefMut<'static, Force>

Same as RefFromWasmAbi::Anchor

Auto Trait Implementations

impl Sync for Force

impl Send for Force

impl Unpin for Force

impl RefUnwindSafe for Force

impl UnwindSafe for Force

Blanket Implementations

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

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

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<T> BorrowMut<T> for T where
    T: ?Sized
[src]

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

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

impl<T> ReturnWasmAbi for T where
    T: IntoWasmAbi
[src]

type Abi = <T as IntoWasmAbi>::Abi

Same as IntoWasmAbi::Abi

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,