A reimplementation of Mario Kart Wii's physics engine in C++
Loading...
Searching...
No Matches
Kart::KartParamFileManager Class Reference

#include <KartParamFileManager.hh>

Description

Abstraction for the process of retrieving kart parameters from files.

This has been modified from the base game in order to perform validation and make the class accessible as a singleton.

Definition at line 12 of file KartParamFileManager.hh.

Inheritance diagram for Kart::KartParamFileManager:

Classes

struct  FileInfo
 
struct  ParamFile
 

Public Member Functions

void clear ()
 
void init ()
 Loads and validates the kart parameter files.
 
EGG::RamStream getDriverStream (Character character) const
 
EGG::RamStream getVehicleStream (Vehicle vehicle) const
 
EGG::RamStream getHitboxStream (Vehicle vehicle) const
 
EGG::RamStream getBikeDispParamsStream (Vehicle vehicle) const
 

Static Public Member Functions

static KartParamFileManagerCreateInstance ()
 
static void DestroyInstance ()
 
static KartParamFileManagerInstance ()
 

Private Member Functions

bool validate () const
 Performs a few checks to make sure the files were loaded successfully.
 
- Private Member Functions inherited from EGG::Disposer

Private Attributes

FileInfo m_kartParam
 
FileInfo m_driverParam
 
FileInfo m_bikeDispParam
 

Static Private Attributes

static KartParamFileManagers_instance = nullptr
 

Additional Inherited Members

- Static Private Member Functions inherited from EGG::Disposer
static constexpr u16 getLinkOffset ()
 

Constructor & Destructor Documentation

◆ KartParamFileManager()

Kart::KartParamFileManager::KartParamFileManager ( )
private

Definition at line 119 of file KartParamFileManager.cc.

Member Function Documentation

◆ ~KartParamFileManager()

Kart::KartParamFileManager::~KartParamFileManager ( )
overrideprivate

Definition at line 123 of file KartParamFileManager.cc.

◆ clear()

void Kart::KartParamFileManager::clear ( )
0x80591C9C

Definition at line 6 of file KartParamFileManager.cc.

◆ CreateInstance()

KartParamFileManager * Kart::KartParamFileManager::CreateInstance ( )
static

Definition at line 106 of file KartParamFileManager.cc.

◆ DestroyInstance()

void Kart::KartParamFileManager::DestroyInstance ( )
static

Definition at line 112 of file KartParamFileManager.cc.

◆ getBikeDispParamsStream()

EGG::RamStream Kart::KartParamFileManager::getBikeDispParamsStream ( Vehicle vehicle) const
nodiscard

Definition at line 92 of file KartParamFileManager.cc.

◆ getDriverStream()

EGG::RamStream Kart::KartParamFileManager::getDriverStream ( Character character) const
nodiscard

Definition at line 23 of file KartParamFileManager.cc.

◆ getHitboxStream()

EGG::RamStream Kart::KartParamFileManager::getHitboxStream ( Vehicle vehicle) const
nodiscard

Definition at line 78 of file KartParamFileManager.cc.

◆ getVehicleStream()

EGG::RamStream Kart::KartParamFileManager::getVehicleStream ( Vehicle vehicle) const
nodiscard

Definition at line 67 of file KartParamFileManager.cc.

◆ init()

void Kart::KartParamFileManager::init ( )
0x805919F4

Loads and validates the kart parameter files.

Definition at line 14 of file KartParamFileManager.cc.

◆ Instance()

static KartParamFileManager * Kart::KartParamFileManager::Instance ( )
inlinestaticnodiscard

Definition at line 24 of file KartParamFileManager.hh.

◆ validate()

bool Kart::KartParamFileManager::validate ( ) const
nodiscardprivate

Performs a few checks to make sure the files were loaded successfully.

Definition at line 131 of file KartParamFileManager.cc.

Member Data Documentation

◆ m_bikeDispParam

FileInfo Kart::KartParamFileManager::m_bikeDispParam
private

Definition at line 57 of file KartParamFileManager.hh.

◆ m_driverParam

FileInfo Kart::KartParamFileManager::m_driverParam
private

Definition at line 56 of file KartParamFileManager.hh.

◆ m_kartParam

FileInfo Kart::KartParamFileManager::m_kartParam
private

Definition at line 55 of file KartParamFileManager.hh.

◆ s_instance

KartParamFileManager * Kart::KartParamFileManager::s_instance = nullptr
staticprivate

Definition at line 59 of file KartParamFileManager.hh.