Library partially implemented (mouse support pending).

This commit is contained in:
Mari the Deer 2022-02-13 23:13:14 +01:00
commit d3725d855e
52 changed files with 1672 additions and 957 deletions

View file

@ -344,6 +344,7 @@ Class SWWMTradeHistory : Thinker
enum ELoreTab
{
LORE_ITEM,
LORE_ENEMY,
LORE_PEOPLE,
LORE_LORE // lol
};
@ -351,6 +352,7 @@ enum ELoreTab
Class SWWMLore
{
String tag, text, assoc;
TextureID img;
int tab;
bool read;
}
@ -524,6 +526,7 @@ Class SWWMLoreLibrary : Thinker
if ( ttab ~== "People" ) e.tab = LORE_PEOPLE;
else if ( ttab ~== "Lore" ) e.tab = LORE_LORE;
else if ( ttab ~== "Item" ) e.tab = LORE_ITEM;
else if ( ttab ~== "Enemy" ) e.tab = LORE_ENEMY;
else
{
Console.Printf("Entry \"%s\" has an incorrect tab setting of \"%s\".",ref,ttab);
@ -537,6 +540,8 @@ Class SWWMLoreLibrary : Thinker
}
e.assoc = "$"..assoc;
e.read = false;
// image for certain entries
e.img = TexMan.CheckForTexture("graphics/KBase/PFP_"..ref..".png",TexMan.Type_Any);
// "new lore" message
if ( (level.maptime > 0) && (gametic > lastaddtic) && (myplayer == players[consoleplayer]) && (!menuactive || (menuactive == Menu.OnNoPause)) && (myplayer.mo is 'Demolitionist') )
Console.Printf(StringTable.Localize("$SWWM_NEWLORE"));