Don't mind this.
This commit is contained in:
parent
5b2e2845c9
commit
de02cd22ff
2 changed files with 19 additions and 1 deletions
|
|
@ -1,2 +1,2 @@
|
|||
[default]
|
||||
SWWM_MODVER="\chSWWM \czGZ\c- \cw0.9.11b-pre r757 \cu(Fri 15 Jan 23:48:51 CET 2021)";
|
||||
SWWM_MODVER="\chSWWM \czGZ\c- \cw0.9.11b-pre r758 \cu(Sat 16 Jan 12:19:27 CET 2021)";
|
||||
|
|
|
|||
|
|
@ -1951,6 +1951,24 @@ Class Demolitionist : PlayerPawn
|
|||
}
|
||||
override void AddInventory( Inventory item )
|
||||
{
|
||||
// hackaround for replaced keys
|
||||
if ( item is 'Key' )
|
||||
{
|
||||
let rep = (Class<Inventory>)(GetReplacement(item.GetClass()));
|
||||
if ( rep && (item.GetClass() != rep) )
|
||||
{
|
||||
item.Destroy();
|
||||
// add the new key instead
|
||||
Actor whom = player?player.mo:PlayerPawn(self);
|
||||
if ( !whom.FindInventory(rep) )
|
||||
{
|
||||
let nk = Inventory(Spawn(rep));
|
||||
nk.AttachToOwner(whom);
|
||||
nk.Use(true);
|
||||
}
|
||||
return;
|
||||
}
|
||||
}
|
||||
Super.AddInventory(item);
|
||||
if ( !player ) return;
|
||||
if ( !bInDefaultInventory )
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue