mirror of
https://github.com/ZDoom/qzdoom.git
synced 2025-02-17 17:41:23 +00:00
- fixed: Clearing a pickup message for inventory items was not possible. Changed it so that "You got a pickup" is AInventory's pickup message and not a default returned when nothing valid is set.
SVN r2625 (trunk)
This commit is contained in:
parent
56cc0569bb
commit
eb3340e872
3 changed files with 4 additions and 4 deletions
|
@ -890,7 +890,7 @@ void AInventory::Touch (AActor *toucher)
|
||||||
{
|
{
|
||||||
const char * message = PickupMessage ();
|
const char * message = PickupMessage ();
|
||||||
|
|
||||||
if (toucher->CheckLocalView (consoleplayer)
|
if (message != NULL && *message != 0 && toucher->CheckLocalView (consoleplayer)
|
||||||
&& (StaticLastMessageTic != gametic || StaticLastMessage != message))
|
&& (StaticLastMessageTic != gametic || StaticLastMessage != message))
|
||||||
{
|
{
|
||||||
StaticLastMessageTic = gametic;
|
StaticLastMessageTic = gametic;
|
||||||
|
@ -960,9 +960,7 @@ void AInventory::DoPickupSpecial (AActor *toucher)
|
||||||
|
|
||||||
const char *AInventory::PickupMessage ()
|
const char *AInventory::PickupMessage ()
|
||||||
{
|
{
|
||||||
const char *message = GetClass()->Meta.GetMetaString (AIMETA_PickupMessage);
|
return GetClass()->Meta.GetMetaString (AIMETA_PickupMessage);
|
||||||
|
|
||||||
return message != NULL? message : "You got a pickup";
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//===========================================================================
|
//===========================================================================
|
||||||
|
|
|
@ -5,6 +5,7 @@ ACTOR Inventory native
|
||||||
Inventory.InterHubAmount 1
|
Inventory.InterHubAmount 1
|
||||||
Inventory.UseSound "misc/invuse"
|
Inventory.UseSound "misc/invuse"
|
||||||
Inventory.PickupSound "misc/i_pkup"
|
Inventory.PickupSound "misc/i_pkup"
|
||||||
|
Inventory.PickupMessage "$TXT_DEFAULTPICKUPMSG"
|
||||||
|
|
||||||
action native A_JumpIfNoAmmo(state label);
|
action native A_JumpIfNoAmmo(state label);
|
||||||
action native A_CustomPunch(int damage, bool norandom = false, int flags = CPF_USEAMMO, class<Actor> pufftype = "BulletPuff", float range = 0, float lifesteal = 0);
|
action native A_CustomPunch(int damage, bool norandom = false, int flags = CPF_USEAMMO, class<Actor> pufftype = "BulletPuff", float range = 0, float lifesteal = 0);
|
||||||
|
|
|
@ -286,6 +286,7 @@ STSTR_CHOPPERS = "... doesn't suck - GM";
|
||||||
STSTR_CLEV = "Changing Level...\n";
|
STSTR_CLEV = "Changing Level...\n";
|
||||||
TXT_BUDDHAON = "Buddha mode ON";
|
TXT_BUDDHAON = "Buddha mode ON";
|
||||||
TXT_BUDDHAOFF = "Buddha mode OFF";
|
TXT_BUDDHAOFF = "Buddha mode OFF";
|
||||||
|
TXT_DEFAULTPICKUPMSG = "You got a pickup";
|
||||||
|
|
||||||
E1TEXT =
|
E1TEXT =
|
||||||
"Once you beat the big badasses and\n"
|
"Once you beat the big badasses and\n"
|
||||||
|
|
Loading…
Reference in a new issue