Scotfleiger Posted December 10, 2021 Report Posted December 10, 2021 The FSUIPC LUA Sounds functions no longer work (found in FSUIPC6 6.1.6 with P3D v5.2 and v5.3). I have tried various test combinations to point functions sound.path and sound.play without success. The functions have long been used to play sounds for use with LINDA.
John Dowson Posted December 10, 2021 Report Posted December 10, 2021 Hi Andrew, yes, I have just tested this and found the same. Not sure what has happened, I will look into this over the weekend. John 1
John Dowson Posted December 11, 2021 Report Posted December 11, 2021 Hi Andrew, On 12/10/2021 at 12:39 PM, John Dowson said: yes, I have just tested this and found the same. Not sure what has happened, I will look into this over the weekend. Well, I just looked at this again and it is working for me now...the paths I had used previously weren't correct. I tested with the below script and heard all three sounds: Quote ipc.log("Playing bncrash2 from P3Dv5 Sound folder") sound.play("bncrash2") ipc.sleep(5000) ipc.log("Playing canopy closing from full path to my device 2") sound.path("D:\\Prepar3D v5 Add-ons\\FSUIPC6\\SoundFiles") sound.play("canopy_closing", 2) ipc.sleep(5000) ipc.log("Playing crash from SoundFiles folder located under P3Dv5 Sound folder") sound.path("SoundFiles") sound.play("crash_ground") ipc.log("Finished SoundTest") Could you adjust that script to use your local folders and sound files to see if you hear anything with that. Cheers, John
Scotfleiger Posted December 13, 2021 Author Report Posted December 13, 2021 On 12/11/2021 at 1:38 PM, John Dowson said: Could you adjust that script to use your local folders and sound files to see if you hear anything with that Sound.play now working thank you. How do I reference the current FSUIPC6 location? Is there an offset?
John Dowson Posted December 13, 2021 Report Posted December 13, 2021 1 hour ago, Scotfleiger said: Sound.play now working thank you. Ok, good - what was the issue? 1 hour ago, Scotfleiger said: How do I reference the current FSUIPC6 location? Is there an offset? There isn't an offset for this, but why do you need it? If you want to reference from the installation folder, use a relative file path.
Scotfleiger Posted December 13, 2021 Author Report Posted December 13, 2021 3 hours ago, John Dowson said: There isn't an offset for this, but why do you need it? If you want to reference from the installation folder, use a relative file path. The relative file path does not appear with to work with the sound.path function. It works with everything else. I have solved my problem by reading the current directory in my GUI and passing that to LUA to give an absolute address for FSUIPC via the sound.path function.
John Dowson Posted December 13, 2021 Report Posted December 13, 2021 1 minute ago, Scotfleiger said: The relative file path does not appear with to work with the sound.path function. It works with everything else. Yes, sorry, I was mistaken...as documented, relative paths are taken from the current default path, which will be the P3D sounds folder, and not the FSUIPC installation path - that is used in FSUIPC7, not FSUIPC6! 7 minutes ago, Scotfleiger said: I have solved my problem by reading the current directory in my GUI and passing that to LUA to give an absolute address for FSUIPC via the sound.path function. Ok. However, I think the installation folder location would be useful, I will look into adding it to an offset - I'm surprised its not already there.... John 1
Scotfleiger Posted December 13, 2021 Author Report Posted December 13, 2021 12 minutes ago, John Dowson said: I'm surprised its not already there.... Previously, FSUIPC was installed in the modules folder of the Flt Sim so they were one and the same. As you reminded me FSUIPC6 should now be in its own folder in a root directory.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now