Struct RpcConfig
pub struct RpcConfig {
pub rpc_mode: RpcMode,
pub transfer_mode: TransferMode,
pub call_local: bool,
pub channel: u32,
}
Expand description
Configuration for a remote procedure call, used with #[rpc(config = ...)]
.
Check documentation of the #[rpc]
attribute for usage.
See also Godot @rpc
keyword.
Fields§
§rpc_mode: RpcMode
§transfer_mode: TransferMode
§call_local: bool
§channel: u32
Implementations§
§impl RpcConfig
impl RpcConfig
pub fn configure_node(
self,
node: &mut Node,
method_name: impl AsArg<StringName>,
)
pub fn configure_node( self, node: &mut Node, method_name: impl AsArg<StringName>, )
Register method
as a remote procedure call on node
.
pub fn to_dictionary(&self) -> Dictionary
pub fn to_dictionary(&self) -> Dictionary
Returns a Dictionary
populated with the values required for a call to Node::rpc_config()
.
Trait Implementations§
impl Copy for RpcConfig
Auto Trait Implementations§
impl Freeze for RpcConfig
impl RefUnwindSafe for RpcConfig
impl Send for RpcConfig
impl Sync for RpcConfig
impl Unpin for RpcConfig
impl UnwindSafe for RpcConfig
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