Hi Martin,mvanbrus wrote: ↑24 Jul 2018, 21:24Looking at the Prosim-door.lua it is saying:
Find "cargo" in the airplane's title and open the big door with TAB 5. This works with cargo planes.
open the Fwd cargo door of airplanes that do not have "cargo" in the name title. This does NOT work.
I removed the top part of FWD_Cargo_Door name search and now TAB 5 is opening the FWD cargo door of NON cargo airplanes. I can't figure out why your "else" is not working though.
Of course it works... You misunderstand the intention.
The TAB+5 in every case SHOULD open either the forward cargo-door OR the main cargo-door (if it's a cargo version).
After the "else" statement the difference is that a different SOUND is being played and that is the ONLY difference.
The cargo version is differentiated by using a different model (.mdl) file and has nothing to do with the lua file.
(In case the cargo plane is desired, there's the model=cargo in the aircraft.cfg file which by that calls the normal=ProSim737-800-2018-Cargo.mdl file from the model.cfg in the model.cargo folder).
Thus the "else" statement is working fine, you just didn't notice that the only difference is the sound-file... and the order the sounds play. With the passenger plane the sound plays after the animation takes place, whereas the cargo version starts playing the sound at the same time the animation is triggered. These are all in the main "else" statement.
But you were right and there was a small glitch in the cargo section, so I fixed that.
I don't want to return to the distributed original version, where there were no separate open and close sounds, so I also placed the new .wav files in the zip.