mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-12-16 15:31:30 +00:00
604b5ef673
should simplify scripting, since it means that meta fields can be treated (mostly) the same as normal fields. SVN r2242 (scripting)
31 lines
777 B
C++
31 lines
777 B
C++
|
|
class AWeaponPiece : public AInventory
|
|
{
|
|
DECLARE_CLASS (AWeaponPiece, AInventory)
|
|
HAS_OBJECT_POINTERS
|
|
protected:
|
|
bool PrivateShouldStay ();
|
|
public:
|
|
void Serialize (FArchive &arc);
|
|
bool TryPickup (AActor *&toucher);
|
|
bool ShouldStay ();
|
|
virtual const char *PickupMessage ();
|
|
virtual void PlayPickupSound (AActor *toucher);
|
|
|
|
int PieceValue;
|
|
PClassWeapon *WeaponClass;
|
|
TObjPtr<AWeapon> FullWeapon;
|
|
};
|
|
|
|
// an internal class to hold the information for player class independent weapon piece handling
|
|
// [BL] Needs to be available for SBarInfo to check weaponpieces
|
|
class AWeaponHolder : public AInventory
|
|
{
|
|
DECLARE_CLASS(AWeaponHolder, AInventory)
|
|
|
|
public:
|
|
int PieceMask;
|
|
const PClass * PieceWeapon;
|
|
|
|
void Serialize (FArchive &arc);
|
|
};
|