#[repr(C)]pub struct RustealRustCallbacks {
pub drop_rust_instance: extern "C" fn(handle: UObjectHandle, type_id: u64, rust_data: *mut u8),
pub invoke_rust_function: extern "C" fn(callback_id: u64, obj: UObjectHandle, params: *mut u8),
pub invoke_delegate_callback: extern "C" fn(callback_id: u64, params: *mut u8),
pub on_shutdown: extern "C" fn(),
pub construct_rust_instance: extern "C" fn(obj: UObjectHandle, type_id: u64, is_cdo: bool),
pub notify_pinned_destroyed: extern "C" fn(handle: UObjectHandle),
pub on_tick: extern "C" fn(delta_seconds: f32),
}Expand description
Callback table filled by Rust and returned to C++ from rusteal_init.
C++ calls into Rust through these function pointers.
Fields§
§drop_rust_instance: extern "C" fn(handle: UObjectHandle, type_id: u64, rust_data: *mut u8)Called when a Rust-defined UClass instance is destroyed (reify only).
invoke_rust_function: extern "C" fn(callback_id: u64, obj: UObjectHandle, params: *mut u8)UE → Rust function call forwarding (for Rust-defined UFunctions).
invoke_delegate_callback: extern "C" fn(callback_id: u64, params: *mut u8)Delegate callback forwarding.
on_shutdown: extern "C" fn()Shutdown notification — Rust should release all resources.
construct_rust_instance: extern "C" fn(obj: UObjectHandle, type_id: u64, is_cdo: bool)Called by C++ when a reified class instance is constructed.
notify_pinned_destroyed: extern "C" fn(handle: UObjectHandle)Called by C++ when a Pinned object is destroyed (DestroyActor, level unload, etc.).
on_tick: extern "C" fn(delta_seconds: f32)Called by C++ every frame on the game thread (the core ticker: in the editor and in games, with or without a world).
Auto Trait Implementations§
impl Freeze for RustealRustCallbacks
impl RefUnwindSafe for RustealRustCallbacks
impl Send for RustealRustCallbacks
impl Sync for RustealRustCallbacks
impl Unpin for RustealRustCallbacks
impl UnsafeUnpin for RustealRustCallbacks
impl UnwindSafe for RustealRustCallbacks
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more