• Which the release of FS2020 we see an explosition of activity on the forun and of course we are very happy to see this. But having all questions about FS2020 in one forum becomes a bit messy. So therefore we would like to ask you all to use the following guidelines when posting your questions:

    • Tag FS2020 specific questions with the MSFS2020 tag.
    • Questions about making 3D assets can be posted in the 3D asset design forum. Either post them in the subforum of the modelling tool you use or in the general forum if they are general.
    • Questions about aircraft design can be posted in the Aircraft design forum
    • Questions about airport design can be posted in the FS2020 airport design forum. Once airport development tools have been updated for FS2020 you can post tool speciifc questions in the subforums of those tools as well of course.
    • Questions about terrain design can be posted in the FS2020 terrain design forum.
    • Questions about SimConnect can be posted in the SimConnect forum.

    Any other question that is not specific to an aspect of development or tool can be posted in the General chat forum.

    By following these guidelines we make sure that the forums remain easy to read for everybody and also that the right people can find your post to answer it.

XMLKEYS limitations??

Messages
85
Country
spain
Hi again!. I'm trying to map the keyboard and a joystick with XMLKEYS. It works fine
for the joystick and some keys, but the last key asignations in the code do not work.

I have made many tests. If I cut some assignations in the middle, the last do work.
I have divided the code in order to have each part exacuted at a clock time. And no
joy. This make me wonder if XMLKEYS is limited to a certain number of keys or to a
certain number of sentences.

¿Can somebody confirm this?
 

taguilo

Resource contributor
Messages
1,585
Country
argentina
Hi,
There's no limit on the number of keys.
Are you assigning all those keys in an <Update> or single <Element>? If so, you should check that your script is not bigger than ~ 50 Kb, otherwise the effect you noted is a typical symptom of that limitation.

Tom
 
Messages
85
Country
spain
Good morning, Tom. Thank you for your answer. I have to puntualize that I'm using XMLTOOLS for P3D v4.

What I have done, schematically is as follows:

Update section 1
joystick button assignation 1
joystick button assignation 2
..............
joystick button assignation 12
/Update section 1

Update section 2
key assignation 1
key assignation 2
/Update section 2

Update section 3
key assignation 3
key assignation 4
..............
key assignation 11
/Update section 3

Update section 4
key assignation 12
key assignation 13
key assignation 14
/Update section 4

With this code, assignations 11, 12, 13 and 14 do not work. But if I change the order and I put Update section 4 before Update section 3, then assignations 12, 13 and 14 do work
but assignations 8, 9, 10 and 11 do not work. This tells me the code of 12, 13 and 14 is correct. As an example, this is the code for assignation 13:

Code:
'u' (>C:XMLKEYS:KeyName,string)
'(L:nav source pilot, enum) 0 == (L:nav source pilot,enum) 2 == 0 1 (L:nav prv pilot, enum) rng &amp;&amp; || if{ (>K:VOR1_OBI_INC) }
 (L:nav source pilot, enum) 1 == (L:nav source pilot,enum) 2 == 2 3 (L:nav prv pilot, enum) rng &amp;&amp; || if{ (>K:VOR2_OBI_INC) }' (>C:XMLKEYS:KeyString,string)
(>C:XMLKEYS:KeyCaptureOn,bool)

Regarding the size of the code, I have to say that all the code is in a file which is 17.3 Kb long.

It's like if the system had not enought time to reach the last 4 assignments. But I have tried to run the update sections in different moments of time with a trigger variable and still
it does not work.
Just to illustrate it, if I do the following

moment1 --->Update section 1
moment2 --->Update section 2
moment3 --->Update section 4
moment4 --->Update section 3

I have the assignments in sections 1, 2 and 4 working but assignments in update section 3 don't work, regardless of the order in which the sections are written. I have also changed
update frequency to 2 with the same results. If I do this:

moment1 --->Update section 2
moment2 --->Update section 3
moment3 --->Update section 4
moment4 --->Update section 1

Then I have all the key assignments working but the last four joystick button assignments don't work (again, regardless of the order of the update sections in the code). I have tried even dividing the code into two different files or gauges with the same (bad) results.

I have tried with code shortening in all assignations and it does not make any change.

In sum, XMLKEYS for P3D v4 acts like if it had a limitation in assignments and once this limitation is reached, it does not accept more key/joystick assignations.

Sorry for this long post, but I think it is necessary to solve what could be an important flaw in XMLKEYS. Regards.
 
Last edited:

taguilo

Resource contributor
Messages
1,585
Country
argentina
Simple question: Are you coding XML with FS9 or FSX schema?


If FSX schema, try using different <Element> sections instead of <Update> ones.

Tom
 
Last edited:
Messages
85
Country
spain
Hi Tom. I always use FSX schema. And as I said:

- I have code of different update sections working.
- I have tried dividing the assignations in more than one gauge files obtaining the same results...
 

taguilo

Resource contributor
Messages
1,585
Country
argentina
I will check if there could be potential issues with the number of captures.
BTW, remember to avoid parsing the captures on each gauge´s cycle, do it only once at flight startup. You can follow the XMLKeys example for that.

Tom
 
Messages
85
Country
spain
Thank you again for your efforts. XMLTOOLS is an outstanding tool.
And... yes, that's the way I do it. I have good teachers here in fsdeveloper. :)
Regards.
 
Messages
85
Country
spain
Hi Tom. Sorry for my insistence. Did you have time to check the issue with the number of captures? :)
 
Messages
212
Country
unitedkingdom
Hi Tom. Sorry for my insistence. Did you have time to check the issue with the number of captures? :)
Hi palacio802, quick question . . . Have you got the original paint kit for the Heli? If not could you share your original PSD file or just the file you used to do your original paint work? I would like to do some hidef re paints for your heli.

P.s. amazing work by the way and sorry for the thread hijack!

Sent from my SM-G935F using Tapatalk
 
Messages
212
Country
unitedkingdom
Amazing thank you . . . It's like Santa has arrived early! Happy Xmas
P.s it's out. Hope you like it.
b1775973065fbc1552fc3df26ce41983.jpg
b303bc1022485dd3144816f01bb6af93.jpg
 
Top