mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-24 21:21:04 +00:00
- same for the ambient sound
# Conflicts: # src/s_advsound.cpp
This commit is contained in:
parent
36f0ab2ea1
commit
0fa92d59e2
1 changed files with 7 additions and 2 deletions
|
@ -2256,7 +2256,12 @@ DEFINE_ACTION_FUNCTION(AAmbientSound, Tick)
|
|||
|
||||
self->Tick();
|
||||
|
||||
if (!self->special2 || level.maptime < self->special1)
|
||||
if (self->special1 > 0)
|
||||
{
|
||||
if (--self->special1 > 0) return 0;
|
||||
}
|
||||
|
||||
if (!self->special2)
|
||||
return 0;
|
||||
|
||||
FAmbientSound *ambient;
|
||||
|
@ -2351,7 +2356,7 @@ DEFINE_ACTION_FUNCTION(AAmbientSound, Activate)
|
|||
amb->periodmin = ::Scale(S_GetMSLength(sndnum), TICRATE, 1000);
|
||||
}
|
||||
|
||||
self->special1 = level.maptime;
|
||||
self->special1 = 0;
|
||||
if (amb->type & (RANDOM|PERIODIC))
|
||||
self->special1 += GetTicker (amb);
|
||||
|
||||
|
|
Loading…
Reference in a new issue