I need some help in coding
I want to improve the graphics on cockpit with some buttons.
Buttons especially for TMC on/off - Mute and OverViewMode
Functions are working and the new buttons are shown in cockpit, but I cannot disable them via settings menü. Settings for on/off are available but do not do anything. Buttons are always visiable in Cockpit.
Any hint for me?
Use PAL version - no skin as fare default skin
Spoiler: Orignal morco_button.ui
Spoiler: Orignal morco_button.lua
Spoiler: Orignal morco_button.css
Here is my code.
Spoiler: My morco_button.ui
Spoiler: My morco_button.lua
Spoiler: Pictures
I need the code for PAL. I've tried to use the code in this ux as template, but do not work for me. Ux for LUNA do not work for me in PAL. Have tried it...
Last edited by userninenine; 12th July 2020 at 10:31 AM.
OK. Sometimes it can give direction, inspiration or an idea to...
Any progress about removing the white camera background?
Last edited by kwbs; 12th July 2020 at 10:50 AM.
All fine mate. Thx.
This code makes me grazy, because I get it running for LUNA but not for my PAL, which I like more...
If I fixes this I will check your request
The code can be less complicated for pal,
here is the code for the Overview mode, You can use the same format for the TMC on/off & mute.
This will give you a button that will look like the ones in your picture & have on/off control.
ui
------
luaCode:Please Login or Register to see the links
-------
false or true, what ever you prefer.Code:Please Login or Register to see the links
***************************************
The mute button code below is for Luna & not required for pal so can be deleted
change in the ui fromCode:Please Login or Register to see the links
toCode:Please Login or Register to see the links
Code:Please Login or Register to see the links
Last edited by morco; 12th July 2020 at 08:22 PM.
@ userninenine
I've been having a little play with this .
Here is an alternative method that you could use.
Example below, again, for the automatic overview -
**ui**
Code:Please Login or Register to see the links
**lua**
**css**Code:Please Login or Register to see the links
* this can be made into a working UX*Code:Please Login or Register to see the links
Last edited by morco; 13th July 2020 at 05:29 PM. Reason: removed some unrequired code
Thx mate, but non of them worked for me. With this modification - i prefer your first solution - PAL crashes all the time. Think I miss something.
What do I have to change in section <modify ui_Cockpit> - Red color?
Code:Please Login or Register to see the links
The code you have in red is not needed so can be deleted
here is my complete 'TEST' UX button that I changed to give the buttons like you want .
Hope this helps
This post requires you to click the "LIKE this post" button and hit F5 to read this content.
for adding your tmc on/off button I would do something like this
**ui**
add thisand thisCode:Please Login or Register to see the links
then **lua**Code:Please Login or Register to see the links
add this
Code:Please Login or Register to see the links
* i have used - %lua.showtmc - for visibility
* i'm assuming you have these images in your UX - ico_TMCon.svg & ico_TMCoff.svg
Last edited by morco; 13th July 2020 at 06:22 PM. Reason: added extra info
Bookmarks