MSI is a complicated system. I fact overcomplicated.
The fact that it runs as "mesiexec.exe+setup.msi" but not as "setup.exe+setup.msi" indicates that there is nothing wrong with the actual msi. And the change in the msi behavior at runtime can only be explained by the differences in the used msi hosting model. For example in case of EmbeddeUI scenario MSI runtime completely ignores InstallUISequence and any actions scheduled for this sequence will not be executed. This is the nature of the MSI architecture. You may also experience problems with custom/standard actions that require elevation if your host (setup.exe) is not elevated.
Thus for all practical reasons you probably better off by just doing your LaunchCondition evaluation directly in your host application (setup.exe) at startup. After all it's just reading a single registry value with C#.
The fact that it runs as "mesiexec.exe+setup.msi" but not as "setup.exe+setup.msi" indicates that there is nothing wrong with the actual msi. And the change in the msi behavior at runtime can only be explained by the differences in the used msi hosting model. For example in case of EmbeddeUI scenario MSI runtime completely ignores InstallUISequence and any actions scheduled for this sequence will not be executed. This is the nature of the MSI architecture. You may also experience problems with custom/standard actions that require elevation if your host (setup.exe) is not elevated.
Thus for all practical reasons you probably better off by just doing your LaunchCondition evaluation directly in your host application (setup.exe) at startup. After all it's just reading a single registry value with C#.