Loading...
Searching...
No Matches
CModManager Class Reference

This class handles the list of mods. More...

`#include <src/app/modman.h>`

## Public Member Functions

| CModManager (CApplication *app, CPathManager *pathManager)
void | FindMods ()
| Finds all the mods along with their metadata.
void | ReloadMods ()
| Applies the current configuration and reloads the application.
void | EnableMod (size_t i)
| Removes a mod from the list of loaded mods.
void | DisableMod (size_t i)
| Adds a mod to the list of loaded mods.
size_t | MoveUp (size_t i)
| Moves the selected mod up in the list so that it's loaded sooner than others, returns the new index.
size_t | MoveDown (size_t i)
| Moves the selected mod down in the list so that it's loaded later than others, returns the new index.
bool | Changes ()
| Checks if the list of currently used mods differs from the current configuration or there were changes made by the user.
void | SaveMods ()
| Saves the current configuration of mods to the config file.
size_t | CountMods () const
| Number of mods loaded.
const Mod & | GetMod (size_t i) const
| Returns the reference to the mod in given position.
const std::vector< Mod > & | GetMods () const
| Returns the list of mods.

## Detailed Description

This class handles the list of mods.

The order matters since the order in which files are loaded matters, because some files can be overwritten.

The changes in the list do not immediately apply.

## Member Function Documentation

## FindMods()

void CModManager::FindMods | ( |  | ) |

Finds all the mods along with their metadata.

## ReloadMods()

void CModManager::ReloadMods | ( |  | ) |

Applies the current configuration and reloads the application.

## EnableMod()

void CModManager::EnableMod | ( | size_t | i | ) |

Removes a mod from the list of loaded mods.

## DisableMod()

void CModManager::DisableMod | ( | size_t | i | ) |

Adds a mod to the list of loaded mods.

## MoveUp()

size_t CModManager::MoveUp | ( | size_t | i | ) |

Moves the selected mod up in the list so that it's loaded sooner than others, returns the new index.

## MoveDown()

size_t CModManager::MoveDown | ( | size_t | i | ) |

Moves the selected mod down in the list so that it's loaded later than others, returns the new index.

## Changes()

bool CModManager::Changes | ( |  | ) |

Checks if the list of currently used mods differs from the current configuration or there were changes made by the user.

## SaveMods()

void CModManager::SaveMods | ( |  | ) |

Saves the current configuration of mods to the config file.

## CountMods()

size_t CModManager::CountMods | ( |  | ) | const

Number of mods loaded.

## GetMod()

const Mod & CModManager::GetMod | ( | size_t | i | ) | const

Returns the reference to the mod in given position.

## GetMods()

const std::vector< Mod > & CModManager::GetMods | ( |  | ) | const

Returns the list of mods.

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

- src/app/modman.h
- src/app/modman.cpp