Jump to content
The simFlight Network Forums

Macro Questions


Recommended Posts

I put together a little Macro test file MacroTest.mcro that looks like this:

[Macros]

1=L:PITOT_L=SET,0
2=L:PITOT_R=SET,0
3=L:PITOT_L=SET,1
4=L:PITOT_R=SET,1

In the resultant FSUIPC6 Key Assignment dropdown list, the 0 and 1 SET values do not show up, so the dropdown has what looks like duplicate entries. That seems confusing, am I doing something wrong?  I had expected the actual SET values associated with each line in the Macro file to show up in the dropdown list to facilitate the key assignment process.  

For SET, the FSUIPC user manual says:

Set copies the parameter in the Macro invocation to the identified Lvar. Alternatively, a value can be given explicitly here, by “Set,n”.

It is not clear to me what is meant by "Macro invocation" -- is this referring to the Parameter field associated with the dropdown list? If you do have to enter the desired SET value in the Parameter field, what is the utility of using SET, n in the Macro file?

Thanks,

Al

 

 

 

 

 

Link to comment
Share on other sites

  • John Dowson changed the title to Macro Questions
4 hours ago, ark1320 said:

1=L:PITOT_L=SET,0
2=L:PITOT_R=SET,0
3=L:PITOT_L=SET,1
4=L:PITOT_R=SET,1

In the resultant FSUIPC6 Key Assignment dropdown list, the 0 and 1 SET values do not show up, so the dropdown has what looks like duplicate entries. That seems confusing, am I doing something wrong?

As the lvar name is the macro entry name, you should not have the same lvar more than once on a macro, especially if using the same action.

4 hours ago, ark1320 said:

I had expected the actual SET values associated with each line in the Macro file to show up in the dropdown list to facilitate the key assignment process.  

No, the set values have never appeared in the drop down list. Its usually just the name which should be sufficient for you to identify the action, but in the case of single lvar macros the action is also appended to the lvar name.

4 hours ago, ark1320 said:

Set copies the parameter in the Macro invocation to the identified Lvar. Alternatively, a value can be given explicitly here, by “Set,n”.

It is not clear to me what is meant by "Macro invocation" -- is this referring to the Parameter field associated with the dropdown list? If you do have to enter the desired SET value in the Parameter field, what is the utility of using SET, n in the Macro file?

"Macro invocation" just means when the macro is ran, so when you run the macro, the parameter is copied to the lvar (or, in other words, used to set the lvar). It refers to the parameter however it is supplied, in the macro file or in the assignment.
You can do things either way, but better to leave the parameter off in the macro file and just set the parameter in your assignment, i.e. just use:

[Macros]
1=L:PITOT_L=SET
2=L:PITOT_R=SET

- and you must do it this way if using the same lvar and action with different parameters, otherwise there is no way to distinguish the different entries.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use. Guidelines Privacy Policy We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.