![]() |
OpenXcom
1.0
Open-source clone of the original X-Com
|
Contains all the game-specific static data that never changes throughout the game, like rulesets and resources. More...
#include <Mod.h>
Public Member Functions | |
Mod () | |
Creates a blank mod. More... | |
~Mod () | |
Cleans up the mod. More... | |
const std::map< std::string, int > & | getUfopaediaSections () const |
For internal use only. | |
Font * | getFont (const std::string &name, bool error=true) const |
Gets a particular font. More... | |
Surface * | getSurface (const std::string &name, bool error=true) |
Gets a particular surface. More... | |
SurfaceSet * | getSurfaceSet (const std::string &name, bool error=true) |
Gets a particular surface set. More... | |
Music * | getMusic (const std::string &name, bool error=true) const |
Gets a particular music. More... | |
void | playMusic (const std::string &name, int id=0) |
Plays a particular music. More... | |
Sound * | getSound (const std::string &set, unsigned int sound, bool error=true) const |
Gets a particular sound. More... | |
Palette * | getPalette (const std::string &name, bool error=true) const |
Gets a particular palette. More... | |
void | setPalette (SDL_Color *colors, int firstcolor=0, int ncolors=256) |
Sets a new palette. More... | |
std::vector< Uint16 > * | getVoxelData () |
Gets list of voxel data. More... | |
Sound * | getSoundByDepth (unsigned int depth, unsigned int sound, bool error=true) const |
Returns a specific sound from either the land or underwater sound set. More... | |
const std::vector< std::vector< Uint8 > > * | getLUTs () const |
Gets list of LUT data. More... | |
int | getModOffset () const |
Gets the mod offset. More... | |
int | getSpriteOffset (int sprite, const std::string &set) const |
Gets the mod offset for a certain sprite. More... | |
int | getSoundOffset (int sound, const std::string &set) const |
Gets the mod offset for a certain sound. More... | |
int | getOffset (int id, int max) const |
Gets the mod offset for a generic value. More... | |
void | loadAll (const std::vector< std::pair< std::string, std::vector< std::string > > > &mods) |
Loads a list of mods. More... | |
SavedGame * | newSave () const |
Generates the starting saved game. More... | |
RuleCountry * | getCountry (const std::string &id, bool error=false) const |
Gets the ruleset for a country type. More... | |
const std::vector< std::string > & | getCountriesList () const |
Gets the available countries. More... | |
RuleRegion * | getRegion (const std::string &id, bool error=false) const |
Gets the ruleset for a region type. More... | |
const std::vector< std::string > & | getRegionsList () const |
Gets the available regions. More... | |
RuleBaseFacility * | getBaseFacility (const std::string &id, bool error=false) const |
Gets the ruleset for a facility type. More... | |
const std::vector< std::string > & | getBaseFacilitiesList () const |
Gets the available facilities. More... | |
RuleCraft * | getCraft (const std::string &id, bool error=false) const |
Gets the ruleset for a craft type. More... | |
const std::vector< std::string > & | getCraftsList () const |
Gets the available crafts. More... | |
RuleCraftWeapon * | getCraftWeapon (const std::string &id, bool error=false) const |
Gets the ruleset for a craft weapon type. More... | |
const std::vector< std::string > & | getCraftWeaponsList () const |
Gets the available craft weapons. More... | |
RuleItem * | getItem (const std::string &id, bool error=false) const |
Gets the ruleset for an item type. More... | |
const std::vector< std::string > & | getItemsList () const |
Gets the available items. More... | |
RuleUfo * | getUfo (const std::string &id, bool error=false) const |
Gets the ruleset for a UFO type. More... | |
const std::vector< std::string > & | getUfosList () const |
Gets the available UFOs. More... | |
RuleTerrain * | getTerrain (const std::string &name, bool error=false) const |
Gets terrains for battlescape games. More... | |
const std::vector< std::string > & | getTerrainList () const |
Gets the available terrains. More... | |
MapDataSet * | getMapDataSet (const std::string &name) |
Gets mapdatafile for battlescape games. More... | |
RuleSoldier * | getSoldier (const std::string &name, bool error=false) const |
Gets soldier unit rules. More... | |
const std::vector< std::string > & | getSoldiersList () const |
Gets the available soldiers. More... | |
RuleCommendations * | getCommendation (const std::string &id, bool error=false) const |
Gets commendation rules. More... | |
const std::map< std::string, RuleCommendations * > & | getCommendationsList () const |
Gets the available commendations. More... | |
Unit * | getUnit (const std::string &name, bool error=false) const |
Gets generated unit rules. More... | |
AlienRace * | getAlienRace (const std::string &name, bool error=false) const |
Gets alien race rules. More... | |
const std::vector< std::string > & | getAlienRacesList () const |
Gets the available alien races. More... | |
AlienDeployment * | getDeployment (const std::string &name, bool error=false) const |
Gets deployment rules. More... | |
const std::vector< std::string > & | getDeploymentsList () const |
Gets the available alien deployments. More... | |
Armor * | getArmor (const std::string &name, bool error=false) const |
Gets armor rules. More... | |
const std::vector< std::string > & | getArmorsList () const |
Gets the available armors. More... | |
ArticleDefinition * | getUfopaediaArticle (const std::string &name, bool error=false) const |
Gets Ufopaedia article definition. More... | |
const std::vector< std::string > & | getUfopaediaList () const |
Gets the available articles. More... | |
const std::vector< std::string > & | getUfopaediaCategoryList () const |
Gets the available article categories. More... | |
std::map< std::string, RuleInventory * > * | getInventories () |
Gets the inventory list. More... | |
RuleInventory * | getInventory (const std::string &id, bool error=false) const |
Gets the ruleset for a specific inventory. More... | |
int | getEngineerCost () const |
Gets the cost of an engineer. More... | |
int | getScientistCost () const |
Gets the cost of a scientist. More... | |
int | getPersonnelTime () const |
Gets the transfer time of personnel. More... | |
RuleResearch * | getResearch (const std::string &id, bool error=false) const |
Gets the ruleset for a specific research project. More... | |
const std::vector< std::string > & | getResearchList () const |
Gets the list of all research projects. More... | |
RuleManufacture * | getManufacture (const std::string &id, bool error=false) const |
Gets the ruleset for a specific manufacture project. More... | |
const std::vector< std::string > & | getManufactureList () const |
Gets the list of all manufacture projects. More... | |
std::vector< RuleBaseFacility * > | getCustomBaseFacilities () const |
Gets facilities for custom bases. More... | |
const UfoTrajectory * | getUfoTrajectory (const std::string &id, bool error=false) const |
Gets a specific UfoTrajectory. More... | |
const RuleAlienMission * | getAlienMission (const std::string &id, bool error=false) const |
Gets the ruleset for a specific alien mission. More... | |
const RuleAlienMission * | getRandomMission (MissionObjective objective, size_t monthsPassed) const |
Gets the ruleset for a random alien mission. More... | |
const std::vector< std::string > & | getAlienMissionList () const |
Gets the list of all alien missions. More... | |
const std::vector< std::vector< int > > & | getAlienItemLevels () const |
Gets the alien item level table. More... | |
const YAML::Node & | getStartingBase () const |
Gets the player starting base. More... | |
const GameTime & | getStartingTime () const |
Gets the game starting time. More... | |
MCDPatch * | getMCDPatch (const std::string &id) const |
Gets an MCDPatch. More... | |
const std::map< std::string, std::vector< ExtraSprites * > > & | getExtraSprites () const |
Gets the list of external Sprites. More... | |
const std::vector< std::pair< std::string, ExtraSounds * > > & | getExtraSounds () const |
Gets the list of external Sounds. More... | |
const std::map< std::string, ExtraStrings * > & | getExtraStrings () const |
Gets the list of external Strings. More... | |
const std::vector< StatString * > & | getStatStrings () const |
Gets the list of StatStrings. More... | |
const std::vector< std::string > & | getPsiRequirements () const |
Gets the research-requirements for Psi-Lab (it's a cache for psiStrengthEval) | |
const std::vector< std::string > & | getInvsList () const |
Returns the sorted list of inventories. More... | |
Soldier * | genSoldier (SavedGame *save, std::string type="") const |
Generates a new soldier. More... | |
std::string | getAlienFuelName () const |
Gets the item to be used as fuel for ships. More... | |
int | getAlienFuelQuantity () const |
Gets the amount of alien fuel to recover. More... | |
std::string | getFontName () const |
Gets the font name. More... | |
int | getTurnAIUseGrenade () const |
Gets first turn when AI can use grenade. | |
int | getTurnAIUseBlaster () const |
Gets first turn when AI can use Blaster launcher. | |
int | getMinRadarRange () const |
Gets the minimum radar's range. More... | |
RuleInterface * | getInterface (const std::string &id, bool error=true) const |
Gets information on an interface element. More... | |
RuleGlobe * | getGlobe () const |
Gets the ruleset for the globe. More... | |
RuleConverter * | getConverter () const |
Gets the ruleset for the converter. More... | |
const std::map< std::string, SoundDefinition * > * | getSoundDefinitions () const |
Gets the list of selective files for insertion into our cat files. | |
const std::vector< SDL_Color > * | getTransparencies () const |
Gets the list of transparency colors,. | |
RuleVideo * | getVideo (const std::string &id, bool error=false) const |
Gets a video for intro/outro etc. More... | |
int | getDefeatScore () const |
Returns the minimum amount of score the player can have, otherwise they are defeated. More... | |
int | getDefeatFunds () const |
Returns the minimum amount of funds the player can have, otherwise they are defeated. More... | |
Contains all the game-specific static data that never changes throughout the game, like rulesets and resources.
OpenXcom::Mod::Mod | ( | ) |
Creates a blank mod.
Creates an empty mod.
OpenXcom::Mod::~Mod | ( | ) |
Cleans up the mod.
Deletes all the mod data from memory.
Generates a new soldier.
Creates a new randomly-generated soldier.
save | Saved game the soldier belongs to. |
type | The soldier type to generate. |
std::string OpenXcom::Mod::getAlienFuelName | ( | ) | const |
Gets the item to be used as fuel for ships.
Gets the name of the item to be used as alien fuel.
int OpenXcom::Mod::getAlienFuelQuantity | ( | ) | const |
Gets the amount of alien fuel to recover.
const std::vector< std::vector< int > > & OpenXcom::Mod::getAlienItemLevels | ( | ) | const |
Gets the alien item level table.
const RuleAlienMission * OpenXcom::Mod::getAlienMission | ( | const std::string & | id, |
bool | error = false |
||
) | const |
Gets the ruleset for a specific alien mission.
Returns the rules for the specified alien mission.
id | Alien mission type. |
const std::vector< std::string > & OpenXcom::Mod::getAlienMissionList | ( | ) | const |
Gets the list of all alien missions.
Returns the list of alien mission types.
AlienRace * OpenXcom::Mod::getAlienRace | ( | const std::string & | name, |
bool | error = false |
||
) | const |
Gets alien race rules.
Returns the info about a specific alien race.
name | Race name. |
const std::vector< std::string > & OpenXcom::Mod::getAlienRacesList | ( | ) | const |
Gets the available alien races.
Returns the list of all alien races.
provided by the mod.
Armor * OpenXcom::Mod::getArmor | ( | const std::string & | name, |
bool | error = false |
||
) | const |
Gets armor rules.
Returns the info about a specific armor.
name | Armor name. |
const std::vector< std::string > & OpenXcom::Mod::getArmorsList | ( | ) | const |
Gets the available armors.
Returns the list of all armors provided by the mod.
const std::vector< std::string > & OpenXcom::Mod::getBaseFacilitiesList | ( | ) | const |
Gets the available facilities.
Returns the list of all base facilities provided by the mod.
RuleBaseFacility * OpenXcom::Mod::getBaseFacility | ( | const std::string & | id, |
bool | error = false |
||
) | const |
Gets the ruleset for a facility type.
Returns the rules for the specified base facility.
id | Facility type. |
RuleCommendations * OpenXcom::Mod::getCommendation | ( | const std::string & | id, |
bool | error = false |
||
) | const |
Gets commendation rules.
Returns the rules for the specified commendation.
id | Commendation type. |
const std::map< std::string, RuleCommendations * > & OpenXcom::Mod::getCommendationsList | ( | ) | const |
Gets the available commendations.
Gets the list of commendations provided by the mod.
RuleConverter * OpenXcom::Mod::getConverter | ( | ) | const |
Gets the ruleset for the converter.
Gets the rules for the Save Converter.
const std::vector< std::string > & OpenXcom::Mod::getCountriesList | ( | ) | const |
Gets the available countries.
Returns the list of all countries provided by the mod.
RuleCountry * OpenXcom::Mod::getCountry | ( | const std::string & | id, |
bool | error = false |
||
) | const |
Gets the ruleset for a country type.
Returns the rules for the specified country.
id | Country type. |
RuleCraft * OpenXcom::Mod::getCraft | ( | const std::string & | id, |
bool | error = false |
||
) | const |
Gets the ruleset for a craft type.
Returns the rules for the specified craft.
id | Craft type. |
const std::vector< std::string > & OpenXcom::Mod::getCraftsList | ( | ) | const |
Gets the available crafts.
Returns the list of all crafts provided by the mod.
RuleCraftWeapon * OpenXcom::Mod::getCraftWeapon | ( | const std::string & | id, |
bool | error = false |
||
) | const |
Gets the ruleset for a craft weapon type.
Returns the rules for the specified craft weapon.
id | Craft weapon type. |
const std::vector< std::string > & OpenXcom::Mod::getCraftWeaponsList | ( | ) | const |
Gets the available craft weapons.
Returns the list of all craft weapons provided by the mod.
std::vector< RuleBaseFacility * > OpenXcom::Mod::getCustomBaseFacilities | ( | ) | const |
Gets facilities for custom bases.
Generates and returns a list of facilities for custom bases.
The list contains all the facilities that are listed in the 'startingBase' part of the ruleset.
int OpenXcom::Mod::getDefeatFunds | ( | ) | const |
Returns the minimum amount of funds the player can have, otherwise they are defeated.
int OpenXcom::Mod::getDefeatScore | ( | ) | const |
Returns the minimum amount of score the player can have, otherwise they are defeated.
Changes based on difficulty.
AlienDeployment * OpenXcom::Mod::getDeployment | ( | const std::string & | name, |
bool | error = false |
||
) | const |
Gets deployment rules.
Returns the info about a specific deployment.
name | Deployment name. |
const std::vector< std::string > & OpenXcom::Mod::getDeploymentsList | ( | ) | const |
Gets the available alien deployments.
Returns the list of all alien deployments provided by the mod.
int OpenXcom::Mod::getEngineerCost | ( | ) | const |
Gets the cost of an engineer.
Returns the cost of an individual engineer for purchase/maintenance.
const std::vector< std::pair< std::string, ExtraSounds * > > & OpenXcom::Mod::getExtraSounds | ( | ) | const |
Gets the list of external Sounds.
Gets the list of external sounds.
const std::map< std::string, std::vector< ExtraSprites * > > & OpenXcom::Mod::getExtraSprites | ( | ) | const |
Gets the list of external Sprites.
Gets the list of external sprites.
const std::map< std::string, ExtraStrings * > & OpenXcom::Mod::getExtraStrings | ( | ) | const |
Gets the list of external Strings.
Gets the list of external strings.
Font * OpenXcom::Mod::getFont | ( | const std::string & | name, |
bool | error = true |
||
) | const |
Gets a particular font.
Returns a specific font from the mod.
name | Name of the font. |
std::string OpenXcom::Mod::getFontName | ( | ) | const |
Gets the font name.
Gets name of font collection.
RuleGlobe * OpenXcom::Mod::getGlobe | ( | ) | const |
Gets the ruleset for the globe.
Gets the rules for the Geoscape globe.
RuleInterface * OpenXcom::Mod::getInterface | ( | const std::string & | id, |
bool | error = true |
||
) | const |
Gets information on an interface element.
Gets information on an interface.
id | the interface we want info on. |
std::map< std::string, RuleInventory * > * OpenXcom::Mod::getInventories | ( | ) |
Gets the inventory list.
Returns the list of inventories.
RuleInventory * OpenXcom::Mod::getInventory | ( | const std::string & | id, |
bool | error = false |
||
) | const |
const std::vector< std::string > & OpenXcom::Mod::getInvsList | ( | ) | const |
Returns the sorted list of inventories.
Returns the list of inventories.
RuleItem * OpenXcom::Mod::getItem | ( | const std::string & | id, |
bool | error = false |
||
) | const |
Gets the ruleset for an item type.
Returns the rules for the specified item.
id | Item type. |
const std::vector< std::string > & OpenXcom::Mod::getItemsList | ( | ) | const |
Gets the available items.
Returns the list of all items provided by the mod.
const std::vector< std::vector< Uint8 > > * OpenXcom::Mod::getLUTs | ( | ) | const |
Gets list of LUT data.
Returns the list of color LUTs in the mod.
RuleManufacture * OpenXcom::Mod::getManufacture | ( | const std::string & | id, |
bool | error = false |
||
) | const |
Gets the ruleset for a specific manufacture project.
Returns the rules for the specified manufacture project.
id | Manufacture project type. |
const std::vector< std::string > & OpenXcom::Mod::getManufactureList | ( | ) | const |
Gets the list of all manufacture projects.
Returns the list of manufacture projects.
MapDataSet * OpenXcom::Mod::getMapDataSet | ( | const std::string & | name | ) |
Gets mapdatafile for battlescape games.
Returns the info about a specific map data file.
name | Datafile name. |
MCDPatch * OpenXcom::Mod::getMCDPatch | ( | const std::string & | id | ) | const |
int OpenXcom::Mod::getMinRadarRange | ( | ) | const |
Gets the minimum radar's range.
Returns the minimum facilitie's radar range.
int OpenXcom::Mod::getModOffset | ( | ) | const |
Music * OpenXcom::Mod::getMusic | ( | const std::string & | name, |
bool | error = true |
||
) | const |
Gets a particular music.
Returns a specific music from the mod.
name | Name of the music. |
int OpenXcom::Mod::getOffset | ( | int | id, |
int | max | ||
) | const |
Gets the mod offset for a generic value.
Returns the appropriate mod-based offset for a generic ID.
If the ID is bigger than the max, the mod offset is applied.
id | Numeric ID. |
max | Maximum vanilla value. |
Palette * OpenXcom::Mod::getPalette | ( | const std::string & | name, |
bool | error = true |
||
) | const |
Gets a particular palette.
Returns a specific palette from the mod.
name | Name of the palette. |
int OpenXcom::Mod::getPersonnelTime | ( | ) | const |
Gets the transfer time of personnel.
Returns the time it takes to transfer personnel between bases.
const RuleAlienMission * OpenXcom::Mod::getRandomMission | ( | MissionObjective | objective, |
size_t | monthsPassed | ||
) | const |
Gets the ruleset for a random alien mission.
Returns the rules for a random alien mission based on a specific objective.
objective | Alien mission objective. |
RuleRegion * OpenXcom::Mod::getRegion | ( | const std::string & | id, |
bool | error = false |
||
) | const |
Gets the ruleset for a region type.
Returns the rules for the specified region.
id | Region type. |
const std::vector< std::string > & OpenXcom::Mod::getRegionsList | ( | ) | const |
Gets the available regions.
Returns the list of all regions provided by the mod.
RuleResearch * OpenXcom::Mod::getResearch | ( | const std::string & | id, |
bool | error = false |
||
) | const |
Gets the ruleset for a specific research project.
Returns the rules for the specified research project.
id | Research project type. |
const std::vector< std::string > & OpenXcom::Mod::getResearchList | ( | ) | const |
Gets the list of all research projects.
Returns the list of research projects.
int OpenXcom::Mod::getScientistCost | ( | ) | const |
Gets the cost of a scientist.
Returns the cost of an individual scientist for purchase/maintenance.
RuleSoldier * OpenXcom::Mod::getSoldier | ( | const std::string & | name, |
bool | error = false |
||
) | const |
Gets soldier unit rules.
Returns the info about a specific unit.
name | Unit name. |
const std::vector< std::string > & OpenXcom::Mod::getSoldiersList | ( | ) | const |
Gets the available soldiers.
Returns the list of all soldiers provided by the mod.
Sound * OpenXcom::Mod::getSound | ( | const std::string & | set, |
unsigned int | sound, | ||
bool | error = true |
||
) | const |
Gets a particular sound.
Returns a specific sound from the mod.
set | Name of the sound set. |
sound | ID of the sound. |
Sound * OpenXcom::Mod::getSoundByDepth | ( | unsigned int | depth, |
unsigned int | sound, | ||
bool | error = true |
||
) | const |
Returns a specific sound from either the land or underwater sound set.
depth | the depth of the battlescape. |
sound | ID of the sound. |
int OpenXcom::Mod::getSoundOffset | ( | int | sound, |
const std::string & | set | ||
) | const |
Gets the mod offset for a certain sound.
Returns the appropriate mod-based offset for a sound.
If the ID is bigger than the soundset contents, the mod offset is applied.
sound | Numeric ID of the sound. |
set | Name of the soundset to lookup. |
int OpenXcom::Mod::getSpriteOffset | ( | int | sprite, |
const std::string & | set | ||
) | const |
Gets the mod offset for a certain sprite.
Returns the appropriate mod-based offset for a sprite.
If the ID is bigger than the surfaceset contents, the mod offset is applied.
sprite | Numeric ID of the sprite. |
set | Name of the surfaceset to lookup. |
const YAML::Node & OpenXcom::Mod::getStartingBase | ( | ) | const |
Gets the player starting base.
Gets the defined starting base.
const GameTime & OpenXcom::Mod::getStartingTime | ( | ) | const |
Gets the game starting time.
Gets the defined starting time.
const std::vector< StatString * > & OpenXcom::Mod::getStatStrings | ( | ) | const |
Gets the list of StatStrings.
Surface * OpenXcom::Mod::getSurface | ( | const std::string & | name, |
bool | error = true |
||
) |
Gets a particular surface.
Returns a specific surface from the mod.
name | Name of the surface. |
SurfaceSet * OpenXcom::Mod::getSurfaceSet | ( | const std::string & | name, |
bool | error = true |
||
) |
Gets a particular surface set.
Returns a specific surface set from the mod.
name | Name of the surface set. |
RuleTerrain * OpenXcom::Mod::getTerrain | ( | const std::string & | name, |
bool | error = false |
||
) | const |
Gets terrains for battlescape games.
Returns the rules for the specified terrain.
name | Terrain name. |
const std::vector< std::string > & OpenXcom::Mod::getTerrainList | ( | ) | const |
Gets the available terrains.
Returns the list of all terrains provided by the mod.
RuleUfo * OpenXcom::Mod::getUfo | ( | const std::string & | id, |
bool | error = false |
||
) | const |
Gets the ruleset for a UFO type.
Returns the rules for the specified UFO.
id | UFO type. |
ArticleDefinition * OpenXcom::Mod::getUfopaediaArticle | ( | const std::string & | name, |
bool | error = false |
||
) | const |
Gets Ufopaedia article definition.
Returns the article definition for a given name.
name | Article name. |
const std::vector< std::string > & OpenXcom::Mod::getUfopaediaCategoryList | ( | ) | const |
Gets the available article categories.
Returns the list of all article categories provided by the mod.
const std::vector< std::string > & OpenXcom::Mod::getUfopaediaList | ( | ) | const |
Gets the available articles.
Returns the list of all articles provided by the mod.
const std::vector< std::string > & OpenXcom::Mod::getUfosList | ( | ) | const |
Gets the available UFOs.
Returns the list of all ufos provided by the mod.
const UfoTrajectory * OpenXcom::Mod::getUfoTrajectory | ( | const std::string & | id, |
bool | error = false |
||
) | const |
Gets a specific UfoTrajectory.
Returns the data for the specified ufo trajectory.
id | Ufo trajectory id. |
Unit * OpenXcom::Mod::getUnit | ( | const std::string & | name, |
bool | error = false |
||
) | const |
Gets generated unit rules.
Returns the info about a specific unit.
name | Unit name. |
RuleVideo * OpenXcom::Mod::getVideo | ( | const std::string & | id, |
bool | error = false |
||
) | const |
Gets a video for intro/outro etc.
Returns the data for the specified video cutscene.
id | Video id. |
std::vector< Uint16 > * OpenXcom::Mod::getVoxelData | ( | ) |
Gets list of voxel data.
Returns the list of voxeldata in the mod.
void OpenXcom::Mod::loadAll | ( | const std::vector< std::pair< std::string, std::vector< std::string > > > & | mods | ) |
Loads a list of mods.
Loads a list of mods specified in the options.
mods | List of <modId, rulesetFiles> pairs. |
SavedGame * OpenXcom::Mod::newSave | ( | ) | const |
Generates the starting saved game.
Generates a brand new saved game with starting data.
void OpenXcom::Mod::playMusic | ( | const std::string & | name, |
int | id = 0 |
||
) |
Plays a particular music.
Plays the specified track if it's not already playing.
name | Name of the music. |
id | Id of the music, 0 for random. |
void OpenXcom::Mod::setPalette | ( | SDL_Color * | colors, |
int | firstcolor = 0 , |
||
int | ncolors = 256 |
||
) |
Sets a new palette.
Changes the palette of all the graphics in the mod.
colors | Pointer to the set of colors. |
firstcolor | Offset of the first color to replace. |
ncolors | Amount of colors to replace. |