Struct rust_warrior::game::Game[][src]

pub struct Game {
    pub profile: Profile,
}
Expand description

This is exposed to the Player to get things started. Their profile is loaded (from .profile) and then the engine is fired up. If the current level is completed successfully, then the README.md file and their profile are updated.

Fields

profile: Profile

Implementations

The main entry point when playing the game.

After loading the player profile and initializing the current level, the game consists of repeatedly calling play_turn on the player’s Player instance.

Trait Implementations

Returns the “default value” for a type. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The alignment of pointer.

The type for initializers.

Initializes a with the given initializer. Read more

Dereferences the given pointer. Read more

Mutably dereferences the given pointer. Read more

Drops the object pointed to by the given pointer. Read more

Tries to create the default.

Calls try_default and panics on an error case.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.