pub struct Client(/* private fields */);Expand description
A Bevy compatible wrapper around steamworks::Client.
Automatically dereferences to the client so it can be transparently used.
For more information on how to use it, see steamworks::Client.
Methods from Deref<Target = Client>§
Sourcepub fn run_callbacks(&self)
pub fn run_callbacks(&self)
Runs any currently pending callbacks
This runs all currently pending callbacks on the current thread.
This should be called frequently (e.g. once per a frame) in order to reduce the latency between recieving events.
Sourcepub fn process_callbacks(&self, callback_handler: impl FnMut(CallbackResult))
pub fn process_callbacks(&self, callback_handler: impl FnMut(CallbackResult))
Runs any currently pending callbacks.
This is identical to run_callbacks in every way, except that
callback_handler is called for every callback invoked.
This option provides an alternative for handling callbacks that
can doesn’t require the handler to be Send, and 'static.
This should be called frequently (e.g. once per a frame) in order to reduce the latency between recieving events.
Sourcepub fn register_callback<C, F>(&self, f: F) -> CallbackHandle
pub fn register_callback<C, F>(&self, f: F) -> CallbackHandle
Registers the passed function as a callback for the given type.
The callback will be run on the thread that run_callbacks
is called when the event arrives.
If the callback handler cannot be made Send or 'static
the call to run_callbacks should be replaced with a call to
process_callbacks instead.
Sourcepub fn matchmaking(&self) -> Matchmaking
pub fn matchmaking(&self) -> Matchmaking
Returns an accessor to the steam matchmaking interface
Sourcepub fn matchmaking_servers(&self) -> MatchmakingServers
pub fn matchmaking_servers(&self) -> MatchmakingServers
Returns an accessor to the steam matchmaking_servers interface
Sourcepub fn networking(&self) -> Networking
pub fn networking(&self) -> Networking
Returns an accessor to the steam networking interface
Sourcepub fn user_stats(&self) -> UserStats
pub fn user_stats(&self) -> UserStats
Returns an accessor to the steam user stats interface
Sourcepub fn remote_play(&self) -> RemotePlay
pub fn remote_play(&self) -> RemotePlay
Returns an accessor to the steam remote play interface
Sourcepub fn remote_storage(&self) -> RemoteStorage
pub fn remote_storage(&self) -> RemoteStorage
Returns an accessor to the steam remote storage interface
Sourcepub fn screenshots(&self) -> Screenshots
pub fn screenshots(&self) -> Screenshots
Returns an accessor to the steam screenshots interface
pub fn networking_messages(&self) -> NetworkingMessages
pub fn networking_sockets(&self) -> NetworkingSockets
pub fn networking_utils(&self) -> NetworkingUtils
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Client
impl RefUnwindSafe for Client
impl Send for Client
impl Sync for Client
impl Unpin for Client
impl UnwindSafe for Client
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>, which can then be
downcast into Box<dyn ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>, which can then be further
downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.