I suspect I posted most of this stuff previously, but to answer Claymation's question about what we can do now (and in the very near future)
OK, I'll make a few comments about what is available for putting sound into the battlescape.
Please note, this is just my current thoughts and what we've got at the moment. Which isn't much.
Enough digression. What we've got is that each item in item.xml that can appear on the battlescape can have a startSound attribute. e.g.
<item id="ITEM_PISTOL" name="Pistol" xsi:type="rangedWeaponItemType" score="0">
<storage type="STORAGE_GEAR" units="1" />
<price buy="800" sell="600" />
<carryInfo xSize="1" ySize="2" mass="5" equipable="true" spriteTop="0" spriteLeft="1" />
<graphics model="Weapons\Xcorps\pistol" x="0.0" y="0.0" z="180.0"/>
<throw percentage="0.25" />
<shoot percentage="0.18" name="ACTION_SNAP_SHOT" accuracy="0.6" range="35.0" startSound=""/>
<shoot percentage="0.30" name="ACTION_AIMED_SHOT" accuracy="0.78" range="35.0" startSound=""/>
Note, at current time, none of the entries in item.xml have been given a value for startSound. (In fact none of them even have declared the attribute.) This is because there were no sounds. (Or, at least, I didn't know where they were.)
The idea was, when the action started (e.g. A weapon was fired) the sound would be play. This would allow a weapon to have multiple sounds, but only one for each firing type. e.g. One sound for a snap shot, and another for an aimed shot. If the shot actually hit something, then the combatant that got hit would give an appropriate sound.
These other sounds would be attached to each combatant. So we needed to build a list of the sounds that each combatant would make. This has not been implemented, again, because I didn't know of any sounds. However, it should not be difficult idea is add a sound element to each combatant. The simplest implementation would be a sound element, with an attribute for each type of sound. e.g.
I should add, I haven't tested the code to play start sounds and the only actions that have been connected up are the shoot actions.
The issues I see is that I haven't allowed for "miss" sounds. Actually, it's potentially a bit more complicated. I think the general solution may be that actions may require not only aa start sound, but possibly a failure sound. Might there be others? Also, there's a desire to have pick sounds from a set. (e.g. Have a number of "aimed shot" sounds, and pick at random between them.) This probably isn't too difficult to handle. Replace the attribute with an element and put a list of sounds into it. Things become more complicated if we want to select the alternate sounds due to other conditions. e.g. A different miss sounds depending on what the missed shot finally impacted on. This is may get even more complicated if we consider the difference between missing with a rocket, and missing with a bullet.
A final comment about different sounds for the bullet ricochet, depending on the material struck, or the material walked on. At the current time, the terrain model doesn't have that information. And it may be some time before it does.
The problem is programming team is mostly me, and I'm trying to do the bits that give the "most bang for my buck" (excuse the pun) in terms of game play. And things like the multiple sounds, well, I think they're pretty far down this list. http://www.xcomufo.c...h...2028636&hl=
(Note, priorities on list are open for negotiation. For example, if you need stuff to continue with what you're doing, then obviously it's going to be a priority for me.)
Saving the world from the scum of the universe is hard work. Especially when you have to create the scum to begin with.