HoverRace  2.0
Public Member Functions | Private Types | List of all members
HoverRace::Player::DemoProfile Class Reference

Profile for "guest" accounts that aren't persisted. More...

#include <DemoProfile.h>

+ Inheritance diagram for HoverRace::Player::DemoProfile:

Public Member Functions

 DemoProfile (std::shared_ptr< AvatarGallery > avatarGallery)
 
virtual ~DemoProfile ()
 
std::shared_ptr< Display::Res< Display::Texture > > GetAvatar () const override
 Retrieve the user's avatar, if available. More...
 
void Save () override
 
- Public Member Functions inherited from HoverRace::Player::Profile
 Profile (std::shared_ptr< AvatarGallery > avatarGallery={})
 
 Profile (std::shared_ptr< AvatarGallery > avatarGallery, const boost::uuids::uuid &uid)
 
 Profile (std::shared_ptr< AvatarGallery > avatarGallery, const boost::uuids::uuid &uid, const std::string &name, const std::string &avatarName, Display::Color primaryColor, Display::Color secondaryColor)
 
virtual ~Profile ()
 
virtual EditableProfileEdit ()
 Retrieve an editable view of this profile. More...
 
virtual RenamableProfileEditName ()
 Retrieve an renamable view of this profile. More...
 
const std::string & GetAvatarName () const
 
Display::Color GetColor (size_t i) const
 Retrieve the color by index. More...
 
const std::string & GetName () const
 Retrieve the name of the player. More...
 
Display::Color GetPrimaryColor () const
 
Display::Color GetSecondaryColor () const
 
const boost::uuids::uuid & GetUid () const
 Retrieve the globally unique identifier for this profile. More...
 
const std::string GetUidStr () const
 Retrieve the UID as a string. More...
 
void SetColor (size_t i, Display::Color color) override
 Set the color by index. More...
 

Private Types

using SUPER = Profile
 

Additional Inherited Members

- Static Public Attributes inherited from HoverRace::Player::Profile
static const size_t MAX_AVATAR_NAME_LENGTH = 16
 
static const size_t MAX_NAME_LENGTH = 30
 Maximum length for the name. More...
 
- Protected Member Functions inherited from HoverRace::Player::Profile
AvatarGalleryGetAvatarGallery () const
 
void Rename (const std::string &name) override
 Attempt to rename the profile. More...
 
void SetAvatarName (const std::string &avatarName) override
 
virtual void SetName (const std::string &name)
 
void SetPrimaryColor (Display::Color color) override
 
void SetSecondaryColor (Display::Color color) override
 

Detailed Description

Profile for "guest" accounts that aren't persisted.

Author
Michael Imamura

Member Typedef Documentation

Constructor & Destructor Documentation

HoverRace::Player::DemoProfile::DemoProfile ( std::shared_ptr< AvatarGallery avatarGallery)
virtual HoverRace::Player::DemoProfile::~DemoProfile ( )
inlinevirtual

Member Function Documentation

std::shared_ptr< Display::Res< Display::Texture > > HoverRace::Player::DemoProfile::GetAvatar ( ) const
overridevirtual

Retrieve the user's avatar, if available.

Returns
The avatar resource (may be nullptr).

Reimplemented from HoverRace::Player::Profile.

void HoverRace::Player::DemoProfile::Save ( )
inlineoverridevirtual

The documentation for this class was generated from the following files: