Delay dialogues until map title text disappears.
This commit is contained in:
parent
445e79c88c
commit
e023f70124
5 changed files with 16 additions and 6 deletions
|
|
@ -287,6 +287,7 @@ Class SWWMDirectMessage : HUDMessageBase
|
|||
SWWMDirectMessage nextmsg; // for chaining messages together from different characters
|
||||
bool nextdirect; // skips directly to next message without delays or fades
|
||||
Font mSmallFont;
|
||||
SWWMHandler hnd;
|
||||
|
||||
private int GetRandom()
|
||||
{
|
||||
|
|
@ -440,6 +441,9 @@ Class SWWMDirectMessage : HUDMessageBase
|
|||
{
|
||||
if ( seqnum < 0 )
|
||||
{
|
||||
// if there's a map message active, wait until it isn't
|
||||
if ( !hnd ) hnd = SWWMHandler(EventHandler.Find("SWWMHandler"));
|
||||
if ( hnd.mapmsg ) return false;
|
||||
delay--;
|
||||
if ( delay <= 0 )
|
||||
{
|
||||
|
|
@ -758,6 +762,9 @@ Class DSMapTitle : HUDMessageBase
|
|||
ch++;
|
||||
}
|
||||
if ( ch != 256 ) ThrowAbortException("sub font definition does not list all 256 glyphs");
|
||||
// this is for compat with the dialogues, and should not go into other mods
|
||||
let hnd = SWWMHandler(EventHandler.Find("SWWMHandler"));
|
||||
if ( hnd ) hnd.mapmsg = self;
|
||||
return self;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -40,6 +40,9 @@ Class SWWMHandler : EventHandler
|
|||
int prof_calls[8];
|
||||
double curms;
|
||||
|
||||
// to avoid some overlaps
|
||||
ui DSMapTitle mapmsg;
|
||||
|
||||
enum EProfileTimer
|
||||
{
|
||||
PT_WORLDTICK,
|
||||
|
|
|
|||
|
|
@ -134,8 +134,8 @@ Class SWWMBulletImpact : Actor
|
|||
let s = Spawn("SWWMChip",pos+x*2);
|
||||
s.vel = pvel;
|
||||
}
|
||||
if ( !Random[Junk](0,3) ) A_StartSound("bullet/ricochet",CHAN_VOICE,attenuation:2.5);
|
||||
else A_StartSound("bullet/hit",CHAN_VOICE,attenuation:3.0);
|
||||
if ( !Random[Junk](0,3) ) A_StartSound("bullet/ricochet",CHAN_VOICE);
|
||||
else A_StartSound("bullet/hit",CHAN_VOICE,attenuation:2.);
|
||||
Spawn("InvisibleSplasher",pos);
|
||||
}
|
||||
States
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ Class SpreadImpact : Actor
|
|||
override void PostBeginPlay()
|
||||
{
|
||||
Super.PostBeginPlay();
|
||||
A_StartSound("spreadgun/pellet",CHAN_VOICE,CHANF_DEFAULT,.4,4.);
|
||||
A_StartSound("spreadgun/pellet",CHAN_VOICE,CHANF_DEFAULT,.4,2.);
|
||||
A_SprayDecal("TinyPock",-20);
|
||||
int numpt = Random[Spreadgun](2,4)-special1;
|
||||
Vector3 x = SWWMUtility.Vec3FromAngles(angle,pitch);
|
||||
|
|
@ -83,7 +83,7 @@ Class SlugImpact : Actor
|
|||
override void PostBeginPlay()
|
||||
{
|
||||
Super.PostBeginPlay();
|
||||
A_StartSound("spreadgun/slug",CHAN_VOICE,CHANF_DEFAULT,1.,2.);
|
||||
A_StartSound("spreadgun/slug",CHAN_VOICE);
|
||||
A_SprayDecal("Pock",-20);
|
||||
int numpt = Random[Spreadgun](5,10)-special1;
|
||||
Vector3 x = SWWMUtility.Vec3FromAngles(angle,pitch);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue