- Added the ACS commands
ReplaceTextures (str old_texture, str new_texture, optional bool not_lower,
optional bool not_mid, optional bool not_upper, optional bool not_floor,
optional bool not_ceiling); and
SectorDamage (int tag, int amount, str type, bool players_only, bool in_air,
str protection_item, bool subclasses_okay);
- Added the vid_nowidescreen cvar to disable widescreen aspect ratio
correction. When this is enabled, the only display ratio available is 4:3
(and 5:4 if vid_tft is set).
- Added support for setting an actor's damage property to an expression
through decorate. Just enclose it within parentheses, and the expression
will be evaluated exactly as-is without the normal Doom damage calculation.
So if you want something that does exactly 6 damage, use a "Damage (6)"
property. To deal normal Doom missile damage, you can use
"Damage (random(1,8)*6)" instead of "Damage 6".
- Moved InvFirst and InvSel into APlayerPawn so that they can be consistantly
maintained by ObtainInventory.
SVN r288 (trunk)
This commit is contained in:
parent
55e299e4b3
commit
b25c7722f3
30 changed files with 369 additions and 180 deletions
|
|
@ -217,8 +217,6 @@ player_s::player_s()
|
|||
oldbuttons(0),
|
||||
attackdown(0),
|
||||
health(0),
|
||||
InvFirst(0),
|
||||
InvSel(0),
|
||||
inventorytics(0),
|
||||
CurrentPlayerClass(0),
|
||||
pieces(0),
|
||||
|
|
@ -363,7 +361,12 @@ int player_t::GetSpawnClass()
|
|||
//
|
||||
//===========================================================================
|
||||
|
||||
IMPLEMENT_STATELESS_ACTOR (APlayerPawn, Any, -1, 0)
|
||||
IMPLEMENT_POINTY_CLASS (APlayerPawn)
|
||||
DECLARE_POINTER(InvFirst)
|
||||
DECLARE_POINTER(InvSel)
|
||||
END_POINTERS
|
||||
|
||||
BEGIN_STATELESS_DEFAULTS (APlayerPawn, Any, -1, 0)
|
||||
PROP_SpawnHealth (100)
|
||||
PROP_RadiusFixed (16)
|
||||
PROP_HeightFixed (56)
|
||||
|
|
@ -394,7 +397,9 @@ void APlayerPawn::Serialize (FArchive &arc)
|
|||
<< ForwardMove2
|
||||
<< SideMove1
|
||||
<< SideMove2
|
||||
<< ScoreIcon;
|
||||
<< ScoreIcon
|
||||
<< InvFirst
|
||||
<< InvSel;
|
||||
}
|
||||
|
||||
//===========================================================================
|
||||
|
|
@ -478,9 +483,9 @@ void APlayerPawn::AddInventory (AInventory *item)
|
|||
Super::AddInventory (item);
|
||||
|
||||
// If nothing is selected, select this item.
|
||||
if (player != NULL && player->InvSel == NULL && (item->ItemFlags & IF_INVBAR))
|
||||
if (InvSel == NULL && (item->ItemFlags & IF_INVBAR))
|
||||
{
|
||||
player->InvSel = item;
|
||||
InvSel = item;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -501,20 +506,20 @@ void APlayerPawn::RemoveInventory (AInventory *item)
|
|||
// item, if there is one, or the previous item.
|
||||
if (player != NULL)
|
||||
{
|
||||
if (player->InvSel == item)
|
||||
if (InvSel == item)
|
||||
{
|
||||
player->InvSel = item->NextInv ();
|
||||
if (player->InvSel == NULL)
|
||||
InvSel = item->NextInv ();
|
||||
if (InvSel == NULL)
|
||||
{
|
||||
player->InvSel = item->PrevInv ();
|
||||
InvSel = item->PrevInv ();
|
||||
}
|
||||
}
|
||||
if (player->InvFirst == item)
|
||||
if (InvFirst == item)
|
||||
{
|
||||
player->InvFirst = item->NextInv ();
|
||||
if (player->InvFirst == NULL)
|
||||
InvFirst = item->NextInv ();
|
||||
if (InvFirst == NULL)
|
||||
{
|
||||
player->InvFirst = item->PrevInv ();
|
||||
InvFirst = item->PrevInv ();
|
||||
}
|
||||
}
|
||||
if (item == player->PendingWeapon)
|
||||
|
|
@ -2087,7 +2092,6 @@ void player_s::Serialize (FArchive &arc)
|
|||
<< centering
|
||||
<< health
|
||||
<< inventorytics
|
||||
<< InvFirst << InvSel
|
||||
<< pieces
|
||||
<< backpack
|
||||
<< fragcount
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue