mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-25 11:10:47 +00:00
CON: Add EVENT_RECOGSOUND.
Set RETURN to -1 to disable the sound played when an enemy awaken. You have to use a command to play a sound, because the bosses use globalsound. Patch from Fox. git-svn-id: https://svn.eduke32.com/eduke32@6517 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
102a720402
commit
1c107bd877
4 changed files with 6 additions and 0 deletions
|
@ -8123,6 +8123,9 @@ void A_PlayAlertSound(int spriteNum)
|
|||
{
|
||||
if (sprite[spriteNum].extra > 0)
|
||||
{
|
||||
if ((VM_OnEventWithReturn(EVENT_RECOGSOUND, spriteNum, myconnectindex, 0)) != 0)
|
||||
return;
|
||||
|
||||
switch (DYNAMICTILEMAP(PN(spriteNum)))
|
||||
{
|
||||
case LIZTROOPONTOILET__STATIC:
|
||||
|
|
|
@ -131,6 +131,7 @@ enum GameEvent_t {
|
|||
EVENT_DISPLAYROOMSEND,
|
||||
EVENT_DISPLAYEND,
|
||||
EVENT_OPENMENUSOUND,
|
||||
EVENT_RECOGSOUND,
|
||||
#ifdef LUNATIC
|
||||
EVENT_ANIMATEALLSPRITES,
|
||||
#endif
|
||||
|
|
|
@ -1557,6 +1557,7 @@ int A_Spawn(int spriteNum, int tileNum)
|
|||
if (sprite[spriteNum].picnum == RESPAWN)
|
||||
pActor->tempang = sprite[newSprite].pal = sprite[spriteNum].pal;
|
||||
|
||||
A_PlayAlertSound(newSprite);
|
||||
changespritestat(newSprite, STAT_ACTOR);
|
||||
}
|
||||
else
|
||||
|
|
|
@ -727,6 +727,7 @@ const char *EventNames[MAXEVENTS] =
|
|||
"EVENT_DISPLAYROOMSEND",
|
||||
"EVENT_DISPLAYEND",
|
||||
"EVENT_OPENMENUSOUND",
|
||||
"EVENT_RECOGSOUND",
|
||||
#ifdef LUNATIC
|
||||
"EVENT_ANIMATEALLSPRITES",
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue