Madcat lore.
This commit is contained in:
parent
7bf38fecfe
commit
7b30e1ebac
9 changed files with 674 additions and 3 deletions
|
|
@ -9,7 +9,11 @@ Class DemolitionistGameTab : DemolitionistMenuTab
|
|||
override DemolitionistMenuTab Init( DemolitionistMenu master )
|
||||
{
|
||||
title = StringTable.Localize("$SWWM_GAMETAB");
|
||||
gamelist.Push((Class<MadcatGame>)('MadcatGame')); // test
|
||||
for ( int i=0; i<AllClasses.Size(); i++ )
|
||||
{
|
||||
if ( AllClasses[i].isAbstract() || !(AllClasses[i] is 'MadcatGame') ) continue;
|
||||
gamelist.Push((Class<MadcatGame>)(AllClasses[i]));
|
||||
}
|
||||
bDirectInput = true;
|
||||
return Super.Init(master);
|
||||
}
|
||||
|
|
@ -23,6 +27,22 @@ Class DemolitionistGameTab : DemolitionistMenuTab
|
|||
override void OnSelect()
|
||||
{
|
||||
sel = master.shnd.menustate.At("LastGame").ToInt();
|
||||
// auto-add lore for kris
|
||||
let lore = SWWMLoreLibrary.Find(players[consoleplayer]);
|
||||
bool found = false;
|
||||
for ( int i=0; i<lore.ent.Size(); i++ )
|
||||
{
|
||||
if ( !(lore.ent[i].tag ~== "$SWWM_LORETAG_MADCAT") ) continue;
|
||||
found = true;
|
||||
break;
|
||||
}
|
||||
if ( !found )
|
||||
{
|
||||
EventHandler.SendNetworkEvent("swwmgamelore",consoleplayer);
|
||||
// notify
|
||||
master.tmsg = StringTable.Localize("$SWWM_NEWLORE");
|
||||
master.tmsgtic = gametic+70;
|
||||
}
|
||||
}
|
||||
override void OnDeselect()
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue