diff --git a/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_core.rs b/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_core.rs index 870b902312..081708bbfc 100644 --- a/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_core.rs +++ b/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_core.rs @@ -8,7 +8,7 @@ use bevy_mod_scripting_core::{ AddContextInitializer, StoreDocumentation, bindings::{ReflectReference, function::from::{Ref, Mut, Val}}, }; -use crate::*; +use crate::{*, namespaced_register::NamespaceBuilder}; pub struct BevyCoreScriptingPlugin; impl ::bevy::app::Plugin for BevyCoreScriptingPlugin { fn build(&self, app: &mut ::bevy::prelude::App) { @@ -20,10 +20,7 @@ impl ::bevy::app::Plugin for BevyCoreScriptingPlugin { _self: Ref, other: Ref| { - let output: bool = ::bevy::core::prelude::Name::eq( - _self.into(), - other.into(), - ) + let output: bool = ::bevy::core::prelude::Name::eq(&_self, &other) .into(); output }, @@ -32,7 +29,7 @@ impl ::bevy::app::Plugin for BevyCoreScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::core::prelude::Name::clone( - _self.into(), + &_self, ) .into(); output diff --git a/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_ecs.rs b/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_ecs.rs index 6bf900abf5..5a169ace0c 100644 --- a/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_ecs.rs +++ b/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_ecs.rs @@ -7,17 +7,38 @@ use bevy_mod_scripting_core::{ AddContextInitializer, StoreDocumentation, bindings::{ReflectReference, function::from::{Ref, Mut, Val}}, }; -use crate::*; +use crate::{*, namespaced_register::NamespaceBuilder}; pub struct BevyEcsScriptingPlugin; impl ::bevy::app::Plugin for BevyEcsScriptingPlugin { fn build(&self, app: &mut ::bevy::prelude::App) { let mut world = app.world_mut(); NamespaceBuilder::<::bevy::ecs::entity::Entity>::new(world) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::ecs::entity::Entity::clone( + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "eq", + | + _self: Ref, + other: Ref| + { + let output: bool = ::bevy::ecs::entity::Entity::eq(&_self, &other) + .into(); + output + }, + ) .overwrite_script_function( "from_raw", |index: u32| { let output: Val = ::bevy::ecs::entity::Entity::from_raw( - index.into(), + index, ) .into(); output @@ -35,7 +56,7 @@ impl ::bevy::app::Plugin for BevyEcsScriptingPlugin { "from_bits", |bits: u64| { let output: Val = ::bevy::ecs::entity::Entity::from_bits( - bits.into(), + bits, ) .into(); output @@ -58,30 +79,6 @@ impl ::bevy::app::Plugin for BevyEcsScriptingPlugin { .into(); output }, - ) - .overwrite_script_function( - "eq", - | - _self: Ref, - other: Ref| - { - let output: bool = ::bevy::ecs::entity::Entity::eq( - _self.into(), - other.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::ecs::entity::Entity::clone( - _self.into(), - ) - .into(); - output - }, ); NamespaceBuilder::<::bevy::ecs::world::OnAdd>::new(world); NamespaceBuilder::<::bevy::ecs::world::OnInsert>::new(world); @@ -95,8 +92,8 @@ impl ::bevy::app::Plugin for BevyEcsScriptingPlugin { other: Ref| { let output: bool = ::bevy::ecs::component::ComponentId::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -106,27 +103,7 @@ impl ::bevy::app::Plugin for BevyEcsScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::ecs::component::ComponentId::clone( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "new", - |index: usize| { - let output: Val = ::bevy::ecs::component::ComponentId::new( - index.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "index", - |_self: Val| { - let output: usize = ::bevy::ecs::component::ComponentId::index( - _self.into(), + &_self, ) .into(); output @@ -136,52 +113,38 @@ impl ::bevy::app::Plugin for BevyEcsScriptingPlugin { "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::bevy::ecs::component::ComponentId::assert_receiver_is_total_eq( - _self.into(), - ) - .into(); - output - }, - ); - NamespaceBuilder::<::bevy::ecs::component::Tick>::new(world) - .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::ecs::component::Tick::assert_receiver_is_total_eq( - _self.into(), + &_self, ) .into(); output }, ) .overwrite_script_function( - "eq", - | - _self: Ref, - other: Ref| - { - let output: bool = ::bevy::ecs::component::Tick::eq( - _self.into(), - other.into(), + "new", + |index: usize| { + let output: Val = ::bevy::ecs::component::ComponentId::new( + index, ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::ecs::component::Tick::clone( + "index", + |_self: Val| { + let output: usize = ::bevy::ecs::component::ComponentId::index( _self.into(), ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::ecs::component::Tick>::new(world) .overwrite_script_function( "new", |tick: u32| { let output: Val = ::bevy::ecs::component::Tick::new( - tick.into(), + tick, ) .into(); output @@ -198,10 +161,7 @@ impl ::bevy::app::Plugin for BevyEcsScriptingPlugin { .overwrite_script_function( "set", |_self: Mut, tick: u32| { - let output: () = ::bevy::ecs::component::Tick::set( - _self.into(), - tick.into(), - ) + let output: () = ::bevy::ecs::component::Tick::set(&mut_self, tick) .into(); output }, @@ -221,18 +181,39 @@ impl ::bevy::app::Plugin for BevyEcsScriptingPlugin { .into(); output }, - ); - NamespaceBuilder::<::bevy::ecs::component::ComponentTicks>::new(world) + ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::ecs::component::ComponentTicks::clone( - _self.into(), + "eq", + | + _self: Ref, + other: Ref| + { + let output: bool = ::bevy::ecs::component::Tick::eq(&_self, &other) + .into(); + output + }, + ) + .overwrite_script_function( + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::ecs::component::Tick::assert_receiver_is_total_eq( + &_self, ) .into(); output }, ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::ecs::component::Tick::clone( + &_self, + ) + .into(); + output + }, + ); + NamespaceBuilder::<::bevy::ecs::component::ComponentTicks>::new(world) .overwrite_script_function( "is_added", | @@ -241,7 +222,7 @@ impl ::bevy::app::Plugin for BevyEcsScriptingPlugin { this_run: Val| { let output: bool = ::bevy::ecs::component::ComponentTicks::is_added( - _self.into(), + &_self, last_run.into(), this_run.into(), ) @@ -257,7 +238,7 @@ impl ::bevy::app::Plugin for BevyEcsScriptingPlugin { this_run: Val| { let output: bool = ::bevy::ecs::component::ComponentTicks::is_changed( - _self.into(), + &_self, last_run.into(), this_run.into(), ) @@ -282,19 +263,29 @@ impl ::bevy::app::Plugin for BevyEcsScriptingPlugin { change_tick: Val| { let output: () = ::bevy::ecs::component::ComponentTicks::set_changed( - _self.into(), + &mut_self, change_tick.into(), ) .into(); output }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::ecs::component::ComponentTicks::clone( + &_self, + ) + .into(); + output + }, ); NamespaceBuilder::<::bevy::ecs::identifier::Identifier>::new(world) .overwrite_script_function( "clone", |_self: Ref| { let output: Val = ::bevy::ecs::identifier::Identifier::clone( - _self.into(), + &_self, ) .into(); output @@ -334,7 +325,7 @@ impl ::bevy::app::Plugin for BevyEcsScriptingPlugin { "from_bits", |value: u64| { let output: Val = ::bevy::ecs::identifier::Identifier::from_bits( - value.into(), + value, ) .into(); output @@ -347,8 +338,8 @@ impl ::bevy::app::Plugin for BevyEcsScriptingPlugin { other: Ref| { let output: bool = ::bevy::ecs::identifier::Identifier::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -359,7 +350,7 @@ impl ::bevy::app::Plugin for BevyEcsScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::ecs::entity::EntityHash::clone( - _self.into(), + &_self, ) .into(); output @@ -374,7 +365,7 @@ impl ::bevy::app::Plugin for BevyEcsScriptingPlugin { let output: Val< bevy::ecs::removal_detection::RemovedComponentEntity, > = ::bevy::ecs::removal_detection::RemovedComponentEntity::clone( - _self.into(), + &_self, ) .into(); output diff --git a/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_hierarchy.rs b/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_hierarchy.rs index faa3ed7af6..67d78778d3 100644 --- a/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_hierarchy.rs +++ b/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_hierarchy.rs @@ -9,7 +9,7 @@ use bevy_mod_scripting_core::{ AddContextInitializer, StoreDocumentation, bindings::{ReflectReference, function::from::{Ref, Mut, Val}}, }; -use crate::*; +use crate::{*, namespaced_register::NamespaceBuilder}; pub struct BevyHierarchyScriptingPlugin; impl ::bevy::app::Plugin for BevyHierarchyScriptingPlugin { fn build(&self, app: &mut ::bevy::prelude::App) { @@ -23,9 +23,9 @@ impl ::bevy::app::Plugin for BevyHierarchyScriptingPlugin { b_index: usize| { let output: () = ::bevy::hierarchy::prelude::Children::swap( - _self.into(), - a_index.into(), - b_index.into(), + &mut_self, + a_index, + b_index, ) .into(); output @@ -36,7 +36,7 @@ impl ::bevy::app::Plugin for BevyHierarchyScriptingPlugin { "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::bevy::hierarchy::prelude::Parent::assert_receiver_is_total_eq( - _self.into(), + &_self, ) .into(); output @@ -49,24 +49,14 @@ impl ::bevy::app::Plugin for BevyHierarchyScriptingPlugin { other: Ref| { let output: bool = ::bevy::hierarchy::prelude::Parent::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output }, ); NamespaceBuilder::<::bevy::hierarchy::HierarchyEvent>::new(world) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::hierarchy::HierarchyEvent::clone( - _self.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "eq", | @@ -74,8 +64,18 @@ impl ::bevy::app::Plugin for BevyHierarchyScriptingPlugin { other: Ref| { let output: bool = ::bevy::hierarchy::HierarchyEvent::eq( - _self.into(), - other.into(), + &_self, + &other, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::hierarchy::HierarchyEvent::clone( + &_self, ) .into(); output @@ -85,7 +85,7 @@ impl ::bevy::app::Plugin for BevyHierarchyScriptingPlugin { "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::bevy::hierarchy::HierarchyEvent::assert_receiver_is_total_eq( - _self.into(), + &_self, ) .into(); output diff --git a/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_input.rs b/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_input.rs index db3d2207c3..9a0785920b 100644 --- a/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_input.rs +++ b/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_input.rs @@ -10,7 +10,7 @@ use bevy_mod_scripting_core::{ AddContextInitializer, StoreDocumentation, bindings::{ReflectReference, function::from::{Ref, Mut, Val}}, }; -use crate::*; +use crate::{*, namespaced_register::NamespaceBuilder}; pub struct BevyInputScriptingPlugin; impl ::bevy::app::Plugin for BevyInputScriptingPlugin { fn build(&self, app: &mut ::bevy::prelude::App) { @@ -20,7 +20,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "vendor_id", |_self: Ref| { let output: std::option::Option = ::bevy::input::gamepad::Gamepad::vendor_id( - _self.into(), + &_self, ) .into(); output @@ -30,7 +30,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "product_id", |_self: Ref| { let output: std::option::Option = ::bevy::input::gamepad::Gamepad::product_id( - _self.into(), + &_self, ) .into(); output @@ -43,7 +43,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { button_type: Val| { let output: bool = ::bevy::input::gamepad::Gamepad::pressed( - _self.into(), + &_self, button_type.into(), ) .into(); @@ -57,7 +57,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { button_type: Val| { let output: bool = ::bevy::input::gamepad::Gamepad::just_pressed( - _self.into(), + &_self, button_type.into(), ) .into(); @@ -71,7 +71,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { button_type: Val| { let output: bool = ::bevy::input::gamepad::Gamepad::just_released( - _self.into(), + &_self, button_type.into(), ) .into(); @@ -83,7 +83,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::bevy::input::gamepad::GamepadAxis::assert_receiver_is_total_eq( - _self.into(), + &_self, ) .into(); output @@ -96,8 +96,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::gamepad::GamepadAxis::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -107,7 +107,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::gamepad::GamepadAxis::clone( - _self.into(), + &_self, ) .into(); output @@ -121,28 +121,28 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::gamepad::GamepadButton::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output }, ) .overwrite_script_function( - "clone", + "assert_receiver_is_total_eq", |_self: Ref| { - let output: Val = ::bevy::input::gamepad::GamepadButton::clone( - _self.into(), + let output: () = ::bevy::input::gamepad::GamepadButton::assert_receiver_is_total_eq( + &_self, ) .into(); output }, ) .overwrite_script_function( - "assert_receiver_is_total_eq", + "clone", |_self: Ref| { - let output: () = ::bevy::input::gamepad::GamepadButton::assert_receiver_is_total_eq( - _self.into(), + let output: Val = ::bevy::input::gamepad::GamepadButton::clone( + &_self, ) .into(); output @@ -153,13 +153,23 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::gamepad::GamepadSettings::clone( - _self.into(), + &_self, ) .into(); output }, ); NamespaceBuilder::<::bevy::input::keyboard::KeyCode>::new(world) + .overwrite_script_function( + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::input::keyboard::KeyCode::assert_receiver_is_total_eq( + &_self, + ) + .into(); + output + }, + ) .overwrite_script_function( "eq", | @@ -167,8 +177,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::keyboard::KeyCode::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -178,28 +188,28 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::keyboard::KeyCode::clone( - _self.into(), + &_self, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::input::mouse::MouseButton>::new(world) .overwrite_script_function( "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::input::keyboard::KeyCode::assert_receiver_is_total_eq( - _self.into(), + |_self: Ref| { + let output: () = ::bevy::input::mouse::MouseButton::assert_receiver_is_total_eq( + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::input::mouse::MouseButton>::new(world) + ) .overwrite_script_function( - "assert_receiver_is_total_eq", + "clone", |_self: Ref| { - let output: () = ::bevy::input::mouse::MouseButton::assert_receiver_is_total_eq( - _self.into(), + let output: Val = ::bevy::input::mouse::MouseButton::clone( + &_self, ) .into(); output @@ -212,18 +222,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::mouse::MouseButton::eq( - _self.into(), - other.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::input::mouse::MouseButton::clone( - _self.into(), + &_self, + &other, ) .into(); output @@ -234,7 +234,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::touch::TouchInput::clone( - _self.into(), + &_self, ) .into(); output @@ -247,8 +247,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::touch::TouchInput::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -259,7 +259,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::keyboard::KeyboardFocusLost::clone( - _self.into(), + &_self, ) .into(); output @@ -269,7 +269,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::bevy::input::keyboard::KeyboardFocusLost::assert_receiver_is_total_eq( - _self.into(), + &_self, ) .into(); output @@ -282,14 +282,24 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::keyboard::KeyboardFocusLost::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output }, ); NamespaceBuilder::<::bevy::input::keyboard::KeyboardInput>::new(world) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::input::keyboard::KeyboardInput::clone( + &_self, + ) + .into(); + output + }, + ) .overwrite_script_function( "eq", | @@ -297,34 +307,34 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::keyboard::KeyboardInput::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output }, ) .overwrite_script_function( - "clone", + "assert_receiver_is_total_eq", |_self: Ref| { - let output: Val = ::bevy::input::keyboard::KeyboardInput::clone( - _self.into(), + let output: () = ::bevy::input::keyboard::KeyboardInput::assert_receiver_is_total_eq( + &_self, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::input::mouse::AccumulatedMouseMotion>::new(world) .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::input::keyboard::KeyboardInput::assert_receiver_is_total_eq( - _self.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::input::mouse::AccumulatedMouseMotion::clone( + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::input::mouse::AccumulatedMouseMotion>::new(world) + ) .overwrite_script_function( "eq", | @@ -332,18 +342,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::mouse::AccumulatedMouseMotion::eq( - _self.into(), - other.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::input::mouse::AccumulatedMouseMotion::clone( - _self.into(), + &_self, + &other, ) .into(); output @@ -354,7 +354,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::mouse::AccumulatedMouseScroll::clone( - _self.into(), + &_self, ) .into(); output @@ -367,8 +367,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::mouse::AccumulatedMouseScroll::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -376,14 +376,10 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { ); NamespaceBuilder::<::bevy::input::mouse::MouseButtonInput>::new(world) .overwrite_script_function( - "eq", - | - _self: Ref, - other: Ref| - { - let output: bool = ::bevy::input::mouse::MouseButtonInput::eq( - _self.into(), - other.into(), + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::input::mouse::MouseButtonInput::assert_receiver_is_total_eq( + &_self, ) .into(); output @@ -393,17 +389,21 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::mouse::MouseButtonInput::clone( - _self.into(), + &_self, ) .into(); output }, ) .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::input::mouse::MouseButtonInput::assert_receiver_is_total_eq( - _self.into(), + "eq", + | + _self: Ref, + other: Ref| + { + let output: bool = ::bevy::input::mouse::MouseButtonInput::eq( + &_self, + &other, ) .into(); output @@ -417,8 +417,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::mouse::MouseMotion::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -428,23 +428,13 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::mouse::MouseMotion::clone( - _self.into(), + &_self, ) .into(); output }, ); NamespaceBuilder::<::bevy::input::mouse::MouseWheel>::new(world) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::input::mouse::MouseWheel::clone( - _self.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "eq", | @@ -452,8 +442,18 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::mouse::MouseWheel::eq( - _self.into(), - other.into(), + &_self, + &other, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::input::mouse::MouseWheel::clone( + &_self, ) .into(); output @@ -464,7 +464,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::gamepad::GamepadAxisChangedEvent::clone( - _self.into(), + &_self, ) .into(); output @@ -477,8 +477,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::gamepad::GamepadAxisChangedEvent::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -489,7 +489,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::gamepad::GamepadButtonChangedEvent::clone( - _self.into(), + &_self, ) .into(); output @@ -502,8 +502,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::gamepad::GamepadButtonChangedEvent::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -512,18 +512,6 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { NamespaceBuilder::< ::bevy::input::gamepad::GamepadButtonStateChangedEvent, >::new(world) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val< - bevy::input::gamepad::GamepadButtonStateChangedEvent, - > = ::bevy::input::gamepad::GamepadButtonStateChangedEvent::clone( - _self.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "eq", | @@ -531,8 +519,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::gamepad::GamepadButtonStateChangedEvent::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -542,7 +530,19 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::bevy::input::gamepad::GamepadButtonStateChangedEvent::assert_receiver_is_total_eq( - _self.into(), + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val< + bevy::input::gamepad::GamepadButtonStateChangedEvent, + > = ::bevy::input::gamepad::GamepadButtonStateChangedEvent::clone( + &_self, ) .into(); output @@ -556,8 +556,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::gamepad::GamepadConnection::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -567,7 +567,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::gamepad::GamepadConnection::clone( - _self.into(), + &_self, ) .into(); output @@ -578,7 +578,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "connected", |_self: Ref| { let output: bool = ::bevy::input::gamepad::GamepadConnectionEvent::connected( - _self.into(), + &_self, ) .into(); output @@ -588,7 +588,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "disconnected", |_self: Ref| { let output: bool = ::bevy::input::gamepad::GamepadConnectionEvent::disconnected( - _self.into(), + &_self, ) .into(); output @@ -601,8 +601,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::gamepad::GamepadConnectionEvent::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -612,53 +612,43 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::gamepad::GamepadConnectionEvent::clone( - _self.into(), + &_self, ) .into(); output }, ); NamespaceBuilder::<::bevy::input::gamepad::GamepadEvent>::new(world) - .overwrite_script_function( - "eq", - | - _self: Ref, - other: Ref| - { - let output: bool = ::bevy::input::gamepad::GamepadEvent::eq( - _self.into(), - other.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "clone", |_self: Ref| { let output: Val = ::bevy::input::gamepad::GamepadEvent::clone( - _self.into(), + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::input::gamepad::GamepadInput>::new(world) + ) .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::input::gamepad::GamepadInput::assert_receiver_is_total_eq( - _self.into(), + "eq", + | + _self: Ref, + other: Ref| + { + let output: bool = ::bevy::input::gamepad::GamepadEvent::eq( + &_self, + &other, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::input::gamepad::GamepadInput>::new(world) .overwrite_script_function( "clone", |_self: Ref| { let output: Val = ::bevy::input::gamepad::GamepadInput::clone( - _self.into(), + &_self, ) .into(); output @@ -671,8 +661,18 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::gamepad::GamepadInput::eq( - _self.into(), - other.into(), + &_self, + &other, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::input::gamepad::GamepadInput::assert_receiver_is_total_eq( + &_self, ) .into(); output @@ -683,7 +683,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::gamepad::GamepadRumbleRequest::clone( - _self.into(), + &_self, ) .into(); output @@ -699,8 +699,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::gamepad::RawGamepadAxisChangedEvent::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -710,7 +710,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::gamepad::RawGamepadAxisChangedEvent::clone( - _self.into(), + &_self, ) .into(); output @@ -725,7 +725,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { let output: Val< bevy::input::gamepad::RawGamepadButtonChangedEvent, > = ::bevy::input::gamepad::RawGamepadButtonChangedEvent::clone( - _self.into(), + &_self, ) .into(); output @@ -738,24 +738,14 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::gamepad::RawGamepadButtonChangedEvent::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output }, ); NamespaceBuilder::<::bevy::input::gamepad::RawGamepadEvent>::new(world) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::input::gamepad::RawGamepadEvent::clone( - _self.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "eq", | @@ -763,24 +753,24 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::gamepad::RawGamepadEvent::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::input::gestures::PinchGesture>::new(world) + ) .overwrite_script_function( "clone", - |_self: Ref| { - let output: Val = ::bevy::input::gestures::PinchGesture::clone( - _self.into(), + |_self: Ref| { + let output: Val = ::bevy::input::gamepad::RawGamepadEvent::clone( + &_self, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::input::gestures::PinchGesture>::new(world) .overwrite_script_function( "eq", | @@ -788,8 +778,18 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::gestures::PinchGesture::eq( - _self.into(), - other.into(), + &_self, + &other, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::input::gestures::PinchGesture::clone( + &_self, ) .into(); output @@ -800,7 +800,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::gestures::RotationGesture::clone( - _self.into(), + &_self, ) .into(); output @@ -813,8 +813,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::gestures::RotationGesture::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -828,8 +828,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::gestures::DoubleTapGesture::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -839,7 +839,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::gestures::DoubleTapGesture::clone( - _self.into(), + &_self, ) .into(); output @@ -850,7 +850,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::gestures::PanGesture::clone( - _self.into(), + &_self, ) .into(); output @@ -863,8 +863,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::gestures::PanGesture::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -872,24 +872,10 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { ); NamespaceBuilder::<::bevy::input::ButtonState>::new(world) .overwrite_script_function( - "eq", - | - _self: Ref, - other: Ref| - { - let output: bool = ::bevy::input::ButtonState::eq( - _self.into(), - other.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "is_pressed", + "clone", |_self: Ref| { - let output: bool = ::bevy::input::ButtonState::is_pressed( - _self.into(), + let output: Val = ::bevy::input::ButtonState::clone( + &_self, ) .into(); output @@ -899,53 +885,38 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::bevy::input::ButtonState::assert_receiver_is_total_eq( - _self.into(), + &_self, ) .into(); output }, ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::input::ButtonState::clone( - _self.into(), - ) - .into(); - output - }, - ); - NamespaceBuilder::<::bevy::input::gamepad::ButtonSettings>::new(world) .overwrite_script_function( "eq", | - _self: Ref, - other: Ref| + _self: Ref, + other: Ref| { - let output: bool = ::bevy::input::gamepad::ButtonSettings::eq( - _self.into(), - other.into(), - ) + let output: bool = ::bevy::input::ButtonState::eq(&_self, &other) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::input::gamepad::ButtonSettings::clone( - _self.into(), - ) + "is_pressed", + |_self: Ref| { + let output: bool = ::bevy::input::ButtonState::is_pressed(&_self) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::input::gamepad::ButtonSettings>::new(world) .overwrite_script_function( "is_pressed", |_self: Ref, value: f32| { let output: bool = ::bevy::input::gamepad::ButtonSettings::is_pressed( - _self.into(), - value.into(), + &_self, + value, ) .into(); output @@ -955,8 +926,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "is_released", |_self: Ref, value: f32| { let output: bool = ::bevy::input::gamepad::ButtonSettings::is_released( - _self.into(), - value.into(), + &_self, + value, ) .into(); output @@ -966,7 +937,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "press_threshold", |_self: Ref| { let output: f32 = ::bevy::input::gamepad::ButtonSettings::press_threshold( - _self.into(), + &_self, ) .into(); output @@ -976,8 +947,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "set_press_threshold", |_self: Mut, value: f32| { let output: f32 = ::bevy::input::gamepad::ButtonSettings::set_press_threshold( - _self.into(), - value.into(), + &mut_self, + value, ) .into(); output @@ -987,7 +958,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "release_threshold", |_self: Ref| { let output: f32 = ::bevy::input::gamepad::ButtonSettings::release_threshold( - _self.into(), + &_self, ) .into(); output @@ -997,33 +968,43 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "set_release_threshold", |_self: Mut, value: f32| { let output: f32 = ::bevy::input::gamepad::ButtonSettings::set_release_threshold( - _self.into(), - value.into(), + &mut_self, + value, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::input::gamepad::AxisSettings>::new(world) + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::input::gamepad::ButtonSettings::clone( + &_self, + ) + .into(); + output + }, + ) .overwrite_script_function( "eq", | - _self: Ref, - other: Ref| + _self: Ref, + other: Ref| { - let output: bool = ::bevy::input::gamepad::AxisSettings::eq( - _self.into(), - other.into(), + let output: bool = ::bevy::input::gamepad::ButtonSettings::eq( + &_self, + &other, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::input::gamepad::AxisSettings>::new(world) .overwrite_script_function( "livezone_upperbound", |_self: Ref| { let output: f32 = ::bevy::input::gamepad::AxisSettings::livezone_upperbound( - _self.into(), + &_self, ) .into(); output @@ -1033,8 +1014,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "set_livezone_upperbound", |_self: Mut, value: f32| { let output: f32 = ::bevy::input::gamepad::AxisSettings::set_livezone_upperbound( - _self.into(), - value.into(), + &mut_self, + value, ) .into(); output @@ -1044,7 +1025,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "deadzone_upperbound", |_self: Ref| { let output: f32 = ::bevy::input::gamepad::AxisSettings::deadzone_upperbound( - _self.into(), + &_self, ) .into(); output @@ -1054,8 +1035,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "set_deadzone_upperbound", |_self: Mut, value: f32| { let output: f32 = ::bevy::input::gamepad::AxisSettings::set_deadzone_upperbound( - _self.into(), - value.into(), + &mut_self, + value, ) .into(); output @@ -1065,7 +1046,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "livezone_lowerbound", |_self: Ref| { let output: f32 = ::bevy::input::gamepad::AxisSettings::livezone_lowerbound( - _self.into(), + &_self, ) .into(); output @@ -1075,8 +1056,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "set_livezone_lowerbound", |_self: Mut, value: f32| { let output: f32 = ::bevy::input::gamepad::AxisSettings::set_livezone_lowerbound( - _self.into(), - value.into(), + &mut_self, + value, ) .into(); output @@ -1086,7 +1067,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "deadzone_lowerbound", |_self: Ref| { let output: f32 = ::bevy::input::gamepad::AxisSettings::deadzone_lowerbound( - _self.into(), + &_self, ) .into(); output @@ -1096,8 +1077,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "set_deadzone_lowerbound", |_self: Mut, value: f32| { let output: f32 = ::bevy::input::gamepad::AxisSettings::set_deadzone_lowerbound( - _self.into(), - value.into(), + &mut_self, + value, ) .into(); output @@ -1107,7 +1088,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "threshold", |_self: Ref| { let output: f32 = ::bevy::input::gamepad::AxisSettings::threshold( - _self.into(), + &_self, ) .into(); output @@ -1117,8 +1098,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "set_threshold", |_self: Mut, value: f32| { let output: f32 = ::bevy::input::gamepad::AxisSettings::set_threshold( - _self.into(), - value.into(), + &mut_self, + value, ) .into(); output @@ -1128,8 +1109,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clamp", |_self: Ref, new_value: f32| { let output: f32 = ::bevy::input::gamepad::AxisSettings::clamp( - _self.into(), - new_value.into(), + &_self, + new_value, ) .into(); output @@ -1143,9 +1124,9 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { old_value: std::option::Option| { let output: std::option::Option = ::bevy::input::gamepad::AxisSettings::filter( - _self.into(), - new_value.into(), - old_value.into(), + &_self, + new_value, + old_value, ) .into(); output @@ -1155,65 +1136,59 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::gamepad::AxisSettings::clone( - _self.into(), + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::input::gamepad::ButtonAxisSettings>::new(world) + ) .overwrite_script_function( - "filter", + "eq", | - _self: Ref, - new_value: f32, - old_value: std::option::Option| + _self: Ref, + other: Ref| { - let output: std::option::Option = ::bevy::input::gamepad::ButtonAxisSettings::filter( - _self.into(), - new_value.into(), - old_value.into(), + let output: bool = ::bevy::input::gamepad::AxisSettings::eq( + &_self, + &other, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::input::gamepad::ButtonAxisSettings>::new(world) .overwrite_script_function( "clone", |_self: Ref| { let output: Val = ::bevy::input::gamepad::ButtonAxisSettings::clone( - _self.into(), - ) - .into(); - output - }, - ); - NamespaceBuilder::<::bevy::input::gamepad::GamepadRumbleIntensity>::new(world) - .overwrite_script_function( - "weak_motor", - |intensity: f32| { - let output: Val = ::bevy::input::gamepad::GamepadRumbleIntensity::weak_motor( - intensity.into(), + &_self, ) .into(); output }, ) .overwrite_script_function( - "strong_motor", - |intensity: f32| { - let output: Val = ::bevy::input::gamepad::GamepadRumbleIntensity::strong_motor( - intensity.into(), + "filter", + | + _self: Ref, + new_value: f32, + old_value: std::option::Option| + { + let output: std::option::Option = ::bevy::input::gamepad::ButtonAxisSettings::filter( + &_self, + new_value, + old_value, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::input::gamepad::GamepadRumbleIntensity>::new(world) .overwrite_script_function( "clone", |_self: Ref| { let output: Val = ::bevy::input::gamepad::GamepadRumbleIntensity::clone( - _self.into(), + &_self, ) .into(); output @@ -1226,8 +1201,28 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::gamepad::GamepadRumbleIntensity::eq( - _self.into(), - other.into(), + &_self, + &other, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "weak_motor", + |intensity: f32| { + let output: Val = ::bevy::input::gamepad::GamepadRumbleIntensity::weak_motor( + intensity, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "strong_motor", + |intensity: f32| { + let output: Val = ::bevy::input::gamepad::GamepadRumbleIntensity::strong_motor( + intensity, ) .into(); output @@ -1238,7 +1233,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::bevy::input::keyboard::Key::assert_receiver_is_total_eq( - _self.into(), + &_self, ) .into(); output @@ -1248,7 +1243,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::keyboard::Key::clone( - _self.into(), + &_self, ) .into(); output @@ -1260,44 +1255,41 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { _self: Ref, other: Ref| { - let output: bool = ::bevy::input::keyboard::Key::eq( - _self.into(), - other.into(), - ) + let output: bool = ::bevy::input::keyboard::Key::eq(&_self, &other) .into(); output }, ); NamespaceBuilder::<::bevy::input::keyboard::NativeKeyCode>::new(world) .overwrite_script_function( - "eq", - | - _self: Ref, - other: Ref| - { - let output: bool = ::bevy::input::keyboard::NativeKeyCode::eq( - _self.into(), - other.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::input::keyboard::NativeKeyCode::clone( + &_self, ) .into(); output }, ) .overwrite_script_function( - "clone", + "assert_receiver_is_total_eq", |_self: Ref| { - let output: Val = ::bevy::input::keyboard::NativeKeyCode::clone( - _self.into(), + let output: () = ::bevy::input::keyboard::NativeKeyCode::assert_receiver_is_total_eq( + &_self, ) .into(); output }, ) .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::input::keyboard::NativeKeyCode::assert_receiver_is_total_eq( - _self.into(), + "eq", + | + _self: Ref, + other: Ref| + { + let output: bool = ::bevy::input::keyboard::NativeKeyCode::eq( + &_self, + &other, ) .into(); output @@ -1311,8 +1303,8 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::keyboard::NativeKey::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -1322,7 +1314,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::bevy::input::keyboard::NativeKey::assert_receiver_is_total_eq( - _self.into(), + &_self, ) .into(); output @@ -1332,7 +1324,7 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::input::keyboard::NativeKey::clone( - _self.into(), + &_self, ) .into(); output @@ -1340,20 +1332,20 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { ); NamespaceBuilder::<::bevy::input::mouse::MouseScrollUnit>::new(world) .overwrite_script_function( - "clone", + "assert_receiver_is_total_eq", |_self: Ref| { - let output: Val = ::bevy::input::mouse::MouseScrollUnit::clone( - _self.into(), + let output: () = ::bevy::input::mouse::MouseScrollUnit::assert_receiver_is_total_eq( + &_self, ) .into(); output }, ) .overwrite_script_function( - "assert_receiver_is_total_eq", + "clone", |_self: Ref| { - let output: () = ::bevy::input::mouse::MouseScrollUnit::assert_receiver_is_total_eq( - _self.into(), + let output: Val = ::bevy::input::mouse::MouseScrollUnit::clone( + &_self, ) .into(); output @@ -1366,19 +1358,29 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::mouse::MouseScrollUnit::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output }, ); NamespaceBuilder::<::bevy::input::touch::TouchPhase>::new(world) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::input::touch::TouchPhase::clone( + &_self, + ) + .into(); + output + }, + ) .overwrite_script_function( "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::bevy::input::touch::TouchPhase::assert_receiver_is_total_eq( - _self.into(), + &_self, ) .into(); output @@ -1391,34 +1393,14 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::touch::TouchPhase::eq( - _self.into(), - other.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::input::touch::TouchPhase::clone( - _self.into(), + &_self, + &other, ) .into(); output }, ); NamespaceBuilder::<::bevy::input::touch::ForceTouch>::new(world) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::input::touch::ForceTouch::clone( - _self.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "eq", | @@ -1426,8 +1408,18 @@ impl ::bevy::app::Plugin for BevyInputScriptingPlugin { other: Ref| { let output: bool = ::bevy::input::touch::ForceTouch::eq( - _self.into(), - other.into(), + &_self, + &other, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::input::touch::ForceTouch::clone( + &_self, ) .into(); output diff --git a/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_math.rs b/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_math.rs index 09e42ace0a..a4874a9b60 100644 --- a/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_math.rs +++ b/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_math.rs @@ -7,22 +7,29 @@ use bevy_mod_scripting_core::{ AddContextInitializer, StoreDocumentation, bindings::{ReflectReference, function::from::{Ref, Mut, Val}}, }; -use crate::*; +use crate::{*, namespaced_register::NamespaceBuilder}; pub struct BevyMathScriptingPlugin; impl ::bevy::app::Plugin for BevyMathScriptingPlugin { fn build(&self, app: &mut ::bevy::prelude::App) { let mut world = app.world_mut(); NamespaceBuilder::<::bevy::math::AspectRatio>::new(world) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::AspectRatio::clone( + &_self, + ) + .into(); + output + }, + ) .overwrite_script_function( "eq", | _self: Ref, other: Ref| { - let output: bool = ::bevy::math::AspectRatio::eq( - _self.into(), - other.into(), - ) + let output: bool = ::bevy::math::AspectRatio::eq(&_self, &other) .into(); output }, @@ -30,8 +37,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "ratio", |_self: Ref| { - let output: f32 = ::bevy::math::AspectRatio::ratio(_self.into()) - .into(); + let output: f32 = ::bevy::math::AspectRatio::ratio(&_self).into(); output }, ) @@ -39,7 +45,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "inverse", |_self: Ref| { let output: Val = ::bevy::math::AspectRatio::inverse( - _self.into(), + &_self, ) .into(); output @@ -48,9 +54,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "is_landscape", |_self: Ref| { - let output: bool = ::bevy::math::AspectRatio::is_landscape( - _self.into(), - ) + let output: bool = ::bevy::math::AspectRatio::is_landscape(&_self) .into(); output }, @@ -58,9 +62,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "is_portrait", |_self: Ref| { - let output: bool = ::bevy::math::AspectRatio::is_portrait( - _self.into(), - ) + let output: bool = ::bevy::math::AspectRatio::is_portrait(&_self) .into(); output }, @@ -68,37 +70,17 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "is_square", |_self: Ref| { - let output: bool = ::bevy::math::AspectRatio::is_square(_self.into()) - .into(); - output - }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::AspectRatio::clone( - _self.into(), - ) + let output: bool = ::bevy::math::AspectRatio::is_square(&_self) .into(); output }, ); NamespaceBuilder::<::bevy::math::CompassOctant>::new(world) - .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::math::CompassOctant::assert_receiver_is_total_eq( - _self.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "clone", |_self: Ref| { let output: Val = ::bevy::math::CompassOctant::clone( - _self.into(), + &_self, ) .into(); output @@ -110,64 +92,54 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { _self: Ref, other: Ref| { - let output: bool = ::bevy::math::CompassOctant::eq( - _self.into(), - other.into(), - ) + let output: bool = ::bevy::math::CompassOctant::eq(&_self, &other) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::CompassQuadrant>::new(world) + ) .overwrite_script_function( "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::math::CompassQuadrant::assert_receiver_is_total_eq( - _self.into(), + |_self: Ref| { + let output: () = ::bevy::math::CompassOctant::assert_receiver_is_total_eq( + &_self, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::CompassQuadrant>::new(world) .overwrite_script_function( "eq", | _self: Ref, other: Ref| { - let output: bool = ::bevy::math::CompassQuadrant::eq( - _self.into(), - other.into(), - ) + let output: bool = ::bevy::math::CompassQuadrant::eq(&_self, &other) .into(); output }, ) .overwrite_script_function( - "clone", + "assert_receiver_is_total_eq", |_self: Ref| { - let output: Val = ::bevy::math::CompassQuadrant::clone( - _self.into(), + let output: () = ::bevy::math::CompassQuadrant::assert_receiver_is_total_eq( + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::Isometry2d>::new(world) + ) .overwrite_script_function( - "mul", - | - _self: Val, - rhs: Val| - { - let output: Val = ::bevy::math::Isometry2d::mul( - _self.into(), - rhs.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::CompassQuadrant::clone( + &_self, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::Isometry2d>::new(world) .overwrite_script_function( "from_rotation", |rotation: Val| { @@ -182,8 +154,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "from_xy", |x: f32, y: f32| { let output: Val = ::bevy::math::Isometry2d::from_xy( - x.into(), - y.into(), + x, + y, ) .into(); output @@ -193,7 +165,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "inverse", |_self: Ref| { let output: Val = ::bevy::math::Isometry2d::inverse( - _self.into(), + &_self, ) .into(); output @@ -203,7 +175,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "inverse_mul", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Isometry2d::inverse_mul( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -214,7 +186,21 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::Isometry2d::clone( + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "mul", + | + _self: Val, + rhs: Val| + { + let output: Val = ::bevy::math::Isometry2d::mul( _self.into(), + rhs.into(), ) .into(); output @@ -234,22 +220,33 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "eq", |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::Isometry2d::eq( - _self.into(), - other.into(), - ) + let output: bool = ::bevy::math::Isometry2d::eq(&_self, &other) .into(); output }, ); NamespaceBuilder::<::bevy::math::Isometry3d>::new(world) + .overwrite_script_function( + "mul", + | + _self: Val, + rhs: Val| + { + let output: Val = ::bevy::math::Isometry3d::mul( + _self.into(), + rhs.into(), + ) + .into(); + output + }, + ) .overwrite_script_function( "from_xyz", |x: f32, y: f32, z: f32| { let output: Val = ::bevy::math::Isometry3d::from_xyz( - x.into(), - y.into(), - z.into(), + x, + y, + z, ) .into(); output @@ -259,7 +256,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "inverse", |_self: Ref| { let output: Val = ::bevy::math::Isometry3d::inverse( - _self.into(), + &_self, ) .into(); output @@ -269,7 +266,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "inverse_mul", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Isometry3d::inverse_mul( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -280,7 +277,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::Isometry3d::clone( - _self.into(), + &_self, ) .into(); output @@ -297,48 +294,27 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { output }, ) - .overwrite_script_function( - "mul", - | - _self: Val, - rhs: Val| - { - let output: Val = ::bevy::math::Isometry3d::mul( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "eq", |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::Isometry3d::eq( - _self.into(), - other.into(), - ) + let output: bool = ::bevy::math::Isometry3d::eq(&_self, &other) .into(); output }, ); NamespaceBuilder::<::bevy::math::Ray2d>::new(world) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::Ray2d::clone( - _self.into(), - ) - .into(); + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::Ray2d::eq(&_self, &other).into(); output }, ) .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::Ray2d::eq( - _self.into(), - other.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::Ray2d::clone( + &_self, ) .into(); output @@ -348,11 +324,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "eq", |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::Ray3d::eq( - _self.into(), - other.into(), - ) - .into(); + let output: bool = ::bevy::math::Ray3d::eq(&_self, &other).into(); output }, ) @@ -360,13 +332,34 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::Ray3d::clone( - _self.into(), + &_self, ) .into(); output }, ); NamespaceBuilder::<::bevy::math::Rot2>::new(world) + .overwrite_script_function( + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::Rot2::eq(&_self, &other).into(); + output + }, + ) + .overwrite_script_function( + "mul", + | + _self: Val, + direction: Val| + { + let output: Val = ::bevy::math::Rot2::mul( + _self.into(), + direction.into(), + ) + .into(); + output + }, + ) .overwrite_script_function( "mul", |_self: Val, rhs: Val| { @@ -382,7 +375,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "radians", |radians: f32| { let output: Val = ::bevy::math::Rot2::radians( - radians.into(), + radians, ) .into(); output @@ -392,7 +385,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "degrees", |degrees: f32| { let output: Val = ::bevy::math::Rot2::degrees( - degrees.into(), + degrees, ) .into(); output @@ -402,7 +395,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "turn_fraction", |fraction: f32| { let output: Val = ::bevy::math::Rot2::turn_fraction( - fraction.into(), + fraction, ) .into(); output @@ -412,8 +405,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "from_sin_cos", |sin: f32, cos: f32| { let output: Val = ::bevy::math::Rot2::from_sin_cos( - sin.into(), - cos.into(), + sin, + cos, ) .into(); output @@ -563,7 +556,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { let output: Val = ::bevy::math::Rot2::nlerp( _self.into(), end.into(), - s.into(), + s, ) .into(); output @@ -575,51 +568,48 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { let output: Val = ::bevy::math::Rot2::slerp( _self.into(), end.into(), - s.into(), + s, ) .into(); output }, ) .overwrite_script_function( - "mul", - | - _self: Val, - direction: Val| - { - let output: Val = ::bevy::math::Rot2::mul( - _self.into(), - direction.into(), - ) + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::Rot2::clone(&_self) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::prelude::Dir2>::new(world) .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::Rot2::eq(_self.into(), other.into()) + "neg", + |_self: Val| { + let output: Val = ::bevy::math::prelude::Dir2::neg( + _self.into(), + ) .into(); output }, ) .overwrite_script_function( "clone", - |_self: Ref| { - let output: Val = ::bevy::math::Rot2::clone( - _self.into(), + |_self: Ref| { + let output: Val = ::bevy::math::prelude::Dir2::clone( + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::prelude::Dir2>::new(world) + ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::prelude::Dir2::clone( - _self.into(), - ) + "eq", + | + _self: Ref, + other: Ref| + { + let output: bool = ::bevy::math::prelude::Dir2::eq(&_self, &other) .into(); output }, @@ -628,8 +618,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "from_xy_unchecked", |x: f32, y: f32| { let output: Val = ::bevy::math::prelude::Dir2::from_xy_unchecked( - x.into(), - y.into(), + x, + y, ) .into(); output @@ -645,7 +635,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { let output: Val = ::bevy::math::prelude::Dir2::slerp( _self.into(), rhs.into(), - s.into(), + s, ) .into(); output @@ -728,32 +718,18 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::prelude::Dir3>::new(world) .overwrite_script_function( - "eq", - | - _self: Ref, - other: Ref| - { - let output: bool = ::bevy::math::prelude::Dir2::eq( - _self.into(), - other.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::prelude::Dir3::clone( + &_self, ) .into(); output }, ) - .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::prelude::Dir2::neg( - _self.into(), - ) - .into(); - output - }, - ); - NamespaceBuilder::<::bevy::math::prelude::Dir3>::new(world) .overwrite_script_function( "neg", |_self: Val| { @@ -764,26 +740,13 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { output }, ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::prelude::Dir3::clone( - _self.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "eq", | _self: Ref, other: Ref| { - let output: bool = ::bevy::math::prelude::Dir3::eq( - _self.into(), - other.into(), - ) + let output: bool = ::bevy::math::prelude::Dir3::eq(&_self, &other) .into(); output }, @@ -792,9 +755,9 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "from_xyz_unchecked", |x: f32, y: f32, z: f32| { let output: Val = ::bevy::math::prelude::Dir3::from_xyz_unchecked( - x.into(), - y.into(), - z.into(), + x, + y, + z, ) .into(); output @@ -810,7 +773,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { let output: Val = ::bevy::math::prelude::Dir3::slerp( _self.into(), rhs.into(), - s.into(), + s, ) .into(); output @@ -827,16 +790,6 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { }, ); NamespaceBuilder::<::bevy::math::prelude::Dir3A>::new(world) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::prelude::Dir3A::clone( - _self.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "neg", |_self: Val| { @@ -847,27 +800,13 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { output }, ) - .overwrite_script_function( - "eq", - | - _self: Ref, - other: Ref| - { - let output: bool = ::bevy::math::prelude::Dir3A::eq( - _self.into(), - other.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "from_xyz_unchecked", |x: f32, y: f32, z: f32| { let output: Val = ::bevy::math::prelude::Dir3A::from_xyz_unchecked( - x.into(), - y.into(), - z.into(), + x, + y, + z, ) .into(); output @@ -883,7 +822,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { let output: Val = ::bevy::math::prelude::Dir3A::slerp( _self.into(), rhs.into(), - s.into(), + s, ) .into(); output @@ -898,6 +837,27 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .into(); output }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::prelude::Dir3A::clone( + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "eq", + | + _self: Ref, + other: Ref| + { + let output: bool = ::bevy::math::prelude::Dir3A::eq(&_self, &other) + .into(); + output + }, ); NamespaceBuilder::<::bevy::math::prelude::IRect>::new(world) .overwrite_script_function( @@ -906,10 +866,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { _self: Ref, other: Ref| { - let output: bool = ::bevy::math::prelude::IRect::eq( - _self.into(), - other.into(), - ) + let output: bool = ::bevy::math::prelude::IRect::eq(&_self, &other) .into(); output }, @@ -918,17 +875,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::bevy::math::prelude::IRect::assert_receiver_is_total_eq( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::prelude::IRect::clone( - _self.into(), + &_self, ) .into(); output @@ -938,10 +885,10 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "new", |x0: i32, y0: i32, x1: i32, y1: i32| { let output: Val = ::bevy::math::prelude::IRect::new( - x0.into(), - y0.into(), - x1.into(), - y1.into(), + x0, + y0, + x1, + y1, ) .into(); output @@ -950,9 +897,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "is_empty", |_self: Ref| { - let output: bool = ::bevy::math::prelude::IRect::is_empty( - _self.into(), - ) + let output: bool = ::bevy::math::prelude::IRect::is_empty(&_self) .into(); output }, @@ -960,15 +905,14 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "width", |_self: Ref| { - let output: i32 = ::bevy::math::prelude::IRect::width(_self.into()) - .into(); + let output: i32 = ::bevy::math::prelude::IRect::width(&_self).into(); output }, ) .overwrite_script_function( "height", |_self: Ref| { - let output: i32 = ::bevy::math::prelude::IRect::height(_self.into()) + let output: i32 = ::bevy::math::prelude::IRect::height(&_self) .into(); output }, @@ -980,7 +924,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Val| { let output: Val = ::bevy::math::prelude::IRect::union( - _self.into(), + &_self, other.into(), ) .into(); @@ -994,7 +938,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Val| { let output: Val = ::bevy::math::prelude::IRect::intersect( - _self.into(), + &_self, other.into(), ) .into(); @@ -1005,8 +949,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "inflate", |_self: Ref, expansion: i32| { let output: Val = ::bevy::math::prelude::IRect::inflate( - _self.into(), - expansion.into(), + &_self, + expansion, ) .into(); output @@ -1016,7 +960,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "as_rect", |_self: Ref| { let output: Val = ::bevy::math::prelude::IRect::as_rect( - _self.into(), + &_self, ) .into(); output @@ -1026,35 +970,31 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "as_urect", |_self: Ref| { let output: Val = ::bevy::math::prelude::IRect::as_urect( - _self.into(), + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::prelude::Rect>::new(world) + ) .overwrite_script_function( - "eq", - | - _self: Ref, - other: Ref| - { - let output: bool = ::bevy::math::prelude::Rect::eq( - _self.into(), - other.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::prelude::IRect::clone( + &_self, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::prelude::Rect>::new(world) .overwrite_script_function( "new", |x0: f32, y0: f32, x1: f32, y1: f32| { let output: Val = ::bevy::math::prelude::Rect::new( - x0.into(), - y0.into(), - x1.into(), - y1.into(), + x0, + y0, + x1, + y1, ) .into(); output @@ -1063,9 +1003,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "is_empty", |_self: Ref| { - let output: bool = ::bevy::math::prelude::Rect::is_empty( - _self.into(), - ) + let output: bool = ::bevy::math::prelude::Rect::is_empty(&_self) .into(); output }, @@ -1073,16 +1011,14 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "width", |_self: Ref| { - let output: f32 = ::bevy::math::prelude::Rect::width(_self.into()) - .into(); + let output: f32 = ::bevy::math::prelude::Rect::width(&_self).into(); output }, ) .overwrite_script_function( "height", |_self: Ref| { - let output: f32 = ::bevy::math::prelude::Rect::height(_self.into()) - .into(); + let output: f32 = ::bevy::math::prelude::Rect::height(&_self).into(); output }, ) @@ -1093,7 +1029,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Val| { let output: Val = ::bevy::math::prelude::Rect::union( - _self.into(), + &_self, other.into(), ) .into(); @@ -1107,7 +1043,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Val| { let output: Val = ::bevy::math::prelude::Rect::intersect( - _self.into(), + &_self, other.into(), ) .into(); @@ -1118,8 +1054,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "inflate", |_self: Ref, expansion: f32| { let output: Val = ::bevy::math::prelude::Rect::inflate( - _self.into(), - expansion.into(), + &_self, + expansion, ) .into(); output @@ -1132,7 +1068,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Val| { let output: Val = ::bevy::math::prelude::Rect::normalize( - _self.into(), + &_self, other.into(), ) .into(); @@ -1143,7 +1079,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "as_irect", |_self: Ref| { let output: Val = ::bevy::math::prelude::Rect::as_irect( - _self.into(), + &_self, ) .into(); output @@ -1153,7 +1089,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "as_urect", |_self: Ref| { let output: Val = ::bevy::math::prelude::Rect::as_urect( - _self.into(), + &_self, ) .into(); output @@ -1163,35 +1099,32 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::prelude::Rect::clone( - _self.into(), + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::prelude::URect>::new(world) + ) .overwrite_script_function( "eq", | - _self: Ref, - other: Ref| + _self: Ref, + other: Ref| { - let output: bool = ::bevy::math::prelude::URect::eq( - _self.into(), - other.into(), - ) + let output: bool = ::bevy::math::prelude::Rect::eq(&_self, &other) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::prelude::URect>::new(world) .overwrite_script_function( "new", |x0: u32, y0: u32, x1: u32, y1: u32| { let output: Val = ::bevy::math::prelude::URect::new( - x0.into(), - y0.into(), - x1.into(), - y1.into(), + x0, + y0, + x1, + y1, ) .into(); output @@ -1200,9 +1133,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "is_empty", |_self: Ref| { - let output: bool = ::bevy::math::prelude::URect::is_empty( - _self.into(), - ) + let output: bool = ::bevy::math::prelude::URect::is_empty(&_self) .into(); output }, @@ -1210,15 +1141,14 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "width", |_self: Ref| { - let output: u32 = ::bevy::math::prelude::URect::width(_self.into()) - .into(); + let output: u32 = ::bevy::math::prelude::URect::width(&_self).into(); output }, ) .overwrite_script_function( "height", |_self: Ref| { - let output: u32 = ::bevy::math::prelude::URect::height(_self.into()) + let output: u32 = ::bevy::math::prelude::URect::height(&_self) .into(); output }, @@ -1230,7 +1160,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Val| { let output: Val = ::bevy::math::prelude::URect::union( - _self.into(), + &_self, other.into(), ) .into(); @@ -1244,7 +1174,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Val| { let output: Val = ::bevy::math::prelude::URect::intersect( - _self.into(), + &_self, other.into(), ) .into(); @@ -1255,8 +1185,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "inflate", |_self: Ref, expansion: i32| { let output: Val = ::bevy::math::prelude::URect::inflate( - _self.into(), - expansion.into(), + &_self, + expansion, ) .into(); output @@ -1266,7 +1196,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "as_rect", |_self: Ref| { let output: Val = ::bevy::math::prelude::URect::as_rect( - _self.into(), + &_self, ) .into(); output @@ -1276,27 +1206,38 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "as_irect", |_self: Ref| { let output: Val = ::bevy::math::prelude::URect::as_irect( - _self.into(), + &_self, ) .into(); output }, ) .overwrite_script_function( - "clone", + "assert_receiver_is_total_eq", |_self: Ref| { - let output: Val = ::bevy::math::prelude::URect::clone( - _self.into(), + let output: () = ::bevy::math::prelude::URect::assert_receiver_is_total_eq( + &_self, ) .into(); output }, ) .overwrite_script_function( - "assert_receiver_is_total_eq", + "eq", + | + _self: Ref, + other: Ref| + { + let output: bool = ::bevy::math::prelude::URect::eq(&_self, &other) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", |_self: Ref| { - let output: () = ::bevy::math::prelude::URect::assert_receiver_is_total_eq( - _self.into(), + let output: Val = ::bevy::math::prelude::URect::clone( + &_self, ) .into(); output @@ -1308,7 +1249,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "bounding_circle", |_self: Ref| { let output: Val = ::bevy::math::bounding::Aabb2d::bounding_circle( - _self.into(), + &_self, ) .into(); output @@ -1318,18 +1259,28 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::bounding::Aabb2d::clone( - _self.into(), + &_self, ) .into(); output }, ); NamespaceBuilder::<::bevy::math::bounding::BoundingCircle>::new(world) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::bounding::BoundingCircle::clone( + &_self, + ) + .into(); + output + }, + ) .overwrite_script_function( "radius", |_self: Ref| { let output: f32 = ::bevy::math::bounding::BoundingCircle::radius( - _self.into(), + &_self, ) .into(); output @@ -1339,23 +1290,23 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "aabb_2d", |_self: Ref| { let output: Val = ::bevy::math::bounding::BoundingCircle::aabb_2d( - _self.into(), + &_self, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::primitives::Circle>::new(world) .overwrite_script_function( "clone", - |_self: Ref| { - let output: Val = ::bevy::math::bounding::BoundingCircle::clone( - _self.into(), + |_self: Ref| { + let output: Val = ::bevy::math::primitives::Circle::clone( + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::primitives::Circle>::new(world) + ) .overwrite_script_function( "eq", | @@ -1363,8 +1314,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::Circle::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -1374,7 +1325,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "new", |radius: f32| { let output: Val = ::bevy::math::primitives::Circle::new( - radius.into(), + radius, ) .into(); output @@ -1383,74 +1334,60 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "diameter", |_self: Ref| { - let output: f32 = ::bevy::math::primitives::Circle::diameter( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::Circle::clone( - _self.into(), - ) + let output: f32 = ::bevy::math::primitives::Circle::diameter(&_self) .into(); output }, ); NamespaceBuilder::<::bevy::math::primitives::Annulus>::new(world) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::Annulus::clone( - _self.into(), + "new", + |inner_radius: f32, outer_radius: f32| { + let output: Val = ::bevy::math::primitives::Annulus::new( + inner_radius, + outer_radius, ) .into(); output }, ) .overwrite_script_function( - "eq", - | - _self: Ref, - other: Ref| - { - let output: bool = ::bevy::math::primitives::Annulus::eq( - _self.into(), - other.into(), - ) + "diameter", + |_self: Ref| { + let output: f32 = ::bevy::math::primitives::Annulus::diameter(&_self) .into(); output }, ) .overwrite_script_function( - "new", - |inner_radius: f32, outer_radius: f32| { - let output: Val = ::bevy::math::primitives::Annulus::new( - inner_radius.into(), - outer_radius.into(), + "thickness", + |_self: Ref| { + let output: f32 = ::bevy::math::primitives::Annulus::thickness( + &_self, ) .into(); output }, ) .overwrite_script_function( - "diameter", + "clone", |_self: Ref| { - let output: f32 = ::bevy::math::primitives::Annulus::diameter( - _self.into(), + let output: Val = ::bevy::math::primitives::Annulus::clone( + &_self, ) .into(); output }, ) .overwrite_script_function( - "thickness", - |_self: Ref| { - let output: f32 = ::bevy::math::primitives::Annulus::thickness( - _self.into(), + "eq", + | + _self: Ref, + other: Ref| + { + let output: bool = ::bevy::math::primitives::Annulus::eq( + &_self, + &other, ) .into(); output @@ -1461,8 +1398,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "new", |radius: f32, half_angle: f32| { let output: Val = ::bevy::math::primitives::Arc2d::new( - radius.into(), - half_angle.into(), + radius, + half_angle, ) .into(); output @@ -1472,8 +1409,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "from_radians", |radius: f32, angle: f32| { let output: Val = ::bevy::math::primitives::Arc2d::from_radians( - radius.into(), - angle.into(), + radius, + angle, ) .into(); output @@ -1483,8 +1420,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "from_degrees", |radius: f32, angle: f32| { let output: Val = ::bevy::math::primitives::Arc2d::from_degrees( - radius.into(), - angle.into(), + radius, + angle, ) .into(); output @@ -1494,8 +1431,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "from_turns", |radius: f32, fraction: f32| { let output: Val = ::bevy::math::primitives::Arc2d::from_turns( - radius.into(), - fraction.into(), + radius, + fraction, ) .into(); output @@ -1504,9 +1441,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "angle", |_self: Ref| { - let output: f32 = ::bevy::math::primitives::Arc2d::angle( - _self.into(), - ) + let output: f32 = ::bevy::math::primitives::Arc2d::angle(&_self) .into(); output }, @@ -1514,9 +1449,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "length", |_self: Ref| { - let output: f32 = ::bevy::math::primitives::Arc2d::length( - _self.into(), - ) + let output: f32 = ::bevy::math::primitives::Arc2d::length(&_self) .into(); output }, @@ -1525,7 +1458,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "half_chord_length", |_self: Ref| { let output: f32 = ::bevy::math::primitives::Arc2d::half_chord_length( - _self.into(), + &_self, ) .into(); output @@ -1535,7 +1468,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "chord_length", |_self: Ref| { let output: f32 = ::bevy::math::primitives::Arc2d::chord_length( - _self.into(), + &_self, ) .into(); output @@ -1544,9 +1477,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "apothem", |_self: Ref| { - let output: f32 = ::bevy::math::primitives::Arc2d::apothem( - _self.into(), - ) + let output: f32 = ::bevy::math::primitives::Arc2d::apothem(&_self) .into(); output }, @@ -1554,9 +1485,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "sagitta", |_self: Ref| { - let output: f32 = ::bevy::math::primitives::Arc2d::sagitta( - _self.into(), - ) + let output: f32 = ::bevy::math::primitives::Arc2d::sagitta(&_self) .into(); output }, @@ -1564,9 +1493,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "is_minor", |_self: Ref| { - let output: bool = ::bevy::math::primitives::Arc2d::is_minor( - _self.into(), - ) + let output: bool = ::bevy::math::primitives::Arc2d::is_minor(&_self) .into(); output }, @@ -1574,19 +1501,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "is_major", |_self: Ref| { - let output: bool = ::bevy::math::primitives::Arc2d::is_major( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::Arc2d::clone( - _self.into(), - ) + let output: bool = ::bevy::math::primitives::Arc2d::is_major(&_self) .into(); output }, @@ -1598,8 +1513,18 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::Arc2d::eq( - _self.into(), - other.into(), + &_self, + &other, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::primitives::Arc2d::clone( + &_self, ) .into(); output @@ -1610,8 +1535,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "new", |radius: f32, length: f32| { let output: Val = ::bevy::math::primitives::Capsule2d::new( - radius.into(), - length.into(), + radius, + length, ) .into(); output @@ -1621,7 +1546,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "to_inner_rectangle", |_self: Ref| { let output: Val = ::bevy::math::primitives::Capsule2d::to_inner_rectangle( - _self.into(), + &_self, ) .into(); output @@ -1634,8 +1559,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::Capsule2d::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -1645,13 +1570,23 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::primitives::Capsule2d::clone( - _self.into(), + &_self, ) .into(); output }, ); NamespaceBuilder::<::bevy::math::primitives::CircularSector>::new(world) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::primitives::CircularSector::clone( + &_self, + ) + .into(); + output + }, + ) .overwrite_script_function( "eq", | @@ -1659,8 +1594,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::CircularSector::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -1670,8 +1605,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "new", |radius: f32, angle: f32| { let output: Val = ::bevy::math::primitives::CircularSector::new( - radius.into(), - angle.into(), + radius, + angle, ) .into(); output @@ -1681,8 +1616,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "from_radians", |radius: f32, angle: f32| { let output: Val = ::bevy::math::primitives::CircularSector::from_radians( - radius.into(), - angle.into(), + radius, + angle, ) .into(); output @@ -1692,8 +1627,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "from_degrees", |radius: f32, angle: f32| { let output: Val = ::bevy::math::primitives::CircularSector::from_degrees( - radius.into(), - angle.into(), + radius, + angle, ) .into(); output @@ -1703,8 +1638,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "from_turns", |radius: f32, fraction: f32| { let output: Val = ::bevy::math::primitives::CircularSector::from_turns( - radius.into(), - fraction.into(), + radius, + fraction, ) .into(); output @@ -1714,7 +1649,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "half_angle", |_self: Ref| { let output: f32 = ::bevy::math::primitives::CircularSector::half_angle( - _self.into(), + &_self, ) .into(); output @@ -1724,7 +1659,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "angle", |_self: Ref| { let output: f32 = ::bevy::math::primitives::CircularSector::angle( - _self.into(), + &_self, ) .into(); output @@ -1734,7 +1669,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "radius", |_self: Ref| { let output: f32 = ::bevy::math::primitives::CircularSector::radius( - _self.into(), + &_self, ) .into(); output @@ -1744,7 +1679,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "arc_length", |_self: Ref| { let output: f32 = ::bevy::math::primitives::CircularSector::arc_length( - _self.into(), + &_self, ) .into(); output @@ -1754,7 +1689,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "half_chord_length", |_self: Ref| { let output: f32 = ::bevy::math::primitives::CircularSector::half_chord_length( - _self.into(), + &_self, ) .into(); output @@ -1764,7 +1699,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "chord_length", |_self: Ref| { let output: f32 = ::bevy::math::primitives::CircularSector::chord_length( - _self.into(), + &_self, ) .into(); output @@ -1774,7 +1709,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "apothem", |_self: Ref| { let output: f32 = ::bevy::math::primitives::CircularSector::apothem( - _self.into(), + &_self, ) .into(); output @@ -1784,29 +1719,29 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "sagitta", |_self: Ref| { let output: f32 = ::bevy::math::primitives::CircularSector::sagitta( - _self.into(), + &_self, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::primitives::CircularSegment>::new(world) .overwrite_script_function( "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::CircularSector::clone( - _self.into(), + |_self: Ref| { + let output: Val = ::bevy::math::primitives::CircularSegment::clone( + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::primitives::CircularSegment>::new(world) + ) .overwrite_script_function( "new", |radius: f32, angle: f32| { let output: Val = ::bevy::math::primitives::CircularSegment::new( - radius.into(), - angle.into(), + radius, + angle, ) .into(); output @@ -1816,8 +1751,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "from_radians", |radius: f32, angle: f32| { let output: Val = ::bevy::math::primitives::CircularSegment::from_radians( - radius.into(), - angle.into(), + radius, + angle, ) .into(); output @@ -1827,8 +1762,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "from_degrees", |radius: f32, angle: f32| { let output: Val = ::bevy::math::primitives::CircularSegment::from_degrees( - radius.into(), - angle.into(), + radius, + angle, ) .into(); output @@ -1838,8 +1773,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "from_turns", |radius: f32, fraction: f32| { let output: Val = ::bevy::math::primitives::CircularSegment::from_turns( - radius.into(), - fraction.into(), + radius, + fraction, ) .into(); output @@ -1849,7 +1784,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "half_angle", |_self: Ref| { let output: f32 = ::bevy::math::primitives::CircularSegment::half_angle( - _self.into(), + &_self, ) .into(); output @@ -1859,7 +1794,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "angle", |_self: Ref| { let output: f32 = ::bevy::math::primitives::CircularSegment::angle( - _self.into(), + &_self, ) .into(); output @@ -1869,7 +1804,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "radius", |_self: Ref| { let output: f32 = ::bevy::math::primitives::CircularSegment::radius( - _self.into(), + &_self, ) .into(); output @@ -1879,7 +1814,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "arc_length", |_self: Ref| { let output: f32 = ::bevy::math::primitives::CircularSegment::arc_length( - _self.into(), + &_self, ) .into(); output @@ -1889,7 +1824,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "half_chord_length", |_self: Ref| { let output: f32 = ::bevy::math::primitives::CircularSegment::half_chord_length( - _self.into(), + &_self, ) .into(); output @@ -1899,7 +1834,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "chord_length", |_self: Ref| { let output: f32 = ::bevy::math::primitives::CircularSegment::chord_length( - _self.into(), + &_self, ) .into(); output @@ -1909,7 +1844,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "apothem", |_self: Ref| { let output: f32 = ::bevy::math::primitives::CircularSegment::apothem( - _self.into(), + &_self, ) .into(); output @@ -1919,17 +1854,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "sagitta", |_self: Ref| { let output: f32 = ::bevy::math::primitives::CircularSegment::sagitta( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::CircularSegment::clone( - _self.into(), + &_self, ) .into(); output @@ -1942,14 +1867,24 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::CircularSegment::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output }, ); NamespaceBuilder::<::bevy::math::primitives::Ellipse>::new(world) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::primitives::Ellipse::clone( + &_self, + ) + .into(); + output + }, + ) .overwrite_script_function( "eq", | @@ -1957,8 +1892,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::Ellipse::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -1968,8 +1903,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "new", |half_width: f32, half_height: f32| { let output: Val = ::bevy::math::primitives::Ellipse::new( - half_width.into(), - half_height.into(), + half_width, + half_height, ) .into(); output @@ -1979,7 +1914,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "eccentricity", |_self: Ref| { let output: f32 = ::bevy::math::primitives::Ellipse::eccentricity( - _self.into(), + &_self, ) .into(); output @@ -1989,7 +1924,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "focal_length", |_self: Ref| { let output: f32 = ::bevy::math::primitives::Ellipse::focal_length( - _self.into(), + &_self, ) .into(); output @@ -1999,7 +1934,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "semi_major", |_self: Ref| { let output: f32 = ::bevy::math::primitives::Ellipse::semi_major( - _self.into(), + &_self, ) .into(); output @@ -2009,33 +1944,13 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "semi_minor", |_self: Ref| { let output: f32 = ::bevy::math::primitives::Ellipse::semi_minor( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::Ellipse::clone( - _self.into(), + &_self, ) .into(); output }, ); NamespaceBuilder::<::bevy::math::primitives::Line2d>::new(world) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::Line2d::clone( - _self.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "eq", | @@ -2043,24 +1958,24 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::Line2d::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::primitives::Plane2d>::new(world) + ) .overwrite_script_function( "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::Plane2d::clone( - _self.into(), + |_self: Ref| { + let output: Val = ::bevy::math::primitives::Line2d::clone( + &_self, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::primitives::Plane2d>::new(world) .overwrite_script_function( "eq", | @@ -2068,8 +1983,18 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::Plane2d::eq( - _self.into(), - other.into(), + &_self, + &other, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::primitives::Plane2d::clone( + &_self, ) .into(); output @@ -2083,8 +2008,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::Rectangle::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -2094,8 +2019,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "new", |width: f32, height: f32| { let output: Val = ::bevy::math::primitives::Rectangle::new( - width.into(), - height.into(), + width, + height, ) .into(); output @@ -2105,7 +2030,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "from_length", |length: f32| { let output: Val = ::bevy::math::primitives::Rectangle::from_length( - length.into(), + length, ) .into(); output @@ -2115,7 +2040,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::primitives::Rectangle::clone( - _self.into(), + &_self, ) .into(); output @@ -2123,10 +2048,14 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { ); NamespaceBuilder::<::bevy::math::primitives::RegularPolygon>::new(world) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::RegularPolygon::clone( - _self.into(), + "eq", + | + _self: Ref, + other: Ref| + { + let output: bool = ::bevy::math::primitives::RegularPolygon::eq( + &_self, + &other, ) .into(); output @@ -2136,8 +2065,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "new", |circumradius: f32, sides: u32| { let output: Val = ::bevy::math::primitives::RegularPolygon::new( - circumradius.into(), - sides.into(), + circumradius, + sides, ) .into(); output @@ -2147,7 +2076,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "circumradius", |_self: Ref| { let output: f32 = ::bevy::math::primitives::RegularPolygon::circumradius( - _self.into(), + &_self, ) .into(); output @@ -2157,7 +2086,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "inradius", |_self: Ref| { let output: f32 = ::bevy::math::primitives::RegularPolygon::inradius( - _self.into(), + &_self, ) .into(); output @@ -2167,7 +2096,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "side_length", |_self: Ref| { let output: f32 = ::bevy::math::primitives::RegularPolygon::side_length( - _self.into(), + &_self, ) .into(); output @@ -2177,7 +2106,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "internal_angle_degrees", |_self: Ref| { let output: f32 = ::bevy::math::primitives::RegularPolygon::internal_angle_degrees( - _self.into(), + &_self, ) .into(); output @@ -2187,7 +2116,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "internal_angle_radians", |_self: Ref| { let output: f32 = ::bevy::math::primitives::RegularPolygon::internal_angle_radians( - _self.into(), + &_self, ) .into(); output @@ -2197,7 +2126,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "external_angle_degrees", |_self: Ref| { let output: f32 = ::bevy::math::primitives::RegularPolygon::external_angle_degrees( - _self.into(), + &_self, ) .into(); output @@ -2207,21 +2136,17 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "external_angle_radians", |_self: Ref| { let output: f32 = ::bevy::math::primitives::RegularPolygon::external_angle_radians( - _self.into(), + &_self, ) .into(); output }, ) .overwrite_script_function( - "eq", - | - _self: Ref, - other: Ref| - { - let output: bool = ::bevy::math::primitives::RegularPolygon::eq( - _self.into(), - other.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::primitives::RegularPolygon::clone( + &_self, ) .into(); output @@ -2235,8 +2160,18 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::Rhombus::eq( - _self.into(), - other.into(), + &_self, + &other, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::primitives::Rhombus::clone( + &_self, ) .into(); output @@ -2246,8 +2181,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "new", |horizontal_diagonal: f32, vertical_diagonal: f32| { let output: Val = ::bevy::math::primitives::Rhombus::new( - horizontal_diagonal.into(), - vertical_diagonal.into(), + horizontal_diagonal, + vertical_diagonal, ) .into(); output @@ -2257,7 +2192,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "from_side", |side: f32| { let output: Val = ::bevy::math::primitives::Rhombus::from_side( - side.into(), + side, ) .into(); output @@ -2267,7 +2202,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "from_inradius", |inradius: f32| { let output: Val = ::bevy::math::primitives::Rhombus::from_inradius( - inradius.into(), + inradius, ) .into(); output @@ -2276,9 +2211,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "side", |_self: Ref| { - let output: f32 = ::bevy::math::primitives::Rhombus::side( - _self.into(), - ) + let output: f32 = ::bevy::math::primitives::Rhombus::side(&_self) .into(); output }, @@ -2287,7 +2220,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "circumradius", |_self: Ref| { let output: f32 = ::bevy::math::primitives::Rhombus::circumradius( - _self.into(), + &_self, ) .into(); output @@ -2296,19 +2229,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "inradius", |_self: Ref| { - let output: f32 = ::bevy::math::primitives::Rhombus::inradius( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::Rhombus::clone( - _self.into(), - ) + let output: f32 = ::bevy::math::primitives::Rhombus::inradius(&_self) .into(); output }, @@ -2321,8 +2242,18 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::Segment2d::eq( - _self.into(), - other.into(), + &_self, + &other, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::primitives::Segment2d::clone( + &_self, ) .into(); output @@ -2333,7 +2264,22 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { |direction: Val, length: f32| { let output: Val = ::bevy::math::primitives::Segment2d::new( direction.into(), - length.into(), + length, + ) + .into(); + output + }, + ); + NamespaceBuilder::<::bevy::math::primitives::Triangle2d>::new(world) + .overwrite_script_function( + "eq", + | + _self: Ref, + other: Ref| + { + let output: bool = ::bevy::math::primitives::Triangle2d::eq( + &_self, + &other, ) .into(); output @@ -2341,20 +2287,19 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { ) .overwrite_script_function( "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::Segment2d::clone( - _self.into(), + |_self: Ref| { + let output: Val = ::bevy::math::primitives::Triangle2d::clone( + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::primitives::Triangle2d>::new(world) + ) .overwrite_script_function( "is_degenerate", |_self: Ref| { let output: bool = ::bevy::math::primitives::Triangle2d::is_degenerate( - _self.into(), + &_self, ) .into(); output @@ -2364,7 +2309,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "is_acute", |_self: Ref| { let output: bool = ::bevy::math::primitives::Triangle2d::is_acute( - _self.into(), + &_self, ) .into(); output @@ -2374,7 +2319,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "is_obtuse", |_self: Ref| { let output: bool = ::bevy::math::primitives::Triangle2d::is_obtuse( - _self.into(), + &_self, ) .into(); output @@ -2384,7 +2329,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "reverse", |_self: Mut| { let output: () = ::bevy::math::primitives::Triangle2d::reverse( - _self.into(), + &mut_self, ) .into(); output @@ -2399,47 +2344,23 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .into(); output }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::Triangle2d::clone( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "eq", - | - _self: Ref, - other: Ref| - { - let output: bool = ::bevy::math::primitives::Triangle2d::eq( - _self.into(), - other.into(), - ) - .into(); - output - }, ); NamespaceBuilder::<::bevy::math::bounding::Aabb3d>::new(world) .overwrite_script_function( - "clone", + "bounding_sphere", |_self: Ref| { - let output: Val = ::bevy::math::bounding::Aabb3d::clone( - _self.into(), + let output: Val = ::bevy::math::bounding::Aabb3d::bounding_sphere( + &_self, ) .into(); output }, ) .overwrite_script_function( - "bounding_sphere", + "clone", |_self: Ref| { - let output: Val = ::bevy::math::bounding::Aabb3d::bounding_sphere( - _self.into(), + let output: Val = ::bevy::math::bounding::Aabb3d::clone( + &_self, ) .into(); output @@ -2450,7 +2371,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "radius", |_self: Ref| { let output: f32 = ::bevy::math::bounding::BoundingSphere::radius( - _self.into(), + &_self, ) .into(); output @@ -2460,7 +2381,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "aabb_3d", |_self: Ref| { let output: Val = ::bevy::math::bounding::BoundingSphere::aabb_3d( - _self.into(), + &_self, ) .into(); output @@ -2470,7 +2391,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::bounding::BoundingSphere::clone( - _self.into(), + &_self, ) .into(); output @@ -2484,18 +2405,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::Sphere::eq( - _self.into(), - other.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::Sphere::clone( - _self.into(), + &_self, + &other, ) .into(); output @@ -2505,7 +2416,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "new", |radius: f32| { let output: Val = ::bevy::math::primitives::Sphere::new( - radius.into(), + radius, ) .into(); output @@ -2514,45 +2425,29 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "diameter", |_self: Ref| { - let output: f32 = ::bevy::math::primitives::Sphere::diameter( - _self.into(), - ) - .into(); - output - }, - ); - NamespaceBuilder::<::bevy::math::primitives::Cuboid>::new(world) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::Cuboid::clone( - _self.into(), - ) + let output: f32 = ::bevy::math::primitives::Sphere::diameter(&_self) .into(); output }, ) .overwrite_script_function( - "eq", - | - _self: Ref, - other: Ref| - { - let output: bool = ::bevy::math::primitives::Cuboid::eq( - _self.into(), - other.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::primitives::Sphere::clone( + &_self, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::primitives::Cuboid>::new(world) .overwrite_script_function( "new", |x_length: f32, y_length: f32, z_length: f32| { let output: Val = ::bevy::math::primitives::Cuboid::new( - x_length.into(), - y_length.into(), - z_length.into(), + x_length, + y_length, + z_length, ) .into(); output @@ -2562,43 +2457,43 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "from_length", |length: f32| { let output: Val = ::bevy::math::primitives::Cuboid::from_length( - length.into(), + length, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::primitives::Cylinder>::new(world) + ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::Cylinder::clone( - _self.into(), + "eq", + | + _self: Ref, + other: Ref| + { + let output: bool = ::bevy::math::primitives::Cuboid::eq( + &_self, + &other, ) .into(); output }, ) .overwrite_script_function( - "eq", - | - _self: Ref, - other: Ref| - { - let output: bool = ::bevy::math::primitives::Cylinder::eq( - _self.into(), - other.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::primitives::Cuboid::clone( + &_self, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::primitives::Cylinder>::new(world) .overwrite_script_function( "new", |radius: f32, height: f32| { let output: Val = ::bevy::math::primitives::Cylinder::new( - radius.into(), - height.into(), + radius, + height, ) .into(); output @@ -2608,7 +2503,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "base", |_self: Ref| { let output: Val = ::bevy::math::primitives::Cylinder::base( - _self.into(), + &_self, ) .into(); output @@ -2618,7 +2513,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "lateral_area", |_self: Ref| { let output: f32 = ::bevy::math::primitives::Cylinder::lateral_area( - _self.into(), + &_self, ) .into(); output @@ -2628,18 +2523,17 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "base_area", |_self: Ref| { let output: f32 = ::bevy::math::primitives::Cylinder::base_area( - _self.into(), + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::primitives::Capsule3d>::new(world) + ) .overwrite_script_function( "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::Capsule3d::clone( - _self.into(), + |_self: Ref| { + let output: Val = ::bevy::math::primitives::Cylinder::clone( + &_self, ) .into(); output @@ -2648,23 +2542,24 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "eq", | - _self: Ref, - other: Ref| + _self: Ref, + other: Ref| { - let output: bool = ::bevy::math::primitives::Capsule3d::eq( - _self.into(), - other.into(), + let output: bool = ::bevy::math::primitives::Cylinder::eq( + &_self, + &other, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::primitives::Capsule3d>::new(world) .overwrite_script_function( "new", |radius: f32, length: f32| { let output: Val = ::bevy::math::primitives::Capsule3d::new( - radius.into(), - length.into(), + radius, + length, ) .into(); output @@ -2674,7 +2569,31 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "to_cylinder", |_self: Ref| { let output: Val = ::bevy::math::primitives::Capsule3d::to_cylinder( - _self.into(), + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "eq", + | + _self: Ref, + other: Ref| + { + let output: bool = ::bevy::math::primitives::Capsule3d::eq( + &_self, + &other, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::primitives::Capsule3d::clone( + &_self, ) .into(); output @@ -2685,8 +2604,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "new", |radius: f32, height: f32| { let output: Val = ::bevy::math::primitives::Cone::new( - radius.into(), - height.into(), + radius, + height, ) .into(); output @@ -2696,7 +2615,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "base", |_self: Ref| { let output: Val = ::bevy::math::primitives::Cone::base( - _self.into(), + &_self, ) .into(); output @@ -2706,7 +2625,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "slant_height", |_self: Ref| { let output: f32 = ::bevy::math::primitives::Cone::slant_height( - _self.into(), + &_self, ) .into(); output @@ -2716,7 +2635,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "lateral_area", |_self: Ref| { let output: f32 = ::bevy::math::primitives::Cone::lateral_area( - _self.into(), + &_self, ) .into(); output @@ -2725,9 +2644,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { .overwrite_script_function( "base_area", |_self: Ref| { - let output: f32 = ::bevy::math::primitives::Cone::base_area( - _self.into(), - ) + let output: f32 = ::bevy::math::primitives::Cone::base_area(&_self) .into(); output }, @@ -2736,7 +2653,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::primitives::Cone::clone( - _self.into(), + &_self, ) .into(); output @@ -2748,15 +2665,22 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { _self: Ref, other: Ref| { - let output: bool = ::bevy::math::primitives::Cone::eq( - _self.into(), - other.into(), + let output: bool = ::bevy::math::primitives::Cone::eq(&_self, &other) + .into(); + output + }, + ); + NamespaceBuilder::<::bevy::math::primitives::ConicalFrustum>::new(world) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::primitives::ConicalFrustum::clone( + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::primitives::ConicalFrustum>::new(world) + ) .overwrite_script_function( "eq", | @@ -2764,18 +2688,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::ConicalFrustum::eq( - _self.into(), - other.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::ConicalFrustum::clone( - _self.into(), + &_self, + &other, ) .into(); output @@ -2786,7 +2700,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::primitives::InfinitePlane3d::clone( - _self.into(), + &_self, ) .into(); output @@ -2799,24 +2713,14 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::InfinitePlane3d::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output }, ); NamespaceBuilder::<::bevy::math::primitives::Line3d>::new(world) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::Line3d::clone( - _self.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "eq", | @@ -2824,8 +2728,18 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::Line3d::eq( - _self.into(), - other.into(), + &_self, + &other, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::primitives::Line3d::clone( + &_self, ) .into(); output @@ -2837,7 +2751,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { |direction: Val, length: f32| { let output: Val = ::bevy::math::primitives::Segment3d::new( direction.into(), - length.into(), + length, ) .into(); output @@ -2850,8 +2764,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::Segment3d::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -2861,7 +2775,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::primitives::Segment3d::clone( - _self.into(), + &_self, ) .into(); output @@ -2872,21 +2786,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::primitives::Torus::clone( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "eq", - | - _self: Ref, - other: Ref| - { - let output: bool = ::bevy::math::primitives::Torus::eq( - _self.into(), - other.into(), + &_self, ) .into(); output @@ -2896,8 +2796,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "new", |inner_radius: f32, outer_radius: f32| { let output: Val = ::bevy::math::primitives::Torus::new( - inner_radius.into(), - outer_radius.into(), + inner_radius, + outer_radius, ) .into(); output @@ -2907,7 +2807,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "inner_radius", |_self: Ref| { let output: f32 = ::bevy::math::primitives::Torus::inner_radius( - _self.into(), + &_self, ) .into(); output @@ -2917,32 +2817,32 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "outer_radius", |_self: Ref| { let output: f32 = ::bevy::math::primitives::Torus::outer_radius( - _self.into(), + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::primitives::Triangle3d>::new(world) + ) .overwrite_script_function( "eq", | - _self: Ref, - other: Ref| + _self: Ref, + other: Ref| { - let output: bool = ::bevy::math::primitives::Triangle3d::eq( - _self.into(), - other.into(), + let output: bool = ::bevy::math::primitives::Torus::eq( + &_self, + &other, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::primitives::Triangle3d>::new(world) .overwrite_script_function( "is_degenerate", |_self: Ref| { let output: bool = ::bevy::math::primitives::Triangle3d::is_degenerate( - _self.into(), + &_self, ) .into(); output @@ -2952,7 +2852,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "is_acute", |_self: Ref| { let output: bool = ::bevy::math::primitives::Triangle3d::is_acute( - _self.into(), + &_self, ) .into(); output @@ -2962,7 +2862,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "is_obtuse", |_self: Ref| { let output: bool = ::bevy::math::primitives::Triangle3d::is_obtuse( - _self.into(), + &_self, ) .into(); output @@ -2972,7 +2872,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "reverse", |_self: Mut| { let output: () = ::bevy::math::primitives::Triangle3d::reverse( - _self.into(), + &mut_self, ) .into(); output @@ -2989,32 +2889,36 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::primitives::Triangle3d::clone( - _self.into(), + "eq", + | + _self: Ref, + other: Ref| + { + let output: bool = ::bevy::math::primitives::Triangle3d::eq( + &_self, + &other, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::bounding::RayCast2d>::new(world) + ) .overwrite_script_function( "clone", - |_self: Ref| { - let output: Val = ::bevy::math::bounding::RayCast2d::clone( - _self.into(), + |_self: Ref| { + let output: Val = ::bevy::math::primitives::Triangle3d::clone( + &_self, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::bounding::RayCast2d>::new(world) .overwrite_script_function( "from_ray", |ray: Val, max: f32| { let output: Val = ::bevy::math::bounding::RayCast2d::from_ray( ray.into(), - max.into(), + max, ) .into(); output @@ -3027,8 +2931,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { aabb: Ref| { let output: std::option::Option = ::bevy::math::bounding::RayCast2d::aabb_intersection_at( - _self.into(), - aabb.into(), + &_self, + &aabb, ) .into(); output @@ -3041,14 +2945,34 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { circle: Ref| { let output: std::option::Option = ::bevy::math::bounding::RayCast2d::circle_intersection_at( - _self.into(), - circle.into(), + &_self, + &circle, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::bounding::RayCast2d::clone( + &_self, ) .into(); output }, ); NamespaceBuilder::<::bevy::math::bounding::AabbCast2d>::new(world) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::bounding::AabbCast2d::clone( + &_self, + ) + .into(); + output + }, + ) .overwrite_script_function( "from_ray", | @@ -3059,7 +2983,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { let output: Val = ::bevy::math::bounding::AabbCast2d::from_ray( aabb.into(), ray.into(), - max.into(), + max, ) .into(); output @@ -3072,22 +2996,12 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { aabb: Val| { let output: std::option::Option = ::bevy::math::bounding::AabbCast2d::aabb_collision_at( - _self.into(), + &_self, aabb.into(), ) .into(); output }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::bounding::AabbCast2d::clone( - _self.into(), - ) - .into(); - output - }, ); NamespaceBuilder::<::bevy::math::bounding::BoundingCircleCast>::new(world) .overwrite_script_function( @@ -3100,7 +3014,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { let output: Val = ::bevy::math::bounding::BoundingCircleCast::from_ray( circle.into(), ray.into(), - max.into(), + max, ) .into(); output @@ -3113,7 +3027,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { circle: Val| { let output: std::option::Option = ::bevy::math::bounding::BoundingCircleCast::circle_collision_at( - _self.into(), + &_self, circle.into(), ) .into(); @@ -3124,29 +3038,19 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::bounding::BoundingCircleCast::clone( - _self.into(), + &_self, ) .into(); output }, ); NamespaceBuilder::<::bevy::math::bounding::RayCast3d>::new(world) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::bounding::RayCast3d::clone( - _self.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "from_ray", |ray: Val, max: f32| { let output: Val = ::bevy::math::bounding::RayCast3d::from_ray( ray.into(), - max.into(), + max, ) .into(); output @@ -3159,8 +3063,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { aabb: Ref| { let output: std::option::Option = ::bevy::math::bounding::RayCast3d::aabb_intersection_at( - _self.into(), - aabb.into(), + &_self, + &aabb, ) .into(); output @@ -3173,8 +3077,18 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { sphere: Ref| { let output: std::option::Option = ::bevy::math::bounding::RayCast3d::sphere_intersection_at( - _self.into(), - sphere.into(), + &_self, + &sphere, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::bounding::RayCast3d::clone( + &_self, ) .into(); output @@ -3191,7 +3105,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { let output: Val = ::bevy::math::bounding::AabbCast3d::from_ray( aabb.into(), ray.into(), - max.into(), + max, ) .into(); output @@ -3204,7 +3118,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { aabb: Val| { let output: std::option::Option = ::bevy::math::bounding::AabbCast3d::aabb_collision_at( - _self.into(), + &_self, aabb.into(), ) .into(); @@ -3215,13 +3129,23 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::bounding::AabbCast3d::clone( - _self.into(), + &_self, ) .into(); output }, ); NamespaceBuilder::<::bevy::math::bounding::BoundingSphereCast>::new(world) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::bounding::BoundingSphereCast::clone( + &_self, + ) + .into(); + output + }, + ) .overwrite_script_function( "from_ray", | @@ -3232,7 +3156,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { let output: Val = ::bevy::math::bounding::BoundingSphereCast::from_ray( sphere.into(), ray.into(), - max.into(), + max, ) .into(); output @@ -3245,33 +3169,19 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { sphere: Val| { let output: std::option::Option = ::bevy::math::bounding::BoundingSphereCast::sphere_collision_at( - _self.into(), + &_self, sphere.into(), ) .into(); output }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::bounding::BoundingSphereCast::clone( - _self.into(), - ) - .into(); - output - }, ); NamespaceBuilder::<::bevy::math::curve::interval::Interval>::new(world) .overwrite_script_function( - "eq", - | - _self: Ref, - other: Ref| - { - let output: bool = ::bevy::math::curve::interval::Interval::eq( - _self.into(), - other.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::curve::interval::Interval::clone( + &_self, ) .into(); output @@ -3342,7 +3252,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { |_self: Val, item: f32| { let output: bool = ::bevy::math::curve::interval::Interval::contains( _self.into(), - item.into(), + item, ) .into(); output @@ -3367,95 +3277,79 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { |_self: Val, value: f32| { let output: f32 = ::bevy::math::curve::interval::Interval::clamp( _self.into(), - value.into(), + value, ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::curve::interval::Interval::clone( - _self.into(), + "eq", + | + _self: Ref, + other: Ref| + { + let output: bool = ::bevy::math::curve::interval::Interval::eq( + &_self, + &other, ) .into(); output }, ); NamespaceBuilder::<::bevy::math::FloatOrd>::new(world) - .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::FloatOrd::neg( - _self.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "clone", |_self: Ref| { let output: Val = ::bevy::math::FloatOrd::clone( - _self.into(), + &_self, ) .into(); output }, ) .overwrite_script_function( - "eq", + "lt", |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::FloatOrd::eq( - _self.into(), - other.into(), - ) - .into(); + let output: bool = ::bevy::math::FloatOrd::lt(&_self, &other).into(); output }, ) .overwrite_script_function( - "lt", + "le", |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::FloatOrd::lt( - _self.into(), - other.into(), - ) - .into(); + let output: bool = ::bevy::math::FloatOrd::le(&_self, &other).into(); output }, ) .overwrite_script_function( - "le", + "gt", |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::FloatOrd::le( - _self.into(), - other.into(), - ) - .into(); + let output: bool = ::bevy::math::FloatOrd::gt(&_self, &other).into(); output }, ) .overwrite_script_function( - "gt", + "ge", |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::FloatOrd::gt( + let output: bool = ::bevy::math::FloatOrd::ge(&_self, &other).into(); + output + }, + ) + .overwrite_script_function( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::FloatOrd::neg( _self.into(), - other.into(), ) .into(); output }, ) .overwrite_script_function( - "ge", + "eq", |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::FloatOrd::ge( - _self.into(), - other.into(), - ) - .into(); + let output: bool = ::bevy::math::FloatOrd::eq(&_self, &other).into(); output }, ); @@ -3464,7 +3358,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::primitives::Plane3d::clone( - _self.into(), + &_self, ) .into(); output @@ -3477,8 +3371,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::Plane3d::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -3489,7 +3383,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "signed_volume", |_self: Ref| { let output: f32 = ::bevy::math::primitives::Tetrahedron::signed_volume( - _self.into(), + &_self, ) .into(); output @@ -3502,8 +3396,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::primitives::Tetrahedron::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -3513,7 +3407,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::primitives::Tetrahedron::clone( - _self.into(), + &_self, ) .into(); output @@ -3524,7 +3418,7 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::curve::easing::EaseFunction::clone( - _self.into(), + &_self, ) .into(); output @@ -3537,8 +3431,8 @@ impl ::bevy::app::Plugin for BevyMathScriptingPlugin { other: Ref| { let output: bool = ::bevy::math::curve::easing::EaseFunction::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output diff --git a/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_reflect.rs b/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_reflect.rs index 603a8e68d0..7b3be573bb 100644 --- a/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_reflect.rs +++ b/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_reflect.rs @@ -6,7 +6,7 @@ use bevy_mod_scripting_core::{ AddContextInitializer, StoreDocumentation, bindings::{ReflectReference, function::from::{Ref, Mut, Val}}, }; -use crate::*; +use crate::{*, namespaced_register::NamespaceBuilder}; pub struct BevyReflectScriptingPlugin; impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { fn build(&self, app: &mut ::bevy::prelude::App) { @@ -16,7 +16,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |v: bool| { let output: Val = ::std::sync::atomic::AtomicBool::new( - v.into(), + v, ) .into(); output @@ -37,7 +37,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |v: i16| { let output: Val = ::std::sync::atomic::AtomicI16::new( - v.into(), + v, ) .into(); output @@ -58,7 +58,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |v: i32| { let output: Val = ::std::sync::atomic::AtomicI32::new( - v.into(), + v, ) .into(); output @@ -79,7 +79,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |v: i64| { let output: Val = ::std::sync::atomic::AtomicI64::new( - v.into(), + v, ) .into(); output @@ -100,7 +100,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |v: i8| { let output: Val = ::std::sync::atomic::AtomicI8::new( - v.into(), + v, ) .into(); output @@ -121,7 +121,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |v: isize| { let output: Val = ::std::sync::atomic::AtomicIsize::new( - v.into(), + v, ) .into(); output @@ -142,7 +142,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |v: u16| { let output: Val = ::std::sync::atomic::AtomicU16::new( - v.into(), + v, ) .into(); output @@ -163,7 +163,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |v: u32| { let output: Val = ::std::sync::atomic::AtomicU32::new( - v.into(), + v, ) .into(); output @@ -184,7 +184,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |v: u64| { let output: Val = ::std::sync::atomic::AtomicU64::new( - v.into(), + v, ) .into(); output @@ -205,7 +205,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |v: u8| { let output: Val = ::std::sync::atomic::AtomicU8::new( - v.into(), + v, ) .into(); output @@ -226,7 +226,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |v: usize| { let output: Val = ::std::sync::atomic::AtomicUsize::new( - v.into(), + v, ) .into(); output @@ -248,7 +248,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: u32| { let output: Val = ::bevy::utils::Duration::mul( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -258,7 +258,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::bevy::utils::Duration::assert_receiver_is_total_eq( - _self.into(), + &_self, ) .into(); output @@ -268,7 +268,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::utils::Duration::clone( - _self.into(), + &_self, ) .into(); output @@ -299,10 +299,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "eq", |_self: Ref, other: Ref| { - let output: bool = ::bevy::utils::Duration::eq( - _self.into(), - other.into(), - ) + let output: bool = ::bevy::utils::Duration::eq(&_self, &other) .into(); output }, @@ -312,7 +309,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: u32| { let output: Val = ::bevy::utils::Duration::div( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -322,8 +319,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |secs: u64, nanos: u32| { let output: Val = ::bevy::utils::Duration::new( - secs.into(), - nanos.into(), + secs, + nanos, ) .into(); output @@ -333,7 +330,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_secs", |secs: u64| { let output: Val = ::bevy::utils::Duration::from_secs( - secs.into(), + secs, ) .into(); output @@ -343,7 +340,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_millis", |millis: u64| { let output: Val = ::bevy::utils::Duration::from_millis( - millis.into(), + millis, ) .into(); output @@ -353,7 +350,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_micros", |micros: u64| { let output: Val = ::bevy::utils::Duration::from_micros( - micros.into(), + micros, ) .into(); output @@ -363,7 +360,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_nanos", |nanos: u64| { let output: Val = ::bevy::utils::Duration::from_nanos( - nanos.into(), + nanos, ) .into(); output @@ -372,25 +369,21 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "is_zero", |_self: Ref| { - let output: bool = ::bevy::utils::Duration::is_zero(_self.into()) - .into(); + let output: bool = ::bevy::utils::Duration::is_zero(&_self).into(); output }, ) .overwrite_script_function( "as_secs", |_self: Ref| { - let output: u64 = ::bevy::utils::Duration::as_secs(_self.into()) - .into(); + let output: u64 = ::bevy::utils::Duration::as_secs(&_self).into(); output }, ) .overwrite_script_function( "subsec_millis", |_self: Ref| { - let output: u32 = ::bevy::utils::Duration::subsec_millis( - _self.into(), - ) + let output: u32 = ::bevy::utils::Duration::subsec_millis(&_self) .into(); output }, @@ -398,9 +391,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "subsec_micros", |_self: Ref| { - let output: u32 = ::bevy::utils::Duration::subsec_micros( - _self.into(), - ) + let output: u32 = ::bevy::utils::Duration::subsec_micros(&_self) .into(); output }, @@ -408,7 +399,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "subsec_nanos", |_self: Ref| { - let output: u32 = ::bevy::utils::Duration::subsec_nanos(_self.into()) + let output: u32 = ::bevy::utils::Duration::subsec_nanos(&_self) .into(); output }, @@ -416,24 +407,21 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "as_millis", |_self: Ref| { - let output: u128 = ::bevy::utils::Duration::as_millis(_self.into()) - .into(); + let output: u128 = ::bevy::utils::Duration::as_millis(&_self).into(); output }, ) .overwrite_script_function( "as_micros", |_self: Ref| { - let output: u128 = ::bevy::utils::Duration::as_micros(_self.into()) - .into(); + let output: u128 = ::bevy::utils::Duration::as_micros(&_self).into(); output }, ) .overwrite_script_function( "as_nanos", |_self: Ref| { - let output: u128 = ::bevy::utils::Duration::as_nanos(_self.into()) - .into(); + let output: u128 = ::bevy::utils::Duration::as_nanos(&_self).into(); output }, ) @@ -475,7 +463,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: u32| { let output: Val = ::bevy::utils::Duration::saturating_mul( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -484,7 +472,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "as_secs_f64", |_self: Ref| { - let output: f64 = ::bevy::utils::Duration::as_secs_f64(_self.into()) + let output: f64 = ::bevy::utils::Duration::as_secs_f64(&_self) .into(); output }, @@ -492,7 +480,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "as_secs_f32", |_self: Ref| { - let output: f32 = ::bevy::utils::Duration::as_secs_f32(_self.into()) + let output: f32 = ::bevy::utils::Duration::as_secs_f32(&_self) .into(); output }, @@ -501,7 +489,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_secs_f64", |secs: f64| { let output: Val = ::bevy::utils::Duration::from_secs_f64( - secs.into(), + secs, ) .into(); output @@ -511,7 +499,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_secs_f32", |secs: f32| { let output: Val = ::bevy::utils::Duration::from_secs_f32( - secs.into(), + secs, ) .into(); output @@ -522,7 +510,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: f64| { let output: Val = ::bevy::utils::Duration::mul_f64( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -533,7 +521,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: f32| { let output: Val = ::bevy::utils::Duration::mul_f32( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -544,7 +532,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: f64| { let output: Val = ::bevy::utils::Duration::div_f64( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -555,7 +543,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: f32| { let output: Val = ::bevy::utils::Duration::div_f32( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -588,7 +576,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::bevy::utils::Instant::assert_receiver_is_total_eq( - _self.into(), + &_self, ) .into(); output @@ -597,11 +585,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "eq", |_self: Ref, other: Ref| { - let output: bool = ::bevy::utils::Instant::eq( - _self.into(), - other.into(), - ) - .into(); + let output: bool = ::bevy::utils::Instant::eq(&_self, &other).into(); output }, ) @@ -639,7 +623,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "duration_since", |_self: Ref, earlier: Val| { let output: Val = ::bevy::utils::Instant::duration_since( - _self.into(), + &_self, earlier.into(), ) .into(); @@ -650,7 +634,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "saturating_duration_since", |_self: Ref, earlier: Val| { let output: Val = ::bevy::utils::Instant::saturating_duration_since( - _self.into(), + &_self, earlier.into(), ) .into(); @@ -661,7 +645,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "elapsed", |_self: Ref| { let output: Val = ::bevy::utils::Instant::elapsed( - _self.into(), + &_self, ) .into(); output @@ -671,7 +655,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::utils::Instant::clone( - _self.into(), + &_self, ) .into(); output @@ -693,7 +677,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::std::ops::RangeFull::clone( - _self.into(), + &_self, ) .into(); output @@ -703,7 +687,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::std::ops::RangeFull::assert_receiver_is_total_eq( - _self.into(), + &_self, ) .into(); output @@ -712,18 +696,51 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "eq", |_self: Ref, other: Ref| { - let output: bool = ::std::ops::RangeFull::eq( + let output: bool = ::std::ops::RangeFull::eq(&_self, &other).into(); + output + }, + ); + NamespaceBuilder::<::bevy::math::Quat>::new(world) + .overwrite_script_function( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Quat::mul( _self.into(), - other.into(), + rhs.into(), ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::Quat>::new(world) + ) + .overwrite_script_function( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Quat::add( + _self.into(), + rhs.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "eq", + |_self: Ref, rhs: Ref| { + let output: bool = ::bevy::math::Quat::eq(&_self, &rhs).into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::Quat::clone(&_self) + .into(); + output + }, + ) .overwrite_script_function( "mul", - |_self: Val, rhs: f32| { + |_self: Val, rhs: Val| { let output: Val = ::bevy::math::Quat::mul( _self.into(), rhs.into(), @@ -732,6 +749,17 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) + .overwrite_script_function( + "mul", + |_self: Val, rhs: f32| { + let output: Val = ::bevy::math::Quat::mul( + _self.into(), + rhs, + ) + .into(); + output + }, + ) .overwrite_script_function( "sub", |_self: Val, rhs: Val| { @@ -755,8 +783,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Quat::mul( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Quat::mul( _self.into(), rhs.into(), ) @@ -765,10 +793,11 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::Quat::clone( + "div", + |_self: Val, rhs: f32| { + let output: Val = ::bevy::math::Quat::div( _self.into(), + rhs, ) .into(); output @@ -778,10 +807,10 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_xyzw", |x: f32, y: f32, z: f32, w: f32| { let output: Val = ::bevy::math::Quat::from_xyzw( - x.into(), - y.into(), - z.into(), - w.into(), + x, + y, + z, + w, ) .into(); output @@ -790,9 +819,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "from_array", |a: [f32; 4]| { - let output: Val = ::bevy::math::Quat::from_array( - a.into(), - ) + let output: Val = ::bevy::math::Quat::from_array(a) .into(); output }, @@ -812,7 +839,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |axis: Val, angle: f32| { let output: Val = ::bevy::math::Quat::from_axis_angle( axis.into(), - angle.into(), + angle, ) .into(); output @@ -832,7 +859,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_x", |angle: f32| { let output: Val = ::bevy::math::Quat::from_rotation_x( - angle.into(), + angle, ) .into(); output @@ -842,7 +869,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_y", |angle: f32| { let output: Val = ::bevy::math::Quat::from_rotation_y( - angle.into(), + angle, ) .into(); output @@ -852,7 +879,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_z", |angle: f32| { let output: Val = ::bevy::math::Quat::from_rotation_z( - angle.into(), + angle, ) .into(); output @@ -863,9 +890,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |euler: Val, a: f32, b: f32, c: f32| { let output: Val = ::bevy::math::Quat::from_euler( euler.into(), - a.into(), - b.into(), - c.into(), + a, + b, + c, ) .into(); output @@ -875,7 +902,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_mat3", |mat: Ref| { let output: Val = ::bevy::math::Quat::from_mat3( - mat.into(), + &mat, ) .into(); output @@ -885,7 +912,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_mat3a", |mat: Ref| { let output: Val = ::bevy::math::Quat::from_mat3a( - mat.into(), + &mat, ) .into(); output @@ -895,7 +922,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_mat4", |mat: Ref| { let output: Val = ::bevy::math::Quat::from_mat4( - mat.into(), + &mat, ) .into(); output @@ -958,8 +985,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_array", |_self: Ref| { - let output: [f32; 4] = ::bevy::math::Quat::to_array(_self.into()) - .into(); + let output: [f32; 4] = ::bevy::math::Quat::to_array(&_self).into(); output }, ) @@ -1084,9 +1110,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { max_angle: f32| { let output: Val = ::bevy::math::Quat::rotate_towards( - _self.into(), + &_self, rhs.into(), - max_angle.into(), + max_angle, ) .into(); output @@ -1102,7 +1128,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: bool = ::bevy::math::Quat::abs_diff_eq( _self.into(), rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -1114,7 +1140,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::Quat::lerp( _self.into(), end.into(), - s.into(), + s, ) .into(); output @@ -1126,7 +1152,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::Quat::slerp( _self.into(), end.into(), - s.into(), + s, ) .into(); output @@ -1158,7 +1184,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_affine3", |a: Ref| { let output: Val = ::bevy::math::Quat::from_affine3( - a.into(), + &a, ) .into(); output @@ -1184,21 +1210,14 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .into(); output }, - ) - .overwrite_script_function( - "eq", - |_self: Ref, rhs: Ref| { - let output: bool = ::bevy::math::Quat::eq(_self.into(), rhs.into()) - .into(); - output - }, - ) + ); + NamespaceBuilder::<::bevy::math::Vec3>::new(world) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Quat::mul( + "sub", + |_self: Val, rhs: f32| { + let output: Val = ::bevy::math::Vec3::sub( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -1206,8 +1225,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Quat::mul( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Vec3::mul( _self.into(), rhs.into(), ) @@ -1216,9 +1235,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Quat::div( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Vec3::add( _self.into(), rhs.into(), ) @@ -1227,23 +1246,22 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Quat::add( + "rem", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::Vec3::rem( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::Vec3>::new(world) + ) .overwrite_script_function( - "mul", + "sub", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::Vec3::mul( + let output: Val = ::bevy::math::Vec3::sub( _self.into(), - rhs.into(), + &rhs, ) .into(); output @@ -1254,7 +1272,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: Ref| { let output: Val = ::bevy::math::Vec3::div( _self.into(), - rhs.into(), + &rhs, ) .into(); output @@ -1262,259 +1280,141 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "mul", - |_self: Val, rhs: Val| { + |_self: Val, rhs: Ref| { let output: Val = ::bevy::math::Vec3::mul( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Vec3::add( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::Vec3::neg( _self.into(), - rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::Vec3::clone( + "add", + |_self: Val, rhs: f32| { + let output: Val = ::bevy::math::Vec3::add( _self.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Vec3::sub( - _self.into(), - rhs.into(), - ) + "new", + |x: f32, y: f32, z: f32| { + let output: Val = ::bevy::math::Vec3::new(x, y, z) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Vec3::rem( - _self.into(), - rhs.into(), - ) + "splat", + |v: f32| { + let output: Val = ::bevy::math::Vec3::splat(v) .into(); output }, ) .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::Vec3::neg( - _self.into(), + "select", + | + mask: Val, + if_true: Val, + if_false: Val| + { + let output: Val = ::bevy::math::Vec3::select( + mask.into(), + if_true.into(), + if_false.into(), ) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Vec3::mul( - _self.into(), - rhs.into(), - ) + "from_array", + |a: [f32; 3]| { + let output: Val = ::bevy::math::Vec3::from_array(a) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::Vec3::sub( - _self.into(), - rhs.into(), - ) - .into(); + "to_array", + |_self: Ref| { + let output: [f32; 3] = ::bevy::math::Vec3::to_array(&_self).into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Vec3::div( + "extend", + |_self: Val, w: f32| { + let output: Val = ::bevy::math::Vec3::extend( _self.into(), - rhs.into(), + w, ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::Vec3::add( + "truncate", + |_self: Val| { + let output: Val = ::bevy::math::Vec3::truncate( _self.into(), - rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::Vec3::rem( + "with_x", + |_self: Val, x: f32| { + let output: Val = ::bevy::math::Vec3::with_x( _self.into(), - rhs.into(), + x, ) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Vec3::rem( + "with_y", + |_self: Val, y: f32| { + let output: Val = ::bevy::math::Vec3::with_y( _self.into(), - rhs.into(), + y, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Vec3::div( + "with_z", + |_self: Val, z: f32| { + let output: Val = ::bevy::math::Vec3::with_z( _self.into(), - rhs.into(), + z, ) .into(); output }, ) .overwrite_script_function( - "new", - |x: f32, y: f32, z: f32| { - let output: Val = ::bevy::math::Vec3::new( - x.into(), - y.into(), - z.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "splat", - |v: f32| { - let output: Val = ::bevy::math::Vec3::splat( - v.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "select", - | - mask: Val, - if_true: Val, - if_false: Val| - { - let output: Val = ::bevy::math::Vec3::select( - mask.into(), - if_true.into(), - if_false.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "from_array", - |a: [f32; 3]| { - let output: Val = ::bevy::math::Vec3::from_array( - a.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "to_array", - |_self: Ref| { - let output: [f32; 3] = ::bevy::math::Vec3::to_array(_self.into()) - .into(); - output - }, - ) - .overwrite_script_function( - "extend", - |_self: Val, w: f32| { - let output: Val = ::bevy::math::Vec3::extend( - _self.into(), - w.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "truncate", - |_self: Val| { - let output: Val = ::bevy::math::Vec3::truncate( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "with_x", - |_self: Val, x: f32| { - let output: Val = ::bevy::math::Vec3::with_x( - _self.into(), - x.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "with_y", - |_self: Val, y: f32| { - let output: Val = ::bevy::math::Vec3::with_y( - _self.into(), - y.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "with_z", - |_self: Val, z: f32| { - let output: Val = ::bevy::math::Vec3::with_z( - _self.into(), - z.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "dot", - |_self: Val, rhs: Val| { - let output: f32 = ::bevy::math::Vec3::dot(_self.into(), rhs.into()) + "dot", + |_self: Val, rhs: Val| { + let output: f32 = ::bevy::math::Vec3::dot(_self.into(), rhs.into()) .into(); output }, @@ -1978,7 +1878,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, n: f32| { let output: Val = ::bevy::math::Vec3::powf( _self.into(), - n.into(), + n, ) .into(); output @@ -2000,7 +1900,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::Vec3::lerp( _self.into(), rhs.into(), - s.into(), + s, ) .into(); output @@ -2010,9 +1910,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "move_towards", |_self: Ref, rhs: Val, d: f32| { let output: Val = ::bevy::math::Vec3::move_towards( - _self.into(), + &_self, rhs.into(), - d.into(), + d, ) .into(); output @@ -2039,7 +1939,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: bool = ::bevy::math::Vec3::abs_diff_eq( _self.into(), rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -2050,8 +1950,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, min: f32, max: f32| { let output: Val = ::bevy::math::Vec3::clamp_length( _self.into(), - min.into(), - max.into(), + min, + max, ) .into(); output @@ -2062,7 +1962,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, max: f32| { let output: Val = ::bevy::math::Vec3::clamp_length_max( _self.into(), - max.into(), + max, ) .into(); output @@ -2073,7 +1973,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, min: f32| { let output: Val = ::bevy::math::Vec3::clamp_length_min( _self.into(), - min.into(), + min, ) .into(); output @@ -2112,7 +2012,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::Vec3::refract( _self.into(), normal.into(), - eta.into(), + eta, ) .into(); output @@ -2133,7 +2033,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "any_orthogonal_vector", |_self: Ref| { let output: Val = ::bevy::math::Vec3::any_orthogonal_vector( - _self.into(), + &_self, ) .into(); output @@ -2143,7 +2043,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "any_orthonormal_vector", |_self: Ref| { let output: Val = ::bevy::math::Vec3::any_orthonormal_vector( - _self.into(), + &_self, ) .into(); output @@ -2153,7 +2053,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dvec3", |_self: Ref| { let output: Val = ::bevy::math::Vec3::as_dvec3( - _self.into(), + &_self, ) .into(); output @@ -2163,7 +2063,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_ivec3", |_self: Ref| { let output: Val = ::bevy::math::Vec3::as_ivec3( - _self.into(), + &_self, ) .into(); output @@ -2173,7 +2073,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_uvec3", |_self: Ref| { let output: Val = ::bevy::math::Vec3::as_uvec3( - _self.into(), + &_self, ) .into(); output @@ -2183,7 +2083,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_i64vec3", |_self: Ref| { let output: Val = ::bevy::math::Vec3::as_i64vec3( - _self.into(), + &_self, ) .into(); output @@ -2193,26 +2093,26 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_u64vec3", |_self: Ref| { let output: Val = ::bevy::math::Vec3::as_u64vec3( - _self.into(), + &_self, ) .into(); output }, ) .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::Vec3::eq(_self.into(), other.into()) + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::Vec3::clone(&_self) .into(); output }, ) .overwrite_script_function( "add", - |_self: Val, rhs: f32| { + |_self: Val, rhs: Ref| { let output: Val = ::bevy::math::Vec3::add( _self.into(), - rhs.into(), + &rhs, ) .into(); output @@ -2228,23 +2128,22 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .into(); output }, - ); - NamespaceBuilder::<::bevy::math::IVec2>::new(world) + ) .overwrite_script_function( - "sub", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::IVec2::sub( + "div", + |_self: Val, rhs: f32| { + let output: Val = ::bevy::math::Vec3::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::IVec2::add( + "div", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Vec3::div( _self.into(), rhs.into(), ) @@ -2253,22 +2152,22 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::IVec2::sub( + "rem", + |_self: Val, rhs: f32| { + let output: Val = ::bevy::math::Vec3::rem( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: i32| { - let output: Val = ::bevy::math::IVec2::add( + "mul", + |_self: Val, rhs: f32| { + let output: Val = ::bevy::math::Vec3::mul( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -2276,8 +2175,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "rem", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::IVec2::rem( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Vec3::rem( _self.into(), rhs.into(), ) @@ -2286,22 +2185,30 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::IVec2::mul( + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::Vec3::eq(&_self, &other).into(); + output + }, + ); + NamespaceBuilder::<::bevy::math::IVec2>::new(world) + .overwrite_script_function( + "sub", + |_self: Val, rhs: i32| { + let output: Val = ::bevy::math::IVec2::sub( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: i32| { - let output: Val = ::bevy::math::IVec2::rem( + "div", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::IVec2::div( _self.into(), - rhs.into(), + &rhs, ) .into(); output @@ -2319,85 +2226,99 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::IVec2::rem( - _self.into(), - rhs.into(), - ) + "new", + |x: i32, y: i32| { + let output: Val = ::bevy::math::IVec2::new(x, y) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::IVec2::div( - _self.into(), - rhs.into(), - ) + "splat", + |v: i32| { + let output: Val = ::bevy::math::IVec2::splat(v) .into(); output }, ) .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::math::IVec2::assert_receiver_is_total_eq( - _self.into(), + "select", + | + mask: Val, + if_true: Val, + if_false: Val| + { + let output: Val = ::bevy::math::IVec2::select( + mask.into(), + if_true.into(), + if_false.into(), ) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: i32| { - let output: Val = ::bevy::math::IVec2::mul( - _self.into(), - rhs.into(), + "from_array", + |a: [i32; 2]| { + let output: Val = ::bevy::math::IVec2::from_array( + a, ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::IVec2::add( + "to_array", + |_self: Ref| { + let output: [i32; 2] = ::bevy::math::IVec2::to_array(&_self).into(); + output + }, + ) + .overwrite_script_function( + "extend", + |_self: Val, z: i32| { + let output: Val = ::bevy::math::IVec2::extend( _self.into(), - rhs.into(), + z, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::IVec2::div( + "with_x", + |_self: Val, x: i32| { + let output: Val = ::bevy::math::IVec2::with_x( _self.into(), - rhs.into(), + x, ) .into(); output }, ) .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::IVec2::eq( + "with_y", + |_self: Val, y: i32| { + let output: Val = ::bevy::math::IVec2::with_y( _self.into(), - other.into(), + y, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: i32| { - let output: Val = ::bevy::math::IVec2::div( + "dot", + |_self: Val, rhs: Val| { + let output: i32 = ::bevy::math::IVec2::dot(_self.into(), rhs.into()) + .into(); + output + }, + ) + .overwrite_script_function( + "dot_into_vec", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::IVec2::dot_into_vec( _self.into(), rhs.into(), ) @@ -2406,127 +2327,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: i32| { - let output: Val = ::bevy::math::IVec2::sub( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "new", - |x: i32, y: i32| { - let output: Val = ::bevy::math::IVec2::new( - x.into(), - y.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "splat", - |v: i32| { - let output: Val = ::bevy::math::IVec2::splat( - v.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "select", - | - mask: Val, - if_true: Val, - if_false: Val| - { - let output: Val = ::bevy::math::IVec2::select( - mask.into(), - if_true.into(), - if_false.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "from_array", - |a: [i32; 2]| { - let output: Val = ::bevy::math::IVec2::from_array( - a.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "to_array", - |_self: Ref| { - let output: [i32; 2] = ::bevy::math::IVec2::to_array(_self.into()) - .into(); - output - }, - ) - .overwrite_script_function( - "extend", - |_self: Val, z: i32| { - let output: Val = ::bevy::math::IVec2::extend( - _self.into(), - z.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "with_x", - |_self: Val, x: i32| { - let output: Val = ::bevy::math::IVec2::with_x( - _self.into(), - x.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "with_y", - |_self: Val, y: i32| { - let output: Val = ::bevy::math::IVec2::with_y( - _self.into(), - y.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "dot", - |_self: Val, rhs: Val| { - let output: i32 = ::bevy::math::IVec2::dot(_self.into(), rhs.into()) - .into(); - output - }, - ) - .overwrite_script_function( - "dot_into_vec", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::IVec2::dot_into_vec( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "min", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::IVec2::min( + "min", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::IVec2::min( _self.into(), rhs.into(), ) @@ -2766,7 +2569,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec2", |_self: Ref| { let output: Val = ::bevy::math::IVec2::as_vec2( - _self.into(), + &_self, ) .into(); output @@ -2776,7 +2579,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dvec2", |_self: Ref| { let output: Val = ::bevy::math::IVec2::as_dvec2( - _self.into(), + &_self, ) .into(); output @@ -2786,7 +2589,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_uvec2", |_self: Ref| { let output: Val = ::bevy::math::IVec2::as_uvec2( - _self.into(), + &_self, ) .into(); output @@ -2796,7 +2599,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_i64vec2", |_self: Ref| { let output: Val = ::bevy::math::IVec2::as_i64vec2( - _self.into(), + &_self, ) .into(); output @@ -2806,7 +2609,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_u64vec2", |_self: Ref| { let output: Val = ::bevy::math::IVec2::as_u64vec2( - _self.into(), + &_self, ) .into(); output @@ -2945,200 +2748,358 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::IVec2::neg( + "rem", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::IVec2::rem( _self.into(), + rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::IVec2::clone( + "mul", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::IVec2::mul( _self.into(), + &rhs, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::IVec3>::new(world) + ) .overwrite_script_function( - "rem", - |_self: Val, rhs: i32| { - let output: Val = ::bevy::math::IVec3::rem( + "sub", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::IVec2::sub( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::IVec3::div( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::IVec2::neg( _self.into(), - rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::math::IVec3::assert_receiver_is_total_eq( + "rem", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::IVec2::rem( _self.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::IVec3::sub( + "div", + |_self: Val, rhs: i32| { + let output: Val = ::bevy::math::IVec2::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "new", - |x: i32, y: i32, z: i32| { - let output: Val = ::bevy::math::IVec3::new( - x.into(), - y.into(), - z.into(), + "mul", + |_self: Val, rhs: i32| { + let output: Val = ::bevy::math::IVec2::mul( + _self.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "splat", - |v: i32| { - let output: Val = ::bevy::math::IVec3::splat( - v.into(), + "sub", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::IVec2::sub( + _self.into(), + rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "select", - | - mask: Val, - if_true: Val, - if_false: Val| - { - let output: Val = ::bevy::math::IVec3::select( - mask.into(), - if_true.into(), - if_false.into(), + "add", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::IVec2::add( + _self.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "from_array", - |a: [i32; 3]| { - let output: Val = ::bevy::math::IVec3::from_array( - a.into(), + "add", + |_self: Val, rhs: i32| { + let output: Val = ::bevy::math::IVec2::add( + _self.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "to_array", - |_self: Ref| { - let output: [i32; 3] = ::bevy::math::IVec3::to_array(_self.into()) + "rem", + |_self: Val, rhs: i32| { + let output: Val = ::bevy::math::IVec2::rem( + _self.into(), + rhs, + ) .into(); output }, ) .overwrite_script_function( - "extend", - |_self: Val, w: i32| { - let output: Val = ::bevy::math::IVec3::extend( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::IVec2::add( _self.into(), - w.into(), + rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "truncate", - |_self: Val| { - let output: Val = ::bevy::math::IVec3::truncate( - _self.into(), - ) - .into(); + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::IVec2::eq(&_self, &other).into(); output }, ) .overwrite_script_function( - "with_x", - |_self: Val, x: i32| { - let output: Val = ::bevy::math::IVec3::with_x( + "div", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::IVec2::div( _self.into(), - x.into(), + rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "with_y", - |_self: Val, y: i32| { - let output: Val = ::bevy::math::IVec3::with_y( - _self.into(), - y.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::IVec2::clone( + &_self, ) .into(); output }, ) .overwrite_script_function( - "with_z", - |_self: Val, z: i32| { - let output: Val = ::bevy::math::IVec3::with_z( - _self.into(), - z.into(), + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::math::IVec2::assert_receiver_is_total_eq( + &_self, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::IVec3>::new(world) .overwrite_script_function( - "dot", - |_self: Val, rhs: Val| { - let output: i32 = ::bevy::math::IVec3::dot(_self.into(), rhs.into()) + "sub", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::IVec3::sub( + _self.into(), + &rhs, + ) .into(); output }, ) .overwrite_script_function( - "dot_into_vec", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::IVec3::dot_into_vec( + "div", + |_self: Val, rhs: i32| { + let output: Val = ::bevy::math::IVec3::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "cross", + "rem", + |_self: Val, rhs: i32| { + let output: Val = ::bevy::math::IVec3::rem( + _self.into(), + rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::IVec3::mul( + _self.into(), + rhs.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "rem", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::IVec3::rem( + _self.into(), + rhs.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "new", + |x: i32, y: i32, z: i32| { + let output: Val = ::bevy::math::IVec3::new( + x, + y, + z, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "splat", + |v: i32| { + let output: Val = ::bevy::math::IVec3::splat(v) + .into(); + output + }, + ) + .overwrite_script_function( + "select", + | + mask: Val, + if_true: Val, + if_false: Val| + { + let output: Val = ::bevy::math::IVec3::select( + mask.into(), + if_true.into(), + if_false.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "from_array", + |a: [i32; 3]| { + let output: Val = ::bevy::math::IVec3::from_array( + a, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "to_array", + |_self: Ref| { + let output: [i32; 3] = ::bevy::math::IVec3::to_array(&_self).into(); + output + }, + ) + .overwrite_script_function( + "extend", + |_self: Val, w: i32| { + let output: Val = ::bevy::math::IVec3::extend( + _self.into(), + w, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "truncate", + |_self: Val| { + let output: Val = ::bevy::math::IVec3::truncate( + _self.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "with_x", + |_self: Val, x: i32| { + let output: Val = ::bevy::math::IVec3::with_x( + _self.into(), + x, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "with_y", + |_self: Val, y: i32| { + let output: Val = ::bevy::math::IVec3::with_y( + _self.into(), + y, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "with_z", + |_self: Val, z: i32| { + let output: Val = ::bevy::math::IVec3::with_z( + _self.into(), + z, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "dot", + |_self: Val, rhs: Val| { + let output: i32 = ::bevy::math::IVec3::dot(_self.into(), rhs.into()) + .into(); + output + }, + ) + .overwrite_script_function( + "dot_into_vec", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::IVec3::dot_into_vec( + _self.into(), + rhs.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "cross", |_self: Val, rhs: Val| { let output: Val = ::bevy::math::IVec3::cross( _self.into(), @@ -3359,7 +3320,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec3", |_self: Ref| { let output: Val = ::bevy::math::IVec3::as_vec3( - _self.into(), + &_self, ) .into(); output @@ -3369,7 +3330,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec3a", |_self: Ref| { let output: Val = ::bevy::math::IVec3::as_vec3a( - _self.into(), + &_self, ) .into(); output @@ -3379,7 +3340,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dvec3", |_self: Ref| { let output: Val = ::bevy::math::IVec3::as_dvec3( - _self.into(), + &_self, ) .into(); output @@ -3389,7 +3350,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_uvec3", |_self: Ref| { let output: Val = ::bevy::math::IVec3::as_uvec3( - _self.into(), + &_self, ) .into(); output @@ -3399,7 +3360,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_i64vec3", |_self: Ref| { let output: Val = ::bevy::math::IVec3::as_i64vec3( - _self.into(), + &_self, ) .into(); output @@ -3409,7 +3370,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_u64vec3", |_self: Ref| { let output: Val = ::bevy::math::IVec3::as_u64vec3( - _self.into(), + &_self, ) .into(); output @@ -3547,32 +3508,21 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) - .overwrite_script_function( - "div", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::IVec3::div( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "mul", |_self: Val, rhs: i32| { let output: Val = ::bevy::math::IVec3::mul( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::IVec3::add( + "div", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::IVec3::div( _self.into(), rhs.into(), ) @@ -3581,20 +3531,20 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: i32| { - let output: Val = ::bevy::math::IVec3::div( + "rem", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::IVec3::rem( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::IVec3::mul( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::IVec3::add( _self.into(), rhs.into(), ) @@ -3603,21 +3553,22 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "add", + "sub", |_self: Val, rhs: i32| { - let output: Val = ::bevy::math::IVec3::add( + let output: Val = ::bevy::math::IVec3::sub( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::IVec3::neg( + "sub", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::IVec3::sub( _self.into(), + rhs.into(), ) .into(); output @@ -3627,7 +3578,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::IVec3::clone( - _self.into(), + &_self, ) .into(); output @@ -3636,75 +3587,69 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "eq", |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::IVec3::eq( - _self.into(), - other.into(), - ) - .into(); + let output: bool = ::bevy::math::IVec3::eq(&_self, &other).into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::IVec3::mul( + "add", + |_self: Val, rhs: i32| { + let output: Val = ::bevy::math::IVec3::add( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", + "add", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::IVec3::sub( + let output: Val = ::bevy::math::IVec3::add( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::IVec3::add( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::IVec3::neg( _self.into(), - rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "rem", + "mul", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::IVec3::rem( + let output: Val = ::bevy::math::IVec3::mul( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: i32| { - let output: Val = ::bevy::math::IVec3::sub( - _self.into(), - rhs.into(), + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::math::IVec3::assert_receiver_is_total_eq( + &_self, ) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::IVec3::rem( + "div", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::IVec3::div( _self.into(), - rhs.into(), + &rhs, ) .into(); output @@ -3712,44 +3657,21 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ); NamespaceBuilder::<::bevy::math::IVec4>::new(world) .overwrite_script_function( - "add", + "rem", |_self: Val, rhs: i32| { - let output: Val = ::bevy::math::IVec4::add( + let output: Val = ::bevy::math::IVec4::rem( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::IVec4::add( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::IVec4::neg( _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "sub", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::IVec4::sub( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::IVec4::mul( - _self.into(), - rhs.into(), ) .into(); output @@ -3759,10 +3681,10 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |x: i32, y: i32, z: i32, w: i32| { let output: Val = ::bevy::math::IVec4::new( - x.into(), - y.into(), - z.into(), - w.into(), + x, + y, + z, + w, ) .into(); output @@ -3771,9 +3693,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "splat", |v: i32| { - let output: Val = ::bevy::math::IVec4::splat( - v.into(), - ) + let output: Val = ::bevy::math::IVec4::splat(v) .into(); output }, @@ -3798,7 +3718,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [i32; 4]| { let output: Val = ::bevy::math::IVec4::from_array( - a.into(), + a, ) .into(); output @@ -3807,8 +3727,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_array", |_self: Ref| { - let output: [i32; 4] = ::bevy::math::IVec4::to_array(_self.into()) - .into(); + let output: [i32; 4] = ::bevy::math::IVec4::to_array(&_self).into(); output }, ) @@ -3827,7 +3746,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, x: i32| { let output: Val = ::bevy::math::IVec4::with_x( _self.into(), - x.into(), + x, ) .into(); output @@ -3838,7 +3757,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, y: i32| { let output: Val = ::bevy::math::IVec4::with_y( _self.into(), - y.into(), + y, ) .into(); output @@ -3849,7 +3768,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, z: i32| { let output: Val = ::bevy::math::IVec4::with_z( _self.into(), - z.into(), + z, ) .into(); output @@ -3860,7 +3779,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, w: i32| { let output: Val = ::bevy::math::IVec4::with_w( _self.into(), - w.into(), + w, ) .into(); output @@ -4096,7 +4015,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec4", |_self: Ref| { let output: Val = ::bevy::math::IVec4::as_vec4( - _self.into(), + &_self, ) .into(); output @@ -4106,7 +4025,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dvec4", |_self: Ref| { let output: Val = ::bevy::math::IVec4::as_dvec4( - _self.into(), + &_self, ) .into(); output @@ -4116,7 +4035,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_uvec4", |_self: Ref| { let output: Val = ::bevy::math::IVec4::as_uvec4( - _self.into(), + &_self, ) .into(); output @@ -4126,7 +4045,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_i64vec4", |_self: Ref| { let output: Val = ::bevy::math::IVec4::as_i64vec4( - _self.into(), + &_self, ) .into(); output @@ -4136,7 +4055,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_u64vec4", |_self: Ref| { let output: Val = ::bevy::math::IVec4::as_u64vec4( - _self.into(), + &_self, ) .into(); output @@ -4275,33 +4194,32 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::IVec4::add( + "sub", + |_self: Val, rhs: i32| { + let output: Val = ::bevy::math::IVec4::sub( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: i32| { - let output: Val = ::bevy::math::IVec4::div( - _self.into(), - rhs.into(), + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::math::IVec4::assert_receiver_is_total_eq( + &_self, ) .into(); output }, ) .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::IVec4::eq( + "add", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::IVec4::add( _self.into(), - other.into(), + &rhs, ) .into(); output @@ -4309,10 +4227,10 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "div", - |_self: Val, rhs: Ref| { + |_self: Val, rhs: i32| { let output: Val = ::bevy::math::IVec4::div( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -4330,9 +4248,20 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::IVec4::rem( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::IVec4::mul( + _self.into(), + rhs.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::IVec4::add( _self.into(), rhs.into(), ) @@ -4345,7 +4274,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: i32| { let output: Val = ::bevy::math::IVec4::mul( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -4355,50 +4284,58 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::IVec4::clone( - _self.into(), + &_self, ) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::IVec4::mul( + "rem", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::IVec4::rem( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::IVec4::sub( + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::IVec4::eq(&_self, &other).into(); + output + }, + ) + .overwrite_script_function( + "mul", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::IVec4::mul( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", + "add", |_self: Val, rhs: i32| { - let output: Val = ::bevy::math::IVec4::sub( + let output: Val = ::bevy::math::IVec4::add( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::IVec4::neg( + "sub", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::IVec4::sub( _self.into(), + rhs.into(), ) .into(); output @@ -4406,29 +4343,30 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "div", - |_self: Val, rhs: Val| { + |_self: Val, rhs: Ref| { let output: Val = ::bevy::math::IVec4::div( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::math::IVec4::assert_receiver_is_total_eq( + "sub", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::IVec4::sub( _self.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: i32| { - let output: Val = ::bevy::math::IVec4::rem( + "div", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::IVec4::div( _self.into(), rhs.into(), ) @@ -4438,10 +4376,11 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ); NamespaceBuilder::<::bevy::math::I64Vec2>::new(world) .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::I64Vec2::neg( + "sub", + |_self: Val, rhs: i64| { + let output: Val = ::bevy::math::I64Vec2::sub( _self.into(), + rhs, ) .into(); output @@ -4452,38 +4391,27 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: i64| { let output: Val = ::bevy::math::I64Vec2::rem( _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "div", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::I64Vec2::div( - _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "rem", + "add", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::I64Vec2::rem( + let output: Val = ::bevy::math::I64Vec2::add( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: i64| { - let output: Val = ::bevy::math::I64Vec2::sub( + "div", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::I64Vec2::div( _self.into(), rhs.into(), ) @@ -4492,95 +4420,84 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "sub", + "rem", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::I64Vec2::sub( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::I64Vec2::eq( + let output: Val = ::bevy::math::I64Vec2::rem( _self.into(), - other.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::I64Vec2::rem( + "add", + |_self: Val, rhs: i64| { + let output: Val = ::bevy::math::I64Vec2::add( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::math::I64Vec2::assert_receiver_is_total_eq( + "mul", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::I64Vec2::mul( _self.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "add", + "div", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::I64Vec2::add( + let output: Val = ::bevy::math::I64Vec2::div( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: i64| { - let output: Val = ::bevy::math::I64Vec2::add( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::I64Vec2::neg( _self.into(), - rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::I64Vec2::clone( + "sub", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::I64Vec2::sub( _self.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::I64Vec2::add( - _self.into(), - rhs.into(), + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::math::I64Vec2::assert_receiver_is_total_eq( + &_self, ) .into(); output }, ) .overwrite_script_function( - "mul", + "sub", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::I64Vec2::mul( + let output: Val = ::bevy::math::I64Vec2::sub( _self.into(), rhs.into(), ) @@ -4592,8 +4509,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |x: i64, y: i64| { let output: Val = ::bevy::math::I64Vec2::new( - x.into(), - y.into(), + x, + y, ) .into(); output @@ -4603,7 +4520,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "splat", |v: i64| { let output: Val = ::bevy::math::I64Vec2::splat( - v.into(), + v, ) .into(); output @@ -4629,7 +4546,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [i64; 2]| { let output: Val = ::bevy::math::I64Vec2::from_array( - a.into(), + a, ) .into(); output @@ -4638,7 +4555,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_array", |_self: Ref| { - let output: [i64; 2] = ::bevy::math::I64Vec2::to_array(_self.into()) + let output: [i64; 2] = ::bevy::math::I64Vec2::to_array(&_self) .into(); output }, @@ -4648,7 +4565,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, z: i64| { let output: Val = ::bevy::math::I64Vec2::extend( _self.into(), - z.into(), + z, ) .into(); output @@ -4659,7 +4576,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, x: i64| { let output: Val = ::bevy::math::I64Vec2::with_x( _self.into(), - x.into(), + x, ) .into(); output @@ -4670,7 +4587,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, y: i64| { let output: Val = ::bevy::math::I64Vec2::with_y( _self.into(), - y.into(), + y, ) .into(); output @@ -4943,7 +4860,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec2", |_self: Ref| { let output: Val = ::bevy::math::I64Vec2::as_vec2( - _self.into(), + &_self, ) .into(); output @@ -4953,7 +4870,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dvec2", |_self: Ref| { let output: Val = ::bevy::math::I64Vec2::as_dvec2( - _self.into(), + &_self, ) .into(); output @@ -4963,7 +4880,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_ivec2", |_self: Ref| { let output: Val = ::bevy::math::I64Vec2::as_ivec2( - _self.into(), + &_self, ) .into(); output @@ -4973,7 +4890,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_uvec2", |_self: Ref| { let output: Val = ::bevy::math::I64Vec2::as_uvec2( - _self.into(), + &_self, ) .into(); output @@ -4983,7 +4900,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_u64vec2", |_self: Ref| { let output: Val = ::bevy::math::I64Vec2::as_u64vec2( - _self.into(), + &_self, ) .into(); output @@ -5122,9 +5039,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: i64| { - let output: Val = ::bevy::math::I64Vec2::div( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::I64Vec2::add( _self.into(), rhs.into(), ) @@ -5133,9 +5050,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::I64Vec2::mul( + "rem", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::I64Vec2::rem( _self.into(), rhs.into(), ) @@ -5143,21 +5060,39 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) + .overwrite_script_function( + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::I64Vec2::eq(&_self, &other).into(); + output + }, + ) + .overwrite_script_function( + "div", + |_self: Val, rhs: i64| { + let output: Val = ::bevy::math::I64Vec2::div( + _self.into(), + rhs, + ) + .into(); + output + }, + ) .overwrite_script_function( "mul", |_self: Val, rhs: i64| { let output: Val = ::bevy::math::I64Vec2::mul( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", + "mul", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::I64Vec2::sub( + let output: Val = ::bevy::math::I64Vec2::mul( _self.into(), rhs.into(), ) @@ -5166,120 +5101,22 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::I64Vec2::div( - _self.into(), - rhs.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::I64Vec2::clone( + &_self, ) .into(); output }, ); NamespaceBuilder::<::bevy::math::I64Vec3>::new(world) - .overwrite_script_function( - "add", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::I64Vec3::add( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "div", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::I64Vec3::div( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "div", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::I64Vec3::div( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "add", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::I64Vec3::add( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::I64Vec3::neg( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::math::I64Vec3::assert_receiver_is_total_eq( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul", - |_self: Val, rhs: i64| { - let output: Val = ::bevy::math::I64Vec3::mul( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::I64Vec3::eq( - _self.into(), - other.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "rem", - |_self: Val, rhs: Ref| { + |_self: Val, rhs: i64| { let output: Val = ::bevy::math::I64Vec3::rem( _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::I64Vec3::mul( - _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -5287,21 +5124,21 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "sub", - |_self: Val, rhs: Val| { + |_self: Val, rhs: Ref| { let output: Val = ::bevy::math::I64Vec3::sub( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "rem", + "sub", |_self: Val, rhs: i64| { - let output: Val = ::bevy::math::I64Vec3::rem( + let output: Val = ::bevy::math::I64Vec3::sub( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -5309,32 +5146,20 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "rem", - |_self: Val, rhs: Val| { + |_self: Val, rhs: Ref| { let output: Val = ::bevy::math::I64Vec3::rem( _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "add", - |_self: Val, rhs: i64| { - let output: Val = ::bevy::math::I64Vec3::add( - _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: i64| { - let output: Val = ::bevy::math::I64Vec3::sub( - _self.into(), - rhs.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::I64Vec3::clone( + &_self, ) .into(); output @@ -5342,19 +5167,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "div", - |_self: Val, rhs: i64| { - let output: Val = ::bevy::math::I64Vec3::div( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::I64Vec3::mul( + let output: Val = ::bevy::math::I64Vec3::div( _self.into(), rhs.into(), ) @@ -5366,9 +5180,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |x: i64, y: i64, z: i64| { let output: Val = ::bevy::math::I64Vec3::new( - x.into(), - y.into(), - z.into(), + x, + y, + z, ) .into(); output @@ -5378,7 +5192,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "splat", |v: i64| { let output: Val = ::bevy::math::I64Vec3::splat( - v.into(), + v, ) .into(); output @@ -5404,7 +5218,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [i64; 3]| { let output: Val = ::bevy::math::I64Vec3::from_array( - a.into(), + a, ) .into(); output @@ -5413,7 +5227,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_array", |_self: Ref| { - let output: [i64; 3] = ::bevy::math::I64Vec3::to_array(_self.into()) + let output: [i64; 3] = ::bevy::math::I64Vec3::to_array(&_self) .into(); output }, @@ -5423,7 +5237,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, w: i64| { let output: Val = ::bevy::math::I64Vec3::extend( _self.into(), - w.into(), + w, ) .into(); output @@ -5444,7 +5258,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, x: i64| { let output: Val = ::bevy::math::I64Vec3::with_x( _self.into(), - x.into(), + x, ) .into(); output @@ -5455,7 +5269,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, y: i64| { let output: Val = ::bevy::math::I64Vec3::with_y( _self.into(), - y.into(), + y, ) .into(); output @@ -5466,7 +5280,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, z: i64| { let output: Val = ::bevy::math::I64Vec3::with_z( _self.into(), - z.into(), + z, ) .into(); output @@ -5718,7 +5532,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec3", |_self: Ref| { let output: Val = ::bevy::math::I64Vec3::as_vec3( - _self.into(), + &_self, ) .into(); output @@ -5728,7 +5542,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec3a", |_self: Ref| { let output: Val = ::bevy::math::I64Vec3::as_vec3a( - _self.into(), + &_self, ) .into(); output @@ -5738,7 +5552,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dvec3", |_self: Ref| { let output: Val = ::bevy::math::I64Vec3::as_dvec3( - _self.into(), + &_self, ) .into(); output @@ -5748,7 +5562,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_ivec3", |_self: Ref| { let output: Val = ::bevy::math::I64Vec3::as_ivec3( - _self.into(), + &_self, ) .into(); output @@ -5758,7 +5572,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_uvec3", |_self: Ref| { let output: Val = ::bevy::math::I64Vec3::as_uvec3( - _self.into(), + &_self, ) .into(); output @@ -5768,7 +5582,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_u64vec3", |_self: Ref| { let output: Val = ::bevy::math::I64Vec3::as_u64vec3( - _self.into(), + &_self, ) .into(); output @@ -5907,106 +5721,106 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "sub", + "add", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::I64Vec3::sub( + let output: Val = ::bevy::math::I64Vec3::add( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::I64Vec3::clone( + "add", + |_self: Val, rhs: i64| { + let output: Val = ::bevy::math::I64Vec3::add( _self.into(), + rhs, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::I64Vec4>::new(world) + ) .overwrite_script_function( - "sub", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::I64Vec4::sub( - _self.into(), - rhs.into(), + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::math::I64Vec3::assert_receiver_is_total_eq( + &_self, ) .into(); output }, ) .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::math::I64Vec4::assert_receiver_is_total_eq( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::I64Vec3::add( _self.into(), + rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::I64Vec4::add( + "div", + |_self: Val, rhs: i64| { + let output: Val = ::bevy::math::I64Vec3::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::I64Vec4::rem( + "div", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::I64Vec3::div( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::I64Vec4::add( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::I64Vec3::neg( _self.into(), - rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::I64Vec4::clone( + "sub", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::I64Vec3::sub( _self.into(), + rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::I64Vec4::div( + "mul", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::I64Vec3::mul( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: i64| { - let output: Val = ::bevy::math::I64Vec4::sub( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::I64Vec3::mul( _self.into(), rhs.into(), ) @@ -6015,9 +5829,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::I64Vec4::div( + "rem", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::I64Vec3::rem( _self.into(), rhs.into(), ) @@ -6026,54 +5840,101 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: i64| { - let output: Val = ::bevy::math::I64Vec4::add( + "mul", + |_self: Val, rhs: i64| { + let output: Val = ::bevy::math::I64Vec3::mul( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) + .overwrite_script_function( + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::I64Vec3::eq(&_self, &other).into(); + output + }, + ); + NamespaceBuilder::<::bevy::math::I64Vec4>::new(world) .overwrite_script_function( "eq", |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::I64Vec4::eq( - _self.into(), - other.into(), - ) - .into(); + let output: bool = ::bevy::math::I64Vec4::eq(&_self, &other).into(); output }, ) .overwrite_script_function( - "mul", + "div", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::I64Vec4::mul( + let output: Val = ::bevy::math::I64Vec4::div( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "mul", + "div", |_self: Val, rhs: i64| { - let output: Val = ::bevy::math::I64Vec4::mul( + let output: Val = ::bevy::math::I64Vec4::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::I64Vec4::mul( - _self.into(), + "rem", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::I64Vec4::rem( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "rem", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::I64Vec4::rem( + _self.into(), + rhs.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "add", + |_self: Val, rhs: i64| { + let output: Val = ::bevy::math::I64Vec4::add( + _self.into(), + rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::I64Vec4::clone( + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "sub", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::I64Vec4::sub( + _self.into(), rhs.into(), ) .into(); @@ -6084,6 +5945,17 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "rem", |_self: Val, rhs: i64| { let output: Val = ::bevy::math::I64Vec4::rem( + _self.into(), + rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "div", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::I64Vec4::div( _self.into(), rhs.into(), ) @@ -6092,9 +5964,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "rem", + "add", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::I64Vec4::rem( + let output: Val = ::bevy::math::I64Vec4::add( _self.into(), rhs.into(), ) @@ -6102,14 +5974,79 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) + .overwrite_script_function( + "sub", + |_self: Val, rhs: i64| { + let output: Val = ::bevy::math::I64Vec4::sub( + _self.into(), + rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "mul", + |_self: Val, rhs: i64| { + let output: Val = ::bevy::math::I64Vec4::mul( + _self.into(), + rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "add", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::I64Vec4::add( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "sub", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::I64Vec4::sub( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "mul", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::I64Vec4::mul( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::math::I64Vec4::assert_receiver_is_total_eq( + &_self, + ) + .into(); + output + }, + ) .overwrite_script_function( "new", |x: i64, y: i64, z: i64, w: i64| { let output: Val = ::bevy::math::I64Vec4::new( - x.into(), - y.into(), - z.into(), - w.into(), + x, + y, + z, + w, ) .into(); output @@ -6119,7 +6056,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "splat", |v: i64| { let output: Val = ::bevy::math::I64Vec4::splat( - v.into(), + v, ) .into(); output @@ -6145,7 +6082,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [i64; 4]| { let output: Val = ::bevy::math::I64Vec4::from_array( - a.into(), + a, ) .into(); output @@ -6154,7 +6091,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_array", |_self: Ref| { - let output: [i64; 4] = ::bevy::math::I64Vec4::to_array(_self.into()) + let output: [i64; 4] = ::bevy::math::I64Vec4::to_array(&_self) .into(); output }, @@ -6174,7 +6111,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, x: i64| { let output: Val = ::bevy::math::I64Vec4::with_x( _self.into(), - x.into(), + x, ) .into(); output @@ -6185,7 +6122,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, y: i64| { let output: Val = ::bevy::math::I64Vec4::with_y( _self.into(), - y.into(), + y, ) .into(); output @@ -6196,7 +6133,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, z: i64| { let output: Val = ::bevy::math::I64Vec4::with_z( _self.into(), - z.into(), + z, ) .into(); output @@ -6207,7 +6144,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, w: i64| { let output: Val = ::bevy::math::I64Vec4::with_w( _self.into(), - w.into(), + w, ) .into(); output @@ -6448,7 +6385,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec4", |_self: Ref| { let output: Val = ::bevy::math::I64Vec4::as_vec4( - _self.into(), + &_self, ) .into(); output @@ -6458,7 +6395,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dvec4", |_self: Ref| { let output: Val = ::bevy::math::I64Vec4::as_dvec4( - _self.into(), + &_self, ) .into(); output @@ -6468,7 +6405,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_ivec4", |_self: Ref| { let output: Val = ::bevy::math::I64Vec4::as_ivec4( - _self.into(), + &_self, ) .into(); output @@ -6478,7 +6415,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_uvec4", |_self: Ref| { let output: Val = ::bevy::math::I64Vec4::as_uvec4( - _self.into(), + &_self, ) .into(); output @@ -6488,7 +6425,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_u64vec4", |_self: Ref| { let output: Val = ::bevy::math::I64Vec4::as_u64vec4( - _self.into(), + &_self, ) .into(); output @@ -6626,6 +6563,17 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) + .overwrite_script_function( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::I64Vec4::mul( + _self.into(), + rhs.into(), + ) + .into(); + output + }, + ) .overwrite_script_function( "neg", |_self: Val| { @@ -6635,13 +6583,21 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .into(); output }, + ); + NamespaceBuilder::<::bevy::math::UVec2>::new(world) + .overwrite_script_function( + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::UVec2::eq(&_self, &other).into(); + output + }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::I64Vec4::sub( + "div", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::UVec2::div( _self.into(), - rhs.into(), + &rhs, ) .into(); output @@ -6649,16 +6605,25 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "div", - |_self: Val, rhs: i64| { - let output: Val = ::bevy::math::I64Vec4::div( + |_self: Val, rhs: u32| { + let output: Val = ::bevy::math::UVec2::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::UVec2>::new(world) + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::UVec2::clone( + &_self, + ) + .into(); + output + }, + ) .overwrite_script_function( "div", |_self: Val, rhs: Val| { @@ -6671,9 +6636,31 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "add", + "sub", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::UVec2::sub( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "rem", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::UVec2::rem( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "rem", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::UVec2::add( + let output: Val = ::bevy::math::UVec2::rem( _self.into(), rhs.into(), ) @@ -6682,9 +6669,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::UVec2::div( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::UVec2::mul( _self.into(), rhs.into(), ) @@ -6697,18 +6684,18 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: Ref| { let output: Val = ::bevy::math::UVec2::add( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "add", + "mul", |_self: Val, rhs: u32| { - let output: Val = ::bevy::math::UVec2::add( + let output: Val = ::bevy::math::UVec2::mul( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -6716,19 +6703,19 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "rem", - |_self: Val, rhs: Val| { + |_self: Val, rhs: u32| { let output: Val = ::bevy::math::UVec2::rem( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: u32| { - let output: Val = ::bevy::math::UVec2::rem( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::UVec2::add( _self.into(), rhs.into(), ) @@ -6737,11 +6724,22 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "div", + "mul", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::UVec2::mul( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "add", |_self: Val, rhs: u32| { - let output: Val = ::bevy::math::UVec2::div( + let output: Val = ::bevy::math::UVec2::add( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -6751,18 +6749,29 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::bevy::math::UVec2::assert_receiver_is_total_eq( + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "sub", + |_self: Val, rhs: u32| { + let output: Val = ::bevy::math::UVec2::sub( _self.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::UVec2::eq( + "sub", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::UVec2::sub( _self.into(), - other.into(), + rhs.into(), ) .into(); output @@ -6771,10 +6780,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "new", |x: u32, y: u32| { - let output: Val = ::bevy::math::UVec2::new( - x.into(), - y.into(), - ) + let output: Val = ::bevy::math::UVec2::new(x, y) .into(); output }, @@ -6782,9 +6788,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "splat", |v: u32| { - let output: Val = ::bevy::math::UVec2::splat( - v.into(), - ) + let output: Val = ::bevy::math::UVec2::splat(v) .into(); output }, @@ -6809,7 +6813,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [u32; 2]| { let output: Val = ::bevy::math::UVec2::from_array( - a.into(), + a, ) .into(); output @@ -6818,8 +6822,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_array", |_self: Ref| { - let output: [u32; 2] = ::bevy::math::UVec2::to_array(_self.into()) - .into(); + let output: [u32; 2] = ::bevy::math::UVec2::to_array(&_self).into(); output }, ) @@ -6828,7 +6831,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, z: u32| { let output: Val = ::bevy::math::UVec2::extend( _self.into(), - z.into(), + z, ) .into(); output @@ -6839,7 +6842,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, x: u32| { let output: Val = ::bevy::math::UVec2::with_x( _self.into(), - x.into(), + x, ) .into(); output @@ -6850,7 +6853,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, y: u32| { let output: Val = ::bevy::math::UVec2::with_y( _self.into(), - y.into(), + y, ) .into(); output @@ -7023,7 +7026,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec2", |_self: Ref| { let output: Val = ::bevy::math::UVec2::as_vec2( - _self.into(), + &_self, ) .into(); output @@ -7033,7 +7036,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dvec2", |_self: Ref| { let output: Val = ::bevy::math::UVec2::as_dvec2( - _self.into(), + &_self, ) .into(); output @@ -7043,7 +7046,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_ivec2", |_self: Ref| { let output: Val = ::bevy::math::UVec2::as_ivec2( - _self.into(), + &_self, ) .into(); output @@ -7053,7 +7056,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_i64vec2", |_self: Ref| { let output: Val = ::bevy::math::UVec2::as_i64vec2( - _self.into(), + &_self, ) .into(); output @@ -7063,7 +7066,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_u64vec2", |_self: Ref| { let output: Val = ::bevy::math::UVec2::as_u64vec2( - _self.into(), + &_self, ) .into(); output @@ -7178,45 +7181,24 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::UVec3>::new(world) .overwrite_script_function( - "rem", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::UVec2::rem( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::UVec2::mul( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul", - |_self: Val, rhs: u32| { - let output: Val = ::bevy::math::UVec2::mul( + "add", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::UVec3::add( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::UVec2::clone( - _self.into(), + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::math::UVec3::assert_receiver_is_total_eq( + &_self, ) .into(); output @@ -7224,8 +7206,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "sub", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::UVec2::sub( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::UVec3::sub( _self.into(), rhs.into(), ) @@ -7234,9 +7216,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::UVec2::sub( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::UVec3::add( _self.into(), rhs.into(), ) @@ -7245,32 +7227,19 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::UVec2::mul( - _self.into(), - rhs.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::UVec3::clone( + &_self, ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: u32| { - let output: Val = ::bevy::math::UVec2::sub( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ); - NamespaceBuilder::<::bevy::math::UVec3>::new(world) - .overwrite_script_function( - "div", - |_self: Val, rhs: u32| { - let output: Val = ::bevy::math::UVec3::div( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::UVec3::mul( _self.into(), rhs.into(), ) @@ -7279,22 +7248,22 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "rem", + "mul", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::UVec3::rem( + let output: Val = ::bevy::math::UVec3::mul( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::UVec3::add( + "mul", + |_self: Val, rhs: u32| { + let output: Val = ::bevy::math::UVec3::mul( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -7304,9 +7273,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |x: u32, y: u32, z: u32| { let output: Val = ::bevy::math::UVec3::new( - x.into(), - y.into(), - z.into(), + x, + y, + z, ) .into(); output @@ -7315,9 +7284,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "splat", |v: u32| { - let output: Val = ::bevy::math::UVec3::splat( - v.into(), - ) + let output: Val = ::bevy::math::UVec3::splat(v) .into(); output }, @@ -7342,7 +7309,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [u32; 3]| { let output: Val = ::bevy::math::UVec3::from_array( - a.into(), + a, ) .into(); output @@ -7351,8 +7318,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_array", |_self: Ref| { - let output: [u32; 3] = ::bevy::math::UVec3::to_array(_self.into()) - .into(); + let output: [u32; 3] = ::bevy::math::UVec3::to_array(&_self).into(); output }, ) @@ -7361,7 +7327,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, w: u32| { let output: Val = ::bevy::math::UVec3::extend( _self.into(), - w.into(), + w, ) .into(); output @@ -7382,7 +7348,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, x: u32| { let output: Val = ::bevy::math::UVec3::with_x( _self.into(), - x.into(), + x, ) .into(); output @@ -7393,7 +7359,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, y: u32| { let output: Val = ::bevy::math::UVec3::with_y( _self.into(), - y.into(), + y, ) .into(); output @@ -7404,7 +7370,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, z: u32| { let output: Val = ::bevy::math::UVec3::with_z( _self.into(), - z.into(), + z, ) .into(); output @@ -7588,7 +7554,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec3", |_self: Ref| { let output: Val = ::bevy::math::UVec3::as_vec3( - _self.into(), + &_self, ) .into(); output @@ -7598,7 +7564,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec3a", |_self: Ref| { let output: Val = ::bevy::math::UVec3::as_vec3a( - _self.into(), + &_self, ) .into(); output @@ -7608,7 +7574,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dvec3", |_self: Ref| { let output: Val = ::bevy::math::UVec3::as_dvec3( - _self.into(), + &_self, ) .into(); output @@ -7618,7 +7584,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_ivec3", |_self: Ref| { let output: Val = ::bevy::math::UVec3::as_ivec3( - _self.into(), + &_self, ) .into(); output @@ -7628,7 +7594,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_i64vec3", |_self: Ref| { let output: Val = ::bevy::math::UVec3::as_i64vec3( - _self.into(), + &_self, ) .into(); output @@ -7638,7 +7604,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_u64vec3", |_self: Ref| { let output: Val = ::bevy::math::UVec3::as_u64vec3( - _self.into(), + &_self, ) .into(); output @@ -7754,32 +7720,21 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) - .overwrite_script_function( - "add", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::UVec3::add( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "sub", - |_self: Val, rhs: Ref| { + |_self: Val, rhs: u32| { let output: Val = ::bevy::math::UVec3::sub( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: u32| { - let output: Val = ::bevy::math::UVec3::mul( + "rem", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::UVec3::rem( _self.into(), rhs.into(), ) @@ -7788,31 +7743,27 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: u32| { - let output: Val = ::bevy::math::UVec3::sub( + "rem", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::UVec3::rem( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::UVec3::mul( - _self.into(), - rhs.into(), - ) - .into(); + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::UVec3::eq(&_self, &other).into(); output }, ) .overwrite_script_function( - "sub", + "div", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::UVec3::sub( + let output: Val = ::bevy::math::UVec3::div( _self.into(), rhs.into(), ) @@ -7821,32 +7772,33 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "rem", + "div", |_self: Val, rhs: u32| { - let output: Val = ::bevy::math::UVec3::rem( + let output: Val = ::bevy::math::UVec3::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::UVec3::div( + "rem", + |_self: Val, rhs: u32| { + let output: Val = ::bevy::math::UVec3::rem( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::math::UVec3::assert_receiver_is_total_eq( + "sub", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::UVec3::sub( _self.into(), + &rhs, ) .into(); output @@ -7857,37 +7809,39 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: u32| { let output: Val = ::bevy::math::UVec3::add( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "mul", + "div", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::UVec3::mul( + let output: Val = ::bevy::math::UVec3::div( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::UVec4>::new(world) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::UVec3::clone( + "sub", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::UVec4::sub( _self.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::UVec3::rem( + "sub", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::UVec4::sub( _self.into(), rhs.into(), ) @@ -7896,33 +7850,32 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::UVec3::eq( + "div", + |_self: Val, rhs: u32| { + let output: Val = ::bevy::math::UVec4::div( _self.into(), - other.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::UVec3::div( - _self.into(), - rhs.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::UVec4::clone( + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::UVec4>::new(world) + ) .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::math::UVec4::assert_receiver_is_total_eq( + "add", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::UVec4::add( _self.into(), + &rhs, ) .into(); output @@ -7930,7 +7883,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "mul", - |_self: Val, rhs: Ref| { + |_self: Val, rhs: Val| { let output: Val = ::bevy::math::UVec4::mul( _self.into(), rhs.into(), @@ -7940,9 +7893,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "add", + "rem", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::UVec4::add( + let output: Val = ::bevy::math::UVec4::rem( _self.into(), rhs.into(), ) @@ -7950,14 +7903,25 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) + .overwrite_script_function( + "mul", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::UVec4::mul( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) .overwrite_script_function( "new", |x: u32, y: u32, z: u32, w: u32| { let output: Val = ::bevy::math::UVec4::new( - x.into(), - y.into(), - z.into(), - w.into(), + x, + y, + z, + w, ) .into(); output @@ -7966,9 +7930,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "splat", |v: u32| { - let output: Val = ::bevy::math::UVec4::splat( - v.into(), - ) + let output: Val = ::bevy::math::UVec4::splat(v) .into(); output }, @@ -7993,7 +7955,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [u32; 4]| { let output: Val = ::bevy::math::UVec4::from_array( - a.into(), + a, ) .into(); output @@ -8002,8 +7964,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_array", |_self: Ref| { - let output: [u32; 4] = ::bevy::math::UVec4::to_array(_self.into()) - .into(); + let output: [u32; 4] = ::bevy::math::UVec4::to_array(&_self).into(); output }, ) @@ -8022,7 +7983,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, x: u32| { let output: Val = ::bevy::math::UVec4::with_x( _self.into(), - x.into(), + x, ) .into(); output @@ -8033,7 +7994,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, y: u32| { let output: Val = ::bevy::math::UVec4::with_y( _self.into(), - y.into(), + y, ) .into(); output @@ -8044,7 +8005,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, z: u32| { let output: Val = ::bevy::math::UVec4::with_z( _self.into(), - z.into(), + z, ) .into(); output @@ -8055,7 +8016,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, w: u32| { let output: Val = ::bevy::math::UVec4::with_w( _self.into(), - w.into(), + w, ) .into(); output @@ -8228,7 +8189,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec4", |_self: Ref| { let output: Val = ::bevy::math::UVec4::as_vec4( - _self.into(), + &_self, ) .into(); output @@ -8238,7 +8199,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dvec4", |_self: Ref| { let output: Val = ::bevy::math::UVec4::as_dvec4( - _self.into(), + &_self, ) .into(); output @@ -8248,7 +8209,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_ivec4", |_self: Ref| { let output: Val = ::bevy::math::UVec4::as_ivec4( - _self.into(), + &_self, ) .into(); output @@ -8258,7 +8219,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_i64vec4", |_self: Ref| { let output: Val = ::bevy::math::UVec4::as_i64vec4( - _self.into(), + &_self, ) .into(); output @@ -8268,7 +8229,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_u64vec4", |_self: Ref| { let output: Val = ::bevy::math::UVec4::as_u64vec4( - _self.into(), + &_self, ) .into(); output @@ -8385,21 +8346,18 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::UVec4::clone( - _self.into(), - ) - .into(); + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::UVec4::eq(&_self, &other).into(); output }, ) .overwrite_script_function( "sub", - |_self: Val, rhs: Ref| { + |_self: Val, rhs: u32| { let output: Val = ::bevy::math::UVec4::sub( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -8416,89 +8374,44 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) - .overwrite_script_function( - "rem", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::UVec4::rem( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "mul", |_self: Val, rhs: u32| { let output: Val = ::bevy::math::UVec4::mul( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "add", + "rem", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::UVec4::add( + let output: Val = ::bevy::math::UVec4::rem( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::UVec4::sub( + "div", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::UVec4::div( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: u32| { - let output: Val = ::bevy::math::UVec4::sub( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::UVec4::mul( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "rem", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::UVec4::rem( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "div", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::UVec4::div( - _self.into(), - rhs.into(), + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::math::UVec4::assert_receiver_is_total_eq( + &_self, ) .into(); output @@ -8509,16 +8422,16 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: u32| { let output: Val = ::bevy::math::UVec4::rem( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: u32| { - let output: Val = ::bevy::math::UVec4::div( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::UVec4::add( _self.into(), rhs.into(), ) @@ -8526,23 +8439,12 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) - .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::UVec4::eq( - _self.into(), - other.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "add", |_self: Val, rhs: u32| { let output: Val = ::bevy::math::UVec4::add( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -8550,19 +8452,20 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ); NamespaceBuilder::<::bevy::math::U64Vec2>::new(world) .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::math::U64Vec2::assert_receiver_is_total_eq( + "mul", + |_self: Val, rhs: u64| { + let output: Val = ::bevy::math::U64Vec2::mul( _self.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", + "rem", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::U64Vec2::sub( + let output: Val = ::bevy::math::U64Vec2::rem( _self.into(), rhs.into(), ) @@ -8572,7 +8475,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "add", - |_self: Val, rhs: u64| { + |_self: Val, rhs: Val| { let output: Val = ::bevy::math::U64Vec2::add( _self.into(), rhs.into(), @@ -8582,22 +8485,22 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: u64| { - let output: Val = ::bevy::math::U64Vec2::rem( + "sub", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::U64Vec2::sub( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", + "mul", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::U64Vec2::sub( + let output: Val = ::bevy::math::U64Vec2::mul( _self.into(), - rhs.into(), + &rhs, ) .into(); output @@ -8608,29 +8511,28 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: u64| { let output: Val = ::bevy::math::U64Vec2::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::U64Vec2::div( - _self.into(), - rhs.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::U64Vec2::clone( + &_self, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::U64Vec2::div( + "sub", + |_self: Val, rhs: u64| { + let output: Val = ::bevy::math::U64Vec2::sub( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -8641,40 +8543,29 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: Ref| { let output: Val = ::bevy::math::U64Vec2::rem( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", + "add", |_self: Val, rhs: u64| { - let output: Val = ::bevy::math::U64Vec2::sub( + let output: Val = ::bevy::math::U64Vec2::add( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "mul", + "div", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::U64Vec2::mul( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::U64Vec2::eq( + let output: Val = ::bevy::math::U64Vec2::div( _self.into(), - other.into(), + &rhs, ) .into(); output @@ -8684,8 +8575,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |x: u64, y: u64| { let output: Val = ::bevy::math::U64Vec2::new( - x.into(), - y.into(), + x, + y, ) .into(); output @@ -8695,7 +8586,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "splat", |v: u64| { let output: Val = ::bevy::math::U64Vec2::splat( - v.into(), + v, ) .into(); output @@ -8721,7 +8612,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [u64; 2]| { let output: Val = ::bevy::math::U64Vec2::from_array( - a.into(), + a, ) .into(); output @@ -8730,7 +8621,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_array", |_self: Ref| { - let output: [u64; 2] = ::bevy::math::U64Vec2::to_array(_self.into()) + let output: [u64; 2] = ::bevy::math::U64Vec2::to_array(&_self) .into(); output }, @@ -8740,7 +8631,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, z: u64| { let output: Val = ::bevy::math::U64Vec2::extend( _self.into(), - z.into(), + z, ) .into(); output @@ -8751,7 +8642,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, x: u64| { let output: Val = ::bevy::math::U64Vec2::with_x( _self.into(), - x.into(), + x, ) .into(); output @@ -8762,7 +8653,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, y: u64| { let output: Val = ::bevy::math::U64Vec2::with_y( _self.into(), - y.into(), + y, ) .into(); output @@ -8940,7 +8831,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec2", |_self: Ref| { let output: Val = ::bevy::math::U64Vec2::as_vec2( - _self.into(), + &_self, ) .into(); output @@ -8950,7 +8841,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dvec2", |_self: Ref| { let output: Val = ::bevy::math::U64Vec2::as_dvec2( - _self.into(), + &_self, ) .into(); output @@ -8960,7 +8851,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_ivec2", |_self: Ref| { let output: Val = ::bevy::math::U64Vec2::as_ivec2( - _self.into(), + &_self, ) .into(); output @@ -8970,7 +8861,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_uvec2", |_self: Ref| { let output: Val = ::bevy::math::U64Vec2::as_uvec2( - _self.into(), + &_self, ) .into(); output @@ -8980,7 +8871,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_i64vec2", |_self: Ref| { let output: Val = ::bevy::math::U64Vec2::as_i64vec2( - _self.into(), + &_self, ) .into(); output @@ -9097,41 +8988,49 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: u64| { - let output: Val = ::bevy::math::U64Vec2::mul( + "add", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::U64Vec2::add( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::U64Vec2::clone( + "div", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::U64Vec2::div( _self.into(), + rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::U64Vec2::mul( + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::U64Vec2::eq(&_self, &other).into(); + output + }, + ) + .overwrite_script_function( + "rem", + |_self: Val, rhs: u64| { + let output: Val = ::bevy::math::U64Vec2::rem( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "add", + "mul", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::U64Vec2::add( + let output: Val = ::bevy::math::U64Vec2::mul( _self.into(), rhs.into(), ) @@ -9140,20 +9039,19 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::U64Vec2::rem( - _self.into(), - rhs.into(), + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::math::U64Vec2::assert_receiver_is_total_eq( + &_self, ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::U64Vec2::add( + "sub", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::U64Vec2::sub( _self.into(), rhs.into(), ) @@ -9164,10 +9062,10 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { NamespaceBuilder::<::bevy::math::U64Vec3>::new(world) .overwrite_script_function( "mul", - |_self: Val, rhs: Val| { + |_self: Val, rhs: u64| { let output: Val = ::bevy::math::U64Vec3::mul( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -9175,230 +9073,109 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "sub", - |_self: Val, rhs: Ref| { + |_self: Val, rhs: u64| { let output: Val = ::bevy::math::U64Vec3::sub( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::U64Vec3::div( - _self.into(), - rhs.into(), + "new", + |x: u64, y: u64, z: u64| { + let output: Val = ::bevy::math::U64Vec3::new( + x, + y, + z, ) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::U64Vec3::rem( - _self.into(), - rhs.into(), + "splat", + |v: u64| { + let output: Val = ::bevy::math::U64Vec3::splat( + v, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::U64Vec3::div( - _self.into(), - rhs.into(), + "select", + | + mask: Val, + if_true: Val, + if_false: Val| + { + let output: Val = ::bevy::math::U64Vec3::select( + mask.into(), + if_true.into(), + if_false.into(), ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: u64| { - let output: Val = ::bevy::math::U64Vec3::div( - _self.into(), - rhs.into(), + "from_array", + |a: [u64; 3]| { + let output: Val = ::bevy::math::U64Vec3::from_array( + a, ) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: u64| { - let output: Val = ::bevy::math::U64Vec3::mul( - _self.into(), - rhs.into(), - ) + "to_array", + |_self: Ref| { + let output: [u64; 3] = ::bevy::math::U64Vec3::to_array(&_self) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::U64Vec3::mul( + "extend", + |_self: Val, w: u64| { + let output: Val = ::bevy::math::U64Vec3::extend( _self.into(), - rhs.into(), + w, ) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::U64Vec3::rem( + "truncate", + |_self: Val| { + let output: Val = ::bevy::math::U64Vec3::truncate( _self.into(), - rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::U64Vec3::add( + "with_x", + |_self: Val, x: u64| { + let output: Val = ::bevy::math::U64Vec3::with_x( _self.into(), - rhs.into(), + x, ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: u64| { - let output: Val = ::bevy::math::U64Vec3::add( + "with_y", + |_self: Val, y: u64| { + let output: Val = ::bevy::math::U64Vec3::with_y( _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "sub", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::U64Vec3::sub( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "sub", - |_self: Val, rhs: u64| { - let output: Val = ::bevy::math::U64Vec3::sub( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "new", - |x: u64, y: u64, z: u64| { - let output: Val = ::bevy::math::U64Vec3::new( - x.into(), - y.into(), - z.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "splat", - |v: u64| { - let output: Val = ::bevy::math::U64Vec3::splat( - v.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "select", - | - mask: Val, - if_true: Val, - if_false: Val| - { - let output: Val = ::bevy::math::U64Vec3::select( - mask.into(), - if_true.into(), - if_false.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "from_array", - |a: [u64; 3]| { - let output: Val = ::bevy::math::U64Vec3::from_array( - a.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "to_array", - |_self: Ref| { - let output: [u64; 3] = ::bevy::math::U64Vec3::to_array(_self.into()) - .into(); - output - }, - ) - .overwrite_script_function( - "extend", - |_self: Val, w: u64| { - let output: Val = ::bevy::math::U64Vec3::extend( - _self.into(), - w.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "truncate", - |_self: Val| { - let output: Val = ::bevy::math::U64Vec3::truncate( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "with_x", - |_self: Val, x: u64| { - let output: Val = ::bevy::math::U64Vec3::with_x( - _self.into(), - x.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "with_y", - |_self: Val, y: u64| { - let output: Val = ::bevy::math::U64Vec3::with_y( - _self.into(), - y.into(), + y, ) .into(); output @@ -9409,7 +9186,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, z: u64| { let output: Val = ::bevy::math::U64Vec3::with_z( _self.into(), - z.into(), + z, ) .into(); output @@ -9598,7 +9375,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec3", |_self: Ref| { let output: Val = ::bevy::math::U64Vec3::as_vec3( - _self.into(), + &_self, ) .into(); output @@ -9608,7 +9385,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec3a", |_self: Ref| { let output: Val = ::bevy::math::U64Vec3::as_vec3a( - _self.into(), + &_self, ) .into(); output @@ -9618,7 +9395,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dvec3", |_self: Ref| { let output: Val = ::bevy::math::U64Vec3::as_dvec3( - _self.into(), + &_self, ) .into(); output @@ -9628,7 +9405,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_ivec3", |_self: Ref| { let output: Val = ::bevy::math::U64Vec3::as_ivec3( - _self.into(), + &_self, ) .into(); output @@ -9638,7 +9415,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_uvec3", |_self: Ref| { let output: Val = ::bevy::math::U64Vec3::as_uvec3( - _self.into(), + &_self, ) .into(); output @@ -9648,7 +9425,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_i64vec3", |_self: Ref| { let output: Val = ::bevy::math::U64Vec3::as_i64vec3( - _self.into(), + &_self, ) .into(); output @@ -9765,9 +9542,20 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: u64| { - let output: Val = ::bevy::math::U64Vec3::rem( + "add", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::U64Vec3::add( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::U64Vec3::mul( _self.into(), rhs.into(), ) @@ -9776,22 +9564,22 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "add", + "rem", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::U64Vec3::add( + let output: Val = ::bevy::math::U64Vec3::rem( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::U64Vec3::eq( + "rem", + |_self: Val, rhs: u64| { + let output: Val = ::bevy::math::U64Vec3::rem( _self.into(), - other.into(), + rhs, ) .into(); output @@ -9801,27 +9589,27 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::bevy::math::U64Vec3::assert_receiver_is_total_eq( - _self.into(), + &_self, ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::U64Vec3::clone( + "div", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::U64Vec3::div( _self.into(), + &rhs, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::U64Vec4>::new(world) + ) .overwrite_script_function( - "rem", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::U64Vec4::rem( + "div", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::U64Vec3::div( _self.into(), rhs.into(), ) @@ -9830,22 +9618,21 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::U64Vec4::mul( + "div", + |_self: Val, rhs: u64| { + let output: Val = ::bevy::math::U64Vec3::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::U64Vec4::sub( - _self.into(), - rhs.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::U64Vec3::clone( + &_self, ) .into(); output @@ -9853,8 +9640,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "rem", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::U64Vec4::rem( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::U64Vec3::rem( _self.into(), rhs.into(), ) @@ -9863,40 +9650,49 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::math::U64Vec4::assert_receiver_is_total_eq( + "sub", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::U64Vec3::sub( _self.into(), + rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::U64Vec4::eq( + "add", + |_self: Val, rhs: u64| { + let output: Val = ::bevy::math::U64Vec3::add( _self.into(), - other.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::U64Vec4::clone( + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::U64Vec3::eq(&_self, &other).into(); + output + }, + ) + .overwrite_script_function( + "mul", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::U64Vec3::mul( _self.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::U64Vec4::div( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::U64Vec3::add( _self.into(), rhs.into(), ) @@ -9905,31 +9701,31 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: u64| { - let output: Val = ::bevy::math::U64Vec4::div( + "sub", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::U64Vec3::sub( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::U64Vec4>::new(world) .overwrite_script_function( - "add", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::U64Vec4::add( - _self.into(), - rhs.into(), + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::math::U64Vec4::assert_receiver_is_total_eq( + &_self, ) .into(); output }, ) .overwrite_script_function( - "mul", + "sub", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::U64Vec4::mul( + let output: Val = ::bevy::math::U64Vec4::sub( _self.into(), rhs.into(), ) @@ -9939,41 +9735,41 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "rem", - |_self: Val, rhs: u64| { + |_self: Val, rhs: Ref| { let output: Val = ::bevy::math::U64Vec4::rem( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "mul", + "div", |_self: Val, rhs: u64| { - let output: Val = ::bevy::math::U64Vec4::mul( + let output: Val = ::bevy::math::U64Vec4::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "add", + "div", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::U64Vec4::add( + let output: Val = ::bevy::math::U64Vec4::div( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::U64Vec4::sub( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::U64Vec4::mul( _self.into(), rhs.into(), ) @@ -9982,9 +9778,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::U64Vec4::div( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::U64Vec4::add( _self.into(), rhs.into(), ) @@ -9992,14 +9788,101 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) + .overwrite_script_function( + "rem", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::U64Vec4::rem( + _self.into(), + rhs.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "sub", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::U64Vec4::sub( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "mul", + |_self: Val, rhs: u64| { + let output: Val = ::bevy::math::U64Vec4::mul( + _self.into(), + rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "add", + |_self: Val, rhs: u64| { + let output: Val = ::bevy::math::U64Vec4::add( + _self.into(), + rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "add", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::U64Vec4::add( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "mul", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::U64Vec4::mul( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "div", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::U64Vec4::div( + _self.into(), + rhs.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::U64Vec4::clone( + &_self, + ) + .into(); + output + }, + ) .overwrite_script_function( "new", |x: u64, y: u64, z: u64, w: u64| { let output: Val = ::bevy::math::U64Vec4::new( - x.into(), - y.into(), - z.into(), - w.into(), + x, + y, + z, + w, ) .into(); output @@ -10009,7 +9892,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "splat", |v: u64| { let output: Val = ::bevy::math::U64Vec4::splat( - v.into(), + v, ) .into(); output @@ -10035,7 +9918,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [u64; 4]| { let output: Val = ::bevy::math::U64Vec4::from_array( - a.into(), + a, ) .into(); output @@ -10044,7 +9927,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_array", |_self: Ref| { - let output: [u64; 4] = ::bevy::math::U64Vec4::to_array(_self.into()) + let output: [u64; 4] = ::bevy::math::U64Vec4::to_array(&_self) .into(); output }, @@ -10064,7 +9947,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, x: u64| { let output: Val = ::bevy::math::U64Vec4::with_x( _self.into(), - x.into(), + x, ) .into(); output @@ -10075,7 +9958,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, y: u64| { let output: Val = ::bevy::math::U64Vec4::with_y( _self.into(), - y.into(), + y, ) .into(); output @@ -10086,7 +9969,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, z: u64| { let output: Val = ::bevy::math::U64Vec4::with_z( _self.into(), - z.into(), + z, ) .into(); output @@ -10097,7 +9980,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, w: u64| { let output: Val = ::bevy::math::U64Vec4::with_w( _self.into(), - w.into(), + w, ) .into(); output @@ -10275,7 +10158,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec4", |_self: Ref| { let output: Val = ::bevy::math::U64Vec4::as_vec4( - _self.into(), + &_self, ) .into(); output @@ -10285,7 +10168,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dvec4", |_self: Ref| { let output: Val = ::bevy::math::U64Vec4::as_dvec4( - _self.into(), + &_self, ) .into(); output @@ -10295,7 +10178,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_ivec4", |_self: Ref| { let output: Val = ::bevy::math::U64Vec4::as_ivec4( - _self.into(), + &_self, ) .into(); output @@ -10305,7 +10188,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_uvec4", |_self: Ref| { let output: Val = ::bevy::math::U64Vec4::as_uvec4( - _self.into(), + &_self, ) .into(); output @@ -10315,7 +10198,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_i64vec4", |_self: Ref| { let output: Val = ::bevy::math::U64Vec4::as_i64vec4( - _self.into(), + &_self, ) .into(); output @@ -10432,22 +10315,29 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "sub", + "rem", |_self: Val, rhs: u64| { - let output: Val = ::bevy::math::U64Vec4::sub( + let output: Val = ::bevy::math::U64Vec4::rem( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "add", + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::U64Vec4::eq(&_self, &other).into(); + output + }, + ) + .overwrite_script_function( + "sub", |_self: Val, rhs: u64| { - let output: Val = ::bevy::math::U64Vec4::add( + let output: Val = ::bevy::math::U64Vec4::sub( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -10455,11 +10345,11 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ); NamespaceBuilder::<::bevy::math::Vec2>::new(world) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Vec2::mul( + "div", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::Vec2::div( _self.into(), - rhs.into(), + &rhs, ) .into(); output @@ -10481,52 +10371,55 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: Ref| { let output: Val = ::bevy::math::Vec2::mul( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Vec2::div( + "sub", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::Vec2::sub( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Vec2::add( + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::Vec2::eq(&_self, &other).into(); + output + }, + ) + .overwrite_script_function( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::Vec2::neg( _self.into(), - rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Vec2::sub( + "div", + |_self: Val, rhs: f32| { + let output: Val = ::bevy::math::Vec2::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Vec2::rem( - _self.into(), - rhs.into(), - ) + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::Vec2::clone(&_self) .into(); output }, @@ -10534,10 +10427,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "new", |x: f32, y: f32| { - let output: Val = ::bevy::math::Vec2::new( - x.into(), - y.into(), - ) + let output: Val = ::bevy::math::Vec2::new(x, y) .into(); output }, @@ -10545,9 +10435,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "splat", |v: f32| { - let output: Val = ::bevy::math::Vec2::splat( - v.into(), - ) + let output: Val = ::bevy::math::Vec2::splat(v) .into(); output }, @@ -10571,9 +10459,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "from_array", |a: [f32; 2]| { - let output: Val = ::bevy::math::Vec2::from_array( - a.into(), - ) + let output: Val = ::bevy::math::Vec2::from_array(a) .into(); output }, @@ -10581,8 +10467,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_array", |_self: Ref| { - let output: [f32; 2] = ::bevy::math::Vec2::to_array(_self.into()) - .into(); + let output: [f32; 2] = ::bevy::math::Vec2::to_array(&_self).into(); output }, ) @@ -10591,7 +10476,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, z: f32| { let output: Val = ::bevy::math::Vec2::extend( _self.into(), - z.into(), + z, ) .into(); output @@ -10602,7 +10487,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, x: f32| { let output: Val = ::bevy::math::Vec2::with_x( _self.into(), - x.into(), + x, ) .into(); output @@ -10613,7 +10498,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, y: f32| { let output: Val = ::bevy::math::Vec2::with_y( _self.into(), - y.into(), + y, ) .into(); output @@ -11075,7 +10960,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, n: f32| { let output: Val = ::bevy::math::Vec2::powf( _self.into(), - n.into(), + n, ) .into(); output @@ -11097,7 +10982,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::Vec2::lerp( _self.into(), rhs.into(), - s.into(), + s, ) .into(); output @@ -11107,9 +10992,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "move_towards", |_self: Ref, rhs: Val, d: f32| { let output: Val = ::bevy::math::Vec2::move_towards( - _self.into(), + &_self, rhs.into(), - d.into(), + d, ) .into(); output @@ -11136,7 +11021,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: bool = ::bevy::math::Vec2::abs_diff_eq( _self.into(), rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -11147,8 +11032,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, min: f32, max: f32| { let output: Val = ::bevy::math::Vec2::clamp_length( _self.into(), - min.into(), - max.into(), + min, + max, ) .into(); output @@ -11159,7 +11044,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, max: f32| { let output: Val = ::bevy::math::Vec2::clamp_length_max( _self.into(), - max.into(), + max, ) .into(); output @@ -11170,7 +11055,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, min: f32| { let output: Val = ::bevy::math::Vec2::clamp_length_min( _self.into(), - min.into(), + min, ) .into(); output @@ -11209,7 +11094,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::Vec2::refract( _self.into(), normal.into(), - eta.into(), + eta, ) .into(); output @@ -11219,7 +11104,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_angle", |angle: f32| { let output: Val = ::bevy::math::Vec2::from_angle( - angle.into(), + angle, ) .into(); output @@ -11294,9 +11179,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { max_angle: f32| { let output: Val = ::bevy::math::Vec2::rotate_towards( - _self.into(), + &_self, rhs.into(), - max_angle.into(), + max_angle, ) .into(); output @@ -11306,7 +11191,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dvec2", |_self: Ref| { let output: Val = ::bevy::math::Vec2::as_dvec2( - _self.into(), + &_self, ) .into(); output @@ -11316,7 +11201,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_ivec2", |_self: Ref| { let output: Val = ::bevy::math::Vec2::as_ivec2( - _self.into(), + &_self, ) .into(); output @@ -11326,7 +11211,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_uvec2", |_self: Ref| { let output: Val = ::bevy::math::Vec2::as_uvec2( - _self.into(), + &_self, ) .into(); output @@ -11336,7 +11221,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_i64vec2", |_self: Ref| { let output: Val = ::bevy::math::Vec2::as_i64vec2( - _self.into(), + &_self, ) .into(); output @@ -11346,34 +11231,27 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_u64vec2", |_self: Ref| { let output: Val = ::bevy::math::Vec2::as_u64vec2( - _self.into(), + &_self, ) .into(); output }, ) .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::Vec2::eq(_self.into(), other.into()) - .into(); - output - }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::Vec2::clone( + "sub", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Vec2::sub( _self.into(), + rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::Vec2::sub( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Vec2::mul( _self.into(), rhs.into(), ) @@ -11383,21 +11261,21 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "rem", - |_self: Val, rhs: Ref| { + |_self: Val, rhs: f32| { let output: Val = ::bevy::math::Vec2::rem( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Vec2::rem( + "add", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::Vec2::add( _self.into(), - rhs.into(), + &rhs, ) .into(); output @@ -11415,11 +11293,11 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "sub", + "add", |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Vec2::sub( + let output: Val = ::bevy::math::Vec2::add( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -11430,39 +11308,40 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: f32| { let output: Val = ::bevy::math::Vec2::mul( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::Vec2::neg( + "rem", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Vec2::rem( _self.into(), + rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::Vec2::add( + "sub", + |_self: Val, rhs: f32| { + let output: Val = ::bevy::math::Vec2::sub( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "div", + "rem", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::Vec2::div( + let output: Val = ::bevy::math::Vec2::rem( _self.into(), - rhs.into(), + &rhs, ) .into(); output @@ -11470,9 +11349,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ); NamespaceBuilder::<::bevy::math::Vec3A>::new(world) .overwrite_script_function( - "rem", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::Vec3A::rem( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Vec3A::add( _self.into(), rhs.into(), ) @@ -11481,33 +11360,39 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Vec3A::mul( + "eq", + |_self: Ref, rhs: Ref| { + let output: bool = ::bevy::math::Vec3A::eq(&_self, &rhs).into(); + output + }, + ) + .overwrite_script_function( + "sub", + |_self: Val, rhs: f32| { + let output: Val = ::bevy::math::Vec3A::sub( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::Vec3A::div( - _self.into(), - rhs.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::Vec3A::clone( + &_self, ) .into(); output }, ) .overwrite_script_function( - "div", + "rem", |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Vec3A::div( + let output: Val = ::bevy::math::Vec3A::rem( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -11515,7 +11400,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "sub", - |_self: Val, rhs: f32| { + |_self: Val, rhs: Val| { let output: Val = ::bevy::math::Vec3A::sub( _self.into(), rhs.into(), @@ -11525,13 +11410,34 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "new", - |x: f32, y: f32, z: f32| { - let output: Val = ::bevy::math::Vec3A::new( - x.into(), - y.into(), - z.into(), - ) + "div", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Vec3A::div( + _self.into(), + rhs.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::Vec3A::neg( + _self.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "new", + |x: f32, y: f32, z: f32| { + let output: Val = ::bevy::math::Vec3A::new( + x, + y, + z, + ) .into(); output }, @@ -11539,9 +11445,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "splat", |v: f32| { - let output: Val = ::bevy::math::Vec3A::splat( - v.into(), - ) + let output: Val = ::bevy::math::Vec3A::splat(v) .into(); output }, @@ -11566,7 +11470,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [f32; 3]| { let output: Val = ::bevy::math::Vec3A::from_array( - a.into(), + a, ) .into(); output @@ -11575,8 +11479,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_array", |_self: Ref| { - let output: [f32; 3] = ::bevy::math::Vec3A::to_array(_self.into()) - .into(); + let output: [f32; 3] = ::bevy::math::Vec3A::to_array(&_self).into(); output }, ) @@ -11595,7 +11498,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, w: f32| { let output: Val = ::bevy::math::Vec3A::extend( _self.into(), - w.into(), + w, ) .into(); output @@ -11616,7 +11519,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, x: f32| { let output: Val = ::bevy::math::Vec3A::with_x( _self.into(), - x.into(), + x, ) .into(); output @@ -11627,7 +11530,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, y: f32| { let output: Val = ::bevy::math::Vec3A::with_y( _self.into(), - y.into(), + y, ) .into(); output @@ -11638,7 +11541,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, z: f32| { let output: Val = ::bevy::math::Vec3A::with_z( _self.into(), - z.into(), + z, ) .into(); output @@ -12111,7 +12014,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, n: f32| { let output: Val = ::bevy::math::Vec3A::powf( _self.into(), - n.into(), + n, ) .into(); output @@ -12133,7 +12036,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::Vec3A::lerp( _self.into(), rhs.into(), - s.into(), + s, ) .into(); output @@ -12143,9 +12046,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "move_towards", |_self: Ref, rhs: Val, d: f32| { let output: Val = ::bevy::math::Vec3A::move_towards( - _self.into(), + &_self, rhs.into(), - d.into(), + d, ) .into(); output @@ -12172,7 +12075,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: bool = ::bevy::math::Vec3A::abs_diff_eq( _self.into(), rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -12183,8 +12086,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, min: f32, max: f32| { let output: Val = ::bevy::math::Vec3A::clamp_length( _self.into(), - min.into(), - max.into(), + min, + max, ) .into(); output @@ -12195,7 +12098,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, max: f32| { let output: Val = ::bevy::math::Vec3A::clamp_length_max( _self.into(), - max.into(), + max, ) .into(); output @@ -12206,7 +12109,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, min: f32| { let output: Val = ::bevy::math::Vec3A::clamp_length_min( _self.into(), - min.into(), + min, ) .into(); output @@ -12249,7 +12152,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::Vec3A::refract( _self.into(), normal.into(), - eta.into(), + eta, ) .into(); output @@ -12270,7 +12173,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "any_orthogonal_vector", |_self: Ref| { let output: Val = ::bevy::math::Vec3A::any_orthogonal_vector( - _self.into(), + &_self, ) .into(); output @@ -12280,7 +12183,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "any_orthonormal_vector", |_self: Ref| { let output: Val = ::bevy::math::Vec3A::any_orthonormal_vector( - _self.into(), + &_self, ) .into(); output @@ -12290,7 +12193,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dvec3", |_self: Ref| { let output: Val = ::bevy::math::Vec3A::as_dvec3( - _self.into(), + &_self, ) .into(); output @@ -12300,7 +12203,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_ivec3", |_self: Ref| { let output: Val = ::bevy::math::Vec3A::as_ivec3( - _self.into(), + &_self, ) .into(); output @@ -12310,7 +12213,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_uvec3", |_self: Ref| { let output: Val = ::bevy::math::Vec3A::as_uvec3( - _self.into(), + &_self, ) .into(); output @@ -12320,7 +12223,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_i64vec3", |_self: Ref| { let output: Val = ::bevy::math::Vec3A::as_i64vec3( - _self.into(), + &_self, ) .into(); output @@ -12330,17 +12233,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_u64vec3", |_self: Ref| { let output: Val = ::bevy::math::Vec3A::as_u64vec3( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::Vec3A::neg( - _self.into(), + &_self, ) .into(); output @@ -12351,17 +12244,18 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: Ref| { let output: Val = ::bevy::math::Vec3A::sub( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::Vec3A::clone( + "mul", + |_self: Val, rhs: f32| { + let output: Val = ::bevy::math::Vec3A::mul( _self.into(), + rhs, ) .into(); output @@ -12372,7 +12266,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: Ref| { let output: Val = ::bevy::math::Vec3A::add( _self.into(), - rhs.into(), + &rhs, ) .into(); output @@ -12383,16 +12277,16 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: f32| { let output: Val = ::bevy::math::Vec3A::add( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", + "mul", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Vec3A::sub( + let output: Val = ::bevy::math::Vec3A::mul( _self.into(), rhs.into(), ) @@ -12402,19 +12296,19 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "div", - |_self: Val, rhs: Val| { + |_self: Val, rhs: f32| { let output: Val = ::bevy::math::Vec3A::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "add", + "rem", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Vec3A::add( + let output: Val = ::bevy::math::Vec3A::rem( _self.into(), rhs.into(), ) @@ -12423,30 +12317,45 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "eq", - |_self: Ref, rhs: Ref| { - let output: bool = ::bevy::math::Vec3A::eq(_self.into(), rhs.into()) + "rem", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::Vec3A::rem( + _self.into(), + &rhs, + ) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Vec3A::rem( + "mul", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::Vec3A::mul( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) + .overwrite_script_function( + "div", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::Vec3A::div( + _self.into(), + &rhs, + ) + .into(); + output + }, + ); + NamespaceBuilder::<::bevy::math::Vec4>::new(world) .overwrite_script_function( "rem", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Vec3A::rem( + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::Vec4::rem( _self.into(), - rhs.into(), + &rhs, ) .into(); output @@ -12454,8 +12363,26 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "mul", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Vec3A::mul( + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::Vec4::mul( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "eq", + |_self: Ref, rhs: Ref| { + let output: bool = ::bevy::math::Vec4::eq(&_self, &rhs).into(); + output + }, + ) + .overwrite_script_function( + "div", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Vec4::div( _self.into(), rhs.into(), ) @@ -12464,25 +12391,78 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::Vec3A::mul( + "div", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::Vec4::div( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::Vec4::neg( + _self.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Vec4::add( _self.into(), rhs.into(), ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::Vec4>::new(world) + ) + .overwrite_script_function( + "add", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::Vec4::add( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "add", + |_self: Val, rhs: f32| { + let output: Val = ::bevy::math::Vec4::add( + _self.into(), + rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "sub", + |_self: Val, rhs: f32| { + let output: Val = ::bevy::math::Vec4::sub( + _self.into(), + rhs, + ) + .into(); + output + }, + ) .overwrite_script_function( "new", |x: f32, y: f32, z: f32, w: f32| { let output: Val = ::bevy::math::Vec4::new( - x.into(), - y.into(), - z.into(), - w.into(), + x, + y, + z, + w, ) .into(); output @@ -12491,9 +12471,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "splat", |v: f32| { - let output: Val = ::bevy::math::Vec4::splat( - v.into(), - ) + let output: Val = ::bevy::math::Vec4::splat(v) .into(); output }, @@ -12517,9 +12495,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "from_array", |a: [f32; 4]| { - let output: Val = ::bevy::math::Vec4::from_array( - a.into(), - ) + let output: Val = ::bevy::math::Vec4::from_array(a) .into(); output }, @@ -12527,8 +12503,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_array", |_self: Ref| { - let output: [f32; 4] = ::bevy::math::Vec4::to_array(_self.into()) - .into(); + let output: [f32; 4] = ::bevy::math::Vec4::to_array(&_self).into(); output }, ) @@ -12547,7 +12522,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, x: f32| { let output: Val = ::bevy::math::Vec4::with_x( _self.into(), - x.into(), + x, ) .into(); output @@ -12558,7 +12533,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, y: f32| { let output: Val = ::bevy::math::Vec4::with_y( _self.into(), - y.into(), + y, ) .into(); output @@ -12569,7 +12544,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, z: f32| { let output: Val = ::bevy::math::Vec4::with_z( _self.into(), - z.into(), + z, ) .into(); output @@ -12580,7 +12555,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, w: f32| { let output: Val = ::bevy::math::Vec4::with_w( _self.into(), - w.into(), + w, ) .into(); output @@ -13042,7 +13017,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, n: f32| { let output: Val = ::bevy::math::Vec4::powf( _self.into(), - n.into(), + n, ) .into(); output @@ -13064,7 +13039,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::Vec4::lerp( _self.into(), rhs.into(), - s.into(), + s, ) .into(); output @@ -13074,9 +13049,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "move_towards", |_self: Ref, rhs: Val, d: f32| { let output: Val = ::bevy::math::Vec4::move_towards( - _self.into(), + &_self, rhs.into(), - d.into(), + d, ) .into(); output @@ -13103,7 +13078,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: bool = ::bevy::math::Vec4::abs_diff_eq( _self.into(), rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -13114,8 +13089,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, min: f32, max: f32| { let output: Val = ::bevy::math::Vec4::clamp_length( _self.into(), - min.into(), - max.into(), + min, + max, ) .into(); output @@ -13126,7 +13101,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, max: f32| { let output: Val = ::bevy::math::Vec4::clamp_length_max( _self.into(), - max.into(), + max, ) .into(); output @@ -13137,7 +13112,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, min: f32| { let output: Val = ::bevy::math::Vec4::clamp_length_min( _self.into(), - min.into(), + min, ) .into(); output @@ -13176,7 +13151,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::Vec4::refract( _self.into(), normal.into(), - eta.into(), + eta, ) .into(); output @@ -13186,7 +13161,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dvec4", |_self: Ref| { let output: Val = ::bevy::math::Vec4::as_dvec4( - _self.into(), + &_self, ) .into(); output @@ -13196,7 +13171,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_ivec4", |_self: Ref| { let output: Val = ::bevy::math::Vec4::as_ivec4( - _self.into(), + &_self, ) .into(); output @@ -13206,7 +13181,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_uvec4", |_self: Ref| { let output: Val = ::bevy::math::Vec4::as_uvec4( - _self.into(), + &_self, ) .into(); output @@ -13216,7 +13191,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_i64vec4", |_self: Ref| { let output: Val = ::bevy::math::Vec4::as_i64vec4( - _self.into(), + &_self, ) .into(); output @@ -13226,38 +13201,16 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_u64vec4", |_self: Ref| { let output: Val = ::bevy::math::Vec4::as_u64vec4( - _self.into(), + &_self, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Vec4::div( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "rem", + "sub", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Vec4::rem( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "rem", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Vec4::rem( + let output: Val = ::bevy::math::Vec4::sub( _self.into(), rhs.into(), ) @@ -13266,11 +13219,11 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "add", + "sub", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::Vec4::add( + let output: Val = ::bevy::math::Vec4::sub( _self.into(), - rhs.into(), + &rhs, ) .into(); output @@ -13287,56 +13240,21 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) - .overwrite_script_function( - "add", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Vec4::add( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "sub", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Vec4::sub( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "rem", - |_self: Val, rhs: Ref| { + |_self: Val, rhs: f32| { let output: Val = ::bevy::math::Vec4::rem( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::Vec4::neg( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "sub", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Vec4::sub( - _self.into(), - rhs.into(), - ) + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::Vec4::clone(&_self) .into(); output }, @@ -13346,46 +13264,16 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: f32| { let output: Val = ::bevy::math::Vec4::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "add", + "rem", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Vec4::add( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "eq", - |_self: Ref, rhs: Ref| { - let output: bool = ::bevy::math::Vec4::eq(_self.into(), rhs.into()) - .into(); - output - }, - ) - .overwrite_script_function( - "sub", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::Vec4::sub( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "div", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::Vec4::div( + let output: Val = ::bevy::math::Vec4::rem( _self.into(), rhs.into(), ) @@ -13393,33 +13281,12 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::Vec4::clone( - _self.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "mul", |_self: Val, rhs: f32| { let output: Val = ::bevy::math::Vec4::mul( _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::Vec4::mul( - _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -13430,19 +13297,23 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::bevy::math::BVec2::assert_receiver_is_total_eq( - _self.into(), + &_self, ) .into(); output }, ) + .overwrite_script_function( + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::BVec2::eq(&_self, &other).into(); + output + }, + ) .overwrite_script_function( "new", |x: bool, y: bool| { - let output: Val = ::bevy::math::BVec2::new( - x.into(), - y.into(), - ) + let output: Val = ::bevy::math::BVec2::new(x, y) .into(); output }, @@ -13450,9 +13321,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "splat", |v: bool| { - let output: Val = ::bevy::math::BVec2::splat( - v.into(), - ) + let output: Val = ::bevy::math::BVec2::splat(v) .into(); output }, @@ -13461,7 +13330,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [bool; 2]| { let output: Val = ::bevy::math::BVec2::from_array( - a.into(), + a, ) .into(); output @@ -13491,22 +13360,14 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "test", |_self: Ref, index: usize| { - let output: bool = ::bevy::math::BVec2::test( - _self.into(), - index.into(), - ) - .into(); + let output: bool = ::bevy::math::BVec2::test(&_self, index).into(); output }, ) .overwrite_script_function( "set", |_self: Mut, index: usize, value: bool| { - let output: () = ::bevy::math::BVec2::set( - _self.into(), - index.into(), - value.into(), - ) + let output: () = ::bevy::math::BVec2::set(&mut_self, index, value) .into(); output }, @@ -13515,41 +13376,20 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::BVec2::clone( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::BVec2::eq( - _self.into(), - other.into(), + &_self, ) .into(); output }, ); NamespaceBuilder::<::bevy::math::BVec3>::new(world) - .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::math::BVec3::assert_receiver_is_total_eq( - _self.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "new", |x: bool, y: bool, z: bool| { let output: Val = ::bevy::math::BVec3::new( - x.into(), - y.into(), - z.into(), + x, + y, + z, ) .into(); output @@ -13558,9 +13398,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "splat", |v: bool| { - let output: Val = ::bevy::math::BVec3::splat( - v.into(), - ) + let output: Val = ::bevy::math::BVec3::splat(v) .into(); output }, @@ -13569,7 +13407,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [bool; 3]| { let output: Val = ::bevy::math::BVec3::from_array( - a.into(), + a, ) .into(); output @@ -13599,42 +13437,40 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "test", |_self: Ref, index: usize| { - let output: bool = ::bevy::math::BVec3::test( - _self.into(), - index.into(), - ) - .into(); + let output: bool = ::bevy::math::BVec3::test(&_self, index).into(); output }, ) .overwrite_script_function( "set", |_self: Mut, index: usize, value: bool| { - let output: () = ::bevy::math::BVec3::set( - _self.into(), - index.into(), - value.into(), - ) + let output: () = ::bevy::math::BVec3::set(&mut_self, index, value) .into(); output }, ) + .overwrite_script_function( + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::BVec3::eq(&_self, &other).into(); + output + }, + ) .overwrite_script_function( "clone", |_self: Ref| { let output: Val = ::bevy::math::BVec3::clone( - _self.into(), + &_self, ) .into(); output }, ) .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::BVec3::eq( - _self.into(), - other.into(), + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::math::BVec3::assert_receiver_is_total_eq( + &_self, ) .into(); output @@ -13642,120 +13478,149 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ); NamespaceBuilder::<::bevy::math::BVec4>::new(world) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::BVec4::clone( - _self.into(), + "new", + |x: bool, y: bool, z: bool, w: bool| { + let output: Val = ::bevy::math::BVec4::new( + x, + y, + z, + w, ) .into(); output }, ) .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::BVec4::eq( - _self.into(), - other.into(), - ) + "splat", + |v: bool| { + let output: Val = ::bevy::math::BVec4::splat(v) .into(); output }, ) .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::math::BVec4::assert_receiver_is_total_eq( - _self.into(), + "from_array", + |a: [bool; 4]| { + let output: Val = ::bevy::math::BVec4::from_array( + a, ) .into(); output }, ) .overwrite_script_function( - "new", - |x: bool, y: bool, z: bool, w: bool| { - let output: Val = ::bevy::math::BVec4::new( - x.into(), - y.into(), - z.into(), - w.into(), - ) + "bitmask", + |_self: Val| { + let output: u32 = ::bevy::math::BVec4::bitmask(_self.into()).into(); + output + }, + ) + .overwrite_script_function( + "any", + |_self: Val| { + let output: bool = ::bevy::math::BVec4::any(_self.into()).into(); + output + }, + ) + .overwrite_script_function( + "all", + |_self: Val| { + let output: bool = ::bevy::math::BVec4::all(_self.into()).into(); + output + }, + ) + .overwrite_script_function( + "test", + |_self: Ref, index: usize| { + let output: bool = ::bevy::math::BVec4::test(&_self, index).into(); + output + }, + ) + .overwrite_script_function( + "set", + |_self: Mut, index: usize, value: bool| { + let output: () = ::bevy::math::BVec4::set(&mut_self, index, value) .into(); output }, ) .overwrite_script_function( - "splat", - |v: bool| { - let output: Val = ::bevy::math::BVec4::splat( - v.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::BVec4::clone( + &_self, ) .into(); output }, ) .overwrite_script_function( - "from_array", - |a: [bool; 4]| { - let output: Val = ::bevy::math::BVec4::from_array( - a.into(), + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::BVec4::eq(&_self, &other).into(); + output + }, + ) + .overwrite_script_function( + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::math::BVec4::assert_receiver_is_total_eq( + &_self, ) .into(); output }, - ) - .overwrite_script_function( - "bitmask", - |_self: Val| { - let output: u32 = ::bevy::math::BVec4::bitmask(_self.into()).into(); - output - }, - ) + ); + NamespaceBuilder::<::bevy::math::DVec2>::new(world) .overwrite_script_function( - "any", - |_self: Val| { - let output: bool = ::bevy::math::BVec4::any(_self.into()).into(); + "neg", + |_self: Val| { + let output: Val = ::bevy::math::DVec2::neg( + _self.into(), + ) + .into(); output }, ) .overwrite_script_function( - "all", - |_self: Val| { - let output: bool = ::bevy::math::BVec4::all(_self.into()).into(); + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DVec2::mul( + _self.into(), + rhs.into(), + ) + .into(); output }, ) .overwrite_script_function( - "test", - |_self: Ref, index: usize| { - let output: bool = ::bevy::math::BVec4::test( + "sub", + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DVec2::sub( _self.into(), - index.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "set", - |_self: Mut, index: usize, value: bool| { - let output: () = ::bevy::math::BVec4::set( + "div", + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DVec2::div( _self.into(), - index.into(), - value.into(), + rhs, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::DVec2>::new(world) + ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DVec2::mul( + "div", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::DVec2::div( _self.into(), - rhs.into(), + &rhs, ) .into(); output @@ -13763,19 +13628,19 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "rem", - |_self: Val, rhs: f64| { + |_self: Val, rhs: Ref| { let output: Val = ::bevy::math::DVec2::rem( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "add", + "div", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DVec2::add( + let output: Val = ::bevy::math::DVec2::div( _self.into(), rhs.into(), ) @@ -13786,10 +13651,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "new", |x: f64, y: f64| { - let output: Val = ::bevy::math::DVec2::new( - x.into(), - y.into(), - ) + let output: Val = ::bevy::math::DVec2::new(x, y) .into(); output }, @@ -13797,9 +13659,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "splat", |v: f64| { - let output: Val = ::bevy::math::DVec2::splat( - v.into(), - ) + let output: Val = ::bevy::math::DVec2::splat(v) .into(); output }, @@ -13824,7 +13684,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [f64; 2]| { let output: Val = ::bevy::math::DVec2::from_array( - a.into(), + a, ) .into(); output @@ -13833,8 +13693,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_array", |_self: Ref| { - let output: [f64; 2] = ::bevy::math::DVec2::to_array(_self.into()) - .into(); + let output: [f64; 2] = ::bevy::math::DVec2::to_array(&_self).into(); output }, ) @@ -13843,7 +13702,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, z: f64| { let output: Val = ::bevy::math::DVec2::extend( _self.into(), - z.into(), + z, ) .into(); output @@ -13854,7 +13713,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, x: f64| { let output: Val = ::bevy::math::DVec2::with_x( _self.into(), - x.into(), + x, ) .into(); output @@ -13865,7 +13724,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, y: f64| { let output: Val = ::bevy::math::DVec2::with_y( _self.into(), - y.into(), + y, ) .into(); output @@ -14327,7 +14186,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, n: f64| { let output: Val = ::bevy::math::DVec2::powf( _self.into(), - n.into(), + n, ) .into(); output @@ -14349,7 +14208,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::DVec2::lerp( _self.into(), rhs.into(), - s.into(), + s, ) .into(); output @@ -14359,9 +14218,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "move_towards", |_self: Ref, rhs: Val, d: f64| { let output: Val = ::bevy::math::DVec2::move_towards( - _self.into(), + &_self, rhs.into(), - d.into(), + d, ) .into(); output @@ -14388,7 +14247,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: bool = ::bevy::math::DVec2::abs_diff_eq( _self.into(), rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -14399,8 +14258,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, min: f64, max: f64| { let output: Val = ::bevy::math::DVec2::clamp_length( _self.into(), - min.into(), - max.into(), + min, + max, ) .into(); output @@ -14411,7 +14270,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, max: f64| { let output: Val = ::bevy::math::DVec2::clamp_length_max( _self.into(), - max.into(), + max, ) .into(); output @@ -14422,7 +14281,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, min: f64| { let output: Val = ::bevy::math::DVec2::clamp_length_min( _self.into(), - min.into(), + min, ) .into(); output @@ -14465,7 +14324,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::DVec2::refract( _self.into(), normal.into(), - eta.into(), + eta, ) .into(); output @@ -14475,7 +14334,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_angle", |angle: f64| { let output: Val = ::bevy::math::DVec2::from_angle( - angle.into(), + angle, ) .into(); output @@ -14550,9 +14409,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { max_angle: f64| { let output: Val = ::bevy::math::DVec2::rotate_towards( - _self.into(), + &_self, rhs.into(), - max_angle.into(), + max_angle, ) .into(); output @@ -14562,7 +14421,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec2", |_self: Ref| { let output: Val = ::bevy::math::DVec2::as_vec2( - _self.into(), + &_self, ) .into(); output @@ -14572,7 +14431,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_ivec2", |_self: Ref| { let output: Val = ::bevy::math::DVec2::as_ivec2( - _self.into(), + &_self, ) .into(); output @@ -14582,7 +14441,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_uvec2", |_self: Ref| { let output: Val = ::bevy::math::DVec2::as_uvec2( - _self.into(), + &_self, ) .into(); output @@ -14592,7 +14451,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_i64vec2", |_self: Ref| { let output: Val = ::bevy::math::DVec2::as_i64vec2( - _self.into(), + &_self, ) .into(); output @@ -14602,29 +14461,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_u64vec2", |_self: Ref| { let output: Val = ::bevy::math::DVec2::as_u64vec2( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "div", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DVec2::div( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "div", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::DVec2::div( - _self.into(), - rhs.into(), + &_self, ) .into(); output @@ -14635,18 +14472,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: Ref| { let output: Val = ::bevy::math::DVec2::mul( _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "rem", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DVec2::rem( - _self.into(), - rhs.into(), + &rhs, ) .into(); output @@ -14654,7 +14480,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "sub", - |_self: Val, rhs: f64| { + |_self: Val, rhs: Val| { let output: Val = ::bevy::math::DVec2::sub( _self.into(), rhs.into(), @@ -14663,75 +14489,17 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) - .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::DVec2::neg( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "add", - |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DVec2::add( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "eq", |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::DVec2::eq( - _self.into(), - other.into(), - ) - .into(); + let output: bool = ::bevy::math::DVec2::eq(&_self, &other).into(); output }, ) .overwrite_script_function( "rem", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::DVec2::rem( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "sub", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DVec2::sub( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "sub", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::DVec2::sub( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul", - |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DVec2::mul( + let output: Val = ::bevy::math::DVec2::rem( _self.into(), rhs.into(), ) @@ -14741,10 +14509,10 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "add", - |_self: Val, rhs: Ref| { + |_self: Val, rhs: f64| { let output: Val = ::bevy::math::DVec2::add( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -14754,41 +14522,18 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::DVec2::clone( - _self.into(), + &_self, ) .into(); output }, ) .overwrite_script_function( - "div", + "rem", |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DVec2::div( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ); - NamespaceBuilder::<::bevy::math::DVec3>::new(world) - .overwrite_script_function( - "div", - |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DVec3::div( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "sub", - |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DVec3::sub( + let output: Val = ::bevy::math::DVec2::rem( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -14796,19 +14541,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "add", - |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DVec3::add( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "div", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DVec3::div( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DVec2::add( _self.into(), rhs.into(), ) @@ -14817,32 +14551,22 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::DVec3::neg( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::DVec3::eq( + "mul", + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DVec2::mul( _self.into(), - other.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DVec3::rem( + "sub", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::DVec2::sub( _self.into(), - rhs.into(), + &rhs, ) .into(); output @@ -14850,43 +14574,32 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "add", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DVec3::add( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "sub", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::DVec3::sub( + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::DVec2::add( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::DVec3>::new(world) .overwrite_script_function( - "add", + "div", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::DVec3::add( + let output: Val = ::bevy::math::DVec3::div( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DVec3::mul( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::DVec3::neg( _self.into(), - rhs.into(), ) .into(); output @@ -14894,19 +14607,19 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "div", - |_self: Val, rhs: Ref| { + |_self: Val, rhs: f64| { let output: Val = ::bevy::math::DVec3::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::DVec3::rem( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DVec3::mul( _self.into(), rhs.into(), ) @@ -14915,11 +14628,11 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DVec3::rem( + "sub", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::DVec3::sub( _self.into(), - rhs.into(), + &rhs, ) .into(); output @@ -14929,9 +14642,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |x: f64, y: f64, z: f64| { let output: Val = ::bevy::math::DVec3::new( - x.into(), - y.into(), - z.into(), + x, + y, + z, ) .into(); output @@ -14940,9 +14653,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "splat", |v: f64| { - let output: Val = ::bevy::math::DVec3::splat( - v.into(), - ) + let output: Val = ::bevy::math::DVec3::splat(v) .into(); output }, @@ -14967,7 +14678,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [f64; 3]| { let output: Val = ::bevy::math::DVec3::from_array( - a.into(), + a, ) .into(); output @@ -14976,8 +14687,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_array", |_self: Ref| { - let output: [f64; 3] = ::bevy::math::DVec3::to_array(_self.into()) - .into(); + let output: [f64; 3] = ::bevy::math::DVec3::to_array(&_self).into(); output }, ) @@ -14986,7 +14696,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, w: f64| { let output: Val = ::bevy::math::DVec3::extend( _self.into(), - w.into(), + w, ) .into(); output @@ -15007,7 +14717,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, x: f64| { let output: Val = ::bevy::math::DVec3::with_x( _self.into(), - x.into(), + x, ) .into(); output @@ -15018,7 +14728,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, y: f64| { let output: Val = ::bevy::math::DVec3::with_y( _self.into(), - y.into(), + y, ) .into(); output @@ -15029,7 +14739,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, z: f64| { let output: Val = ::bevy::math::DVec3::with_z( _self.into(), - z.into(), + z, ) .into(); output @@ -15502,7 +15212,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, n: f64| { let output: Val = ::bevy::math::DVec3::powf( _self.into(), - n.into(), + n, ) .into(); output @@ -15524,7 +15234,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::DVec3::lerp( _self.into(), rhs.into(), - s.into(), + s, ) .into(); output @@ -15534,9 +15244,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "move_towards", |_self: Ref, rhs: Val, d: f64| { let output: Val = ::bevy::math::DVec3::move_towards( - _self.into(), + &_self, rhs.into(), - d.into(), + d, ) .into(); output @@ -15563,7 +15273,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: bool = ::bevy::math::DVec3::abs_diff_eq( _self.into(), rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -15574,8 +15284,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, min: f64, max: f64| { let output: Val = ::bevy::math::DVec3::clamp_length( _self.into(), - min.into(), - max.into(), + min, + max, ) .into(); output @@ -15586,7 +15296,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, max: f64| { let output: Val = ::bevy::math::DVec3::clamp_length_max( _self.into(), - max.into(), + max, ) .into(); output @@ -15597,7 +15307,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, min: f64| { let output: Val = ::bevy::math::DVec3::clamp_length_min( _self.into(), - min.into(), + min, ) .into(); output @@ -15640,7 +15350,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::DVec3::refract( _self.into(), normal.into(), - eta.into(), + eta, ) .into(); output @@ -15651,96 +15361,341 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: Val| { let output: f64 = ::bevy::math::DVec3::angle_between( _self.into(), - rhs.into(), + rhs.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "any_orthogonal_vector", + |_self: Ref| { + let output: Val = ::bevy::math::DVec3::any_orthogonal_vector( + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "any_orthonormal_vector", + |_self: Ref| { + let output: Val = ::bevy::math::DVec3::any_orthonormal_vector( + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "as_vec3", + |_self: Ref| { + let output: Val = ::bevy::math::DVec3::as_vec3( + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "as_vec3a", + |_self: Ref| { + let output: Val = ::bevy::math::DVec3::as_vec3a( + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "as_ivec3", + |_self: Ref| { + let output: Val = ::bevy::math::DVec3::as_ivec3( + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "as_uvec3", + |_self: Ref| { + let output: Val = ::bevy::math::DVec3::as_uvec3( + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "as_i64vec3", + |_self: Ref| { + let output: Val = ::bevy::math::DVec3::as_i64vec3( + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "as_u64vec3", + |_self: Ref| { + let output: Val = ::bevy::math::DVec3::as_u64vec3( + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "sub", + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DVec3::sub( + _self.into(), + rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "rem", + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DVec3::rem( + _self.into(), + rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "div", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DVec3::div( + _self.into(), + rhs.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::DVec3::eq(&_self, &other).into(); + output + }, + ) + .overwrite_script_function( + "rem", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::DVec3::rem( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "sub", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DVec3::sub( + _self.into(), + rhs.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "add", + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DVec3::add( + _self.into(), + rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "add", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::DVec3::add( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "mul", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::DVec3::mul( + _self.into(), + &rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "mul", + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DVec3::mul( + _self.into(), + rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "rem", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DVec3::rem( + _self.into(), + rhs.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DVec3::add( + _self.into(), + rhs.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::DVec3::clone( + &_self, + ) + .into(); + output + }, + ); + NamespaceBuilder::<::bevy::math::DVec4>::new(world) + .overwrite_script_function( + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::DVec4::eq(&_self, &other).into(); + output + }, + ) + .overwrite_script_function( + "mul", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::DVec4::mul( + _self.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "any_orthogonal_vector", - |_self: Ref| { - let output: Val = ::bevy::math::DVec3::any_orthogonal_vector( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DVec4::add( _self.into(), + rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "any_orthonormal_vector", - |_self: Ref| { - let output: Val = ::bevy::math::DVec3::any_orthonormal_vector( + "sub", + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DVec4::sub( _self.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "as_vec3", - |_self: Ref| { - let output: Val = ::bevy::math::DVec3::as_vec3( + "div", + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DVec4::div( _self.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "as_vec3a", - |_self: Ref| { - let output: Val = ::bevy::math::DVec3::as_vec3a( + "div", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DVec4::div( _self.into(), + rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "as_ivec3", - |_self: Ref| { - let output: Val = ::bevy::math::DVec3::as_ivec3( + "rem", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::DVec4::rem( _self.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "as_uvec3", - |_self: Ref| { - let output: Val = ::bevy::math::DVec3::as_uvec3( + "mul", + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DVec4::mul( _self.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "as_i64vec3", - |_self: Ref| { - let output: Val = ::bevy::math::DVec3::as_i64vec3( + "rem", + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DVec4::rem( _self.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "as_u64vec3", - |_self: Ref| { - let output: Val = ::bevy::math::DVec3::as_u64vec3( + "add", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::DVec4::add( _self.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DVec3::mul( + "sub", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DVec4::sub( _self.into(), rhs.into(), ) @@ -15750,53 +15705,53 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "clone", - |_self: Ref| { - let output: Val = ::bevy::math::DVec3::clone( - _self.into(), + |_self: Ref| { + let output: Val = ::bevy::math::DVec4::clone( + &_self, ) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::DVec3::mul( + "div", + |_self: Val, rhs: Ref| { + let output: Val = ::bevy::math::DVec4::div( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DVec3::sub( + "rem", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DVec4::rem( _self.into(), rhs.into(), ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::DVec4>::new(world) + ) .overwrite_script_function( - "rem", + "sub", |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::DVec4::rem( + let output: Val = ::bevy::math::DVec4::sub( _self.into(), - rhs.into(), + &rhs, ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::DVec4::clone( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DVec4::mul( _self.into(), + rhs.into(), ) .into(); output @@ -15816,10 +15771,10 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |x: f64, y: f64, z: f64, w: f64| { let output: Val = ::bevy::math::DVec4::new( - x.into(), - y.into(), - z.into(), - w.into(), + x, + y, + z, + w, ) .into(); output @@ -15828,9 +15783,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "splat", |v: f64| { - let output: Val = ::bevy::math::DVec4::splat( - v.into(), - ) + let output: Val = ::bevy::math::DVec4::splat(v) .into(); output }, @@ -15855,7 +15808,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [f64; 4]| { let output: Val = ::bevy::math::DVec4::from_array( - a.into(), + a, ) .into(); output @@ -15864,8 +15817,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_array", |_self: Ref| { - let output: [f64; 4] = ::bevy::math::DVec4::to_array(_self.into()) - .into(); + let output: [f64; 4] = ::bevy::math::DVec4::to_array(&_self).into(); output }, ) @@ -15884,7 +15836,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, x: f64| { let output: Val = ::bevy::math::DVec4::with_x( _self.into(), - x.into(), + x, ) .into(); output @@ -15895,7 +15847,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, y: f64| { let output: Val = ::bevy::math::DVec4::with_y( _self.into(), - y.into(), + y, ) .into(); output @@ -15906,7 +15858,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, z: f64| { let output: Val = ::bevy::math::DVec4::with_z( _self.into(), - z.into(), + z, ) .into(); output @@ -15917,7 +15869,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, w: f64| { let output: Val = ::bevy::math::DVec4::with_w( _self.into(), - w.into(), + w, ) .into(); output @@ -16379,7 +16331,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, n: f64| { let output: Val = ::bevy::math::DVec4::powf( _self.into(), - n.into(), + n, ) .into(); output @@ -16401,7 +16353,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::DVec4::lerp( _self.into(), rhs.into(), - s.into(), + s, ) .into(); output @@ -16411,9 +16363,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "move_towards", |_self: Ref, rhs: Val, d: f64| { let output: Val = ::bevy::math::DVec4::move_towards( - _self.into(), + &_self, rhs.into(), - d.into(), + d, ) .into(); output @@ -16440,7 +16392,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: bool = ::bevy::math::DVec4::abs_diff_eq( _self.into(), rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -16451,8 +16403,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, min: f64, max: f64| { let output: Val = ::bevy::math::DVec4::clamp_length( _self.into(), - min.into(), - max.into(), + min, + max, ) .into(); output @@ -16463,7 +16415,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, max: f64| { let output: Val = ::bevy::math::DVec4::clamp_length_max( _self.into(), - max.into(), + max, ) .into(); output @@ -16474,7 +16426,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, min: f64| { let output: Val = ::bevy::math::DVec4::clamp_length_min( _self.into(), - min.into(), + min, ) .into(); output @@ -16517,7 +16469,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::DVec4::refract( _self.into(), normal.into(), - eta.into(), + eta, ) .into(); output @@ -16527,212 +16479,58 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_vec4", |_self: Ref| { let output: Val = ::bevy::math::DVec4::as_vec4( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "as_ivec4", - |_self: Ref| { - let output: Val = ::bevy::math::DVec4::as_ivec4( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "as_uvec4", - |_self: Ref| { - let output: Val = ::bevy::math::DVec4::as_uvec4( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "as_i64vec4", - |_self: Ref| { - let output: Val = ::bevy::math::DVec4::as_i64vec4( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "as_u64vec4", - |_self: Ref| { - let output: Val = ::bevy::math::DVec4::as_u64vec4( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::DVec4::eq( - _self.into(), - other.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DVec4::mul( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "div", - |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DVec4::div( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "add", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::DVec4::add( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "sub", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::DVec4::sub( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::DVec4::mul( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "sub", - |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DVec4::sub( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "div", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DVec4::div( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "sub", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DVec4::sub( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "rem", - |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DVec4::rem( - _self.into(), - rhs.into(), + &_self, ) .into(); output }, ) - .overwrite_script_function( - "add", - |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DVec4::add( - _self.into(), - rhs.into(), + .overwrite_script_function( + "as_ivec4", + |_self: Ref| { + let output: Val = ::bevy::math::DVec4::as_ivec4( + &_self, ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DVec4::add( - _self.into(), - rhs.into(), + "as_uvec4", + |_self: Ref| { + let output: Val = ::bevy::math::DVec4::as_uvec4( + &_self, ) .into(); output }, ) .overwrite_script_function( - "rem", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DVec4::rem( - _self.into(), - rhs.into(), + "as_i64vec4", + |_self: Ref| { + let output: Val = ::bevy::math::DVec4::as_i64vec4( + &_self, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: Ref| { - let output: Val = ::bevy::math::DVec4::div( - _self.into(), - rhs.into(), + "as_u64vec4", + |_self: Ref| { + let output: Val = ::bevy::math::DVec4::as_u64vec4( + &_self, ) .into(); output }, ) .overwrite_script_function( - "mul", + "add", |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DVec4::mul( + let output: Val = ::bevy::math::DVec4::add( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -16740,9 +16538,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ); NamespaceBuilder::<::bevy::math::Mat2>::new(world) .overwrite_script_function( - "div", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Mat2::div( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Mat2::mul( _self.into(), rhs.into(), ) @@ -16751,28 +16549,22 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "eq", - |_self: Ref, rhs: Ref| { - let output: bool = ::bevy::math::Mat2::eq(_self.into(), rhs.into()) - .into(); - output - }, - ) - .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::Mat2::neg( + "div", + |_self: Val, rhs: f32| { + let output: Val = ::bevy::math::Mat2::div( _self.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::Mat2::clone( + "sub", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Mat2::sub( _self.into(), + rhs.into(), ) .into(); output @@ -16792,9 +16584,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_cols_array", |_self: Ref| { - let output: [f32; 4] = ::bevy::math::Mat2::to_cols_array( - _self.into(), - ) + let output: [f32; 4] = ::bevy::math::Mat2::to_cols_array(&_self) .into(); output }, @@ -16803,7 +16593,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "to_cols_array_2d", |_self: Ref| { let output: [[f32; 2]; 2] = ::bevy::math::Mat2::to_cols_array_2d( - _self.into(), + &_self, ) .into(); output @@ -16824,7 +16614,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |scale: Val, angle: f32| { let output: Val = ::bevy::math::Mat2::from_scale_angle( scale.into(), - angle.into(), + angle, ) .into(); output @@ -16834,7 +16624,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_angle", |angle: f32| { let output: Val = ::bevy::math::Mat2::from_angle( - angle.into(), + angle, ) .into(); output @@ -16855,8 +16645,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |m: Val, i: usize, j: usize| { let output: Val = ::bevy::math::Mat2::from_mat3_minor( m.into(), - i.into(), - j.into(), + i, + j, ) .into(); output @@ -16877,8 +16667,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |m: Val, i: usize, j: usize| { let output: Val = ::bevy::math::Mat2::from_mat3a_minor( m.into(), - i.into(), - j.into(), + i, + j, ) .into(); output @@ -16888,8 +16678,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "col", |_self: Ref, index: usize| { let output: Val = ::bevy::math::Mat2::col( - _self.into(), - index.into(), + &_self, + index, ) .into(); output @@ -16899,8 +16689,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "row", |_self: Ref, index: usize| { let output: Val = ::bevy::math::Mat2::row( - _self.into(), - index.into(), + &_self, + index, ) .into(); output @@ -16909,15 +16699,14 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "is_finite", |_self: Ref| { - let output: bool = ::bevy::math::Mat2::is_finite(_self.into()) - .into(); + let output: bool = ::bevy::math::Mat2::is_finite(&_self).into(); output }, ) .overwrite_script_function( "is_nan", |_self: Ref| { - let output: bool = ::bevy::math::Mat2::is_nan(_self.into()).into(); + let output: bool = ::bevy::math::Mat2::is_nan(&_self).into(); output }, ) @@ -16925,7 +16714,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transpose", |_self: Ref| { let output: Val = ::bevy::math::Mat2::transpose( - _self.into(), + &_self, ) .into(); output @@ -16934,8 +16723,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "determinant", |_self: Ref| { - let output: f32 = ::bevy::math::Mat2::determinant(_self.into()) - .into(); + let output: f32 = ::bevy::math::Mat2::determinant(&_self).into(); output }, ) @@ -16943,7 +16731,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "inverse", |_self: Ref| { let output: Val = ::bevy::math::Mat2::inverse( - _self.into(), + &_self, ) .into(); output @@ -16953,7 +16741,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_vec2", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Mat2::mul_vec2( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -16964,8 +16752,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_mat2", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::Mat2::mul_mat2( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -16975,8 +16763,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "add_mat2", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::Mat2::add_mat2( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -16986,8 +16774,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "sub_mat2", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::Mat2::sub_mat2( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -16997,8 +16785,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_scalar", |_self: Ref, rhs: f32| { let output: Val = ::bevy::math::Mat2::mul_scalar( - _self.into(), - rhs.into(), + &_self, + rhs, ) .into(); output @@ -17008,8 +16796,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "div_scalar", |_self: Ref, rhs: f32| { let output: Val = ::bevy::math::Mat2::div_scalar( - _self.into(), - rhs.into(), + &_self, + rhs, ) .into(); output @@ -17023,9 +16811,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { max_abs_diff: f32| { let output: bool = ::bevy::math::Mat2::abs_diff_eq( - _self.into(), + &_self, rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -17034,9 +16822,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "abs", |_self: Ref| { - let output: Val = ::bevy::math::Mat2::abs( - _self.into(), - ) + let output: Val = ::bevy::math::Mat2::abs(&_self) .into(); output }, @@ -17045,27 +16831,23 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dmat2", |_self: Ref| { let output: Val = ::bevy::math::Mat2::as_dmat2( - _self.into(), + &_self, ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Mat2::sub( - _self.into(), - rhs.into(), - ) - .into(); + "eq", + |_self: Ref, rhs: Ref| { + let output: bool = ::bevy::math::Mat2::eq(&_self, &rhs).into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Mat2::mul( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Mat2::add( _self.into(), rhs.into(), ) @@ -17074,11 +16856,10 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Mat2::mul( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::Mat2::neg( _self.into(), - rhs.into(), ) .into(); output @@ -17089,35 +16870,32 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: f32| { let output: Val = ::bevy::math::Mat2::mul( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "add", + "mul", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Mat2::add( + let output: Val = ::bevy::math::Mat2::mul( _self.into(), rhs.into(), ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::Mat3>::new(world) + ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Mat3::mul( - _self.into(), - rhs.into(), - ) + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::Mat2::clone(&_self) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::Mat3>::new(world) .overwrite_script_function( "mul", |_self: Val, rhs: Val| { @@ -17130,9 +16908,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "mul", + "add", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Mat3::mul( + let output: Val = ::bevy::math::Mat3::add( _self.into(), rhs.into(), ) @@ -17142,29 +16920,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Mat3::mul( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::Mat3::neg( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "add", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Mat3::add( + let output: Val = ::bevy::math::Mat3::mul( _self.into(), rhs.into(), ) @@ -17172,16 +16929,6 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::Mat3::clone( - _self.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "from_cols", | @@ -17201,9 +16948,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_cols_array", |_self: Ref| { - let output: [f32; 9] = ::bevy::math::Mat3::to_cols_array( - _self.into(), - ) + let output: [f32; 9] = ::bevy::math::Mat3::to_cols_array(&_self) .into(); output }, @@ -17212,7 +16957,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "to_cols_array_2d", |_self: Ref| { let output: [[f32; 3]; 3] = ::bevy::math::Mat3::to_cols_array_2d( - _self.into(), + &_self, ) .into(); output @@ -17243,8 +16988,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |m: Val, i: usize, j: usize| { let output: Val = ::bevy::math::Mat3::from_mat4_minor( m.into(), - i.into(), - j.into(), + i, + j, ) .into(); output @@ -17265,7 +17010,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |axis: Val, angle: f32| { let output: Val = ::bevy::math::Mat3::from_axis_angle( axis.into(), - angle.into(), + angle, ) .into(); output @@ -17276,9 +17021,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |order: Val, a: f32, b: f32, c: f32| { let output: Val = ::bevy::math::Mat3::from_euler( order.into(), - a.into(), - b.into(), - c.into(), + a, + b, + c, ) .into(); output @@ -17288,7 +17033,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "to_euler", |_self: Ref, order: Val| { let output: (f32, f32, f32) = ::bevy::math::Mat3::to_euler( - _self.into(), + &_self, order.into(), ) .into(); @@ -17299,7 +17044,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_x", |angle: f32| { let output: Val = ::bevy::math::Mat3::from_rotation_x( - angle.into(), + angle, ) .into(); output @@ -17309,7 +17054,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_y", |angle: f32| { let output: Val = ::bevy::math::Mat3::from_rotation_y( - angle.into(), + angle, ) .into(); output @@ -17319,7 +17064,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_z", |angle: f32| { let output: Val = ::bevy::math::Mat3::from_rotation_z( - angle.into(), + angle, ) .into(); output @@ -17339,7 +17084,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_angle", |angle: f32| { let output: Val = ::bevy::math::Mat3::from_angle( - angle.into(), + angle, ) .into(); output @@ -17354,7 +17099,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { { let output: Val = ::bevy::math::Mat3::from_scale_angle_translation( scale.into(), - angle.into(), + angle, translation.into(), ) .into(); @@ -17385,8 +17130,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "col", |_self: Ref, index: usize| { let output: Val = ::bevy::math::Mat3::col( - _self.into(), - index.into(), + &_self, + index, ) .into(); output @@ -17396,8 +17141,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "row", |_self: Ref, index: usize| { let output: Val = ::bevy::math::Mat3::row( - _self.into(), - index.into(), + &_self, + index, ) .into(); output @@ -17406,15 +17151,14 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "is_finite", |_self: Ref| { - let output: bool = ::bevy::math::Mat3::is_finite(_self.into()) - .into(); + let output: bool = ::bevy::math::Mat3::is_finite(&_self).into(); output }, ) .overwrite_script_function( "is_nan", |_self: Ref| { - let output: bool = ::bevy::math::Mat3::is_nan(_self.into()).into(); + let output: bool = ::bevy::math::Mat3::is_nan(&_self).into(); output }, ) @@ -17422,7 +17166,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transpose", |_self: Ref| { let output: Val = ::bevy::math::Mat3::transpose( - _self.into(), + &_self, ) .into(); output @@ -17431,8 +17175,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "determinant", |_self: Ref| { - let output: f32 = ::bevy::math::Mat3::determinant(_self.into()) - .into(); + let output: f32 = ::bevy::math::Mat3::determinant(&_self).into(); output }, ) @@ -17440,7 +17183,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "inverse", |_self: Ref| { let output: Val = ::bevy::math::Mat3::inverse( - _self.into(), + &_self, ) .into(); output @@ -17450,7 +17193,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_point2", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Mat3::transform_point2( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -17461,7 +17204,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_vector2", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Mat3::transform_vector2( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -17472,7 +17215,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_vec3", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Mat3::mul_vec3( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -17483,7 +17226,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_vec3a", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Mat3::mul_vec3a( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -17494,8 +17237,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_mat3", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::Mat3::mul_mat3( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -17505,8 +17248,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "add_mat3", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::Mat3::add_mat3( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -17516,8 +17259,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "sub_mat3", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::Mat3::sub_mat3( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -17527,8 +17270,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_scalar", |_self: Ref, rhs: f32| { let output: Val = ::bevy::math::Mat3::mul_scalar( - _self.into(), - rhs.into(), + &_self, + rhs, ) .into(); output @@ -17538,8 +17281,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "div_scalar", |_self: Ref, rhs: f32| { let output: Val = ::bevy::math::Mat3::div_scalar( - _self.into(), - rhs.into(), + &_self, + rhs, ) .into(); output @@ -17553,9 +17296,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { max_abs_diff: f32| { let output: bool = ::bevy::math::Mat3::abs_diff_eq( - _self.into(), + &_self, rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -17564,9 +17307,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "abs", |_self: Ref| { - let output: Val = ::bevy::math::Mat3::abs( - _self.into(), - ) + let output: Val = ::bevy::math::Mat3::abs(&_self) .into(); output }, @@ -17575,18 +17316,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dmat3", |_self: Ref| { let output: Val = ::bevy::math::Mat3::as_dmat3( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Mat3::mul( - _self.into(), - rhs.into(), + &_self, ) .into(); output @@ -17595,38 +17325,24 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "eq", |_self: Ref, rhs: Ref| { - let output: bool = ::bevy::math::Mat3::eq(_self.into(), rhs.into()) - .into(); + let output: bool = ::bevy::math::Mat3::eq(&_self, &rhs).into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Mat3::div( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::Mat3::neg( _self.into(), - rhs.into(), ) .into(); output }, ) - .overwrite_script_function( - "sub", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Mat3::sub( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ); - NamespaceBuilder::<::bevy::math::Mat3A>::new(world) .overwrite_script_function( "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Mat3A::mul( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Mat3::mul( _self.into(), rhs.into(), ) @@ -17636,39 +17352,16 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "clone", - |_self: Ref| { - let output: Val = ::bevy::math::Mat3A::clone( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Mat3A::mul( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::Mat3A::neg( - _self.into(), - ) + |_self: Ref| { + let output: Val = ::bevy::math::Mat3::clone(&_self) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Mat3A::add( + "sub", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Mat3::sub( _self.into(), rhs.into(), ) @@ -17678,8 +17371,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Mat3A::mul( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Mat3::mul( _self.into(), rhs.into(), ) @@ -17688,39 +17381,50 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "eq", - |_self: Ref, rhs: Ref| { - let output: bool = ::bevy::math::Mat3A::eq(_self.into(), rhs.into()) + "mul", + |_self: Val, rhs: f32| { + let output: Val = ::bevy::math::Mat3::mul( + _self.into(), + rhs, + ) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Mat3A::mul( + "div", + |_self: Val, rhs: f32| { + let output: Val = ::bevy::math::Mat3::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::Mat3A>::new(world) .overwrite_script_function( "div", |_self: Val, rhs: f32| { let output: Val = ::bevy::math::Mat3A::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) + .overwrite_script_function( + "eq", + |_self: Ref, rhs: Ref| { + let output: bool = ::bevy::math::Mat3A::eq(&_self, &rhs).into(); + output + }, + ) .overwrite_script_function( "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Mat3A::mul( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Mat3A::mul( _self.into(), rhs.into(), ) @@ -17739,6 +17443,16 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::Mat3A::clone( + &_self, + ) + .into(); + output + }, + ) .overwrite_script_function( "from_cols", | @@ -17758,9 +17472,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_cols_array", |_self: Ref| { - let output: [f32; 9] = ::bevy::math::Mat3A::to_cols_array( - _self.into(), - ) + let output: [f32; 9] = ::bevy::math::Mat3A::to_cols_array(&_self) .into(); output }, @@ -17769,7 +17481,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "to_cols_array_2d", |_self: Ref| { let output: [[f32; 3]; 3] = ::bevy::math::Mat3A::to_cols_array_2d( - _self.into(), + &_self, ) .into(); output @@ -17800,8 +17512,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |m: Val, i: usize, j: usize| { let output: Val = ::bevy::math::Mat3A::from_mat4_minor( m.into(), - i.into(), - j.into(), + i, + j, ) .into(); output @@ -17822,7 +17534,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |axis: Val, angle: f32| { let output: Val = ::bevy::math::Mat3A::from_axis_angle( axis.into(), - angle.into(), + angle, ) .into(); output @@ -17833,9 +17545,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |order: Val, a: f32, b: f32, c: f32| { let output: Val = ::bevy::math::Mat3A::from_euler( order.into(), - a.into(), - b.into(), - c.into(), + a, + b, + c, ) .into(); output @@ -17845,7 +17557,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "to_euler", |_self: Ref, order: Val| { let output: (f32, f32, f32) = ::bevy::math::Mat3A::to_euler( - _self.into(), + &_self, order.into(), ) .into(); @@ -17856,7 +17568,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_x", |angle: f32| { let output: Val = ::bevy::math::Mat3A::from_rotation_x( - angle.into(), + angle, ) .into(); output @@ -17866,7 +17578,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_y", |angle: f32| { let output: Val = ::bevy::math::Mat3A::from_rotation_y( - angle.into(), + angle, ) .into(); output @@ -17876,7 +17588,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_z", |angle: f32| { let output: Val = ::bevy::math::Mat3A::from_rotation_z( - angle.into(), + angle, ) .into(); output @@ -17896,7 +17608,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_angle", |angle: f32| { let output: Val = ::bevy::math::Mat3A::from_angle( - angle.into(), + angle, ) .into(); output @@ -17911,7 +17623,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { { let output: Val = ::bevy::math::Mat3A::from_scale_angle_translation( scale.into(), - angle.into(), + angle, translation.into(), ) .into(); @@ -17942,8 +17654,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "col", |_self: Ref, index: usize| { let output: Val = ::bevy::math::Mat3A::col( - _self.into(), - index.into(), + &_self, + index, ) .into(); output @@ -17953,8 +17665,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "row", |_self: Ref, index: usize| { let output: Val = ::bevy::math::Mat3A::row( - _self.into(), - index.into(), + &_self, + index, ) .into(); output @@ -17963,15 +17675,14 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "is_finite", |_self: Ref| { - let output: bool = ::bevy::math::Mat3A::is_finite(_self.into()) - .into(); + let output: bool = ::bevy::math::Mat3A::is_finite(&_self).into(); output }, ) .overwrite_script_function( "is_nan", |_self: Ref| { - let output: bool = ::bevy::math::Mat3A::is_nan(_self.into()).into(); + let output: bool = ::bevy::math::Mat3A::is_nan(&_self).into(); output }, ) @@ -17979,7 +17690,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transpose", |_self: Ref| { let output: Val = ::bevy::math::Mat3A::transpose( - _self.into(), + &_self, ) .into(); output @@ -17988,8 +17699,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "determinant", |_self: Ref| { - let output: f32 = ::bevy::math::Mat3A::determinant(_self.into()) - .into(); + let output: f32 = ::bevy::math::Mat3A::determinant(&_self).into(); output }, ) @@ -17997,7 +17707,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "inverse", |_self: Ref| { let output: Val = ::bevy::math::Mat3A::inverse( - _self.into(), + &_self, ) .into(); output @@ -18007,7 +17717,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_point2", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Mat3A::transform_point2( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -18018,7 +17728,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_vector2", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Mat3A::transform_vector2( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -18029,7 +17739,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_vec3", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Mat3A::mul_vec3( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -18040,7 +17750,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_vec3a", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Mat3A::mul_vec3a( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -18051,8 +17761,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_mat3", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::Mat3A::mul_mat3( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -18062,8 +17772,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "add_mat3", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::Mat3A::add_mat3( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -18073,8 +17783,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "sub_mat3", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::Mat3A::sub_mat3( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -18084,8 +17794,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_scalar", |_self: Ref, rhs: f32| { let output: Val = ::bevy::math::Mat3A::mul_scalar( - _self.into(), - rhs.into(), + &_self, + rhs, ) .into(); output @@ -18095,8 +17805,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "div_scalar", |_self: Ref, rhs: f32| { let output: Val = ::bevy::math::Mat3A::div_scalar( - _self.into(), - rhs.into(), + &_self, + rhs, ) .into(); output @@ -18110,9 +17820,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { max_abs_diff: f32| { let output: bool = ::bevy::math::Mat3A::abs_diff_eq( - _self.into(), + &_self, rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -18121,9 +17831,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "abs", |_self: Ref| { - let output: Val = ::bevy::math::Mat3A::abs( - _self.into(), - ) + let output: Val = ::bevy::math::Mat3A::abs(&_self) .into(); output }, @@ -18132,37 +17840,38 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dmat3", |_self: Ref| { let output: Val = ::bevy::math::Mat3A::as_dmat3( - _self.into(), + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::Mat4>::new(world) + ) .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::Mat4::neg( + "mul", + |_self: Val, rhs: f32| { + let output: Val = ::bevy::math::Mat3A::mul( _self.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::Mat4::clone( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Mat3A::mul( _self.into(), + rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Mat4::mul( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Mat3A::add( _self.into(), rhs.into(), ) @@ -18170,10 +17879,20 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) + .overwrite_script_function( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::Mat3A::neg( + _self.into(), + ) + .into(); + output + }, + ) .overwrite_script_function( "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Mat4::mul( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Mat3A::mul( _self.into(), rhs.into(), ) @@ -18182,20 +17901,28 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Mat4::add( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Mat3A::mul( _self.into(), rhs.into(), ) .into(); output }, + ); + NamespaceBuilder::<::bevy::math::Mat4>::new(world) + .overwrite_script_function( + "eq", + |_self: Ref, rhs: Ref| { + let output: bool = ::bevy::math::Mat4::eq(&_self, &rhs).into(); + output + }, ) .overwrite_script_function( "mul", - |_self: Val, rhs: f32| { - let output: Val = ::bevy::math::Mat4::mul( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Mat4::mul( _self.into(), rhs.into(), ) @@ -18204,9 +17931,12 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "eq", - |_self: Ref, rhs: Ref| { - let output: bool = ::bevy::math::Mat4::eq(_self.into(), rhs.into()) + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Mat4::mul( + _self.into(), + rhs.into(), + ) .into(); output }, @@ -18226,6 +17956,27 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "div", |_self: Val, rhs: f32| { let output: Val = ::bevy::math::Mat4::div( + _self.into(), + rhs, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::Mat4::neg( + _self.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Mat4::mul( _self.into(), rhs.into(), ) @@ -18233,6 +17984,14 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::Mat4::clone(&_self) + .into(); + output + }, + ) .overwrite_script_function( "from_cols", | @@ -18254,9 +18013,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_cols_array", |_self: Ref| { - let output: [f32; 16] = ::bevy::math::Mat4::to_cols_array( - _self.into(), - ) + let output: [f32; 16] = ::bevy::math::Mat4::to_cols_array(&_self) .into(); output }, @@ -18265,7 +18022,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "to_cols_array_2d", |_self: Ref| { let output: [[f32; 4]; 4] = ::bevy::math::Mat4::to_cols_array_2d( - _self.into(), + &_self, ) .into(); output @@ -18353,7 +18110,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |axis: Val, angle: f32| { let output: Val = ::bevy::math::Mat4::from_axis_angle( axis.into(), - angle.into(), + angle, ) .into(); output @@ -18364,9 +18121,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |order: Val, a: f32, b: f32, c: f32| { let output: Val = ::bevy::math::Mat4::from_euler( order.into(), - a.into(), - b.into(), - c.into(), + a, + b, + c, ) .into(); output @@ -18376,7 +18133,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "to_euler", |_self: Ref, order: Val| { let output: (f32, f32, f32) = ::bevy::math::Mat4::to_euler( - _self.into(), + &_self, order.into(), ) .into(); @@ -18387,7 +18144,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_x", |angle: f32| { let output: Val = ::bevy::math::Mat4::from_rotation_x( - angle.into(), + angle, ) .into(); output @@ -18397,7 +18154,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_y", |angle: f32| { let output: Val = ::bevy::math::Mat4::from_rotation_y( - angle.into(), + angle, ) .into(); output @@ -18407,7 +18164,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_z", |angle: f32| { let output: Val = ::bevy::math::Mat4::from_rotation_z( - angle.into(), + angle, ) .into(); output @@ -18427,8 +18184,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "col", |_self: Ref, index: usize| { let output: Val = ::bevy::math::Mat4::col( - _self.into(), - index.into(), + &_self, + index, ) .into(); output @@ -18438,8 +18195,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "row", |_self: Ref, index: usize| { let output: Val = ::bevy::math::Mat4::row( - _self.into(), - index.into(), + &_self, + index, ) .into(); output @@ -18448,15 +18205,14 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "is_finite", |_self: Ref| { - let output: bool = ::bevy::math::Mat4::is_finite(_self.into()) - .into(); + let output: bool = ::bevy::math::Mat4::is_finite(&_self).into(); output }, ) .overwrite_script_function( "is_nan", |_self: Ref| { - let output: bool = ::bevy::math::Mat4::is_nan(_self.into()).into(); + let output: bool = ::bevy::math::Mat4::is_nan(&_self).into(); output }, ) @@ -18464,7 +18220,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transpose", |_self: Ref| { let output: Val = ::bevy::math::Mat4::transpose( - _self.into(), + &_self, ) .into(); output @@ -18473,8 +18229,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "determinant", |_self: Ref| { - let output: f32 = ::bevy::math::Mat4::determinant(_self.into()) - .into(); + let output: f32 = ::bevy::math::Mat4::determinant(&_self).into(); output }, ) @@ -18482,7 +18237,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "inverse", |_self: Ref| { let output: Val = ::bevy::math::Mat4::inverse( - _self.into(), + &_self, ) .into(); output @@ -18556,10 +18311,10 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "perspective_rh_gl", |fov_y_radians: f32, aspect_ratio: f32, z_near: f32, z_far: f32| { let output: Val = ::bevy::math::Mat4::perspective_rh_gl( - fov_y_radians.into(), - aspect_ratio.into(), - z_near.into(), - z_far.into(), + fov_y_radians, + aspect_ratio, + z_near, + z_far, ) .into(); output @@ -18569,10 +18324,10 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "perspective_lh", |fov_y_radians: f32, aspect_ratio: f32, z_near: f32, z_far: f32| { let output: Val = ::bevy::math::Mat4::perspective_lh( - fov_y_radians.into(), - aspect_ratio.into(), - z_near.into(), - z_far.into(), + fov_y_radians, + aspect_ratio, + z_near, + z_far, ) .into(); output @@ -18582,10 +18337,10 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "perspective_rh", |fov_y_radians: f32, aspect_ratio: f32, z_near: f32, z_far: f32| { let output: Val = ::bevy::math::Mat4::perspective_rh( - fov_y_radians.into(), - aspect_ratio.into(), - z_near.into(), - z_far.into(), + fov_y_radians, + aspect_ratio, + z_near, + z_far, ) .into(); output @@ -18595,9 +18350,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "perspective_infinite_lh", |fov_y_radians: f32, aspect_ratio: f32, z_near: f32| { let output: Val = ::bevy::math::Mat4::perspective_infinite_lh( - fov_y_radians.into(), - aspect_ratio.into(), - z_near.into(), + fov_y_radians, + aspect_ratio, + z_near, ) .into(); output @@ -18607,9 +18362,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "perspective_infinite_reverse_lh", |fov_y_radians: f32, aspect_ratio: f32, z_near: f32| { let output: Val = ::bevy::math::Mat4::perspective_infinite_reverse_lh( - fov_y_radians.into(), - aspect_ratio.into(), - z_near.into(), + fov_y_radians, + aspect_ratio, + z_near, ) .into(); output @@ -18619,9 +18374,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "perspective_infinite_rh", |fov_y_radians: f32, aspect_ratio: f32, z_near: f32| { let output: Val = ::bevy::math::Mat4::perspective_infinite_rh( - fov_y_radians.into(), - aspect_ratio.into(), - z_near.into(), + fov_y_radians, + aspect_ratio, + z_near, ) .into(); output @@ -18631,9 +18386,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "perspective_infinite_reverse_rh", |fov_y_radians: f32, aspect_ratio: f32, z_near: f32| { let output: Val = ::bevy::math::Mat4::perspective_infinite_reverse_rh( - fov_y_radians.into(), - aspect_ratio.into(), - z_near.into(), + fov_y_radians, + aspect_ratio, + z_near, ) .into(); output @@ -18643,12 +18398,12 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "orthographic_rh_gl", |left: f32, right: f32, bottom: f32, top: f32, near: f32, far: f32| { let output: Val = ::bevy::math::Mat4::orthographic_rh_gl( - left.into(), - right.into(), - bottom.into(), - top.into(), - near.into(), - far.into(), + left, + right, + bottom, + top, + near, + far, ) .into(); output @@ -18658,12 +18413,12 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "orthographic_lh", |left: f32, right: f32, bottom: f32, top: f32, near: f32, far: f32| { let output: Val = ::bevy::math::Mat4::orthographic_lh( - left.into(), - right.into(), - bottom.into(), - top.into(), - near.into(), - far.into(), + left, + right, + bottom, + top, + near, + far, ) .into(); output @@ -18673,12 +18428,12 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "orthographic_rh", |left: f32, right: f32, bottom: f32, top: f32, near: f32, far: f32| { let output: Val = ::bevy::math::Mat4::orthographic_rh( - left.into(), - right.into(), - bottom.into(), - top.into(), - near.into(), - far.into(), + left, + right, + bottom, + top, + near, + far, ) .into(); output @@ -18688,7 +18443,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "project_point3", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Mat4::project_point3( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -18699,7 +18454,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_point3", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Mat4::transform_point3( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -18710,7 +18465,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_vector3", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Mat4::transform_vector3( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -18721,7 +18476,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "project_point3a", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Mat4::project_point3a( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -18732,7 +18487,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_point3a", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Mat4::transform_point3a( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -18743,7 +18498,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_vector3a", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Mat4::transform_vector3a( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -18754,7 +18509,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_vec4", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Mat4::mul_vec4( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -18765,8 +18520,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_mat4", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::Mat4::mul_mat4( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -18776,8 +18531,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "add_mat4", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::Mat4::add_mat4( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -18787,8 +18542,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "sub_mat4", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::Mat4::sub_mat4( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -18798,8 +18553,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_scalar", |_self: Ref, rhs: f32| { let output: Val = ::bevy::math::Mat4::mul_scalar( - _self.into(), - rhs.into(), + &_self, + rhs, ) .into(); output @@ -18809,8 +18564,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "div_scalar", |_self: Ref, rhs: f32| { let output: Val = ::bevy::math::Mat4::div_scalar( - _self.into(), - rhs.into(), + &_self, + rhs, ) .into(); output @@ -18824,9 +18579,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { max_abs_diff: f32| { let output: bool = ::bevy::math::Mat4::abs_diff_eq( - _self.into(), + &_self, rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -18835,9 +18590,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "abs", |_self: Ref| { - let output: Val = ::bevy::math::Mat4::abs( - _self.into(), - ) + let output: Val = ::bevy::math::Mat4::abs(&_self) .into(); output }, @@ -18846,7 +18599,18 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_dmat4", |_self: Ref| { let output: Val = ::bevy::math::Mat4::as_dmat4( + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Mat4::add( _self.into(), + rhs.into(), ) .into(); output @@ -18854,10 +18618,10 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "mul", - |_self: Val, rhs: Val| { + |_self: Val, rhs: f32| { let output: Val = ::bevy::math::Mat4::mul( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -18865,38 +18629,41 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ); NamespaceBuilder::<::bevy::math::DMat2>::new(world) .overwrite_script_function( - "eq", - |_self: Ref, rhs: Ref| { - let output: bool = ::bevy::math::DMat2::eq(_self.into(), rhs.into()) + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::DMat2::clone( + &_self, + ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::DMat2::clone( + "mul", + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DMat2::mul( _self.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DMat2::add( + "div", + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DMat2::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DMat2::sub( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DMat2::mul( _self.into(), rhs.into(), ) @@ -18905,9 +18672,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "mul", + "add", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DMat2::mul( + let output: Val = ::bevy::math::DMat2::add( _self.into(), rhs.into(), ) @@ -18916,10 +18683,11 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::DMat2::neg( + "sub", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DMat2::sub( _self.into(), + rhs.into(), ) .into(); output @@ -18927,8 +18695,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DMat2::mul( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DMat2::mul( _self.into(), rhs.into(), ) @@ -18936,6 +18704,13 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) + .overwrite_script_function( + "eq", + |_self: Ref, rhs: Ref| { + let output: bool = ::bevy::math::DMat2::eq(&_self, &rhs).into(); + output + }, + ) .overwrite_script_function( "from_cols", |x_axis: Val, y_axis: Val| { @@ -18950,9 +18725,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_cols_array", |_self: Ref| { - let output: [f64; 4] = ::bevy::math::DMat2::to_cols_array( - _self.into(), - ) + let output: [f64; 4] = ::bevy::math::DMat2::to_cols_array(&_self) .into(); output }, @@ -18961,7 +18734,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "to_cols_array_2d", |_self: Ref| { let output: [[f64; 2]; 2] = ::bevy::math::DMat2::to_cols_array_2d( - _self.into(), + &_self, ) .into(); output @@ -18982,7 +18755,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |scale: Val, angle: f64| { let output: Val = ::bevy::math::DMat2::from_scale_angle( scale.into(), - angle.into(), + angle, ) .into(); output @@ -18992,7 +18765,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_angle", |angle: f64| { let output: Val = ::bevy::math::DMat2::from_angle( - angle.into(), + angle, ) .into(); output @@ -19013,8 +18786,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |m: Val, i: usize, j: usize| { let output: Val = ::bevy::math::DMat2::from_mat3_minor( m.into(), - i.into(), - j.into(), + i, + j, ) .into(); output @@ -19024,8 +18797,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "col", |_self: Ref, index: usize| { let output: Val = ::bevy::math::DMat2::col( - _self.into(), - index.into(), + &_self, + index, ) .into(); output @@ -19035,8 +18808,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "row", |_self: Ref, index: usize| { let output: Val = ::bevy::math::DMat2::row( - _self.into(), - index.into(), + &_self, + index, ) .into(); output @@ -19045,15 +18818,14 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "is_finite", |_self: Ref| { - let output: bool = ::bevy::math::DMat2::is_finite(_self.into()) - .into(); + let output: bool = ::bevy::math::DMat2::is_finite(&_self).into(); output }, ) .overwrite_script_function( "is_nan", |_self: Ref| { - let output: bool = ::bevy::math::DMat2::is_nan(_self.into()).into(); + let output: bool = ::bevy::math::DMat2::is_nan(&_self).into(); output }, ) @@ -19061,7 +18833,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transpose", |_self: Ref| { let output: Val = ::bevy::math::DMat2::transpose( - _self.into(), + &_self, ) .into(); output @@ -19070,8 +18842,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "determinant", |_self: Ref| { - let output: f64 = ::bevy::math::DMat2::determinant(_self.into()) - .into(); + let output: f64 = ::bevy::math::DMat2::determinant(&_self).into(); output }, ) @@ -19079,7 +18850,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "inverse", |_self: Ref| { let output: Val = ::bevy::math::DMat2::inverse( - _self.into(), + &_self, ) .into(); output @@ -19089,7 +18860,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_vec2", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::DMat2::mul_vec2( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -19100,8 +18871,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_mat2", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::DMat2::mul_mat2( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -19111,8 +18882,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "add_mat2", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::DMat2::add_mat2( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -19122,8 +18893,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "sub_mat2", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::DMat2::sub_mat2( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -19133,8 +18904,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_scalar", |_self: Ref, rhs: f64| { let output: Val = ::bevy::math::DMat2::mul_scalar( - _self.into(), - rhs.into(), + &_self, + rhs, ) .into(); output @@ -19144,8 +18915,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "div_scalar", |_self: Ref, rhs: f64| { let output: Val = ::bevy::math::DMat2::div_scalar( - _self.into(), - rhs.into(), + &_self, + rhs, ) .into(); output @@ -19159,9 +18930,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { max_abs_diff: f64| { let output: bool = ::bevy::math::DMat2::abs_diff_eq( - _self.into(), + &_self, rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -19170,9 +18941,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "abs", |_self: Ref| { - let output: Val = ::bevy::math::DMat2::abs( - _self.into(), - ) + let output: Val = ::bevy::math::DMat2::abs(&_self) .into(); output }, @@ -19181,39 +18950,48 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_mat2", |_self: Ref| { let output: Val = ::bevy::math::DMat2::as_mat2( - _self.into(), + &_self, ) .into(); output }, ) + .overwrite_script_function( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::DMat2::neg( + _self.into(), + ) + .into(); + output + }, + ); + NamespaceBuilder::<::bevy::math::DMat3>::new(world) .overwrite_script_function( "mul", - |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DMat2::mul( + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DMat3::mul( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DMat2::div( - _self.into(), - rhs.into(), + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::DMat3::clone( + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::DMat3>::new(world) + ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DMat3::mul( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DMat3::add( _self.into(), rhs.into(), ) @@ -19233,9 +19011,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "add", + "sub", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DMat3::add( + let output: Val = ::bevy::math::DMat3::sub( _self.into(), rhs.into(), ) @@ -19262,9 +19040,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_cols_array", |_self: Ref| { - let output: [f64; 9] = ::bevy::math::DMat3::to_cols_array( - _self.into(), - ) + let output: [f64; 9] = ::bevy::math::DMat3::to_cols_array(&_self) .into(); output }, @@ -19273,7 +19049,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "to_cols_array_2d", |_self: Ref| { let output: [[f64; 3]; 3] = ::bevy::math::DMat3::to_cols_array_2d( - _self.into(), + &_self, ) .into(); output @@ -19304,8 +19080,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |m: Val, i: usize, j: usize| { let output: Val = ::bevy::math::DMat3::from_mat4_minor( m.into(), - i.into(), - j.into(), + i, + j, ) .into(); output @@ -19326,7 +19102,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |axis: Val, angle: f64| { let output: Val = ::bevy::math::DMat3::from_axis_angle( axis.into(), - angle.into(), + angle, ) .into(); output @@ -19337,9 +19113,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |order: Val, a: f64, b: f64, c: f64| { let output: Val = ::bevy::math::DMat3::from_euler( order.into(), - a.into(), - b.into(), - c.into(), + a, + b, + c, ) .into(); output @@ -19349,7 +19125,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "to_euler", |_self: Ref, order: Val| { let output: (f64, f64, f64) = ::bevy::math::DMat3::to_euler( - _self.into(), + &_self, order.into(), ) .into(); @@ -19360,7 +19136,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_x", |angle: f64| { let output: Val = ::bevy::math::DMat3::from_rotation_x( - angle.into(), + angle, ) .into(); output @@ -19370,7 +19146,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_y", |angle: f64| { let output: Val = ::bevy::math::DMat3::from_rotation_y( - angle.into(), + angle, ) .into(); output @@ -19380,7 +19156,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_z", |angle: f64| { let output: Val = ::bevy::math::DMat3::from_rotation_z( - angle.into(), + angle, ) .into(); output @@ -19400,7 +19176,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_angle", |angle: f64| { let output: Val = ::bevy::math::DMat3::from_angle( - angle.into(), + angle, ) .into(); output @@ -19415,7 +19191,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { { let output: Val = ::bevy::math::DMat3::from_scale_angle_translation( scale.into(), - angle.into(), + angle, translation.into(), ) .into(); @@ -19446,8 +19222,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "col", |_self: Ref, index: usize| { let output: Val = ::bevy::math::DMat3::col( - _self.into(), - index.into(), + &_self, + index, ) .into(); output @@ -19457,8 +19233,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "row", |_self: Ref, index: usize| { let output: Val = ::bevy::math::DMat3::row( - _self.into(), - index.into(), + &_self, + index, ) .into(); output @@ -19467,15 +19243,14 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "is_finite", |_self: Ref| { - let output: bool = ::bevy::math::DMat3::is_finite(_self.into()) - .into(); + let output: bool = ::bevy::math::DMat3::is_finite(&_self).into(); output }, ) .overwrite_script_function( "is_nan", |_self: Ref| { - let output: bool = ::bevy::math::DMat3::is_nan(_self.into()).into(); + let output: bool = ::bevy::math::DMat3::is_nan(&_self).into(); output }, ) @@ -19483,7 +19258,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transpose", |_self: Ref| { let output: Val = ::bevy::math::DMat3::transpose( - _self.into(), + &_self, ) .into(); output @@ -19492,8 +19267,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "determinant", |_self: Ref| { - let output: f64 = ::bevy::math::DMat3::determinant(_self.into()) - .into(); + let output: f64 = ::bevy::math::DMat3::determinant(&_self).into(); output }, ) @@ -19501,7 +19275,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "inverse", |_self: Ref| { let output: Val = ::bevy::math::DMat3::inverse( - _self.into(), + &_self, ) .into(); output @@ -19511,7 +19285,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_point2", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::DMat3::transform_point2( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -19522,7 +19296,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_vector2", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::DMat3::transform_vector2( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -19533,7 +19307,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_vec3", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::DMat3::mul_vec3( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -19544,8 +19318,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_mat3", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::DMat3::mul_mat3( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -19555,8 +19329,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "add_mat3", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::DMat3::add_mat3( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -19566,8 +19340,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "sub_mat3", |_self: Ref, rhs: Ref| { let output: Val = ::bevy::math::DMat3::sub_mat3( - _self.into(), - rhs.into(), + &_self, + &rhs, ) .into(); output @@ -19577,8 +19351,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "mul_scalar", |_self: Ref, rhs: f64| { let output: Val = ::bevy::math::DMat3::mul_scalar( - _self.into(), - rhs.into(), + &_self, + rhs, ) .into(); output @@ -19588,8 +19362,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "div_scalar", |_self: Ref, rhs: f64| { let output: Val = ::bevy::math::DMat3::div_scalar( - _self.into(), - rhs.into(), + &_self, + rhs, ) .into(); output @@ -19603,9 +19377,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { max_abs_diff: f64| { let output: bool = ::bevy::math::DMat3::abs_diff_eq( - _self.into(), + &_self, rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -19614,9 +19388,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "abs", |_self: Ref| { - let output: Val = ::bevy::math::DMat3::abs( - _self.into(), - ) + let output: Val = ::bevy::math::DMat3::abs(&_self) .into(); output }, @@ -19625,25 +19397,29 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "as_mat3", |_self: Ref| { let output: Val = ::bevy::math::DMat3::as_mat3( - _self.into(), + &_self, ) .into(); output }, ) .overwrite_script_function( - "eq", - |_self: Ref, rhs: Ref| { - let output: bool = ::bevy::math::DMat3::eq(_self.into(), rhs.into()) + "div", + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DMat3::div( + _self.into(), + rhs, + ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::DMat3::clone( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DMat3::mul( _self.into(), + rhs.into(), ) .into(); output @@ -19651,7 +19427,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "mul", - |_self: Val, rhs: f64| { + |_self: Val, rhs: Val| { let output: Val = ::bevy::math::DMat3::mul( _self.into(), rhs.into(), @@ -19660,6 +19436,13 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) + .overwrite_script_function( + "eq", + |_self: Ref, rhs: Ref| { + let output: bool = ::bevy::math::DMat3::eq(&_self, &rhs).into(); + output + }, + ) .overwrite_script_function( "neg", |_self: Val| { @@ -19669,11 +19452,12 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::DMat4>::new(world) .overwrite_script_function( "sub", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DMat3::sub( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DMat4::sub( _self.into(), rhs.into(), ) @@ -19683,8 +19467,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DMat3::mul( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DMat4::mul( _self.into(), rhs.into(), ) @@ -19693,23 +19477,39 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DMat3::div( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DMat4::mul( _self.into(), rhs.into(), ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::DMat4>::new(world) + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::DMat4::clone( + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "eq", + |_self: Ref, rhs: Ref| { + let output: bool = ::bevy::math::DMat4::eq(&_self, &rhs).into(); + output + }, + ) .overwrite_script_function( "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DMat4::mul( + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DMat4::mul( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -19717,8 +19517,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DMat4::mul( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DMat4::mul( _self.into(), rhs.into(), ) @@ -19747,9 +19547,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_cols_array", |_self: Ref| { - let output: [f64; 16] = ::bevy::math::DMat4::to_cols_array( - _self.into(), - ) + let output: [f64; 16] = ::bevy::math::DMat4::to_cols_array(&_self) .into(); output }, @@ -19758,7 +19556,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "to_cols_array_2d", |_self: Ref| { let output: [[f64; 4]; 4] = ::bevy::math::DMat4::to_cols_array_2d( - _self.into(), + &_self, ) .into(); output @@ -19836,7 +19634,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |axis: Val, angle: f64| { let output: Val = ::bevy::math::DMat4::from_axis_angle( axis.into(), - angle.into(), + angle, ) .into(); output @@ -19847,9 +19645,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |order: Val, a: f64, b: f64, c: f64| { let output: Val = ::bevy::math::DMat4::from_euler( order.into(), - a.into(), - b.into(), - c.into(), + a, + b, + c, ) .into(); output @@ -19859,7 +19657,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "to_euler", |_self: Ref, order: Val| { let output: (f64, f64, f64) = ::bevy::math::DMat4::to_euler( - _self.into(), + &_self, order.into(), ) .into(); @@ -19870,7 +19668,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_x", |angle: f64| { let output: Val = ::bevy::math::DMat4::from_rotation_x( - angle.into(), + angle, ) .into(); output @@ -19880,7 +19678,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_y", |angle: f64| { let output: Val = ::bevy::math::DMat4::from_rotation_y( - angle.into(), + angle, ) .into(); output @@ -19890,7 +19688,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_z", |angle: f64| { let output: Val = ::bevy::math::DMat4::from_rotation_z( - angle.into(), + angle, ) .into(); output @@ -19910,8 +19708,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "col", |_self: Ref, index: usize| { let output: Val = ::bevy::math::DMat4::col( - _self.into(), - index.into(), + &_self, + index, ) .into(); output @@ -19921,8 +19719,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "row", |_self: Ref, index: usize| { let output: Val = ::bevy::math::DMat4::row( - _self.into(), - index.into(), + &_self, + index, ) .into(); output @@ -19931,15 +19729,14 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "is_finite", |_self: Ref| { - let output: bool = ::bevy::math::DMat4::is_finite(_self.into()) - .into(); + let output: bool = ::bevy::math::DMat4::is_finite(&_self).into(); output }, ) .overwrite_script_function( "is_nan", |_self: Ref| { - let output: bool = ::bevy::math::DMat4::is_nan(_self.into()).into(); + let output: bool = ::bevy::math::DMat4::is_nan(&_self).into(); output }, ) @@ -19947,7 +19744,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transpose", |_self: Ref| { let output: Val = ::bevy::math::DMat4::transpose( - _self.into(), + &_self, ) .into(); output @@ -19956,8 +19753,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "determinant", |_self: Ref| { - let output: f64 = ::bevy::math::DMat4::determinant(_self.into()) - .into(); + let output: f64 = ::bevy::math::DMat4::determinant(&_self).into(); output }, ) @@ -19965,7 +19761,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "inverse", |_self: Ref| { let output: Val = ::bevy::math::DMat4::inverse( - _self.into(), + &_self, ) .into(); output @@ -20039,10 +19835,10 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "perspective_rh_gl", |fov_y_radians: f64, aspect_ratio: f64, z_near: f64, z_far: f64| { let output: Val = ::bevy::math::DMat4::perspective_rh_gl( - fov_y_radians.into(), - aspect_ratio.into(), - z_near.into(), - z_far.into(), + fov_y_radians, + aspect_ratio, + z_near, + z_far, ) .into(); output @@ -20052,10 +19848,10 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "perspective_lh", |fov_y_radians: f64, aspect_ratio: f64, z_near: f64, z_far: f64| { let output: Val = ::bevy::math::DMat4::perspective_lh( - fov_y_radians.into(), - aspect_ratio.into(), - z_near.into(), - z_far.into(), + fov_y_radians, + aspect_ratio, + z_near, + z_far, ) .into(); output @@ -20065,10 +19861,10 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "perspective_rh", |fov_y_radians: f64, aspect_ratio: f64, z_near: f64, z_far: f64| { let output: Val = ::bevy::math::DMat4::perspective_rh( - fov_y_radians.into(), - aspect_ratio.into(), - z_near.into(), - z_far.into(), + fov_y_radians, + aspect_ratio, + z_near, + z_far, ) .into(); output @@ -20078,9 +19874,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "perspective_infinite_lh", |fov_y_radians: f64, aspect_ratio: f64, z_near: f64| { let output: Val = ::bevy::math::DMat4::perspective_infinite_lh( - fov_y_radians.into(), - aspect_ratio.into(), - z_near.into(), + fov_y_radians, + aspect_ratio, + z_near, ) .into(); output @@ -20090,9 +19886,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "perspective_infinite_reverse_lh", |fov_y_radians: f64, aspect_ratio: f64, z_near: f64| { let output: Val = ::bevy::math::DMat4::perspective_infinite_reverse_lh( - fov_y_radians.into(), - aspect_ratio.into(), - z_near.into(), + fov_y_radians, + aspect_ratio, + z_near, ) .into(); output @@ -20102,9 +19898,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "perspective_infinite_rh", |fov_y_radians: f64, aspect_ratio: f64, z_near: f64| { let output: Val = ::bevy::math::DMat4::perspective_infinite_rh( - fov_y_radians.into(), - aspect_ratio.into(), - z_near.into(), + fov_y_radians, + aspect_ratio, + z_near, ) .into(); output @@ -20114,9 +19910,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "perspective_infinite_reverse_rh", |fov_y_radians: f64, aspect_ratio: f64, z_near: f64| { let output: Val = ::bevy::math::DMat4::perspective_infinite_reverse_rh( - fov_y_radians.into(), - aspect_ratio.into(), - z_near.into(), + fov_y_radians, + aspect_ratio, + z_near, ) .into(); output @@ -20126,12 +19922,12 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "orthographic_rh_gl", |left: f64, right: f64, bottom: f64, top: f64, near: f64, far: f64| { let output: Val = ::bevy::math::DMat4::orthographic_rh_gl( - left.into(), - right.into(), - bottom.into(), - top.into(), - near.into(), - far.into(), + left, + right, + bottom, + top, + near, + far, ) .into(); output @@ -20141,12 +19937,12 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "orthographic_lh", |left: f64, right: f64, bottom: f64, top: f64, near: f64, far: f64| { let output: Val = ::bevy::math::DMat4::orthographic_lh( - left.into(), - right.into(), - bottom.into(), - top.into(), - near.into(), - far.into(), + left, + right, + bottom, + top, + near, + far, ) .into(); output @@ -20156,12 +19952,12 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "orthographic_rh", |left: f64, right: f64, bottom: f64, top: f64, near: f64, far: f64| { let output: Val = ::bevy::math::DMat4::orthographic_rh( - left.into(), - right.into(), - bottom.into(), - top.into(), - near.into(), - far.into(), + left, + right, + bottom, + top, + near, + far, ) .into(); output @@ -20171,7 +19967,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "project_point3", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::DMat4::project_point3( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -20182,7 +19978,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_point3", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::DMat4::transform_point3( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -20193,7 +19989,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_vector3", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::DMat4::transform_vector3( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -20203,221 +19999,136 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "mul_vec4", |_self: Ref, rhs: Val| { - let output: Val = ::bevy::math::DMat4::mul_vec4( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul_mat4", - |_self: Ref, rhs: Ref| { - let output: Val = ::bevy::math::DMat4::mul_mat4( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "add_mat4", - |_self: Ref, rhs: Ref| { - let output: Val = ::bevy::math::DMat4::add_mat4( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "sub_mat4", - |_self: Ref, rhs: Ref| { - let output: Val = ::bevy::math::DMat4::sub_mat4( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul_scalar", - |_self: Ref, rhs: f64| { - let output: Val = ::bevy::math::DMat4::mul_scalar( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "div_scalar", - |_self: Ref, rhs: f64| { - let output: Val = ::bevy::math::DMat4::div_scalar( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "abs_diff_eq", - | - _self: Ref, - rhs: Val, - max_abs_diff: f64| - { - let output: bool = ::bevy::math::DMat4::abs_diff_eq( - _self.into(), - rhs.into(), - max_abs_diff.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "abs", - |_self: Ref| { - let output: Val = ::bevy::math::DMat4::abs( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "as_mat4", - |_self: Ref| { - let output: Val = ::bevy::math::DMat4::as_mat4( - _self.into(), + let output: Val = ::bevy::math::DMat4::mul_vec4( + &_self, + rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::DMat4::neg( - _self.into(), + "mul_mat4", + |_self: Ref, rhs: Ref| { + let output: Val = ::bevy::math::DMat4::mul_mat4( + &_self, + &rhs, ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::DMat4::clone( - _self.into(), + "add_mat4", + |_self: Ref, rhs: Ref| { + let output: Val = ::bevy::math::DMat4::add_mat4( + &_self, + &rhs, ) .into(); output }, ) .overwrite_script_function( - "sub", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DMat4::sub( - _self.into(), - rhs.into(), + "sub_mat4", + |_self: Ref, rhs: Ref| { + let output: Val = ::bevy::math::DMat4::sub_mat4( + &_self, + &rhs, ) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DMat4::mul( - _self.into(), - rhs.into(), + "mul_scalar", + |_self: Ref, rhs: f64| { + let output: Val = ::bevy::math::DMat4::mul_scalar( + &_self, + rhs, ) .into(); output }, ) .overwrite_script_function( - "eq", - |_self: Ref, rhs: Ref| { - let output: bool = ::bevy::math::DMat4::eq(_self.into(), rhs.into()) + "div_scalar", + |_self: Ref, rhs: f64| { + let output: Val = ::bevy::math::DMat4::div_scalar( + &_self, + rhs, + ) .into(); output }, ) .overwrite_script_function( - "add", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DMat4::add( - _self.into(), + "abs_diff_eq", + | + _self: Ref, + rhs: Val, + max_abs_diff: f64| + { + let output: bool = ::bevy::math::DMat4::abs_diff_eq( + &_self, rhs.into(), + max_abs_diff, ) .into(); output }, ) .overwrite_script_function( - "div", - |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DMat4::div( - _self.into(), - rhs.into(), - ) + "abs", + |_self: Ref| { + let output: Val = ::bevy::math::DMat4::abs(&_self) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DMat4::mul( - _self.into(), - rhs.into(), + "as_mat4", + |_self: Ref| { + let output: Val = ::bevy::math::DMat4::as_mat4( + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::Affine2>::new(world) + ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Affine2::mul( + "div", + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DMat4::div( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Affine2::mul( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::DMat4::neg( _self.into(), - rhs.into(), ) .into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::Affine2::clone( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DMat4::add( _self.into(), + rhs.into(), ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::Affine2>::new(world) .overwrite_script_function( "from_cols", | @@ -20437,9 +20148,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_cols_array", |_self: Ref| { - let output: [f32; 6] = ::bevy::math::Affine2::to_cols_array( - _self.into(), - ) + let output: [f32; 6] = ::bevy::math::Affine2::to_cols_array(&_self) .into(); output }, @@ -20448,7 +20157,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "to_cols_array_2d", |_self: Ref| { let output: [[f32; 2]; 3] = ::bevy::math::Affine2::to_cols_array_2d( - _self.into(), + &_self, ) .into(); output @@ -20468,7 +20177,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_angle", |angle: f32| { let output: Val = ::bevy::math::Affine2::from_angle( - angle.into(), + angle, ) .into(); output @@ -20514,7 +20223,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { { let output: Val = ::bevy::math::Affine2::from_scale_angle_translation( scale.into(), - angle.into(), + angle, translation.into(), ) .into(); @@ -20525,7 +20234,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_angle_translation", |angle: f32, translation: Val| { let output: Val = ::bevy::math::Affine2::from_angle_translation( - angle.into(), + angle, translation.into(), ) .into(); @@ -20556,7 +20265,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_point2", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Affine2::transform_point2( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -20567,7 +20276,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_vector2", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Affine2::transform_vector2( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -20577,16 +20286,14 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "is_finite", |_self: Ref| { - let output: bool = ::bevy::math::Affine2::is_finite(_self.into()) - .into(); + let output: bool = ::bevy::math::Affine2::is_finite(&_self).into(); output }, ) .overwrite_script_function( "is_nan", |_self: Ref| { - let output: bool = ::bevy::math::Affine2::is_nan(_self.into()) - .into(); + let output: bool = ::bevy::math::Affine2::is_nan(&_self).into(); output }, ) @@ -20598,9 +20305,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { max_abs_diff: f32| { let output: bool = ::bevy::math::Affine2::abs_diff_eq( - _self.into(), + &_self, rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -20610,16 +20317,16 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "inverse", |_self: Ref| { let output: Val = ::bevy::math::Affine2::inverse( - _self.into(), + &_self, ) .into(); output }, ) .overwrite_script_function( - "eq", - |_self: Ref, rhs: Ref| { - let output: bool = ::bevy::math::Affine2::eq( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Affine2::mul( _self.into(), rhs.into(), ) @@ -20637,12 +20344,11 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .into(); output }, - ); - NamespaceBuilder::<::bevy::math::Affine3A>::new(world) + ) .overwrite_script_function( - "eq", - |_self: Ref, rhs: Ref| { - let output: bool = ::bevy::math::Affine3A::eq( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Affine2::mul( _self.into(), rhs.into(), ) @@ -20650,16 +20356,24 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) + .overwrite_script_function( + "eq", + |_self: Ref, rhs: Ref| { + let output: bool = ::bevy::math::Affine2::eq(&_self, &rhs).into(); + output + }, + ) .overwrite_script_function( "clone", - |_self: Ref| { - let output: Val = ::bevy::math::Affine3A::clone( - _self.into(), + |_self: Ref| { + let output: Val = ::bevy::math::Affine2::clone( + &_self, ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::Affine3A>::new(world) .overwrite_script_function( "from_cols", | @@ -20681,9 +20395,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_cols_array", |_self: Ref| { - let output: [f32; 12] = ::bevy::math::Affine3A::to_cols_array( - _self.into(), - ) + let output: [f32; 12] = ::bevy::math::Affine3A::to_cols_array(&_self) .into(); output }, @@ -20692,7 +20404,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "to_cols_array_2d", |_self: Ref| { let output: [[f32; 3]; 4] = ::bevy::math::Affine3A::to_cols_array_2d( - _self.into(), + &_self, ) .into(); output @@ -20723,7 +20435,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |axis: Val, angle: f32| { let output: Val = ::bevy::math::Affine3A::from_axis_angle( axis.into(), - angle.into(), + angle, ) .into(); output @@ -20733,7 +20445,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_x", |angle: f32| { let output: Val = ::bevy::math::Affine3A::from_rotation_x( - angle.into(), + angle, ) .into(); output @@ -20743,7 +20455,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_y", |angle: f32| { let output: Val = ::bevy::math::Affine3A::from_rotation_y( - angle.into(), + angle, ) .into(); output @@ -20753,7 +20465,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_z", |angle: f32| { let output: Val = ::bevy::math::Affine3A::from_rotation_z( - angle.into(), + angle, ) .into(); output @@ -20895,7 +20607,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_point3", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Affine3A::transform_point3( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -20906,7 +20618,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_vector3", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Affine3A::transform_vector3( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -20917,7 +20629,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_point3a", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Affine3A::transform_point3a( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -20928,7 +20640,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_vector3a", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::Affine3A::transform_vector3a( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -20938,16 +20650,14 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "is_finite", |_self: Ref| { - let output: bool = ::bevy::math::Affine3A::is_finite(_self.into()) - .into(); + let output: bool = ::bevy::math::Affine3A::is_finite(&_self).into(); output }, ) .overwrite_script_function( "is_nan", |_self: Ref| { - let output: bool = ::bevy::math::Affine3A::is_nan(_self.into()) - .into(); + let output: bool = ::bevy::math::Affine3A::is_nan(&_self).into(); output }, ) @@ -20959,9 +20669,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { max_abs_diff: f32| { let output: bool = ::bevy::math::Affine3A::abs_diff_eq( - _self.into(), + &_self, rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -20971,12 +20681,30 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "inverse", |_self: Ref| { let output: Val = ::bevy::math::Affine3A::inverse( + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::Affine3A::mul( _self.into(), + rhs.into(), ) .into(); output }, ) + .overwrite_script_function( + "eq", + |_self: Ref, rhs: Ref| { + let output: bool = ::bevy::math::Affine3A::eq(&_self, &rhs).into(); + output + }, + ) .overwrite_script_function( "mul", |_self: Val, rhs: Val| { @@ -20988,24 +20716,40 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::Affine3A::clone( + &_self, + ) + .into(); + output + }, + ); + NamespaceBuilder::<::bevy::math::DAffine2>::new(world) .overwrite_script_function( "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::Affine3A::mul( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DAffine2::mul( _self.into(), rhs.into(), ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::DAffine2>::new(world) + ) .overwrite_script_function( "eq", |_self: Ref, rhs: Ref| { - let output: bool = ::bevy::math::DAffine2::eq( - _self.into(), - rhs.into(), + let output: bool = ::bevy::math::DAffine2::eq(&_self, &rhs).into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::DAffine2::clone( + &_self, ) .into(); output @@ -21030,9 +20774,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_cols_array", |_self: Ref| { - let output: [f64; 6] = ::bevy::math::DAffine2::to_cols_array( - _self.into(), - ) + let output: [f64; 6] = ::bevy::math::DAffine2::to_cols_array(&_self) .into(); output }, @@ -21041,7 +20783,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "to_cols_array_2d", |_self: Ref| { let output: [[f64; 2]; 3] = ::bevy::math::DAffine2::to_cols_array_2d( - _self.into(), + &_self, ) .into(); output @@ -21061,7 +20803,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_angle", |angle: f64| { let output: Val = ::bevy::math::DAffine2::from_angle( - angle.into(), + angle, ) .into(); output @@ -21107,7 +20849,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { { let output: Val = ::bevy::math::DAffine2::from_scale_angle_translation( scale.into(), - angle.into(), + angle, translation.into(), ) .into(); @@ -21118,7 +20860,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_angle_translation", |angle: f64, translation: Val| { let output: Val = ::bevy::math::DAffine2::from_angle_translation( - angle.into(), + angle, translation.into(), ) .into(); @@ -21139,7 +20881,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_point2", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::DAffine2::transform_point2( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -21150,7 +20892,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_vector2", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::DAffine2::transform_vector2( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -21160,16 +20902,14 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "is_finite", |_self: Ref| { - let output: bool = ::bevy::math::DAffine2::is_finite(_self.into()) - .into(); + let output: bool = ::bevy::math::DAffine2::is_finite(&_self).into(); output }, ) .overwrite_script_function( "is_nan", |_self: Ref| { - let output: bool = ::bevy::math::DAffine2::is_nan(_self.into()) - .into(); + let output: bool = ::bevy::math::DAffine2::is_nan(&_self).into(); output }, ) @@ -21181,9 +20921,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { max_abs_diff: f64| { let output: bool = ::bevy::math::DAffine2::abs_diff_eq( - _self.into(), + &_self, rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -21193,7 +20933,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "inverse", |_self: Ref| { let output: Val = ::bevy::math::DAffine2::inverse( - _self.into(), + &_self, ) .into(); output @@ -21209,11 +20949,12 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::DAffine3>::new(world) .overwrite_script_function( "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DAffine2::mul( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DAffine3::mul( _self.into(), rhs.into(), ) @@ -21223,15 +20964,21 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "clone", - |_self: Ref| { - let output: Val = ::bevy::math::DAffine2::clone( - _self.into(), + |_self: Ref| { + let output: Val = ::bevy::math::DAffine3::clone( + &_self, ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::DAffine3>::new(world) + ) + .overwrite_script_function( + "eq", + |_self: Ref, rhs: Ref| { + let output: bool = ::bevy::math::DAffine3::eq(&_self, &rhs).into(); + output + }, + ) .overwrite_script_function( "from_cols", | @@ -21253,9 +21000,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_cols_array", |_self: Ref| { - let output: [f64; 12] = ::bevy::math::DAffine3::to_cols_array( - _self.into(), - ) + let output: [f64; 12] = ::bevy::math::DAffine3::to_cols_array(&_self) .into(); output }, @@ -21264,7 +21009,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "to_cols_array_2d", |_self: Ref| { let output: [[f64; 3]; 4] = ::bevy::math::DAffine3::to_cols_array_2d( - _self.into(), + &_self, ) .into(); output @@ -21295,7 +21040,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |axis: Val, angle: f64| { let output: Val = ::bevy::math::DAffine3::from_axis_angle( axis.into(), - angle.into(), + angle, ) .into(); output @@ -21305,7 +21050,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_x", |angle: f64| { let output: Val = ::bevy::math::DAffine3::from_rotation_x( - angle.into(), + angle, ) .into(); output @@ -21315,7 +21060,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_y", |angle: f64| { let output: Val = ::bevy::math::DAffine3::from_rotation_y( - angle.into(), + angle, ) .into(); output @@ -21325,7 +21070,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_z", |angle: f64| { let output: Val = ::bevy::math::DAffine3::from_rotation_z( - angle.into(), + angle, ) .into(); output @@ -21467,7 +21212,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_point3", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::DAffine3::transform_point3( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -21478,7 +21223,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "transform_vector3", |_self: Ref, rhs: Val| { let output: Val = ::bevy::math::DAffine3::transform_vector3( - _self.into(), + &_self, rhs.into(), ) .into(); @@ -21488,16 +21233,14 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "is_finite", |_self: Ref| { - let output: bool = ::bevy::math::DAffine3::is_finite(_self.into()) - .into(); + let output: bool = ::bevy::math::DAffine3::is_finite(&_self).into(); output }, ) .overwrite_script_function( "is_nan", |_self: Ref| { - let output: bool = ::bevy::math::DAffine3::is_nan(_self.into()) - .into(); + let output: bool = ::bevy::math::DAffine3::is_nan(&_self).into(); output }, ) @@ -21509,9 +21252,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { max_abs_diff: f64| { let output: bool = ::bevy::math::DAffine3::abs_diff_eq( - _self.into(), + &_self, rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -21521,38 +21264,39 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "inverse", |_self: Ref| { let output: Val = ::bevy::math::DAffine3::inverse( - _self.into(), + &_self, ) .into(); output }, ) .overwrite_script_function( - "eq", - |_self: Ref, rhs: Ref| { - let output: bool = ::bevy::math::DAffine3::eq( + "mul", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DAffine3::mul( _self.into(), rhs.into(), ) .into(); output }, - ) + ); + NamespaceBuilder::<::bevy::math::DQuat>::new(world) .overwrite_script_function( "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DAffine3::mul( + |_self: Val, rhs: f64| { + let output: Val = ::bevy::math::DQuat::mul( _self.into(), - rhs.into(), + rhs, ) .into(); output }, ) .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DAffine3::mul( + "add", + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DQuat::add( _self.into(), rhs.into(), ) @@ -21561,20 +21305,28 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::DAffine3::clone( + "eq", + |_self: Ref, rhs: Ref| { + let output: bool = ::bevy::math::DQuat::eq(&_self, &rhs).into(); + output + }, + ) + .overwrite_script_function( + "neg", + |_self: Val| { + let output: Val = ::bevy::math::DQuat::neg( _self.into(), ) .into(); output }, - ); - NamespaceBuilder::<::bevy::math::DQuat>::new(world) + ) .overwrite_script_function( - "eq", - |_self: Ref, rhs: Ref| { - let output: bool = ::bevy::math::DQuat::eq(_self.into(), rhs.into()) + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::DQuat::clone( + &_self, + ) .into(); output }, @@ -21584,7 +21336,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |_self: Val, rhs: f64| { let output: Val = ::bevy::math::DQuat::div( _self.into(), - rhs.into(), + rhs, ) .into(); output @@ -21594,10 +21346,10 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_xyzw", |x: f64, y: f64, z: f64, w: f64| { let output: Val = ::bevy::math::DQuat::from_xyzw( - x.into(), - y.into(), - z.into(), - w.into(), + x, + y, + z, + w, ) .into(); output @@ -21607,7 +21359,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [f64; 4]| { let output: Val = ::bevy::math::DQuat::from_array( - a.into(), + a, ) .into(); output @@ -21628,7 +21380,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |axis: Val, angle: f64| { let output: Val = ::bevy::math::DQuat::from_axis_angle( axis.into(), - angle.into(), + angle, ) .into(); output @@ -21648,7 +21400,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_x", |angle: f64| { let output: Val = ::bevy::math::DQuat::from_rotation_x( - angle.into(), + angle, ) .into(); output @@ -21658,7 +21410,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_y", |angle: f64| { let output: Val = ::bevy::math::DQuat::from_rotation_y( - angle.into(), + angle, ) .into(); output @@ -21668,7 +21420,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_rotation_z", |angle: f64| { let output: Val = ::bevy::math::DQuat::from_rotation_z( - angle.into(), + angle, ) .into(); output @@ -21679,9 +21431,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { |euler: Val, a: f64, b: f64, c: f64| { let output: Val = ::bevy::math::DQuat::from_euler( euler.into(), - a.into(), - b.into(), - c.into(), + a, + b, + c, ) .into(); output @@ -21691,7 +21443,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_mat3", |mat: Ref| { let output: Val = ::bevy::math::DQuat::from_mat3( - mat.into(), + &mat, ) .into(); output @@ -21701,7 +21453,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_mat4", |mat: Ref| { let output: Val = ::bevy::math::DQuat::from_mat4( - mat.into(), + &mat, ) .into(); output @@ -21764,8 +21516,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "to_array", |_self: Ref| { - let output: [f64; 4] = ::bevy::math::DQuat::to_array(_self.into()) - .into(); + let output: [f64; 4] = ::bevy::math::DQuat::to_array(&_self).into(); output }, ) @@ -21892,9 +21643,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { max_angle: f64| { let output: Val = ::bevy::math::DQuat::rotate_towards( - _self.into(), + &_self, rhs.into(), - max_angle.into(), + max_angle, ) .into(); output @@ -21910,7 +21661,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: bool = ::bevy::math::DQuat::abs_diff_eq( _self.into(), rhs.into(), - max_abs_diff.into(), + max_abs_diff, ) .into(); output @@ -21922,7 +21673,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::DQuat::lerp( _self.into(), end.into(), - s.into(), + s, ) .into(); output @@ -21934,7 +21685,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { let output: Val = ::bevy::math::DQuat::slerp( _self.into(), end.into(), - s.into(), + s, ) .into(); output @@ -21966,7 +21717,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_affine3", |a: Ref| { let output: Val = ::bevy::math::DQuat::from_affine3( - a.into(), + &a, ) .into(); output @@ -21982,38 +21733,6 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { output }, ) - .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DQuat::mul( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul", - |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DQuat::mul( - _self.into(), - rhs.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::DQuat::clone( - _self.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "sub", |_self: Val, rhs: Val| { @@ -22027,8 +21746,8 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ) .overwrite_script_function( "mul", - |_self: Val, rhs: f64| { - let output: Val = ::bevy::math::DQuat::mul( + |_self: Val, rhs: Val| { + let output: Val = ::bevy::math::DQuat::mul( _self.into(), rhs.into(), ) @@ -22037,19 +21756,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { }, ) .overwrite_script_function( - "neg", - |_self: Val| { - let output: Val = ::bevy::math::DQuat::neg( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "add", + "mul", |_self: Val, rhs: Val| { - let output: Val = ::bevy::math::DQuat::add( + let output: Val = ::bevy::math::DQuat::mul( _self.into(), rhs.into(), ) @@ -22059,31 +21768,27 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ); NamespaceBuilder::<::bevy::math::EulerRot>::new(world) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::EulerRot::clone( - _self.into(), - ) - .into(); + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::math::EulerRot::eq(&_self, &other).into(); output }, ) .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::math::EulerRot::eq( - _self.into(), - other.into(), + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::math::EulerRot::assert_receiver_is_total_eq( + &_self, ) .into(); output }, ) .overwrite_script_function( - "assert_receiver_is_total_eq", + "clone", |_self: Ref| { - let output: () = ::bevy::math::EulerRot::assert_receiver_is_total_eq( - _self.into(), + let output: Val = ::bevy::math::EulerRot::clone( + &_self, ) .into(); output @@ -22094,9 +21799,9 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "new", |x: bool, y: bool, z: bool| { let output: Val = ::bevy::math::BVec3A::new( - x.into(), - y.into(), - z.into(), + x, + y, + z, ) .into(); output @@ -22105,9 +21810,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "splat", |v: bool| { - let output: Val = ::bevy::math::BVec3A::splat( - v.into(), - ) + let output: Val = ::bevy::math::BVec3A::splat(v) .into(); output }, @@ -22116,7 +21819,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [bool; 3]| { let output: Val = ::bevy::math::BVec3A::from_array( - a.into(), + a, ) .into(); output @@ -22146,22 +21849,14 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "test", |_self: Ref, index: usize| { - let output: bool = ::bevy::math::BVec3A::test( - _self.into(), - index.into(), - ) - .into(); + let output: bool = ::bevy::math::BVec3A::test(&_self, index).into(); output }, ) .overwrite_script_function( "set", |_self: Mut, index: usize, value: bool| { - let output: () = ::bevy::math::BVec3A::set( - _self.into(), - index.into(), - value.into(), - ) + let output: () = ::bevy::math::BVec3A::set(&mut_self, index, value) .into(); output }, @@ -22170,7 +21865,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::math::BVec3A::clone( - _self.into(), + &_self, ) .into(); output @@ -22179,20 +21874,29 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "eq", |_self: Ref, rhs: Ref| { - let output: bool = ::bevy::math::BVec3A::eq(_self.into(), rhs.into()) - .into(); + let output: bool = ::bevy::math::BVec3A::eq(&_self, &rhs).into(); output }, ); NamespaceBuilder::<::bevy::math::BVec4A>::new(world) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::math::BVec4A::clone( + &_self, + ) + .into(); + output + }, + ) .overwrite_script_function( "new", |x: bool, y: bool, z: bool, w: bool| { let output: Val = ::bevy::math::BVec4A::new( - x.into(), - y.into(), - z.into(), - w.into(), + x, + y, + z, + w, ) .into(); output @@ -22201,9 +21905,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "splat", |v: bool| { - let output: Val = ::bevy::math::BVec4A::splat( - v.into(), - ) + let output: Val = ::bevy::math::BVec4A::splat(v) .into(); output }, @@ -22212,7 +21914,7 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { "from_array", |a: [bool; 4]| { let output: Val = ::bevy::math::BVec4A::from_array( - a.into(), + a, ) .into(); output @@ -22242,22 +21944,14 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "test", |_self: Ref, index: usize| { - let output: bool = ::bevy::math::BVec4A::test( - _self.into(), - index.into(), - ) - .into(); + let output: bool = ::bevy::math::BVec4A::test(&_self, index).into(); output }, ) .overwrite_script_function( "set", |_self: Mut, index: usize, value: bool| { - let output: () = ::bevy::math::BVec4A::set( - _self.into(), - index.into(), - value.into(), - ) + let output: () = ::bevy::math::BVec4A::set(&mut_self, index, value) .into(); output }, @@ -22265,73 +21959,55 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { .overwrite_script_function( "eq", |_self: Ref, rhs: Ref| { - let output: bool = ::bevy::math::BVec4A::eq(_self.into(), rhs.into()) - .into(); - output - }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::math::BVec4A::clone( - _self.into(), - ) - .into(); + let output: bool = ::bevy::math::BVec4A::eq(&_self, &rhs).into(); output }, ); NamespaceBuilder::<::smol_str::SmolStr>::new(world) .overwrite_script_function( - "clone", + "to_string", |_self: Ref| { - let output: Val = ::smol_str::SmolStr::clone( - _self.into(), + let output: std::string::String = ::smol_str::SmolStr::to_string( + &_self, ) .into(); output }, ) .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::smol_str::SmolStr::eq( - _self.into(), - other.into(), - ) - .into(); + "len", + |_self: Ref| { + let output: usize = ::smol_str::SmolStr::len(&_self).into(); output }, ) .overwrite_script_function( - "to_string", + "is_empty", |_self: Ref| { - let output: std::string::String = ::smol_str::SmolStr::to_string( - _self.into(), - ) - .into(); + let output: bool = ::smol_str::SmolStr::is_empty(&_self).into(); output }, ) .overwrite_script_function( - "len", + "is_heap_allocated", |_self: Ref| { - let output: usize = ::smol_str::SmolStr::len(_self.into()).into(); + let output: bool = ::smol_str::SmolStr::is_heap_allocated(&_self) + .into(); output }, ) .overwrite_script_function( - "is_empty", - |_self: Ref| { - let output: bool = ::smol_str::SmolStr::is_empty(_self.into()) - .into(); + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::smol_str::SmolStr::eq(&_self, &other).into(); output }, ) .overwrite_script_function( - "is_heap_allocated", + "clone", |_self: Ref| { - let output: bool = ::smol_str::SmolStr::is_heap_allocated( - _self.into(), + let output: Val = ::smol_str::SmolStr::clone( + &_self, ) .into(); output @@ -22339,167 +22015,156 @@ impl ::bevy::app::Plugin for BevyReflectScriptingPlugin { ); NamespaceBuilder::<::uuid::Uuid>::new(world) .overwrite_script_function( - "get_version_num", - |_self: Ref| { - let output: usize = ::uuid::Uuid::get_version_num(_self.into()) - .into(); + "nil", + || { + let output: Val = ::uuid::Uuid::nil().into(); output }, ) .overwrite_script_function( - "as_u128", - |_self: Ref| { - let output: u128 = ::uuid::Uuid::as_u128(_self.into()).into(); + "max", + || { + let output: Val = ::uuid::Uuid::max().into(); output }, ) .overwrite_script_function( - "to_u128_le", - |_self: Ref| { - let output: u128 = ::uuid::Uuid::to_u128_le(_self.into()).into(); + "from_u128", + |v: u128| { + let output: Val = ::uuid::Uuid::from_u128(v).into(); output }, ) .overwrite_script_function( - "as_u64_pair", - |_self: Ref| { - let output: (u64, u64) = ::uuid::Uuid::as_u64_pair(_self.into()) - .into(); + "from_u128_le", + |v: u128| { + let output: Val = ::uuid::Uuid::from_u128_le(v).into(); output }, ) .overwrite_script_function( - "into_bytes", - |_self: Val| { - let output: [u8; 16] = ::uuid::Uuid::into_bytes(_self.into()).into(); + "from_u64_pair", + |high_bits: u64, low_bits: u64| { + let output: Val = ::uuid::Uuid::from_u64_pair( + high_bits, + low_bits, + ) + .into(); output }, ) .overwrite_script_function( - "to_bytes_le", - |_self: Ref| { - let output: [u8; 16] = ::uuid::Uuid::to_bytes_le(_self.into()) - .into(); + "from_bytes", + |bytes: [u8; 16]| { + let output: Val = ::uuid::Uuid::from_bytes(bytes).into(); output }, ) .overwrite_script_function( - "is_nil", - |_self: Ref| { - let output: bool = ::uuid::Uuid::is_nil(_self.into()).into(); + "from_bytes_le", + |b: [u8; 16]| { + let output: Val = ::uuid::Uuid::from_bytes_le(b).into(); output }, ) .overwrite_script_function( - "is_max", + "assert_receiver_is_total_eq", |_self: Ref| { - let output: bool = ::uuid::Uuid::is_max(_self.into()).into(); + let output: () = ::uuid::Uuid::assert_receiver_is_total_eq(&_self) + .into(); output }, ) .overwrite_script_function( - "encode_buffer", - || { - let output: [u8; 45] = ::uuid::Uuid::encode_buffer().into(); + "get_version_num", + |_self: Ref| { + let output: usize = ::uuid::Uuid::get_version_num(&_self).into(); output }, ) .overwrite_script_function( - "get_node_id", + "as_u128", |_self: Ref| { - let output: bevy::reflect::erased_serde::__private::serde::__private::Option< - [u8; 6], - > = ::uuid::Uuid::get_node_id(_self.into()).into(); + let output: u128 = ::uuid::Uuid::as_u128(&_self).into(); output }, ) .overwrite_script_function( - "assert_receiver_is_total_eq", + "to_u128_le", |_self: Ref| { - let output: () = ::uuid::Uuid::assert_receiver_is_total_eq( - _self.into(), - ) - .into(); + let output: u128 = ::uuid::Uuid::to_u128_le(&_self).into(); output }, ) .overwrite_script_function( - "nil", - || { - let output: Val = ::uuid::Uuid::nil().into(); + "as_u64_pair", + |_self: Ref| { + let output: (u64, u64) = ::uuid::Uuid::as_u64_pair(&_self).into(); output }, ) .overwrite_script_function( - "max", - || { - let output: Val = ::uuid::Uuid::max().into(); + "into_bytes", + |_self: Val| { + let output: [u8; 16] = ::uuid::Uuid::into_bytes(_self.into()).into(); output }, ) .overwrite_script_function( - "from_u128", - |v: u128| { - let output: Val = ::uuid::Uuid::from_u128(v.into()) - .into(); + "to_bytes_le", + |_self: Ref| { + let output: [u8; 16] = ::uuid::Uuid::to_bytes_le(&_self).into(); output }, ) .overwrite_script_function( - "from_u128_le", - |v: u128| { - let output: Val = ::uuid::Uuid::from_u128_le(v.into()) - .into(); + "is_nil", + |_self: Ref| { + let output: bool = ::uuid::Uuid::is_nil(&_self).into(); output }, ) .overwrite_script_function( - "from_u64_pair", - |high_bits: u64, low_bits: u64| { - let output: Val = ::uuid::Uuid::from_u64_pair( - high_bits.into(), - low_bits.into(), - ) - .into(); + "is_max", + |_self: Ref| { + let output: bool = ::uuid::Uuid::is_max(&_self).into(); output }, ) .overwrite_script_function( - "from_bytes", - |bytes: [u8; 16]| { - let output: Val = ::uuid::Uuid::from_bytes(bytes.into()) - .into(); + "encode_buffer", + || { + let output: [u8; 45] = ::uuid::Uuid::encode_buffer().into(); output }, ) .overwrite_script_function( - "from_bytes_le", - |b: [u8; 16]| { - let output: Val = ::uuid::Uuid::from_bytes_le(b.into()) - .into(); + "get_node_id", + |_self: Ref| { + let output: bevy::reflect::erased_serde::__private::serde::__private::Option< + [u8; 6], + > = ::uuid::Uuid::get_node_id(&_self).into(); output }, ) .overwrite_script_function( "eq", |_self: Ref, other: Ref| { - let output: bool = ::uuid::Uuid::eq(_self.into(), other.into()) - .into(); + let output: bool = ::uuid::Uuid::eq(&_self, &other).into(); output }, ) .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::uuid::Uuid::clone(_self.into()) - .into(); + "new_v4", + || { + let output: Val = ::uuid::Uuid::new_v4().into(); output }, ) .overwrite_script_function( - "new_v4", - || { - let output: Val = ::uuid::Uuid::new_v4().into(); + "clone", + |_self: Ref| { + let output: Val = ::uuid::Uuid::clone(&_self).into(); output }, ); diff --git a/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_time.rs b/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_time.rs index 2a0259468a..9f8557282e 100644 --- a/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_time.rs +++ b/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_time.rs @@ -8,7 +8,7 @@ use bevy_mod_scripting_core::{ AddContextInitializer, StoreDocumentation, bindings::{ReflectReference, function::from::{Ref, Mut, Val}}, }; -use crate::*; +use crate::{*, namespaced_register::NamespaceBuilder}; pub struct BevyTimeScriptingPlugin; impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { fn build(&self, app: &mut ::bevy::prelude::App) { @@ -18,7 +18,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::time::prelude::Fixed::clone( - _self.into(), + &_self, ) .into(); output @@ -29,28 +29,18 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::time::prelude::Real::clone( - _self.into(), + &_self, ) .into(); output }, ); NamespaceBuilder::<::bevy::time::prelude::Timer>::new(world) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::time::prelude::Timer::clone( - _self.into(), - ) - .into(); - output - }, - ) .overwrite_script_function( "assert_receiver_is_total_eq", |_self: Ref| { let output: () = ::bevy::time::prelude::Timer::assert_receiver_is_total_eq( - _self.into(), + &_self, ) .into(); output @@ -60,7 +50,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { "from_seconds", |duration: f32, mode: Val| { let output: Val = ::bevy::time::prelude::Timer::from_seconds( - duration.into(), + duration, mode.into(), ) .into(); @@ -70,9 +60,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { .overwrite_script_function( "finished", |_self: Ref| { - let output: bool = ::bevy::time::prelude::Timer::finished( - _self.into(), - ) + let output: bool = ::bevy::time::prelude::Timer::finished(&_self) .into(); output }, @@ -81,7 +69,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { "just_finished", |_self: Ref| { let output: bool = ::bevy::time::prelude::Timer::just_finished( - _self.into(), + &_self, ) .into(); output @@ -90,9 +78,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { .overwrite_script_function( "elapsed_secs", |_self: Ref| { - let output: f32 = ::bevy::time::prelude::Timer::elapsed_secs( - _self.into(), - ) + let output: f32 = ::bevy::time::prelude::Timer::elapsed_secs(&_self) .into(); output }, @@ -101,7 +87,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { "elapsed_secs_f64", |_self: Ref| { let output: f64 = ::bevy::time::prelude::Timer::elapsed_secs_f64( - _self.into(), + &_self, ) .into(); output @@ -111,7 +97,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { "mode", |_self: Ref| { let output: Val = ::bevy::time::prelude::Timer::mode( - _self.into(), + &_self, ) .into(); output @@ -124,7 +110,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { mode: Val| { let output: () = ::bevy::time::prelude::Timer::set_mode( - _self.into(), + &mut_self, mode.into(), ) .into(); @@ -134,7 +120,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { .overwrite_script_function( "pause", |_self: Mut| { - let output: () = ::bevy::time::prelude::Timer::pause(_self.into()) + let output: () = ::bevy::time::prelude::Timer::pause(&mut_self) .into(); output }, @@ -142,7 +128,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { .overwrite_script_function( "unpause", |_self: Mut| { - let output: () = ::bevy::time::prelude::Timer::unpause(_self.into()) + let output: () = ::bevy::time::prelude::Timer::unpause(&mut_self) .into(); output }, @@ -150,7 +136,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { .overwrite_script_function( "paused", |_self: Ref| { - let output: bool = ::bevy::time::prelude::Timer::paused(_self.into()) + let output: bool = ::bevy::time::prelude::Timer::paused(&_self) .into(); output }, @@ -158,7 +144,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { .overwrite_script_function( "reset", |_self: Mut| { - let output: () = ::bevy::time::prelude::Timer::reset(_self.into()) + let output: () = ::bevy::time::prelude::Timer::reset(&mut_self) .into(); output }, @@ -166,9 +152,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { .overwrite_script_function( "fraction", |_self: Ref| { - let output: f32 = ::bevy::time::prelude::Timer::fraction( - _self.into(), - ) + let output: f32 = ::bevy::time::prelude::Timer::fraction(&_self) .into(); output }, @@ -177,7 +161,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { "fraction_remaining", |_self: Ref| { let output: f32 = ::bevy::time::prelude::Timer::fraction_remaining( - _self.into(), + &_self, ) .into(); output @@ -187,7 +171,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { "remaining_secs", |_self: Ref| { let output: f32 = ::bevy::time::prelude::Timer::remaining_secs( - _self.into(), + &_self, ) .into(); output @@ -197,7 +181,17 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { "times_finished_this_tick", |_self: Ref| { let output: u32 = ::bevy::time::prelude::Timer::times_finished_this_tick( - _self.into(), + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::time::prelude::Timer::clone( + &_self, ) .into(); output @@ -209,10 +203,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { _self: Ref, other: Ref| { - let output: bool = ::bevy::time::prelude::Timer::eq( - _self.into(), - other.into(), - ) + let output: bool = ::bevy::time::prelude::Timer::eq(&_self, &other) .into(); output }, @@ -225,28 +216,28 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { other: Ref| { let output: bool = ::bevy::time::prelude::TimerMode::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output }, ) .overwrite_script_function( - "clone", + "assert_receiver_is_total_eq", |_self: Ref| { - let output: Val = ::bevy::time::prelude::TimerMode::clone( - _self.into(), + let output: () = ::bevy::time::prelude::TimerMode::assert_receiver_is_total_eq( + &_self, ) .into(); output }, ) .overwrite_script_function( - "assert_receiver_is_total_eq", + "clone", |_self: Ref| { - let output: () = ::bevy::time::prelude::TimerMode::assert_receiver_is_total_eq( - _self.into(), + let output: Val = ::bevy::time::prelude::TimerMode::clone( + &_self, ) .into(); output @@ -257,13 +248,23 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::time::prelude::Virtual::clone( - _self.into(), + &_self, ) .into(); output }, ); NamespaceBuilder::<::bevy::time::Stopwatch>::new(world) + .overwrite_script_function( + "assert_receiver_is_total_eq", + |_self: Ref| { + let output: () = ::bevy::time::Stopwatch::assert_receiver_is_total_eq( + &_self, + ) + .into(); + output + }, + ) .overwrite_script_function( "new", || { @@ -275,7 +276,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { .overwrite_script_function( "elapsed_secs", |_self: Ref| { - let output: f32 = ::bevy::time::Stopwatch::elapsed_secs(_self.into()) + let output: f32 = ::bevy::time::Stopwatch::elapsed_secs(&_self) .into(); output }, @@ -283,9 +284,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { .overwrite_script_function( "elapsed_secs_f64", |_self: Ref| { - let output: f64 = ::bevy::time::Stopwatch::elapsed_secs_f64( - _self.into(), - ) + let output: f64 = ::bevy::time::Stopwatch::elapsed_secs_f64(&_self) .into(); output }, @@ -293,39 +292,35 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { .overwrite_script_function( "pause", |_self: Mut| { - let output: () = ::bevy::time::Stopwatch::pause(_self.into()).into(); + let output: () = ::bevy::time::Stopwatch::pause(&mut_self).into(); output }, ) .overwrite_script_function( "unpause", |_self: Mut| { - let output: () = ::bevy::time::Stopwatch::unpause(_self.into()) - .into(); + let output: () = ::bevy::time::Stopwatch::unpause(&mut_self).into(); output }, ) .overwrite_script_function( "is_paused", |_self: Ref| { - let output: bool = ::bevy::time::Stopwatch::is_paused(_self.into()) - .into(); + let output: bool = ::bevy::time::Stopwatch::is_paused(&_self).into(); output }, ) .overwrite_script_function( "reset", |_self: Mut| { - let output: () = ::bevy::time::Stopwatch::reset(_self.into()).into(); + let output: () = ::bevy::time::Stopwatch::reset(&mut_self).into(); output }, ) .overwrite_script_function( - "assert_receiver_is_total_eq", - |_self: Ref| { - let output: () = ::bevy::time::Stopwatch::assert_receiver_is_total_eq( - _self.into(), - ) + "eq", + |_self: Ref, other: Ref| { + let output: bool = ::bevy::time::Stopwatch::eq(&_self, &other) .into(); output }, @@ -334,18 +329,7 @@ impl ::bevy::app::Plugin for BevyTimeScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::time::Stopwatch::clone( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "eq", - |_self: Ref, other: Ref| { - let output: bool = ::bevy::time::Stopwatch::eq( - _self.into(), - other.into(), + &_self, ) .into(); output diff --git a/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_transform.rs b/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_transform.rs index c32d3ee20e..99a200579c 100644 --- a/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_transform.rs +++ b/crates/bevy_mod_scripting_functions/src/bevy_bindings/bevy_transform.rs @@ -11,7 +11,7 @@ use bevy_mod_scripting_core::{ AddContextInitializer, StoreDocumentation, bindings::{ReflectReference, function::from::{Ref, Mut, Val}}, }; -use crate::*; +use crate::{*, namespaced_register::NamespaceBuilder}; pub struct BevyTransformScriptingPlugin; impl ::bevy::app::Plugin for BevyTransformScriptingPlugin { fn build(&self, app: &mut ::bevy::prelude::App) { @@ -21,35 +21,7 @@ impl ::bevy::app::Plugin for BevyTransformScriptingPlugin { "clone", |_self: Ref| { let output: Val = ::bevy::transform::components::GlobalTransform::clone( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul", - | - _self: Val, - global_transform: Val| - { - let output: Val = ::bevy::transform::components::GlobalTransform::mul( - _self.into(), - global_transform.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "mul", - | - _self: Val, - transform: Val| - { - let output: Val = ::bevy::transform::components::GlobalTransform::mul( - _self.into(), - transform.into(), + &_self, ) .into(); output @@ -62,8 +34,8 @@ impl ::bevy::app::Plugin for BevyTransformScriptingPlugin { other: Ref| { let output: bool = ::bevy::transform::components::GlobalTransform::eq( - _self.into(), - other.into(), + &_self, + &other, ) .into(); output @@ -73,9 +45,9 @@ impl ::bevy::app::Plugin for BevyTransformScriptingPlugin { "from_xyz", |x: f32, y: f32, z: f32| { let output: Val = ::bevy::transform::components::GlobalTransform::from_xyz( - x.into(), - y.into(), - z.into(), + x, + y, + z, ) .into(); output @@ -85,7 +57,7 @@ impl ::bevy::app::Plugin for BevyTransformScriptingPlugin { "compute_transform", |_self: Ref| { let output: Val = ::bevy::transform::components::GlobalTransform::compute_transform( - _self.into(), + &_self, ) .into(); output @@ -98,8 +70,8 @@ impl ::bevy::app::Plugin for BevyTransformScriptingPlugin { parent: Ref| { let output: Val = ::bevy::transform::components::GlobalTransform::reparented_to( - _self.into(), - parent.into(), + &_self, + &parent, ) .into(); output @@ -112,6 +84,34 @@ impl ::bevy::app::Plugin for BevyTransformScriptingPlugin { transform: Val| { let output: Val = ::bevy::transform::components::GlobalTransform::mul_transform( + &_self, + transform.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "mul", + | + _self: Val, + global_transform: Val| + { + let output: Val = ::bevy::transform::components::GlobalTransform::mul( + _self.into(), + global_transform.into(), + ) + .into(); + output + }, + ) + .overwrite_script_function( + "mul", + | + _self: Val, + transform: Val| + { + let output: Val = ::bevy::transform::components::GlobalTransform::mul( _self.into(), transform.into(), ) @@ -120,13 +120,51 @@ impl ::bevy::app::Plugin for BevyTransformScriptingPlugin { }, ); NamespaceBuilder::<::bevy::transform::components::Transform>::new(world) + .overwrite_script_function( + "clone", + |_self: Ref| { + let output: Val = ::bevy::transform::components::Transform::clone( + &_self, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "eq", + | + _self: Ref, + other: Ref| + { + let output: bool = ::bevy::transform::components::Transform::eq( + &_self, + &other, + ) + .into(); + output + }, + ) + .overwrite_script_function( + "mul", + | + _self: Val, + global_transform: Val| + { + let output: Val = ::bevy::transform::components::Transform::mul( + _self.into(), + global_transform.into(), + ) + .into(); + output + }, + ) .overwrite_script_function( "from_xyz", |x: f32, y: f32, z: f32| { let output: Val = ::bevy::transform::components::Transform::from_xyz( - x.into(), - y.into(), - z.into(), + x, + y, + z, ) .into(); output @@ -136,8 +174,8 @@ impl ::bevy::app::Plugin for BevyTransformScriptingPlugin { "rotate_x", |_self: Mut, angle: f32| { let output: () = ::bevy::transform::components::Transform::rotate_x( - _self.into(), - angle.into(), + &mut_self, + angle, ) .into(); output @@ -147,8 +185,8 @@ impl ::bevy::app::Plugin for BevyTransformScriptingPlugin { "rotate_y", |_self: Mut, angle: f32| { let output: () = ::bevy::transform::components::Transform::rotate_y( - _self.into(), - angle.into(), + &mut_self, + angle, ) .into(); output @@ -158,8 +196,8 @@ impl ::bevy::app::Plugin for BevyTransformScriptingPlugin { "rotate_z", |_self: Mut, angle: f32| { let output: () = ::bevy::transform::components::Transform::rotate_z( - _self.into(), - angle.into(), + &mut_self, + angle, ) .into(); output @@ -169,8 +207,8 @@ impl ::bevy::app::Plugin for BevyTransformScriptingPlugin { "rotate_local_x", |_self: Mut, angle: f32| { let output: () = ::bevy::transform::components::Transform::rotate_local_x( - _self.into(), - angle.into(), + &mut_self, + angle, ) .into(); output @@ -180,8 +218,8 @@ impl ::bevy::app::Plugin for BevyTransformScriptingPlugin { "rotate_local_y", |_self: Mut, angle: f32| { let output: () = ::bevy::transform::components::Transform::rotate_local_y( - _self.into(), - angle.into(), + &mut_self, + angle, ) .into(); output @@ -191,8 +229,8 @@ impl ::bevy::app::Plugin for BevyTransformScriptingPlugin { "rotate_local_z", |_self: Mut, angle: f32| { let output: () = ::bevy::transform::components::Transform::rotate_local_z( - _self.into(), - angle.into(), + &mut_self, + angle, ) .into(); output @@ -205,7 +243,7 @@ impl ::bevy::app::Plugin for BevyTransformScriptingPlugin { transform: Val| { let output: Val = ::bevy::transform::components::Transform::mul_transform( - _self.into(), + &_self, transform.into(), ) .into(); @@ -216,21 +254,7 @@ impl ::bevy::app::Plugin for BevyTransformScriptingPlugin { "is_finite", |_self: Ref| { let output: bool = ::bevy::transform::components::Transform::is_finite( - _self.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "eq", - | - _self: Ref, - other: Ref| - { - let output: bool = ::bevy::transform::components::Transform::eq( - _self.into(), - other.into(), + &_self, ) .into(); output @@ -249,30 +273,6 @@ impl ::bevy::app::Plugin for BevyTransformScriptingPlugin { .into(); output }, - ) - .overwrite_script_function( - "mul", - | - _self: Val, - global_transform: Val| - { - let output: Val = ::bevy::transform::components::Transform::mul( - _self.into(), - global_transform.into(), - ) - .into(); - output - }, - ) - .overwrite_script_function( - "clone", - |_self: Ref| { - let output: Val = ::bevy::transform::components::Transform::clone( - _self.into(), - ) - .into(); - output - }, ); } }