So I still vaguely believe that the music for a scene (if constant eg briefing music) is stored in the dat file (Bri.dat file 0), where the debrief music is stored may be more complicated
I've been looking at the medals.
MEDAL0.IF2 reads as follows:
;/*---------------*/
; MEDAL0.INF
;/*---------------*/
; DONOT REMAKE!
;/*---------------*/
#00 ;
16 11 -1
0
#01 ;
6 0 -1
J13 02,J15 06,
$M5
1
1
1
;(SUN)
;(HONOR)
#02 ;
6 0 -1
J14 08,
2
#03 ;
6 0 -1
3
#04 ;
6 0 -1
4
#05 ;
6 0 -1
5
#06 ;
6 0 -1
J13 08,
6
#07 ;
6 0 -1
7
#08 ;
6 0 -1
$S13
8
9
10
11
12
13
14
15
16
17
18
19
20
#09 ;
6 0 -1
$A30
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
#10 ;
7 0 -1
J13 11,J15 12,
$M3
51
52
53
#11 ;
7 0 -1
J14 13,
54
#12 ;
7 0 -1
J13 13,
55
#13 ;
84 0 12
56
#14 ;
93 9 13
57
#15 ;
8 11 -1
58
#16
-2
%
Now the audio files run as follows (number then content, ** indicates a variable over several files, either a system name, a medal name or a rank):
1 For meritorious conduct in confronting the Kilrathi enemy
2 In consideration of his valorous service to humanity
3 Leading the forces of the confederation against the empire of kilrah
4 Taking a decisive role in the Vega sector campaign
5 and commanding the squadron which accomplished the pivotal victory
6 For bravely sacrificing his vessel and endangering his life
7 In combat with the Kilrathi Enemy
8-20 System Names (In the ** system)
21-26 Bronze Star (The Terran Confederation is proud to present the ** to ** Hotshot)
27-32 Silver Star
33-38 Gold Star
39-44 Golden Sun
45-50 Terran Confederation Medal of Honour
51-53 Your courage is exemplorary of the Confederation's Finest Defenders
54 History shall number you among the greatest heroes of Humanity
55 Your Devotion to the Confederation honours all Humanity.
56 Good job, Hotshot. Congratulations.
57 Thankyou Sir.
58 Filled with Pride you meet the applause of your fellows.
Next, listening to the 5 medal speeches (medal, system earnt, file markers called, i've used 8 to mean any system in the 8-20 block, same with the medals but have specified the medal, just not the rank):
Bronze Star (Gimle) 1,8,21,51,56,57,58
Silver Star (Kurasawa) 1,8,27,51,56,57,58
Gold Star (Dakota) 1,8,33,51,56,57,58
Golden Sun (Venice) 6,7,8,39,55,56,57,58
Medal of Honour (Venice) 2,3,4,5,8,45,54,56,57,58
Okay so I believe that J13 (for instance) is a logic if clause, i.e.
J13 02 means if J13 is true then go to #02 in the file (simple enough right?)
meanwhile $M, $S13 $A30 etc are strings to identify - not sure, system/series and medal/rank being won respectively. I'm not sure about $M3 and $M5 because $M5 is only used at the beginning AFTER the choice has been made that this is a bronze/silver/gold star. $M3 is even more bizarre, as it (again) only applies for the 3 star type medals but basically precedes 3 file markers (51-53), all of which contain the same speech (identical speech!)
Oh and those J13, J14 etc logic gates - they determine the type of medal being won:
j13 is the medal of honour
j14 is normal medals
j15 is the golden sun
Anyway, that means we can break down the medal file into a nice simple basic style code (for the sake of argument im assuming $S13 is a 13 value array ranging from 0-12 - I dont have any reason to believe this, but it makes little difference and suits this example):
0 Play file 0
1 if (j13 goto 2)
if (j15 goto 6)
$M5
Play file 1
2 if (j14 goto 8)
Play file 2
3 Play file 3
4 Play file 4
5 Play file 5
6 if (j13 goto 8)
Play file 6
7 Play file 7
8 Play file 8+$13 //Select Series
9 Play file 21+$A30 //Select Medal and Rank
10 if (j13 goto 11)
if (j15 goto 12)
Play file 51+$m3
11 if (j14 goto 13)
Play file 54
12 if (j13 goto 13)
Play file 55
13 Play file 56
14 Play file 57
15 Play file 58
16 End
Sorry about the stupidly long post - but hopefully this isn't basic stuff to everyone
(if it is, please tell me i'm a moron !)
Edit: In the FUNE_PC4.IF2 - the funeral for series 8,10,11,13 the $R6 is a string to tell the game which rank you have and thus which intro (we are gathered here...) to play - so the $M markers must be a string to indicate which medal is being won. Since we have $M3 AND $M5 I suggest that $M3 is simply the first 3 values of $M5 and indicates the 3 star medals, and values 4 and 5 indicate the sun and planet (though not necessarily in that order, since the j values refer to planet, stars, sun).