pub struct Player {
name: Rc<str>,
character: Option<Shared<GameObjectEntity<Character>>>,
lineage: Vec<LineageNode>,
}
Expand description
A struct representing a player in the game
Fields§
§name: Rc<str>
§character: Option<Shared<GameObjectEntity<Character>>>
§lineage: Vec<LineageNode>
Trait Implementations§
Source§impl<'a> From<&'a Player> for EntryPoint<'a>
impl<'a> From<&'a Player> for EntryPoint<'a>
Source§impl FromGameObject for Player
impl FromGameObject for Player
fn from_game_object( base: &HashMap<String, SaveFileValue>, game_state: &mut GameState, ) -> Result<Self, ParsingError>
fn finalize(&mut self, reference: &Shared<GameObjectEntity<Self>>)
Source§impl GameObjectDerived for Player
impl GameObjectDerived for Player
Source§impl Localizable for Player
impl Localizable for Player
Source§impl Renderable for Player
impl Renderable for Player
Source§fn get_template() -> &'static str
fn get_template() -> &'static str
Returns the template file name.
This method is used to retrieve the template from the [Environment] object in the Renderer object.
Auto Trait Implementations§
impl Freeze for Player
impl !RefUnwindSafe for Player
impl !Send for Player
impl !Sync for Player
impl Unpin for Player
impl !UnwindSafe for Player
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more