UFOpaedia script interpreter. More...
#include "../cl_shared.h"
#include "../cl_inventory.h"
#include "../ui/ui_main.h"
#include "../ui/ui_icon.h"
#include "../../shared/parse.h"
#include "cp_campaign.h"
#include "cp_mapfightequip.h"
#include "cp_time.h"
Go to the source code of this file.
Defines | |
#define | MAX_UPTEXT 4096 |
#define | MAIL_LENGTH 256 |
#define | MAIL_BUFFER_SIZE 0x4000 |
#define | CHECK_MAIL_EOL if (tempBuf[MAIL_LENGTH-3] != '\n') tempBuf[MAIL_LENGTH-2] = '\n'; |
#define | MAIL_CLIENT_LINES 15 |
Enumerations | |
enum | { UFOPEDIA_CHAPTERS, UFOPEDIA_INDEX, UFOPEDIA_ARTICLE, UFOPEDIA_DISPLAYEND } |
Functions | |
static qboolean | UP_TechGetsDisplayed (const technology_t *tech) |
Checks If a technology/UFOpaedia-entry will be displayed in the UFOpaedia (-list). | |
static void | UP_ChangeDisplay (int newDisplay) |
Modify the global display var. | |
static const char * | CL_AircraftStatToName (int stat) |
Translate a aircraft statistic integer to a translated string. | |
static const char * | CL_AircraftSizeToName (int aircraftSize) |
Translate a aircraft size integer to a translated string. | |
static void | UP_DisplayTechTree (const technology_t *t) |
Displays the tech tree dependencies in the UFOpaedia. | |
static void | UP_BuildingDescription (const technology_t *t) |
Prints the UFOpaedia description for buildings. | |
void | UP_AircraftItemDescription (const objDef_t *item) |
Prints the (UFOpaedia and other) description for aircraft items. | |
void | UP_AircraftDescription (const technology_t *tech) |
Prints the UFOpaedia description for aircraft. | |
void | UP_UGVDescription (const ugv_t *ugvType) |
Prints the description for robots/ugvs. | |
int | UP_GetUnreadMails (void) |
Sets the amount of unread/new mails. | |
static void | UP_SetMailHeader (technology_t *tech, techMailType_t type, eventMail_t *mail) |
Binds the mail header (if needed) to the mn.menuText array. | |
static void | UP_DrawAssociatedAmmo (const technology_t *tech) |
Set the ammo model to display to selected ammo (only for a reloadable weapon). | |
static void | UP_Article (technology_t *tech, eventMail_t *mail) |
Display only the TEXT_UFOPEDIA part for a given technology. | |
void | UP_OpenEventMail (const char *eventMailID) |
static void | UP_OpenMailWith (const char *techID) |
Opens the mail view from everywhere with the entry given through name. | |
void | UP_OpenWith (const char *techID) |
Opens the UFOpaedia from everywhere with the entry given through name. | |
void | UP_OpenCopyWith (const char *techID) |
Opens the UFOpaedia with the entry given through name, not deleting copies. | |
static void | UP_FindEntry_f (void) |
Search and open the UFOpaedia with given id. | |
static uiNode_t * | UP_GenerateArticlesSummary (pediaChapter_t *parentChapter) |
Generate a list of options for all allowed articles of a chapter. | |
static void | UP_GenerateSummary (void) |
Generate a tree of option for all allowed chapters and articles. | |
static void | UP_Content_f (void) |
Displays the chapters in the UFOpaedia. | |
static void | UP_Click_f (void) |
Callback when we click on the ufopedia summary. | |
static void | UP_TechTreeClick_f (void) |
static void | UP_Update_f (void) |
Redraw the UFOpaedia article. | |
static void | UP_MailClientClick_f (void) |
Mailclient click function callback. | |
static void | UP_ResearchedLinkClick_f (void) |
Change UFOpaedia article when clicking on the name of associated ammo or weapon. | |
static void | UP_SetMailButtons_f (void) |
Set up mail icons. | |
static void | UP_OpenMail_f (void) |
Start the mailclient. | |
static void | UP_SetAllMailsRead_f (void) |
Marks all mails read in mailclient. | |
void | UP_InitStartup (void) |
void | UP_Shutdown (void) |
void | UP_ParseChapters (const char *name, const char **text) |
Parse the UFOpaedia chapters from scripts. | |
Variables | |
static cvar_t * | mn_uppretext |
static cvar_t * | mn_uppreavailable |
static pediaChapter_t * | upChaptersDisplayList [MAX_PEDIACHAPTERS] |
static int | numChaptersDisplayList |
static technology_t * | upCurrentTech |
static pediaChapter_t * | currentChapter |
static char | upBuffer [MAX_UPTEXT] |
static char | mailBuffer [MAIL_BUFFER_SIZE] |
static int | upDisplay = UFOPEDIA_CHAPTERS |
UFOpaedia script interpreter.
Split the mail code into cl_mailclient.c/h
Remove direct access to nodes
Definition in file cp_ufopedia.c.
#define CHECK_MAIL_EOL if (tempBuf[MAIL_LENGTH-3] != '\n') tempBuf[MAIL_LENGTH-2] = '\n'; |
Definition at line 52 of file cp_ufopedia.c.
Referenced by UP_OpenMail_f().
#define MAIL_BUFFER_SIZE 0x4000 |
Definition at line 50 of file cp_ufopedia.c.
#define MAIL_CLIENT_LINES 15 |
Definition at line 53 of file cp_ufopedia.c.
Referenced by UP_SetMailButtons_f().
#define MAIL_LENGTH 256 |
Definition at line 49 of file cp_ufopedia.c.
Referenced by UP_OpenMail_f().
#define MAX_UPTEXT 4096 |
Definition at line 46 of file cp_ufopedia.c.
anonymous enum |
Definition at line 59 of file cp_ufopedia.c.
static const char* CL_AircraftSizeToName | ( | int | aircraftSize | ) | [static] |
Translate a aircraft size integer to a translated string.
Definition at line 166 of file cp_ufopedia.c.
References _, AIRCRAFT_LARGE, and AIRCRAFT_SMALL.
Referenced by UP_AircraftDescription().
static const char* CL_AircraftStatToName | ( | int | stat | ) | [static] |
Translate a aircraft statistic integer to a translated string.
Definition at line 138 of file cp_ufopedia.c.
References _, AIR_STATS_ACCURACY, AIR_STATS_DAMAGE, AIR_STATS_ECM, AIR_STATS_FUELSIZE, AIR_STATS_MAXSPEED, AIR_STATS_SHIELD, AIR_STATS_SPEED, and AIR_STATS_WRANGE.
Referenced by UP_AircraftDescription(), and UP_AircraftItemDescription().
void UP_AircraftDescription | ( | const technology_t * | tech | ) |
Prints the UFOpaedia description for aircraft.
Definition at line 323 of file cp_ufopedia.c.
References _, AIR_GetAircraft(), AIR_GetOperationRange(), AIR_IsUFO, AIR_STATS_ACCURACY, AIR_STATS_FUELSIZE, AIR_STATS_MAX, AIR_STATS_MAXSPEED, AIR_STATS_SPEED, CL_AircraftMenuStatsValues(), CL_AircraftSizeToName(), CL_AircraftStatToName(), Com_sprintf(), Cvar_Set(), i, INV_ItemDescription(), aircraft_s::maxTeamSize, technology_s::provides, Q_strcat(), RS_Collected_(), RS_IsResearched_ptr(), aircraft_s::size, aircraft_s::stats, TEXT_ITEMDESCRIPTION, UI_RegisterText(), UP_DisplayTechTree(), upBuffer, and va().
Referenced by BS_MarketAircraftDescription(), and UP_Article().
void UP_AircraftItemDescription | ( | const objDef_t * | item | ) |
Prints the (UFOpaedia and other) description for aircraft items.
item | The object definition of the item |
Definition at line 248 of file cp_ufopedia.c.
References _, AC_ITEM_AMMO, AC_ITEM_WEAPON, AII_GetItemWeightBySize(), AII_WeightToName(), AIR_STATS_MAX, AIR_STATS_WRANGE, objDef_s::ammo, CL_AircraftMenuStatsValues(), CL_AircraftStatToName(), objDef_s::craftitem, Cvar_Set(), i, objDef_s::id, INV_ItemDescription(), technology_s::mdl, technology_s::name, Q_strcat(), RS_GetTechForItem(), RS_IsResearched_ptr(), craftitem_s::stats, TEXT_ITEMDESCRIPTION, craftitem_s::type, UI_RegisterText(), UI_ResetData(), va(), craftitem_s::weaponDamage, and craftitem_s::weaponDelay.
Referenced by AIM_UpdateItemDescription(), BDEF_SelectItem_f(), BS_BuyType(), BS_MarketClick_f(), and UP_Article().
static void UP_Article | ( | technology_t * | tech, | |
eventMail_t * | ||||
) | [static] |
Display only the TEXT_UFOPEDIA part for a given technology.
[in] | tech | The technology_t pointer to print the UFOpaedia article for |
[in] | The mail parameters in case we produce a mail |
Definition at line 567 of file cp_ufopedia.c.
References _, eventMail_s::body, Com_Error(), Com_GetUGVByIDSilent(), csi, Cvar_Set(), Cvar_SetValue(), technology_s::description, ERR_DROP, i, objDef_s::id, technology_s::image, cvar_s::integer, INV_ItemDescription(), INVSH_GetItemByID(), INVSH_GetItemByIDX(), technology_s::mdl, technology_s::name, descriptions_s::numDescriptions, csi_s::numODs, technology_s::preDescription, technology_s::provides, RS_ARMOUR, RS_BUILDING, RS_Collected_(), RS_CRAFT, RS_CRAFTITEM, RS_GetDescription(), RS_IsResearched_ptr(), RS_TECH, RS_UGV, RS_WEAPON, technology_s::statusResearchable, TECHMAIL_PRE, TECHMAIL_RESEARCHED, TEXT_UFOPEDIA, TEXT_UFOPEDIA_REQUIREMENT, technology_s::type, UFOPEDIA_ARTICLE, UFOPEDIA_CHAPTERS, UFOPEDIA_INDEX, UI_ExecuteConfunc(), UI_RegisterText(), UI_ResetData(), UP_AircraftDescription(), UP_AircraftItemDescription(), UP_BuildingDescription(), UP_ChangeDisplay(), UP_DisplayTechTree(), UP_DrawAssociatedAmmo(), UP_SetMailHeader(), UP_UGVDescription(), technology_s::upChapter, upDisplay, and va().
Referenced by UP_Click_f(), UP_FindEntry_f(), UP_OpenEventMail(), and UP_Update_f().
static void UP_BuildingDescription | ( | const technology_t * | t | ) | [static] |
Prints the UFOpaedia description for buildings.
Definition at line 222 of file cp_ufopedia.c.
References _, B_GetBuildingTemplate(), building_s::buildTime, Com_sprintf(), Cvar_Set(), building_s::dependsBuilding, building_s::fixCosts, building_s::name, ngettext, technology_s::provides, Q_strcat(), TEXT_ITEMDESCRIPTION, UI_RegisterText(), UP_DisplayTechTree(), upBuffer, va(), and building_s::varCosts.
Referenced by UP_Article().
static void UP_ChangeDisplay | ( | int | newDisplay | ) | [static] |
Modify the global display var.
Definition at line 95 of file cp_ufopedia.c.
References _, Com_Printf(), Cvar_Set(), Cvar_SetValue(), TEXT_ITEMDESCRIPTION, TEXT_UFOPEDIA, TEXT_UFOPEDIA_MAIL, TEXT_UFOPEDIA_MAILHEADER, TEXT_UFOPEDIA_REQUIREMENT, UFOPEDIA_ARTICLE, UFOPEDIA_CHAPTERS, UFOPEDIA_INDEX, UI_ExecuteConfunc(), UI_ResetData(), and upDisplay.
Referenced by UP_Article(), UP_Click_f(), and UP_Content_f().
static void UP_Click_f | ( | void | ) | [static] |
Callback when we click on the ufopedia summary.
Definition at line 849 of file cp_ufopedia.c.
References ccs, Cmd_Argc(), Cmd_Argv(), ccs_s::numTechnologies, ccs_s::technologies, UFOPEDIA_CHAPTERS, UI_ExecuteConfunc(), UP_Article(), and UP_ChangeDisplay().
Referenced by UP_InitStartup().
static void UP_Content_f | ( | void | ) | [static] |
Displays the chapters in the UFOpaedia.
Definition at line 838 of file cp_ufopedia.c.
References UFOPEDIA_CHAPTERS, UP_ChangeDisplay(), and UP_GenerateSummary().
Referenced by UP_InitStartup().
static void UP_DisplayTechTree | ( | const technology_t * | t | ) | [static] |
Displays the tech tree dependencies in the UFOpaedia.
Add support for "requireAND"
re-iterate trough logic blocks (i.e. append the tech-names it references recursively)
Only display tech if it is ok to do so.
Definition at line 184 of file cp_ufopedia.c.
References _, Com_Error(), Cvar_Set(), ERR_DROP, i, requirement_s::id, requirement_s::link, requirements_s::links, LIST_AddString(), technology_s::name, requirements_s::numLinks, technology_s::requireAND, RS_LINK_TECH, TEXT_UFOPEDIA_REQUIREMENT, requirement_s::type, UI_RegisterLinkedListText(), and UP_TechGetsDisplayed().
Referenced by UP_AircraftDescription(), UP_Article(), and UP_BuildingDescription().
static void UP_DrawAssociatedAmmo | ( | const technology_t * | tech | ) | [static] |
Set the ammo model to display to selected ammo (only for a reloadable weapon).
tech | technology_t pointer for the weapon's tech |
Definition at line 551 of file cp_ufopedia.c.
References objDef_s::ammos, Cvar_Set(), INVSH_GetItemByID(), technology_s::mdl, objDef_s::numAmmos, technology_s::provides, and RS_GetTechForItem().
Referenced by UP_Article().
static void UP_FindEntry_f | ( | void | ) | [static] |
Search and open the UFOpaedia with given id.
Definition at line 737 of file cp_ufopedia.c.
References Cmd_Argc(), Cmd_Argv(), Com_DPrintf(), Com_Printf(), DEBUG_CLIENT, id, technology_s::redirect, RS_GetTechByID(), and UP_Article().
Referenced by UP_InitStartup().
static uiNode_t* UP_GenerateArticlesSummary | ( | pediaChapter_t * | parentChapter | ) | [static] |
Generate a list of options for all allowed articles of a chapter.
[in] | parentChapter | requested chapter |
Definition at line 773 of file cp_ufopedia.c.
References pediaChapter_s::first, technology_s::idx, technology_s::name, UI_AddOption(), UI_SortOptions(), UP_TechGetsDisplayed(), technology_s::upNext, and va().
Referenced by UP_GenerateSummary().
static void UP_GenerateSummary | ( | void | ) | [static] |
Generate a tree of option for all allowed chapters and articles.
Definition at line 795 of file cp_ufopedia.c.
References _, ccs, Com_Error(), Cvar_Set(), ERR_DROP, pediaChapter_s::first, uiNode_s::firstChild, i, pediaChapter_s::id, MAX_PEDIACHAPTERS, pediaChapter_s::name, ccs_s::numChapters, numChaptersDisplayList, OPTION_UFOPEDIA, OPTIONEXTRADATA, qfalse, qtrue, UI_AddOption(), UI_GetIconByName(), UI_RegisterOption(), UP_GenerateArticlesSummary(), UP_TechGetsDisplayed(), ccs_s::upChapters, technology_s::upNext, and va().
Referenced by UP_Content_f().
int UP_GetUnreadMails | ( | void | ) |
Sets the amount of unread/new mails.
Definition at line 414 of file cp_ufopedia.c.
References ccs, cp_messageStack, Cvar_Set(), message_s::eventMail, techMail_s::from, m, technology_s::mail, MSG_EVENT, MSG_NEWS, MSG_RESEARCH_FINISHED, MSG_RESEARCH_PROPOSAL, message_s::next, ccs_s::numUnreadMails, message_s::pedia, eventMail_s::read, techMail_s::read, RS_IsResearched_ptr(), TECHMAIL_PRE, TECHMAIL_RESEARCHED, message_s::type, and va().
Referenced by CL_CampaignRun().
void UP_InitStartup | ( | void | ) |
Definition at line 1220 of file cp_ufopedia.c.
References Cmd_AddCommand(), Cvar_Get(), Cvar_Set(), UP_Click_f(), UP_Content_f(), UP_FindEntry_f(), UP_MailClientClick_f(), UP_OpenMail_f(), UP_ResearchedLinkClick_f(), UP_SetAllMailsRead_f(), UP_SetMailButtons_f(), UP_TechTreeClick_f(), and UP_Update_f().
Referenced by CP_InitStartup().
static void UP_MailClientClick_f | ( | void | ) | [static] |
Mailclient click function callback.
Definition at line 925 of file cp_ufopedia.c.
References Cmd_Argc(), Cmd_Argv(), cp_messageStack, Cvar_SetValue(), message_s::eventMail, techMail_s::from, eventMail_s::id, technology_s::id, m, technology_s::mail, MSG_EVENT, MSG_NEWS, MSG_RESEARCH_FINISHED, MSG_RESEARCH_PROPOSAL, message_s::next, message_s::pedia, TECHMAIL_PRE, TECHMAIL_RESEARCHED, message_s::type, UP_OpenEventMail(), and UP_OpenMailWith().
Referenced by UP_InitStartup().
void UP_OpenCopyWith | ( | const char * | techID | ) |
Opens the UFOpaedia with the entry given through name, not deleting copies.
techID | UFOpaedia entry id (technology script id) |
Definition at line 727 of file cp_ufopedia.c.
References Cbuf_AddText(), Cmd_ExecuteString(), and va().
Referenced by RS_ShowPedia_f().
void UP_OpenEventMail | ( | const char * | eventMailID | ) |
Definition at line 683 of file cp_ufopedia.c.
References CL_GetEventMail(), qfalse, UI_PushWindow(), and UP_Article().
Referenced by UP_MailClientClick_f().
static void UP_OpenMail_f | ( | void | ) | [static] |
Start the mailclient.
Definition at line 1090 of file cp_ufopedia.c.
References _, CHECK_MAIL_EOL, CL_DateConvertLong(), Com_sprintf(), cp_messageStack, eventMail_s::date, Date_GetMonthName(), dateLong_s::day, message_s::eventMail, eventMail_s::from, techMail_s::from, m, technology_s::mail, MAIL_LENGTH, mailBuffer, dateLong_s::month, MSG_EVENT, MSG_NEWS, MSG_RESEARCH_FINISHED, MSG_RESEARCH_PROPOSAL, message_s::next, message_s::pedia, technology_s::preResearchedDate, Q_strcat(), eventMail_s::read, techMail_s::read, technology_s::researchedDate, eventMail_s::subject, techMail_s::subject, TECHMAIL_PRE, TECHMAIL_RESEARCHED, TEXT_UFOPEDIA_MAIL, message_s::type, UI_RegisterText(), UP_SetMailButtons_f(), and dateLong_s::year.
Referenced by UP_InitStartup(), and UP_SetAllMailsRead_f().
static void UP_OpenMailWith | ( | const char * | techID | ) | [static] |
Opens the mail view from everywhere with the entry given through name.
techID | mail entry id (technology script id) |
Definition at line 699 of file cp_ufopedia.c.
References Cbuf_AddText(), UI_PushWindow(), and va().
Referenced by UP_MailClientClick_f().
void UP_OpenWith | ( | const char * | techID | ) |
Opens the UFOpaedia from everywhere with the entry given through name.
techID | UFOpaedia entry id (technology script id) |
Definition at line 713 of file cp_ufopedia.c.
References Cbuf_AddText(), UI_PushWindow(), and va().
Referenced by AC_OpenUFOpedia_f(), B_BuildingInfoClick_f(), B_BuildingOpenAfterClick(), BS_MarketInfoClick_f(), PR_ProductionListRightClick_f(), UP_ResearchedLinkClick_f(), and UP_TechTreeClick_f().
void UP_ParseChapters | ( | const char * | name, | |
const char ** | text | |||
) |
Parse the UFOpaedia chapters from scripts.
[in] | name | Chapter ID |
[in] | text | Text for chapter ID |
Definition at line 1269 of file cp_ufopedia.c.
References ccs, Com_EParse(), Com_Parse(), Com_Printf(), cp_campaignPool, pediaChapter_s::id, pediaChapter_s::idx, MAX_PEDIACHAPTERS, Mem_PoolStrDup, pediaChapter_s::name, ccs_s::numChapters, and ccs_s::upChapters.
Referenced by CL_ParseScriptFirst().
static void UP_ResearchedLinkClick_f | ( | void | ) | [static] |
Change UFOpaedia article when clicking on the name of associated ammo or weapon.
Definition at line 984 of file cp_ufopedia.c.
References objDef_s::ammos, technology_s::id, INV_IsAmmo, INVSH_GetItemByID(), technology_s::provides, objDef_s::reload, RS_GetTechForItem(), UP_OpenWith(), UP_TechGetsDisplayed(), objDef_s::weapon, and objDef_s::weapons.
Referenced by UP_InitStartup().
static void UP_SetAllMailsRead_f | ( | void | ) | [static] |
Marks all mails read in mailclient.
Definition at line 1183 of file cp_ufopedia.c.
References ccs, cp_messageStack, Cvar_Set(), message_s::eventMail, m, technology_s::mail, MSG_EVENT, MSG_NEWS, MSG_RESEARCH_FINISHED, MSG_RESEARCH_PROPOSAL, message_s::next, ccs_s::numUnreadMails, message_s::pedia, qtrue, eventMail_s::read, techMail_s::read, TECHMAIL_PRE, TECHMAIL_RESEARCHED, message_s::type, UP_OpenMail_f(), and va().
Referenced by UP_InitStartup().
static void UP_SetMailButtons_f | ( | void | ) | [static] |
Set up mail icons.
UP_OpenMail_f
must be called before using this function - we need the mailClientListNode
pointer here Definition at line 1011 of file cp_ufopedia.c.
References Cmd_Argc(), Cmd_Argv(), Com_Printf(), cp_messageStack, Cvar_Set(), message_s::eventMail, eventMail_s::from, techMail_s::from, i, eventMail_s::icon, techMail_s::icon, m, technology_s::mail, MAIL_CLIENT_LINES, MSG_EVENT, MSG_NEWS, MSG_RESEARCH_FINISHED, MSG_RESEARCH_PROPOSAL, message_s::next, message_s::pedia, eventMail_s::read, techMail_s::read, TECHMAIL_PRE, TECHMAIL_RESEARCHED, message_s::type, and va().
Referenced by UP_InitStartup(), and UP_OpenMail_f().
static void UP_SetMailHeader | ( | technology_t * | tech, | |
techMailType_t | type, | |||
eventMail_t * | ||||
) | [static] |
Binds the mail header (if needed) to the mn.menuText array.
[in] | tech | The tech to generate a header for. |
[in] | type | The type of mail (research proposal or finished research) |
[in] | The mail descriptor structure |
Definition at line 468 of file cp_ufopedia.c.
References _, ccs, CL_DateConvertLong(), Com_Error(), Com_sprintf(), Cvar_Set(), techMail_s::date, eventMail_s::date, Date_GetMonthName(), dateLong_s::day, ERR_DROP, techMail_s::from, eventMail_s::from, technology_s::mail, MAX_VAR, techMail_s::model, eventMail_s::model, dateLong_s::month, technology_s::numTechMails, ccs_s::numUnreadMails, technology_s::preResearchedDate, Q_strncpyz(), qtrue, techMail_s::read, eventMail_s::read, technology_s::researchedDate, techMail_s::subject, eventMail_s::subject, TECHMAIL_MAX, TECHMAIL_PRE, TECHMAIL_RESEARCHED, TEXT_UFOPEDIA_MAILHEADER, techMail_s::to, eventMail_s::to, UI_RegisterText(), UI_ResetData(), va(), and dateLong_s::year.
Referenced by UP_Article().
void UP_Shutdown | ( | void | ) |
Definition at line 1243 of file cp_ufopedia.c.
References Cmd_RemoveCommand(), and Cvar_Delete().
Referenced by CP_RemoveCampaignCallbackCommands().
static qboolean UP_TechGetsDisplayed | ( | const technology_t * | tech | ) | [static] |
Checks If a technology/UFOpaedia-entry will be displayed in the UFOpaedia (-list).
UP_Article
Definition at line 75 of file cp_ufopedia.c.
References INVSH_GetItemByIDSilent(), objDef_s::isVirtual, descriptions_s::numDescriptions, technology_s::preDescription, technology_s::provides, qfalse, technology_s::redirect, RS_Collected_(), RS_IsResearched_ptr(), RS_LOGIC, technology_s::statusResearchable, and technology_s::type.
Referenced by UP_DisplayTechTree(), UP_GenerateArticlesSummary(), UP_GenerateSummary(), and UP_ResearchedLinkClick_f().
static void UP_TechTreeClick_f | ( | void | ) | [static] |
Definition at line 876 of file cp_ufopedia.c.
References Cmd_Argc(), Cmd_Argv(), Com_Error(), ERR_DROP, i, technology_s::id, requirement_s::id, requirement_s::link, requirements_s::links, requirements_s::numLinks, technology_s::requireAND, RS_LINK_TECH, RS_LINK_TECH_NOT, requirement_s::type, UP_OpenWith(), and technology_s::upChapter.
Referenced by UP_InitStartup().
void UP_UGVDescription | ( | const ugv_t * | ugvType | ) |
Prints the description for robots/ugvs.
[in] | ugvType | What type of robot/ugv to print the description for. |
Definition at line 379 of file cp_ufopedia.c.
References _, Com_sprintf(), Cvar_Set(), ugv_s::id, INV_ItemDescription(), technology_s::name, technology_s::provides, RS_Collected_(), RS_GetTechByProvided(), RS_IsResearched_ptr(), TEXT_ITEMDESCRIPTION, UI_RegisterText(), and ugv_s::weapon.
static void UP_Update_f | ( | void | ) | [static] |
Redraw the UFOpaedia article.
Definition at line 915 of file cp_ufopedia.c.
References UP_Article().
Referenced by UP_InitStartup().
pediaChapter_t* currentChapter [static] |
Definition at line 44 of file cp_ufopedia.c.
char mailBuffer[MAIL_BUFFER_SIZE] [static] |
Definition at line 51 of file cp_ufopedia.c.
Referenced by UP_OpenMail_f().
cvar_t* mn_uppreavailable [static] |
Definition at line 38 of file cp_ufopedia.c.
cvar_t* mn_uppretext [static] |
Definition at line 37 of file cp_ufopedia.c.
int numChaptersDisplayList [static] |
Definition at line 41 of file cp_ufopedia.c.
Referenced by UP_GenerateSummary().
char upBuffer[MAX_UPTEXT] [static] |
Definition at line 47 of file cp_ufopedia.c.
Referenced by UP_AircraftDescription(), and UP_BuildingDescription().
pediaChapter_t* upChaptersDisplayList[MAX_PEDIACHAPTERS] [static] |
Definition at line 40 of file cp_ufopedia.c.
technology_t* upCurrentTech [static] |
Definition at line 43 of file cp_ufopedia.c.
int upDisplay = UFOPEDIA_CHAPTERS [static] |
Definition at line 66 of file cp_ufopedia.c.
Referenced by UP_Article(), and UP_ChangeDisplay().