fixing compiler warning, handle *SOUND_TO_OBJ events correctly in demo playback
This commit is contained in:
parent
9df975f7a7
commit
96418c210e
|
@ -1,5 +1,9 @@
|
|||
D1X-Rebirth Changelog
|
||||
|
||||
20070628
|
||||
--------
|
||||
main/game.c, main/newdemo.c: fixing compiler warning, handle *SOUND_TO_OBJ events correctly in demo playback
|
||||
|
||||
20070616
|
||||
--------
|
||||
main/newmenu.c: adjusted size of Inputbox
|
||||
|
|
|
@ -460,7 +460,7 @@ void HUD_clear_messages();
|
|||
|
||||
void toggle_cockpit()
|
||||
{
|
||||
int new_mode;
|
||||
int new_mode=CM_FULL_SCREEN;
|
||||
|
||||
switch (Cockpit_mode)
|
||||
{
|
||||
|
|
|
@ -184,6 +184,8 @@ sbyte playback_style;
|
|||
sbyte First_time_playback=1;
|
||||
fix JasonPlaybackTotal=0;
|
||||
|
||||
extern int digi_link_sound_to_object3( int org_soundnum, short objnum, int forever, fix max_volume, fix max_distance, int loop_start, int loop_end );
|
||||
|
||||
FILE *infile;
|
||||
FILE *outfile;
|
||||
|
||||
|
@ -2190,6 +2192,34 @@ int newdemo_read_frame_information()
|
|||
break;
|
||||
}
|
||||
|
||||
case ND_EVENT_LINK_SOUND_TO_OBJ:
|
||||
{
|
||||
int soundno, objnum, max_volume, max_distance, loop_start, loop_end;
|
||||
int signature;
|
||||
nd_read_int( &soundno );
|
||||
nd_read_int( &signature );
|
||||
nd_read_int( &max_volume );
|
||||
nd_read_int( &max_distance );
|
||||
nd_read_int( &loop_start );
|
||||
nd_read_int( &loop_end );
|
||||
objnum = newdemo_find_object( signature );
|
||||
if ( objnum > -1 ) { // @mk, 2/22/96, John told me to.
|
||||
digi_link_sound_to_object3( soundno, objnum, 1, max_volume, max_distance, loop_start, loop_end );
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
case ND_EVENT_KILL_SOUND_TO_OBJ:
|
||||
{
|
||||
int objnum, signature;
|
||||
nd_read_int( &signature );
|
||||
objnum = newdemo_find_object( signature );
|
||||
if ( objnum > -1 ) { // @mk, 2/22/96, John told me to.
|
||||
digi_kill_sound_linked_to_object(objnum);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
default:
|
||||
Int3();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue