February 28, 20242 yr Is it possible to replace the "VOICE:Microsoft Catherine" in the macro: <Macro Name="C208B">VOICE:Microsoft Catherine) (VOICERATE:0) (VOICEVOLUME:15) (SPEAK</Macro> with a string variable? To produce something like this: <Macro Name="C208B">VOICE:(L:Voice, String)) (VOICERATE:0) (VOICEVOLUME:15) (SPEAK</Macro> So that "Microsoft Catherine" (>L:Voice, String) would set it up.
February 28, 20242 yr Commercial Member AAO (MSFS) manual, page 67, chapter about "RPN Macros": Quote You can also use LVars as macros, AAO will replace the „@variablename“ with the actual value: 2·(>L:engnum) (A:ENG·COMBUSTION:@engnum,·Bool) => (A:ENG·COMBUSTION:2,·Bool) In your case <Macro·Name="C208B">VOICE:@voice)·(VOICERATE:0)·(VOICEVOLUME:15)·(SPEAK</Macro> 'Microsoft·Catherine'·(>L:voice,·String) (@C208B:Test) Edited February 28, 20242 yr by Lorby_SI LORBY-SI
February 28, 20242 yr Author Thank you so much - I guess I missed that paragraph. Another quickie: when you issue a (CHECKLIST:xxx) command, does that work like a 'call' or a 'goto'? In other words, is there a return from a (CHECKLIST:xxx) command?
February 28, 20242 yr Commercial Member 1 hour ago, The Artful Dodger said: Thank you so much - I guess I missed that paragraph. Another quickie: when you issue a (CHECKLIST:xxx) command, does that work like a 'call' or a 'goto'? In other words, is there a return from a (CHECKLIST:xxx) command? I'm sorry, but I don't understand the question. All AAO scripting is asynchronous, the command doesn't block processing. While the checklist is running, you can call a thousand other scripts, script files or CONVERSATIONs and they will execute in parallel. How would a checklist "return" to where exactly? Edited February 28, 20242 yr by Lorby_SI LORBY-SI
February 28, 20242 yr Author Statement A . . (CHECKLIST:My_Checklist.txt) Statement B I execute My_Checklist.txt but once My_Checklist is complete, does it now execute Statement B (effectively a call) or is Statement effectively dead (effectively a GOTO)? Edited February 28, 20242 yr by The Artful Dodger
February 28, 20242 yr Commercial Member 19 minutes ago, The Artful Dodger said: Statement A . . (CHECKLIST:My_Checklist.txt) Statement B I execute My_Checklist.txt but once My_Checklist is complete, does it now execute Statement B (effectively a call) or is Statement effectively dead (effectively a GOTO)? No, that is not how this works. As I tried to explain above, everything is asynchronous. Statement B will be executed immediately, regardless of what the checklist is doing or not doing. The only way for a sequence like you want would be a CONVERSATION where you call the checklist and the checklist then sets an LVar at the end and Statements B would use [] to wait for that change. But it would be much more simple to just call Statement B at the end of the checklist file... Edited February 28, 20242 yr by Lorby_SI LORBY-SI
February 28, 20242 yr Author I was afraid that was the case. So, if I don't want Statement B to execute I would have to say: (CHECKLIST:My_Checklist.txt) (GOTO Somewhere_else) Statement B Is that how to prevent B from executing?
February 28, 20242 yr Commercial Member 7 minutes ago, The Artful Dodger said: I was afraid that was the case. So, if I don't want Statement B to execute I would have to say: (CHECKLIST:My_Checklist.txt) (GOTO Somewhere_else) Statement B Is that how to prevent B from executing? What is the point of this exercise? Why add Statement B at all when it is not supposed to be executed anyway? The GOTO will also not wait for the CHECKLIST, it will be executed immediately (and jump over Statement B) As mentioned before, what you want to do is a job for the CONVERSATION feature. With a little effort you should be able to impelemt the desired control flow. Edited February 28, 20242 yr by Lorby_SI LORBY-SI
Archived
This topic is now archived and is closed to further replies.