Tiny tweaks.

This commit is contained in:
Mari the Deer 2021-01-05 17:01:44 +01:00
commit e85e01c496
4 changed files with 11 additions and 3 deletions

View file

@ -93,6 +93,10 @@ user int swwm_shadowdist = 2000; // max distance beyond which blob shadows are
server bool swwm_swapweapons = true; // [DLC1] allows carrying only one weapon in each slot (excluding starter melee and pistol)
user int swwm_forcestats = 0; // always shows level stats on the HUD, not just when the automap is open (2 - also show map name, otherwise only stats)
// TODO selection order array of weapons, for user tweaking
// if empty, use default selection order defined in zscript
user String swwm_weaponorder = "";
server noarchive bool swwm_iseriouslywanttoplaythiswithbd = false; // self-explanatory
// cross-session achievement cvars (0: locked, 1: unlocked, 2: notified)

View file

@ -1,2 +1,2 @@
[default]
SWWM_MODVER="\chSWWM \czGZ\c- \cw0.9.11b-pre r734 \cu(Tue 5 Jan 12:05:24 CET 2021)";
SWWM_MODVER="\chSWWM \czGZ\c- \cw0.9.11b-pre r735 \cu(Tue 5 Jan 17:01:44 CET 2021)";

View file

@ -2896,7 +2896,7 @@ Class SWWMHandler : EventHandler
S_StartSound("menu/buyinv",CHAN_ITEM,CHANF_UI);
S_StartSound("misc/ammo_pkup",CHAN_VOICE,CHANF_UI);
}
players[e.Args[0]].mo.GiveInventory("HammerspaceEmbiggener",16,true);
players[e.Args[0]].mo.GiveInventory("HammerspaceEmbiggener",8,true);
for ( Inventory i=players[e.Args[0]].mo.inv; i; i=i.inv )
{
if ( !(i is 'Ammo') ) continue;

View file

@ -812,7 +812,6 @@ Class DemolitionistMenu : GenericMenu
return true;
}
EventHandler.SendNetworkEvent(String.Format("swwmstoregive.%s",storelist[sel0].GetClassName()),consoleplayer,price,amt);
if ( (camt+amt) >= max ) ofs1 = sel0 = max(0,sel0-1);
MenuSound("menu/buyinv");
}
else if ( tabs[curtab] == TAB_LIBRARY )
@ -2141,6 +2140,8 @@ Class DemolitionistMenu : GenericMenu
}
else if ( tabs[curtab] == TAB_STORE )
{
Class<Inventory> lastsel = null;
if ( storelist.Size() > 0 ) lastsel = storelist[sel0];
storelist.Clear();
storeunits.Clear();
// price-sorted buyables
@ -2253,6 +2254,9 @@ Class DemolitionistMenu : GenericMenu
}
// re-sort by category
qsort_store(storelist,storeunits,0,storelist.Size()-1);
// shift back if the last selected item was removed
if ( lastsel && (storelist.Find(lastsel)) >= storelist.Size() )
sel0 = max(0,sel0-1);
// crop selection
if ( sel0 >= storelist.Size() ) sel0 = max(0,storelist.Size()-1);
}