-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathWallpaperService.bas
2655 lines (2277 loc) · 192 KB
/
WallpaperService.bas
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
B4A=true
Group=Default Group
ModulesStructureVersion=1
Type=Service
Version=7.3
@EndOfDesignText@
#Region Module Attributes
#StartAtBoot: False
#End Region
'Service module WIDTH refers to width of wallpaper, widthofscreen refers to the resolution of the actual display/screen/LCD
Sub Process_Globals
'These global variables will be declared once when the application starts.
'These variables can be accessed from all modules.
Dim lwm As LWManager,IsVisible As Boolean ', ExDraw As ABExtDrawing
Dim TempCurrentOffsetX As Int ,LastUpdate As Long,Delay As Int ,AllowPreview As Boolean, IsClean As Boolean
Dim msdWidth As Int, msdHeight As Int,msdY As Int, FramesPerSecond As Int ,OldPoint As Point ,AllowScrolling As Boolean ,OldY As Int, PreviewMode As Boolean ,DoIncrement As Boolean ,isInPmode As Boolean
Dim SettingsLoaded As Boolean ,CurrentSection As Int=-1, CurrentMSD As String, Settings As Map ,CurrentMode As String ,LastSec As Int, BigText As Int
Dim SamsungMode As Int ,SamsungCursorCount As Int, SamsungX As Int,SamsungY As Int ,SamsungX2 As Int,DDisrunning As Boolean ,SamsungTolerance As Int=100
'Type Cursor(Loc As Point, Element As Int, State As Int )
'Dim DebugString As StringBuilder, DebugPoints As Int, DebugDone As Boolean ,OldX As Int:OldX=-99999
Dim LCARelements As List, PhysicalWidth As Int ,PhysicalHeight As Int, VirtualWidth As Int ,X2 As Int ,TOP As Int, BOTTOM As Int ,DoScale As Boolean, SSM As Boolean ,LastX As Int
Dim MSDList As List,LCARGroups As List,GroupsEnabled As Boolean, NeedsRefresh As Boolean ,RefreshesLive As Boolean,CursorID As Int, CursorCount As Int'Cursors As List , 'Not Downloaded yet
Dim Landscape As Boolean
Dim MediaControls As Boolean =True,WasFromMainmenu As Boolean ,OmegaUnlock As String ,UseXinstead As Int, UseWidthinstead As Int ,NeedsReset As Boolean ,Darken As Int , TimeOut As Int' ,MouseState As Boolean
Dim ENTdata As List, ENTmode As Boolean, ENTbuttons As Int = 2, PCARframeID As Int = -1, LastColor As Int = -1, BridgePanels As Int = 5, AllowAlpha As Boolean, RNDindex As Int, SubScreenIndex As Int = -1
End Sub
Sub Refresh
lwm.StopTicking
lwm.StartTicking(1)
NeedsReset=True
NeedsRefresh=True
'Log("FORCED REFRESH NEEDED!")
End Sub
Sub ClearLCARS
LCARelements.Initialize
LCARGroups.Initialize
'Cursors.Initialize
ENTdata.Initialize
CursorID=-1
ENTmode=False
RNDindex=0
PCARframeID=-1
LastX=0
AllowAlpha=False
LCARSeffects2.ClearRandomNumbers
'MouseState = False
End Sub
Sub AddMiniButton(Qty As Int) As Int ', LastColor As Int ) As Int
Dim temp2 As Int' , LastColor As Int = -1
ENTmode=True
For temp2 = 1 To Qty
Dim temp As MiniButton '(Text As String, ColorID As Int)
temp.initialize
temp.ColorID = LastColor
Do Until temp.ColorID <> LastColor
temp.ColorID = LCARSeffects3.ENTcolor(-1)
Loop
temp.Text = API.PadtoLength(Rnd(0,1000), True, 3, "0")
ENTdata.Add(temp)
LastColor = temp.ColorID
Next
Return LastColor
End Sub
Sub IsPCARSframe(ElementType As Int) As Boolean
Select Case ElementType
Case LCAR.ENT_Radar, LCAR.ENT_Meter, LCAR.ENT_Sin, LCAR.PCAR_Frame, LCAR.ENT_RndNumbers: Return True
End Select
End Sub
Sub AddLCAR2(Data As LCARelement) As Int
If IsPCARSframe(Data.ElementType) Then LastColor = AddMiniButton(ENTbuttons)', LastColor)
Return AddLCAR(Data.Name, -999, Data.LOC.currX, Data.LOC.currY, Data.Size.currX, Data.Size.currY, Data.LWidth, Data.RWidth, Data.ColorID, Data.ElementType, Data.Text,Data.sidetext,Data.tag, Data.Group,True,Data.textalign, Data.enabled, Data.Align,255)
End Sub
Sub AddLCAR(Name As String,SurfaceID As Int, X As Int, Y As Int, Width As Int, Height As Int, LWidth As Int, RWidth As Int, ColorID As Int, ElementType As Int, Text As String,SideText As String , Tag As String,Group As Int, Visible As Boolean, TextAlign As Int, Enabled As Boolean, Align As Int, Alpha As Int ) As Int
Dim Temp As LCARelement
If Not(GroupsEnabled) Then Group=0
If API.Left(Text,1)="!" Then Text = LCARSeffects3.RandomENT(API.Right(Text, Text.Length-1))
LastX= Max(LastX, X+Width)'X coordinate of the right side of the right-most element
If Not(AllowAlpha) Then Alpha = 255
Temp=LCAR.MakeLCAR(Name,-999,X,Y,Width,Height,LWidth,RWidth,ColorID,ElementType,Text,SideText,Tag,Group,True,TextAlign,Enabled,Align,Alpha)
If SurfaceID = 1 Then Temp.RespondToAll = True
LCARelements.Add(Temp )
AddLCARtoGroup(LCARelements.Size-1, Group)
Return LCARelements.Size-1
End Sub
Sub AddRND(Dest As Rect, Title As String)
Dim X As Int = Dest.Left, Y As Int = Dest.Top, Width As Int = Dest.Right-Dest.Left, Height As Int = Dest.Bottom-Dest.Top
If Dest.Right < Dest.Left Then Width = -1
If Dest.Bottom< Dest.Top Then Height = -1
AddLCAR("RNDnum", 0, X,Y, Width, Height,RNDindex,0, LCAR.LCAR_Orange , LCAR.LCAR_RndNumbers, Title, "", "", -1, False,0 , True ,0,0)
RNDindex=RNDindex+1
End Sub
Sub Service_Create
'LCAR.SetupTheVariables
'LCAR.Setupcolors
API.AutoLoad
lwm.Initialize("LWM", True)
'LCAR.LoadLCARSize(Null)
End Sub
Sub Service_Start (StartingIntent As Intent)
API.StartPhoneEvents
End Sub
Sub Service_Destroy
lwm.StopTicking
End Sub
Sub PreviewLWP(BG As Canvas)
'Dim Increment As Boolean
If AllowPreview Then
If DreamService.DDisrunning Then
PhysicalWidth = DreamService.DD.Panel.Width
PhysicalHeight = DreamService.DD.Panel.Height
Else
PhysicalWidth = LCAR.Scalewidth
PhysicalHeight= LCAR.ScaleHeight
End If
'VirtualWidth=PhysicalHeight*2 'Engine.FullWallpaperWidth
NeedsRefresh=False
If Not(PreviewMode) Then SettingsLoaded=False
PreviewMode = True
LoadSettings(BG, VirtualWidth,PhysicalHeight, PhysicalWidth )
'PreviewMode=False
VirtualWidth=Max(msdWidth,PhysicalHeight*2)
LCAR.ClearLocked=True
'Log(DateTime.Now & " " & LastUpdate & " " & Delay)
'If DateTime.Now >= LastUpdate + Delay Then Increment=True
SystemTick
DrawScreen(BG, DoIncrement, TempCurrentOffsetX, VirtualWidth, PhysicalHeight, PhysicalWidth )
If DoIncrement Then
LastUpdate = DateTime.Now
DoIncrement=False
End If
End If
End Sub
Sub TouchDownLWP(X As Int, Y As Int)
OldPoint = Trig.SetPoint(X,Y)
If TimeOut> 0 Then API.NewTimer("Shutoff", 5, TimeOut)
HandleTouch(0,X,Y)
OldY=Y
AllowScrolling=True
If Main.CurrentSection = 78 And PreviewMode Then
API.NewTimer("NNNtime", 7, 10)
ToggleBigText(True)
End If
End Sub
Sub ToggleBigText(Visible As Boolean)
Dim element As LCARelement = LCARelements.Get(BigText)
element.Visible = True
element.Opacity.Desired= API.IIF(Visible,255,0)
End Sub
Sub TouchUpLWP(X As Int, Y As Int)
HandleTouch(1,X,Y)
End Sub
Sub TouchMoveLWP(X As Int, Y As Int)
Dim Tolerance As Int = 50
If LCAR.CrazyRez>0 Then Tolerance = Tolerance * LCAR.CrazyRez
IsClean=False
OldPoint.X=OldPoint.X+X
OldPoint.Y=OldPoint.Y+Y
If Abs(OldY - OldPoint.Y) >Tolerance Then AllowScrolling = False
HandleTouch(2,OldPoint.X,OldPoint.Y)
End Sub
Sub ScrollLWP(ElementID As Int, X As Int)
'Log(AllowScrolling & ": " & X & " (" & TempCurrentOffsetX & ")")
If AllowScrolling Then BypassScroll(ElementID,X)
'TempCurrentOffsetX = API.Limit( TempCurrentOffsetX - X, 0, VirtualWidth-PhysicalWidth)
'LCAR.DirtyElement(ElementID)
'End If
'Log(TempCurrentOffsetX)
End Sub
Sub BypassScroll(ElementID As Int, X As Int)
IsClean=False
TempCurrentOffsetX = API.Limit( TempCurrentOffsetX - X, 0, VirtualWidth-PhysicalWidth)
LCAR.DirtyElement(ElementID)
End Sub
Sub LoadSettings(BG As Canvas, Width As Int, Height As Int, WidthofScreen As Int)
Dim temp As Int, temp2 As Int, tempstr As String ,RedAlert As Boolean ,tempP As Point ' ,temp3 As Int
If Not(SettingsLoaded) Then
If Not(Settings.IsInitialized) Then Settings = API.LoadMap(File.DirInternal, "LWP.MAP")
TempCurrentOffsetX=0
AllowAlpha=False
SettingsLoaded=True
FramesPerSecond = Settings.Getdefault("FPS", 0)
If Not(IsPaused(Main)) Then PreviewMode = True
isInPmode=PreviewMode
SamsungMode=0
IsClean=False
BridgePanels=Settings.GetDefault("PAN",5)
If PreviewMode Then
Log("Preview mode: " & AllowPreview)
CurrentMode="PRV"
If (DreamService.DDisrunning Or DDisrunning) And Settings.Getdefault("DAY", -1) > -1 Then CurrentMode="DAY"
If CurrentMode = "PRV" And Not(AllowPreview) Then Return
CurrentSection = Settings.Getdefault(CurrentMode, -1)
If CurrentSection = -1 Then CurrentSection = Settings.Getdefault("SCR", -1)
TOP=0
BOTTOM=0
Else
Log("Wallpaper mode")
If Settings.ContainsKey("SAM") Then
Settings.Put("FSM", API.IIF(Settings.Get("SAM"), 1,0))
Settings.Remove("SAM")
End If
SamsungMode= Settings.Getdefault("FSM", 0)
CurrentSection = Settings.Getdefault("SCR", -1)
CurrentMode="SCR"
TOP = Settings.Getdefault("TOP", 0)
BOTTOM = Settings.Getdefault(API.IIF(Height>WidthofScreen, "BOT", "LND"), 0)
End If
If CurrentSection > -1 Then
tempstr = API.LWPLIST.Get(CurrentSection)
If tempstr.Contains(":") Then'has a subscreen
temp = tempstr.LastIndexOf(":")
SubScreenIndex = API.Right(tempstr, tempstr.Length - temp - 1)
SubScreenIndex = SubScreenIndex - 1
tempstr = API.RemoveBrackets(API.Left(tempstr,temp).ToUpperCase, 0).Trim
CurrentSection = API.LWPLIST.IndexOf(tempstr)
End If
End If
LCAR.HideToast
DDisrunning = (CurrentMode = "DAY") Or (API.CheckLock And Not(IsPaused(Main))) Or DreamService.DDisrunning
MediaControls = Settings.Getdefault("MED", False)
Darken=Settings.GetDefault("DRK", 0)
Landscape = PhysicalWidth > PhysicalHeight
'Log("Loaded: " & PreviewMode & " " & CurrentSection)
DoScale = Settings.GetDefault("SCL", False)
RedAlert=Settings.Getdefault("ALERT", 0) > 0
Wireframe.SVGscreen = -1
SSM = Settings.Getdefault("SSM", False)
GroupsEnabled=False
lwm.StopTicking
ClearLCARS
SetMSDwidthSquare(WidthofScreen,Height)
If SamsungMode>0 Then SetupConsole(BG,-1)
RefreshesLive=True
If (CurrentSection = 12 Or CurrentSection = 27) And LCAR.LCARlists.Size = 0 Then 'analysis
StartActivity(Main)
LCAR.PushEvent(LCAR.SYS_System, 1,0,0,0,0,0,LCAR.Event_Down )
End If
Log("Starting wallpaper: " & CurrentMode & " " & CurrentSection)
Select Case CurrentSection'API.LWPLIST
Case -1'none
AddLCAR("TEXT", 0, 0, msdHeight/2,-1,20, 0,0,LCAR.LCAR_Orange , LCAR.LCAR_Textbox, API.GetString("no_wallpaper"), "", "", 0, True, 5, True,0,255)
Case 0'Alert
AddLCAR("AlertStatus", 0, 0,0,-1,-1, LCAR.Classic_Green, 0, LCAR.Classic_Green, LCAR.LCAR_Alert, "", "","", 0, False,0,True,0,255)
Case 1'starbase Clock
AddLCAR("Starbase", 0, 0,0,-1,-1, 0, 0, LCAR.Classic_Green, LCAR.LCAR_StarBase, "", "","", 18,False,0,True,0,255)
Case 2'Sonar
AddLCAR("Sonar", 0, 0,0, -1 ,-1, 0,0,LCAR.Classic_Blue, LCAR.Legacy_Sonar, API.getstring("photic") & " ", "", "", 30, False, 0 ,True, 0,255)
Case 3'Science Station
AddLCAR("Moire", 0, 0,0, -1 ,-1, 0,0,LCAR.lcar_orange, LCAR.TOS_Moires, "", "", "", 29, False, 0 ,True, 0,255)
Case 4'FWD NAV SCAN
tempP = MakeFrame("FWD NAV SCAN")
AddLCAR("Navigation", 0, tempP.x,tempP.y, -1 ,-1, 0,-45,LCAR.lcar_orange, LCAR.LCAR_Navigation, "", "", "", 9, False, 0,True, 0,255)
Case 5'AFM NAV SCAN
tempP = Trig.SetPoint(0,0)' MakeFrame("FWD NAV SCAN")
AddLCAR("Navigation", 0, tempP.x,tempP.y, -1 ,-1, 0,-45,LCAR.lcar_orange, LCAR.SBALLS_Plaid, "", "", "", 9, False, 0,True, 0,255)
Case 6'PTOE
AddLCAR("PToE", 0,0,0,-1,-1,0,0,LCAR.LCAR_Orange, LCAR.LCAR_PToE, API.GetString("sec_21"), API.GetString("lsod_0"), "", 32,False, 0,True, 0,0)
Case 7'AFM PTOE
FramesPerSecond=0
AddLCAR("PToE", 0,0,0,-1,-1,0,1,LCAR.LCAR_Orange, LCAR.LCAR_PToE, "", "", "", 32,False, 0,True, 0,0)
Case 8'Federation database
AddLCAR("TheMatrix", 0, 0,0, -1 ,-1, 55,95, LCAR.LCAR_DarkBlue , LCAR.LCAR_Matrix, "", "", "", 17, False,4 , True ,0,0)
Case 9'Warp core status
If Height>WidthofScreen Then msdWidth=WidthofScreen
AddLCAR("WARPCORE", 0, 0,0, -1,-1, 0,1, LCAR.LCAR_Orange , LCAR.LCAR_Engineering, "", "", "", 20, False,0 , True ,0,0)
Case 10, 29'second and third in command
SetupConsole(BG, CurrentSection)
FramesPerSecond=0
Case 11'MSD
RedAlert=False
FramesPerSecond=0
tempstr=Settings.Getdefault("MSD","")
If tempstr.Length =0 Or Not(LCARSeffects2.LoadUniversalBMP(LCAR.DirDefaultExternal, tempstr ,LCAR.LCAR_MSD)) Or tempstr.Contains("[") Then
AddLCAR("TEXT", 0, 0, msdHeight/2,-1,20, 0,0,LCAR.LCAR_Orange , LCAR.LCAR_Textbox, API.getstring("no_msd"), "", "", 0, True, 5, True,0,255)
Else
msdWidth=0
End If
Case 12'Analysis
RedAlert=False
tempP = MakeFrame(API.GetString("snsr_ana"))
LCARSeffects2.SeedScanAnalysis(18, LCAR.LCAR_TNG)
AddLCAR("AlertStatus", 0,tempP.x,tempP.y,-1,-1, 18, 0, LCAR.LCAR_Orange, LCAR.LCAR_List, "", "","", 0, False,0,True,0,255)
Case 13'Scan animation
tempP = MakeFrame(API.GetString("snsr_scan"))
AddLCAR("SensorGrid", 0, tempP.x,tempP.y, -1 ,-1, 55,95, LCAR.LCAR_DarkBlue , LCAR.LCAR_SensorGrid, "", "", "0", 2, False,4, True ,0,0)
Case 14, 16, 22, 27, 28, 33, 34, 36,37,41,48,49 'transporter console, shuttle bay, CONN, Voyager conference room, OPS, TOS Bridge, NX-01 Bridge, Transporter 2, Hallway, Warp Field, TMP Bridge, TMP Helm
RedAlert=False'Don't forget to add it to HandleTouch
msdHeight= Height-BOTTOM-TOP
SetupConsole(BG, CurrentSection)
If CurrentSection = 34 Then
Log("NEEDS LCAR FONT")
LCAR.NeedsLCARfont = True
End If
Case 15'Warp core 2
RedAlert=False
LCARSeffects2.SetupWarpCore(-1)
LCARSeffects2.SetupWarpCore(msdHeight)
AddLCAR("WarpCore", 0, 0,0, -1 ,-1, 0,0, LCAR.LCAR_DarkBlue , LCAR.LCAR_WarpCore, "", "", "", 0, True,0, True ,0,0)
Case 17'Environmental
AddLCAR("ENVIRON", 0, 0,0, -1,-1, -1, 0, LCAR.LCAR_Orange , LCAR.LCAR_ASquare, "", "", "", 0, True,0 , True ,0,0)
Case 18'Starfield
RedAlert=False
LCARSeffects3.StarWidth=0
LCARSeffects3.LoadMSD(Settings.Getdefault("MSD",""))'put effects here
AddLCAR("stars", 0, 0,0, -1,-1, -1, 0, LCAR.LCAR_Orange , LCAR.LCAR_Starfield, "", "", "", 0, False,0 , True ,0,0)
Case 19'BORG
temp=LCAR.BORG_Color' LCAR.AddLCARcolor("BORG", 0, 120,0, 64)
AddLCAR("BORG", 0, 0, 0,-1,-1, 0,0,temp, LCAR.LCAR_Borg,"","","", 0 , True, 0,False,0,255)
Case 20'science station 2 (TNG)
tempP = MakeFrame("")
temp=msdWidth-tempP.X
AddLCAR("SCI1", 0, tempP.x,0, temp, API.IIF(LCAR.SmallScreen,72,145), LCAR.LCAR_LightPurple,0, LCAR.LCAR_Orange , LCAR.LCAR_Science, "", "", "", 36, False,0 , True ,0,0)'element 89 (group 36)'72 in SSM
AddLCAR("SCI2", 0, tempP.x, API.IIF(LCAR.SmallScreen, 94, 181), temp,-1, LCAR.LCAR_LightPurple,0, LCAR.LCAR_Orange , LCAR.LCAR_Science, "", "", "", 36, False,0 , True ,1,0)'element 90 (group 36)
Case 21'alert status clock
RedAlert=False
AddLCAR("AlertStatus", 0, 0,0,-1,-1, -1, 0, -1, LCAR.LCAR_Alert, "", "","", 0, False,0,True,0,255)
Case 23'cylon
AddLCAR("CYLON", 0, 0,0,-1,-1, -1, 0, -1, LCAR.DRD_Matrix, "", "","", 0, False,0,True,0,255)
Case 24'SHATTER Glass
AddLCAR("DS9", 0, 0,0,-1,-1, 0,0,0, LCAR.CRD_Shatter, "", "", "", 0, False, 0,True, 1,255)
Case 25'SOLAR System
AddLCAR("SOLAR", 0, 0,0,-1,-1, 0,0,0, LCAR.ENT_Planets, "", "", "", 0, False, 0,True, 0,255)
Case 26, 42 'VEHICLE Status [VOY], [ENT-E]
tempP = MakeFrame(API.GetString("vehicle_status"))
temp=msdWidth-tempP.X
temp2 = API.IIF(CurrentSection=26, 1,2)
'AddLCAR("RNDnum", 0, tempP.x,0, -1,API.IIF(LCAR.SmallScreen,72,145),0,0, LCAR.LCAR_Orange , LCAR.LCAR_RndNumbers, API.GetString("vehicle_status"), "", "", -1, False,0 , True ,0,0)
AddLCAR("VOY", 0, tempP.x, API.IIF(LCAR.SmallScreen, 94, 181), temp,-1, 1,1,LCAR.lcar_orange, LCAR.LCAR_ShieldStatus, "", "", "", -1, False, 0,True, temp2 ,255)
'Case 27 Voyager conference room
'case 28 OPS
'case 29 Number two
Case 30'Romulan Clock
AddLCAR("RomClock", 0, 0,0,-1,-1, -1,-1, 0, LCAR.ROM_Square, "","", "", -1, True, -1, True, -1, 255)
Case 31'Klingon_Clock
If PreviewMode Then msdWidth=WidthofScreen
AddLCAR("KlnClock", 0, 0,0,-1,-1, -1,-1, 0, LCAR.Klingon_Clock, "","","", -1, True, -1, True,-1 , 255)
Case 32'DS9
LCARSeffects5.SetupDS9(32, False)
AddLCAR("DS9", 0, 0,0,-1,-1, 0,0,0, LCAR.CRD_Shatter, "", "", "", 0, False, 0,True, 2,255)
'case 33,34 TOS, ENT
Case 35'Tactical 2
If msdHeight > msdWidth Then msdWidth = msdHeight*(LCARSeffects5.TacMaxWidth/LCARSeffects5.TacMaxHeight)
AddLCAR("TAC2", 0, 0,0,-1,-1, 1,1, 0, LCAR.LCAR_Tactical2, "","", "", -1, True, -1, True, LCARSeffects5.randomtactical, 255)
'case 36'transporter 2
'Case 37'UFP Logo/Hallway
' AddLCAR("UFP", 0,0,0,-1,-1, 0,0,LCAR.Classic_Blue, LCAR.LCAR_UFP, "","","", 0,True,0,True,0,0)
Case 38'Qnet
LCARSeffects3.StarWidth=0
LCARSeffects3.LoadMSD(Settings.Getdefault("MSD",""))'put effects here
AddLCAR("Qnet", 0, 0,0, -1,-1, 0, 0, LCAR.LCAR_Orange , LCAR.Q_net, "", "", "", 0, False,0 , True ,0,0)
Case 39'SHELIAK
LCARSeffects5.ShowText= PreviewMode
AddLCAR("SHELIAK", 0, 0,0, -1,-1, 0, 0, LCAR.LCAR_Orange , LCAR.MSC_Sheliak, "", "", "", 0, False,0 , True ,0,0)
Case 40'cardassian
AddLCAR("CARDY", 1, 0,0, -1,-1, 0, -1, LCAR.LCAR_Orange , LCAR.CRD_Main, "cardassian", "", "", 0, False,0 , True ,0,0)
'case 41, 42'warp field, ent e
Case 43'DNA
temp = MakeFrameForDNA(LCARSeffects6.RandomDNA(-1))
AddLCAR("DNA", 0, 0,0, -1,-1, 0, 0, LCAR.LCAR_Orange , LCAR.LCAR_DNA, "", "", "", 0, False,0 , True , temp , 0)
Case 44'INTRO 2
AddLCAR("UFP", 0, 0,0, -1,-1, -1, 0, LCAR.LCAR_Orange , LCAR.LCAR_UFP, API.GetString("comm_net"), "", "", 0, False,0 , True , 0, 0)
msdWidth = PhysicalWidth
'Case 45'hackers
' AddLCAR("ZEROCOOL", 0, 0,0, -1,-1, 0, 0, LCAR.LCAR_Orange , LCAR.MSC_Hacking, "", "", "", 0, False,0 , True , 0, 0)
Case 45'TCARS
temp = Wireframe.RandomTCARS
msdWidth = Wireframe.TCARSwidth(temp, msdHeight)
AddLCAR("TCARS", 0, 0,0, -1,-1, temp, 0, LCAR.TCAR_LightTurquoise, LCAR.TCAR_Main, API.GetString("werx_status"), "", "", 0, False,0 , True , 0, 0)
Case 46'Borg
tempP = MakeFrame("EMULATION SUBROUTINE 408")
LCARSeffects6.Init_Borg
AddLCAR("BORG", 0, tempP.x, API.IIF(LCAR.SmallScreen, 94, 181), -1,-1, -1,-1,LCAR.lcar_orange, LCAR.BORG_Borg, "BORG SYSTEM EMULATION ACTION", "", "", -1, False, 0,True, 0 ,255)
Case 47'Ferengi
AddLCAR("FERENGI", 0, 0,0, -1,-1, -1, 0, LCAR.LCAR_Orange , LCAR.FER_Ticker, "", "", "", 0, False,0 , True , 0, 0)
'case 48, 49 'ENT-B Bridge, ENT-B HELM
Case Else
AddLCAR("OMEGA", 0,0,0,-1,-1,Main.DOS,0,LCAR.Classic_Blue, LCAR.LCAR_Omega, "Ω","","", 24,True,0,True,0,0)'element 70 (group 24)
End Select
If MediaControls And DDisrunning Then
temp=(WidthofScreen-6)/3
AddLCAR("MEDIAREW", 0, 0,0, temp,LCAR.ItemHeight, LCAR.leftside,0, LCAR.LCAR_Orange, LCAR.LCAR_Button, API.GetString("prev"), "", "MEDIA_PREV", 0, True, 5, True, 0, 255)
AddLCAR("MEDIAPLAY", 0, temp+3,0, temp,LCAR.ItemHeight, 0,0, LCAR.LCAR_Orange, LCAR.LCAR_Button, API.GetString("music_playpause_d"), "", "MEDIA_PLAY", 0, True, 5, True, 0, 255)
AddLCAR("MEDIAPLAY", 0, temp*2+6,0, temp,LCAR.ItemHeight, 0,LCAR.leftside, LCAR.LCAR_Orange, LCAR.LCAR_Button, API.GetString("next"), "", "MEDIA_NEXT", 0, True, 5, True, 0, 255)
End If
If PreviewMode And Main.CurrentSection = 78 Then
temp = msdHeight /3
temp2= msdWidth / 4
AllowAlpha=True
BigText = AddLCAR("BigText", 0, temp2, temp, temp2*2 , temp, 0,0,LCAR.lcar_orange, LCAR.LCAR_Textbox , "%TIME%", "", "NNN", 6 , False, -12, True, 0, 0)
End If
'If Not(LCAR.flagset) Then
' LCAR.WasRedAlert = LCAR.RedAlert
' LCAR.flagset=True
'End If
If IsPaused(Main) Then
LCAR.SetRedAlert(RedAlert, "Load Settings")
If Settings.Getdefault("ALERT", 0) = 2 Then LCAR.RedAlertMode = LCAR.Classic_Blue
End If
If FramesPerSecond =0 And SamsungMode>0 Then FramesPerSecond=1
If FramesPerSecond>0 Then
Delay=1000/FramesPerSecond
'If DreamService.DDisrunning OR DDisrunning Then
DreamService.TimerMain.Interval = API.IIF(Delay=0,1000,Delay)
lwm.StopTicking
lwm.StartTicking(Delay)
Else
DreamService.TimerMain.Interval = 1000
End If
LogColor("Delay: " & DreamService.TimerMain.Interval & " ms (" & Floor(1000/DreamService.TimerMain.Interval) & " fps)", Colors.Blue)
End If
End Sub
Sub MakeFrame(Text As String)As Point
Dim Height As Int,Width As Int
Width=API.IIF(LCAR.SmallScreen, 53,115)
Height=API.IIF(LCAR.SmallScreen, 72,145)
LCARSeffects2.ClearRandomNumbers
AddLCAR("FRAME", 0, 0,0,-1,-1, Height,0,0, LCAR.LCAR_Frame, "","","",0, True,0,False,0,255)
If Text.Length>0 Then AddLCAR("RNDnum", 0, Width, 0, -1,Height,0,0, LCAR.LCAR_Orange , LCAR.LCAR_RndNumbers, Text, "", "", 31, False,0 , True ,0,0)
If LCAR.SmallScreen Then
Return Trig.SetPoint( 56,102)
Else
Return Trig.SetPoint(115,200)
End If
End Sub
Sub MakeFrameForDNA(Style As Int) As Int
Select Case Style
Case 0'VOY
MakeFrame2(0,0, msdWidth, msdHeight, LCARSeffects6.DNAdim(0,0), msdHeight*0.5, 3,3)
Case 3'3D
'MakeFrame("DNA ANALYSIS")
End Select
Return Style
End Sub
Sub MakeFrame2(X As Int, Y As Int, Width As Int, Height As Int, BarWidth As Int, MiddleY As Int, TopSquares As Int, BottomSquares As Int)
Dim WhiteSpace As Int = 10, BarHeight As Int = WhiteSpace * LCAR.ScaleFactor, HalfWhitespace As Int = 5, TextFormat As String = "###@"', temp As Int, temp2 As Int
AddLCAR("BLElbow", 0, X, Y+MiddleY-BarWidth-HalfWhitespace, Width-BarWidth-WhiteSpace, BarWidth, BarWidth, BarHeight, LCAR.LCAR_RandomColor, LCAR.LCAR_Elbow , LCARSeffects6.RandomNumber(TextFormat),LCAR.LCAR_RandomText,TextFormat,1, True, 3, True, 2, 255)
AddLCAR("TLElbow", 0, X, Y+MiddleY+HalfWhitespace, Width-BarWidth-WhiteSpace, BarWidth, BarWidth, BarHeight, LCAR.LCAR_RandomColor, LCAR.LCAR_Elbow , LCARSeffects6.RandomNumber(TextFormat),LCAR.LCAR_RandomText,TextFormat,1, True, 9, True, 0, 255)
MakeButtons(X, Y, BarWidth, MiddleY - BarWidth - HalfWhitespace, TopSquares, WhiteSpace, TextFormat)
MakeButtons(X, Y + MiddleY + BarWidth + HalfWhitespace+ WhiteSpace, BarWidth, (Height - MiddleY) - BarWidth - HalfWhitespace, TopSquares, WhiteSpace, TextFormat)
AddLCAR("SQRBL", 0, X+Width-BarWidth, Y+MiddleY-HalfWhitespace-BarHeight, BarWidth, BarHeight, 0,0, LCAR.LCAR_RandomColor, LCAR.LCAR_Button, "", "", "", 1, True, 9, True, 0, 255)
AddLCAR("SQRTL", 0, X+Width-BarWidth, Y+MiddleY+HalfWhitespace, BarWidth, BarHeight, 0,0, LCAR.LCAR_RandomColor, LCAR.LCAR_Button, "", "", "", 1, True, 9, True, 0, 255)
End Sub
Sub MakeButtons(X As Int, Y As Int, Width As Int, Height As Int, Squares As Int, WhiteSpace As Int, TextFormat As String)
Dim SquareHeight As Int = Height / Squares
Do Until Squares < 1
AddLCAR("SQR" & Squares, 0, X, Y, Width, SquareHeight - WhiteSpace, 0,0, LCAR.LCAR_RandomColor, LCAR.LCAR_Button, LCARSeffects6.RandomNumber(TextFormat), LCAR.LCAR_RandomText, TextFormat, 1, True, 9, True, 0, 255)
Y = Y + SquareHeight
Squares = Squares - 1
Loop
End Sub
Sub SetupRandomNumbers(ConsoleID As Int, Force As Boolean)
If Force Then LCARSeffects2.ClearRandomNumbers
If LCARSeffects2.InitRandomNumbers(LCAR.LCAR_LWP, True) Or Force Then
Select Case ConsoleID
Case 14'transporter
LCARSeffects2.AddRowOfNumbers(0, LCAR.LCAR_White, Array As Int(4,1,26,1,6,1,8,1,3,1))
LCARSeffects2.AddRowOfNumbers(1, LCAR.LCAR_White, Array As Int(-4,1,2,1,6,1))
'Case 16
'LCARSeffects2.AddRowOfNumbers(0, LCAR.lcar_Orange, Array As Int(
End Select
End If
End Sub
Sub SetupConsole(BG As Canvas, ConsoleID As Int)'also add the section to Games.ImagePackDone for ambient noise, SetGroup for beeps
Dim temp As Int, temp0 As Int, temp1 As Int, temp2 As Int, temp3 As Int, temp4 As Int,temp5 As Int ,temp6 As Int, temp7 As Int, temp8 As Int, temp9 As Int,temp10 As Int, temp11 As Int, temp12 As Int,tempstr As String ,tempdbl As Double
Dim ElbowSize As Int
LCAR.CheckNumbersize(BG)
Select Case ConsoleID
Case 1,27, 34
Case Else
FramesPerSecond=1
GroupsEnabled=True
RefreshesLive=False
End Select
SetupRandomNumbers(ConsoleID,True)
PlayRandomBeep(True)
Select Case ConsoleID
Case 10,29'number 1 and 2
temp = msdHeight'Min(Activity.Width, Activity.Height)
temp2=temp*0.05
temp3=temp2
msdWidth=0
temp4= API.IIF(LCAR.SmallScreen,65,95)
temp5= API.IIF(LCAR.SmallScreen,42,72)
temp6= API.IIF(LCAR.SmallScreen,26,36)
AddLCAR("TL2", 0, 216,0, temp-temp2-216, temp4,temp5,temp6, API.IIF(ConsoleID=10, LCAR.lcar_yellow, LCAR.LCAR_Purple) , LCAR.LCAR_Elbow, "", "", "", -1, False,0 , True ,5,0)
AddLCAR("TL1", 0, temp2,0, 96,temp4,temp5,temp6, API.IIF(ConsoleID=10, LCAR.lcar_yellow, LCAR.LCAR_LightPurple ), LCAR.LCAR_Elbow, "34-1906", "", "", -1, False,0 , True ,4,0)
temp4= API.IIF(LCAR.SmallScreen,120,212)
temp2=temp*0.37
temp5= API.IIF(LCAR.SmallScreen,89,129)
temp6= API.IIF(LCAR.SmallScreen,48,58)
temp7= API.IIF(LCAR.SmallScreen,69,122)''temp4-temp6 -LCAR.LCARCornerElbow2.Height ' API.IIF(LCAR.SmallScreen,102,122)
temp8= API.IIF(LCAR.SmallScreen,72,82)
AddLCAR("TL3", 0, 0,temp-temp4, temp2,temp5,temp8,temp6, API.IIF(ConsoleID=10, LCAR.LCAR_Orange, LCAR.LCAR_Purple ) , LCAR.LCAR_Elbow, "", "", "", -1, False,0 , True ,6,0)
temp2=temp*0.6
AddLCAR("TL4", 0, temp-temp2,temp-temp4, temp2,temp4, temp8,temp7,API.IIF(ConsoleID=10, LCAR.lcar_yellow , LCAR.LCAR_LightPurple), LCAR.LCAR_Elbow, "", "", "", -1, False,0 , True ,9,0)
temp2=temp3
temp3= temp - temp2*2 - 144
temp5= API.IIF(LCAR.SmallScreen,30,60)
If ConsoleID=10 Then
AddLCAR("ENT", 0, temp2+72, temp5,temp3,temp-temp5-temp4, 0,0, LCAR.LCAR_Yellow, LCAR.LCAR_NCC1701D, "", "", "", -1, True, 0, True, 0, 255)'element 4
Else
AddLCAR("SQR", 0, temp2+72, temp5,temp3,temp-temp5-temp4, 29,0, LCAR.LCAR_Orange, LCAR.LCAR_LWP, "", "","", -1,True, 0,True,0,255)
End If
Case 14'transporter
'msdWidth = msdHeight * 4.5
'Column 1 (Sequence select)
temp2=LCAR.ListItemsHeight(4)-3'height of top half
temp10=BG.MeasureStringWidth("451", LCAR.LCARfont, LCAR.NumberTextSize)
temp0=LCAR.TextWidth(BG, "EMERGENCY OVERIDE")+30
temp= Max(LCAR.leftside*6+ temp10+6,temp0) 'temp2* 89/111'width of current column
'temp3= LCAR.leftside*3 + LCAR.TextWidth(BG,"20150")'width of the minibuttons
temp11=BG.MeasureStringWidth("451", LCAR.LCARfont, LCAR.NumberTextSize)+LCAR.TextWidth(BG,"20150")+LCAR.leftside*10+1'total width of the COORDINATE LOCK-198696 button
If temp2>100 Or temp11>100 Then ElbowSize = temp2 * 0.5 Else ElbowSize=LCAR.LCARCornerElbow2.height' LCAR.InnerElbowSize2(temp11, temp2, False)
temp5 = msdHeight -LCAR.ListItemsHeight(8) + LCAR.LCARCornerElbow2.height'Y of bottom half
If temp5 < temp2 + ElbowSize Then temp5 = temp2 + ElbowSize'LCAR.LCARCornerElbow2.height 'force it to be below the upper half
temp12=temp'width of the slanted button
AddLCAR("SEQSEL", 0, 17,0,temp, temp2, 0, 0, LCAR.LCAR_Red, LCAR.LCAR_Button, "SEQUENCE SELECT", "","", -1, True,0,True,1,255)'group -1
temp6=17+temp - LCAR.leftside*2 - 3
temp7=temp6+LCAR.leftside+3
temp8=7+temp - LCAR.leftside*2
AddLCAR("15G88L", 0, 10, temp5, LCAR.leftside, LCAR.ItemHeight, LCAR.leftside, 0, LCAR.LCAR_Orange, LCAR.LCAR_Button,"", "", "", 0, True, 6, True, 0,255)'group 0
AddLCAR("15G88R", 0, 10+ LCAR.leftside*2, temp5, temp8, LCAR.ItemHeight, 0,0,LCAR.LCAR_Orange, LCAR.LCAR_Button,"15G88", "","", 0,True, 6,True, 0,255)
temp8=temp5 + LCAR.ItemHeight + LCAR.LCARCornerElbow2.height
temp1=temp8
AddLCAR("20T", 0, 10+LCAR.leftside, temp8, temp6-13-LCAR.leftside, LCAR.NumberTextSize, -1,0, LCAR.LCAR_Red, LCAR.LCAR_Textbox, "20", "", "", 1, True, 6, True,0,255)'group 1
AddLCAR("20L", 0, 10, temp8, LCAR.leftside, LCAR.ItemHeight, LCAR.leftside, 0, LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"", "", "", 1, True, 6, True, 0,255)
AddLCAR("20R", 0, temp6 , temp8, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_DarkOrange, LCAR.lcar_button,"", "","", 1,True, 7,True, -1,255)
temp8=temp8 + LCAR.ItemHeight + 3'
temp9=temp6-16 -LCAR.leftside*2- temp10'width of middle block
AddLCAR("G92T", 0, 10+LCAR.leftside*3, temp8, temp6-13-LCAR.leftside*3, LCAR.NumberTextSize, -1,0, LCAR.LCAR_Grey, LCAR.LCAR_Textbox, "008", "", "", 2, True, 6, True,0,255)'group 2
AddLCAR("G92L", 0, 10, temp8, LCAR.leftside, LCAR.ItemHeight, LCAR.leftside, 0, LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"", "", "", 2, True, 6, True, 0,255)
AddLCAR("G92M", 0, 10+LCAR.leftside*2 , temp8, temp9, LCAR.ItemHeight, 0,0,LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"G92", "","", 2,True, 6,True, 0,255)
AddLCAR("G92R", 0, temp6 , temp8, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"", "","", 2,True, 7,True, -1,255)
AddLCAR("G92G", 0, temp7 , temp8, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_Grey, LCAR.LCAR_Button,"", "","", -1,True, 7,True, -1,255)'group -1
temp8=temp8 + LCAR.ItemHeight+3
AddLCAR("72T", 0, 10+LCAR.leftside, temp8, temp6-13-LCAR.leftside, LCAR.NumberTextSize, -1,0, LCAR.LCAR_Red, LCAR.LCAR_Textbox, "72", "", "", 3, True, 6, True,0,255)'group 3
AddLCAR("72L", 0, 5, temp8, LCAR.leftside+5, LCAR.ItemHeight, LCAR.leftside+5, 0, LCAR.LCAR_LightPurple, LCAR.LCAR_Button,"", "", "", 3, True, 6, True, 0,255)
AddLCAR("72R", 0, temp6 , temp8, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"", "","",3,True, 7,True, -1,255)
AddLCAR("72G", 0, temp7 , temp8, LCAR.leftside, LCAR.ItemHeight*3+6, 0,0,LCAR.LCAR_Grey, LCAR.LCAR_Button,"", "","", -1,True, 7,True, -1,255)'group -1
temp8=temp8 + LCAR.ItemHeight+3
AddLCAR("514T", 0, 10+LCAR.leftside, temp8, temp6-13-LCAR.leftside, LCAR.NumberTextSize, -1,0, LCAR.LCAR_Grey, LCAR.LCAR_Textbox, "358", "", "", 4, True, 6, True,0,255)'group 4
AddLCAR("514L", 0, 0, temp8, LCAR.leftside+10, LCAR.ItemHeight, LCAR.leftside+10, 0, LCAR.LCAR_Orange, LCAR.LCAR_Button,"", "", "", 4, True, 6, True, 0,255)
AddLCAR("514M", 0, 10+ LCAR.leftside*2 , temp8, temp9, LCAR.ItemHeight, 0,0,LCAR.LCAR_Orange, LCAR.LCAR_Button,"514", "","", 4,True, 6,True, 0,255)
AddLCAR("514R", 0, temp6 , temp8, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_Orange, LCAR.LCAR_Button,"", "","", 4,True, 7,True, -1,255)
temp8=temp8 + LCAR.ItemHeight+3
AddLCAR("G83T", 0, 10+LCAR.leftside, temp8, temp6-10-LCAR.leftside, LCAR.NumberTextSize, -1,0, LCAR.LCAR_Grey, LCAR.LCAR_Textbox, "451", "", "", 5, True, 6, True,0,255)'group 5
AddLCAR("G83M", 0, 10+ LCAR.leftside*2 , temp8,temp9, LCAR.ItemHeight, 0,0,LCAR.LCAR_Orange, LCAR.LCAR_Button,"G83", "","", 5,True, 6,True, 0,255)
AddLCAR("G83R", 0, temp6 , temp8, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_Orange, LCAR.LCAR_Button,"", "","", 5,True, 7,True, -1,255)
temp8=temp8 + (LCAR.ItemHeight*1.5)+3
AddLCAR("BOTBAR", 0, 0 , temp8, temp+18, LCAR.ItemHeight*0.5, 0,0,LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"", "","", -1,True, 5,True, -1,255)'group -1
'Column 2 PATTERN BUFFER (QUANTUM)/PHASE TRANSITION COILS (PRIMARY)
'temp1 = Y of first item in the list
temp3=27+temp'X position of current column
temp10=LCAR.TextWidth(BG, "PHASE TRANSITION COILS (PRIMARY)")+20
temp=Max(temp2* 182/111,temp10)'width of column
AddLCAR("PATBUF", 0, temp3,0,temp, temp2, 0, 0, LCAR.LCAR_DarkOrange, LCAR.LCAR_Button, "SUBSPACE FIELD COMPENSATION", "","", -1, False,9,True,-1,255)'PATTERN BUFFER (QUANTUM)
AddLCAR("PTC", 0,temp3, temp5, temp, LCAR.ItemHeight, 0,0,LCAR.LCAR_Orange, LCAR.LCAR_Button,"PHASE TRANSITION COILS (PRIMARY)", "","", -1,True, 6,True, 0,255)
AddLCAR("BOTBAR2", 0, temp3, temp8, temp, LCAR.ItemHeight*0.5, 0,0,LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"", "","", -1,True, 5,True, -1,255)
AddLCAR("RNDNUM2", 0, temp3, temp1+LCAR.ListItemsHeight(1) , temp*0.7, LCAR.ListItemsHeight(2.5), 1,0, LCAR.LCAR_White, LCAR.LCAR_RndNumbers, "", "","", 6,True, 0,True,0,255)'group 6
AddLCAR("RNDNUM1", 0, temp3, temp1, temp*0.75, LCAR.ListItemsHeight(1), 14,1, LCAR.LCAR_DarkOrange, LCAR.LCAR_LWP, "00283", "","", 6,True, 0,True,0,255)
'column 3 (The buttons next to pattern buffer)
temp3=temp3+temp+20
temp10=temp3
AddLCAR("TOPUSL", 0, temp3, 0, LCAR.leftside+4, LCAR.ItemHeight, LCAR.leftside, 0, LCAR.LCAR_Red, LCAR.LCAR_Button,"", "", "", 7, True, 0, True, 0,255)'group 7
AddLCAR("BALIVL", 0, temp3, LCAR.ItemHeight+3, LCAR.leftside+4, LCAR.ItemHeight, LCAR.leftside, 0, LCAR.LCAR_LightPurple, LCAR.LCAR_Button,"", "", "", 8, True, 0, True, 0,255)'group 8
'AddLCAR("GRJEIL", 0, temp3, (LCAR.ItemHeight+3)*2, LCAR.leftside+4, LCAR.ItemHeight, LCAR.leftside, 0, LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"", "", "", 9, True, 0, True, 0,255)'group 9
AddLCAR("MISCNL", 0, temp3, (LCAR.ItemHeight+3)*3, LCAR.leftside+4, LCAR.ItemHeight, LCAR.leftside, 0, LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"", "", "", 10, True, 0, True, 0,255)'group 10
temp3=temp3+LCAR.leftside
temp4=BG.MeasureStringWidth(" 72001", LCAR.LCARfont, LCAR.NumberTextSize)
AddLCAR("TOPUST", 0, temp3, 0, temp4, LCAR.NumberTextSize, -1,0, LCAR.LCAR_LightPurple, LCAR.LCAR_Textbox, " 72001", "", "", 7, True, 4, True,0,255)'group 7
AddLCAR("BALIVT", 0, temp3, LCAR.ItemHeight+3, temp4, LCAR.NumberTextSize, 0,0, LCAR.LCAR_LightPurple, LCAR.LCAR_Textbox, "020", "", "", 8, True, 6, True,0,255)'group 8
AddLCAR("GRJEIT", 0, temp3, (LCAR.ItemHeight+3)*2, temp4, LCAR.NumberTextSize, 0,0, LCAR.LCAR_DarkOrange, LCAR.LCAR_Textbox, "51906", "", "", 9, True, 6, True,0,255)'group 9
AddLCAR("MISCNT", 0, temp3, (LCAR.ItemHeight+3)*3, temp4, LCAR.NumberTextSize, 0,0, LCAR.LCAR_LightOrange, LCAR.LCAR_Textbox, "40776", "", "", 10, True, 6, True,0,255)'group 10
temp3=temp3+temp4
AddLCAR("TOPUSR", 0, temp3 , 0, 120, LCAR.ItemHeight, 0,0,LCAR.LCAR_Red, LCAR.LCAR_Button,"TE FRE", "","", 7,True, 7,True, -1,255)'group 7
AddLCAR("BALIVR", 0, temp3 , LCAR.ItemHeight+3, 120, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button,"JE HAY", "","", 8,True, 7,True, -1,255)'group 8
AddLCAR("GRJEIR", 0, temp3 , (LCAR.ItemHeight+3)*2, 120, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button,"JO SYM", "","", 9,True, 7,True, -1,255)'group 9
AddLCAR("MISCNR", 0, temp3 , (LCAR.ItemHeight+3)*3, 120, LCAR.ItemHeight, 0,0,LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"TI IAC", "","", 10,True, 7,True, -1,255)'group 10
'column 4 (Targeting coordiante reference/G92)
temp7=temp5
temp3=temp3+120+LCAR.leftside
temp=temp2* 160/111'width of column
temp5=LCAR.TextWidth(BG, "TARGETING COORDINATE REFERENCE")+20 + LCAR.ListItemsHeight(5)
temp9=Max(temp+ temp4+120+LCAR.leftside*2,temp5)
temp=Max(temp, (temp10+temp9)-(temp3+1))
temp5 = LCAR.ListItemsHeight(5)'width/height of dpad
temp0 = temp10+temp9-temp5'X coord of dpad
temp11 = temp5 * LCARSeffects.DpadCenter *1.6 'width of center
temp6 = temp5 * 0.5 - (temp11*0.5)'X coord in dpad of start of middle
temp9 = temp9 - (temp5-temp6)'width of bar
AddLCAR("SQUARE", 0, temp3+1,0,temp, temp2+1, 14, 0, LCAR.LCAR_LightPurple, LCAR.LCAR_LWP, "", "","", -1, False, temp11 +1 ,True,temp5-temp6,255)
AddLCAR("TCR", 0,temp10, temp7, temp9, LCAR.ItemHeight, 0,0,LCAR.LCAR_Orange, LCAR.LCAR_Button,"TARGETING COORDINATE REFERENCE", "","", 11,True, 6,True, 0,255)'group 11
AddLCAR("DPAD", 0, temp0, temp1, temp5,temp5, 0,0, LCAR.LCAR_Orange, LCAR.LCAR_Dpad, "","","", -1 ,True, 0,True, 0,0)
AddLCAR("BOTBAR3", 0, temp0, temp8, temp5, LCAR.ItemHeight*0.5, 0,0,LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"", "","", -1,True, 5,True, -1,255)
AddLCAR("TCR1", 0, temp10+temp9+1, temp7 - LCAR.ItemHeight*0.25 -1, temp11, LCAR.ItemHeight*0.25, 0,0, LCAR.LCAR_LightBlue, LCAR.LCAR_Button,"", "","",11,True, 5,True, -1,255)'group 11
AddLCAR("TCR2", 0, temp10+temp9+1, temp7, temp11, LCAR.ItemHeight*0.25, 0,0, LCAR.LCAR_LightBlue, LCAR.LCAR_Button,"", "","", 11,True, 5,True, -1,255)
AddLCAR("TCR3", 0, temp10+temp9+1, temp7 + LCAR.ItemHeight*0.5, temp11, LCAR.ItemHeight*0.5-1, 0,0, LCAR.LCAR_LightBlue, LCAR.LCAR_Button,"", "","", 11,True, 5,True, -1,255)
AddLCAR("G92", 0,temp10+temp9+2+temp11+1, temp7, temp6 , LCAR.ItemHeight, 0,0,LCAR.LCAR_LightOrange, LCAR.LCAR_Button,"G92", "","", 11,True, 6,True, 0,255)'group 11
'Trgetting scanners/Coordinate Lock/Auto Seq columns
temp = temp10+temp9+2+temp11+1+temp6 + LCAR.leftside 'X of current column
temp0=BG.MeasureStringWidth("451", LCAR.LCARfont, LCAR.NumberTextSize)'width of 3 BIG numbers
'temp1 = y of first item in bottom half
'temp2 = height of top half
temp3= LCAR.leftside*3 + LCAR.TextWidth(BG,"20150")'width of the minibuttons
temp4=temp3+temp+LCAR.leftside'x start of buttons
temp6= temp0 + temp3+LCAR.leftside*7'width of these 2 columns
'temp7 = y of bottom half
'temp8 = Y of bottom row
temp11=temp0+temp3+LCAR.leftside*7+1'total width of the COORDINATE LOCK-198696 button
AddLCAR("TARSCAL", 0, temp,0, temp6*1.33+3, temp7-3, temp6*0.33, temp2, LCAR.LCAR_DarkOrange, LCAR.LCAR_Elbow, "TARGET ACQUISITION", "", "", -1, True, -2, True, 1 ,255)
AddLCAR("COORDL", 0,temp, temp7, temp3+LCAR.leftside*5 , LCAR.ItemHeight, 0,0,LCAR.LCAR_LightOrange, LCAR.LCAR_Button,"COORDINATE LOCK", "","", 12,True, 4,True, 0,255)'group 12
AddLCAR("COORDM", 0,temp+temp3+LCAR.leftside*5-1, temp7, temp0+LCAR.leftside*2+1, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightOrange, LCAR.LCAR_Button,"198696", "","", 12,True, 6,True, 0,255)
AddLCAR("COORDR", 0,temp+temp6+3, temp7, temp6*0.33, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightOrange, LCAR.LCAR_Button,"AUTO SEQ", "","", -1,True, 6,True, 0,255)
AddLCAR("20T", 0, temp4+LCAR.leftside*5, temp1, temp0, LCAR.NumberTextSize, -1,0, LCAR.LCAR_White, LCAR.LCAR_Textbox, "20", "", "", 13, True, 6, True,0,255)'group 13
AddLCAR("20L", 0, temp4, temp1, LCAR.leftside, LCAR.ItemHeight, LCAR.leftside, 0, LCAR.LCAR_Purple, LCAR.LCAR_Button,"", "", "", 13, True, 6, True, 0,255)
AddLCAR("20M", 0, temp4+LCAR.leftside*2 , temp1, LCAR.leftside*3, LCAR.ItemHeight, 0,0,LCAR.LCAR_Purple, LCAR.LCAR_Button,"2904", "","", 13,True, 6,True, 0,255)
AddLCAR("20R", 0, temp4+LCAR.leftside*5+ temp0, temp1, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_Red, LCAR.LCAR_Button,"", "","", 13,True, 7,True, -1,255)
AddLCAR("DAMUOKUDA1", 0, temp4+LCAR.leftside*2,temp1, temp6*1.33+3 - temp3- LCAR.leftside*3, LCAR.ListItemsHeight(6)-2, temp6*0.33, LCAR.ListItemsHeight(0.5) , LCAR.LCAR_DarkOrange, LCAR.LCAR_Elbow, "", "", "", -1, True, -2, False, 3 ,255)
AddLCAR("DAMUOKUDA2", 0, temp+temp6+3, temp1, temp6*0.66, LCAR.ListItemsHeight(6)-2, temp6*0.33, LCAR.ListItemsHeight(1), LCAR.LCAR_DarkOrange, LCAR.LCAR_Elbow, "", "", "", -1, True, -2, False, 2 ,255)
AddLCAR("DAMUOKUDA3", 0, temp+temp6+3, temp1, temp6* 0.33,LCAR.ListItemsHeight(6)-3, 0,0, LCAR.LCAR_DarkOrange, LCAR.LCAR_Button, "", "", "", -1,True, 0,False, -1,255)
AddLCAR("20150", 0, temp, temp1+LCAR.ItemHeight+3, temp3, LCAR.ItemHeight, 0,0, LCAR.LCAR_LightOrange, LCAR.LCAR_MiniButton, "20150", "", "", -1, True, 6, True,0,255)
AddLCAR("008T", 0, temp4+LCAR.leftside*5, temp1+LCAR.ItemHeight+3, temp0, LCAR.NumberTextSize, -1,0, LCAR.LCAR_Purple, LCAR.LCAR_Textbox, "008", "", "", 14, True, 6, True,0,255)'group 14
'AddLCAR("008L", 0, temp4, temp1+LCAR.ItemHeight+3, LCAR.leftside, LCAR.ItemHeight, LCAR.leftside, 0, LCAR.LCAR_LightPurple, LCAR.LCAR_Button,"", "", "", 0, True, 6, True, 0,255)
AddLCAR("008M", 0, temp4+LCAR.leftside*2 , temp1+LCAR.ItemHeight+3, LCAR.leftside*3, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button,"13888", "","", 14,True, 6,True, 0,255)
'AddLCAR("008R", 0, temp4+LCAR.leftside*5+ temp0, temp1+LCAR.ItemHeight+3, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button,"", "","", 0,True, 7,True, -1,255)
AddLCAR("B33", 0, temp, temp1+(LCAR.ItemHeight+3)*2, temp3, LCAR.ItemHeight, 0,0, LCAR.LCAR_LightOrange, LCAR.LCAR_MiniButton, "B33", "", "", -1, True, 6, True,0,255)
AddLCAR("B72T", 0, temp4+LCAR.leftside*5, temp1+(LCAR.ItemHeight+3)*2, temp0, LCAR.NumberTextSize, -1,0, LCAR.LCAR_White, LCAR.LCAR_Textbox, "72", "", "", 15, True, 6, True,0,255)'group 15
AddLCAR("B72L", 0, temp4, temp1+(LCAR.ItemHeight+3)*2, LCAR.leftside, LCAR.ItemHeight, LCAR.leftside, 0, LCAR.LCAR_LightOrange, LCAR.LCAR_Button,"", "", "", 15, True, 6, True, 0,255)
AddLCAR("B72M", 0, temp4+LCAR.leftside*2 , temp1+(LCAR.ItemHeight+3)*2, LCAR.leftside*3, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightOrange, LCAR.LCAR_Button, LCAR.LCAR_Block, "","", 15,True, 6,True, 0,255)
AddLCAR("B72R", 0, temp4+LCAR.leftside*5+ temp0, temp1+(LCAR.ItemHeight+3)*2, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightOrange, LCAR.LCAR_Button,"", "","",15,True, 7,True, -1,255)
AddLCAR("04", 0, temp, temp1+(LCAR.ItemHeight+3)*3, temp3, LCAR.ItemHeight, 0,0, LCAR.LCAR_Orange, LCAR.LCAR_MiniButton, "04", "", "", -1, True, 6, True,0,255)
AddLCAR("B358T", 0, temp4+LCAR.leftside*5, temp1+(LCAR.ItemHeight+3)*3, temp0, LCAR.NumberTextSize, -1,0, LCAR.LCAR_Orange, LCAR.LCAR_Textbox, "358", "", "", 16, True, 6, True,0,255)'group 16
AddLCAR("B358L", 0, temp4, temp1+(LCAR.ItemHeight+3)*3, LCAR.leftside, LCAR.ItemHeight, LCAR.leftside, 0, LCAR.LCAR_Orange, LCAR.LCAR_Button,"", "", "", 16, True, 6, True, 0,255)
AddLCAR("B358M", 0, temp4+LCAR.leftside*2 , temp1+(LCAR.ItemHeight+3)*3, LCAR.leftside*3, LCAR.ItemHeight, 0,0,LCAR.LCAR_Orange, LCAR.LCAR_Button, LCAR.LCAR_Block, "","", 16,True, 6,True, 0,255)
AddLCAR("B358R", 0, temp4+LCAR.leftside*5+ temp0, temp1+(LCAR.ItemHeight+3)*3, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button,"", "","", 16,True, 7,True, -1,255)
AddLCAR("957", 0, temp, temp1+(LCAR.ItemHeight+3)*4, temp3, LCAR.ItemHeight, 0,0, LCAR.LCAR_Red, LCAR.LCAR_MiniButton, "957", "", "", -1, True, 6, True,0,255)
AddLCAR("451T", 0, temp4+LCAR.leftside*5, temp1+(LCAR.ItemHeight+3)*4, temp0, LCAR.NumberTextSize, -1,0, LCAR.LCAR_White, LCAR.LCAR_Textbox, "451", "", "", 17, True, 6, True,0,255)'group 17
AddLCAR("451L", 0, temp4, temp1+(LCAR.ItemHeight+3)*4, LCAR.leftside, LCAR.ItemHeight, LCAR.leftside, 0, LCAR.LCAR_Purple, LCAR.LCAR_Button,"", "", "", 17, True, 6, True, 0,255)
AddLCAR("451M", 0, temp4+LCAR.leftside*2 , temp1+(LCAR.ItemHeight+3)*4, LCAR.leftside*3, LCAR.ItemHeight, 0,0,LCAR.LCAR_Purple, LCAR.LCAR_Button,"6009", "","", 17,True, 6,True, 0,255)
AddLCAR("451R", 0, temp4+LCAR.leftside*5+ temp0, temp1+(LCAR.ItemHeight+3)*4, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button,"", "","", 17,True, 7,True, -1,255)
AddLCAR("BOTBAR4", 0, temp, temp8-LCAR.ItemHeight*0.1, temp3, LCAR.ItemHeight*0.6+1, 0,0,LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"", "","", -1,True, 5,False, -1,255)
AddLCAR("BOTBAR5", 0, temp+temp3-1, temp8, LCAR.leftside*2 +5 , LCAR.ItemHeight*0.5, 0,0,LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"", "","", -1,True, 5,False, -1,255)
'Transporter sliders
'temp0 = width of the 3 BIG numbers
'temp1 = y of first item in bottom half
'temp2 = height of top half
temp3= temp6*0.25 'width of a transporter slider
temp =temp+temp6+3 + temp6*0.33 + temp3 'x coord of this column
temp4=temp+temp3-1
'temp7 = y of bottom half
'temp8 = Y of bottom row
ElbowSize = LCAR.InnerElbowSize2(temp3, LCAR.ItemHeight*0.5, False)
AddLCAR("DAMUOKUDA5", 0, temp, temp8-LCAR.ItemHeight, temp3, LCAR.ItemHeight*1.5, 0,0,LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"", "","", -1,True, 5,False, -1,255)
AddLCAR("DAMUOKUDA6", 0, temp4, temp8-ElbowSize, temp3*3+10, LCAR.ItemHeight*0.5+ElbowSize+1, temp3, LCAR.ItemHeight*0.5, LCAR.LCAR_DarkOrange, LCAR.LCAR_Elbow, "","","", -1, True, 0,False, 3 ,255)
AddLCAR("DAMUOKUDA7", 0, temp4+ temp3, temp1, 10, LCAR.ListItemsHeight(6)-5, 0,0, LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"", "","", -1,True, 5,False, -1,255)
AddLCAR("MIDBAR1", 0, temp4+ temp3, 0, 10, temp7-5, 0,0, LCAR.LCAR_LightBlue, LCAR.LCAR_Button,"", "","", -1,True, 5,True, -1,255)
AddLCAR("MIDBAR2", 0, temp4+ temp3, temp7, 10, LCAR.ItemHeight, 0,0, LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"", "","", -1,True, 5,True, -1,255)
AddTransporterSlider("TS1", temp, temp7, temp3, temp8-LCAR.ItemHeight , "6688", 18)'group 18
AddTransporterSlider("TS2", temp+10+temp3*3, temp7, temp3, temp8-LCAR.ItemHeight , "835", 19)'group 19
AddTransporterSlider("TS3", temp4+ temp3*5, temp7, temp3, temp8-LCAR.ItemHeight , "965", 20)'group 20
'AddLCAR("MIDBAR3", 0,temp, temp7, temp3, LCAR.ItemHeight, 0,0,LCAR.LCAR_Orange, LCAR.LCAR_Button,"6688", "","", 0,True, 6,True, 0,255)
AddLCAR("MIDBAR4", 0, temp4+ temp3*4, 0, 10, temp7-5, 0,0, LCAR.LCAR_LightBlue, LCAR.LCAR_Button,"", "","", -1,True, 5,True, -1,255)
AddLCAR("MIDBAR5", 0, temp4+ temp3*4, temp7, 10, LCAR.ItemHeight, 0,0, LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"", "","", -1,True, 5,True, -1,255)
AddLCAR("DAMUOKUDA8",0,temp4+ temp3*4, temp1, 10+temp3, LCAR.ListItemsHeight(6), 10, LCAR.ItemHeight*0.5, LCAR.LCAR_DarkOrange, LCAR.LCAR_Elbow,"", "","", -1,True, 5,True, 2,255)
AddLCAR("DAMUOKUDA9", 0, temp4+ temp3*5, temp8-LCAR.ItemHeight, temp3, LCAR.ItemHeight*1.5+2, 0,0,LCAR.LCAR_DarkOrange, LCAR.LCAR_Button,"", "","", -1,True, 5, False, -1,255)
temp= temp4+ temp3*6'start X coord of this column
temp9= temp3 + temp0 + 7 + LCAR.leftside 'width of the buttons
'temp11=total width of the COORDINATE LOCK-198696 button
temp10=temp+temp3
'top half
AddLCAR("MOLIMG1", 0,temp10,0, temp11+temp3*2 , temp7-3, temp11 , temp2, LCAR.LCAR_DarkOrange, LCAR.LCAR_Elbow, "", "", "", -1, True, -2, True, 0 ,255)
AddLCAR("MOLIMG2", 0,temp10, temp7, temp11 , LCAR.ItemHeight, 0,0,LCAR.LCAR_LightOrange, LCAR.LCAR_Button,"MOLECULAR IMAGING SCANNERS", "","", -1,True, 4,True, 0,255)
AddLCAR("EMRGOVR", 0, temp10+temp11+temp3*2+10,0,temp12, temp2-1, 0, 0, LCAR.LCAR_Red, LCAR.LCAR_Button, "EMERGENCY OVERIDE", "","", -1, False,0,True,2,255)
AddLCAR("DAMUOKUDAX", 0, temp, temp1, temp11+temp3, LCAR.ListItemsHeight(6), temp11-temp9, LCAR.ItemHeight*0.5, LCAR.LCAR_DarkOrange, LCAR.LCAR_Elbow,"", "","", -1,True, 5,True, 3,255)
AddLCAR("9580T", 0,temp10+temp3+3, temp1, temp0, LCAR.NumberTextSize, -1,0, LCAR.LCAR_White, LCAR.LCAR_Textbox, "300", "", "", 21, True, 6, True,0,255)'group 21
AddLCAR("9580L", 0,temp10 , temp1,temp3, LCAR.ItemHeight, 0,0,LCAR.LCAR_DarkOrange, LCAR.LCAR_Button, "9580", "","", 21,True, 6,True, 0,255)
AddLCAR("9580R", 0,temp10+temp3+temp0+6 , temp1,LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightOrange, LCAR.LCAR_Button, "", "","", 21,True, 6,True, 0,255)
AddLCAR("653L", 0,temp10 , temp1 + LCAR.ListItemsHeight(1) ,temp3, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button, "653", "","", 22,True, 6,True, 0,255)'group 22
AddLCAR("653R", 0,temp10+temp3+temp0+6 , temp1 + LCAR.ListItemsHeight(1),LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightOrange, LCAR.LCAR_Button, "", "","", 22,True, 6,True, 0,255)
AddLCAR("B947T", 0,temp10+temp3+3, temp1 + LCAR.ListItemsHeight(2), temp0, LCAR.NumberTextSize, -1,0, LCAR.LCAR_LightPurple, LCAR.LCAR_Textbox, "947", "", "", 23, True, 6, True,0,255)'group 23
AddLCAR("B947L", 0,temp10 , temp1 + LCAR.ListItemsHeight(2),temp3, LCAR.ItemHeight, 0,0,LCAR.LCAR_DarkOrange, LCAR.LCAR_Button, LCAR.LCAR_Block, "","", 23,True, 6,True, 0,255)
AddLCAR("B947R", 0,temp10+temp3+temp0+6 , temp1 + LCAR.ListItemsHeight(2),LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button, "", "","", 23,True, 6,True, 0,255)
AddLCAR("B88T", 0,temp10+temp3+3, temp1 + LCAR.ListItemsHeight(3), temp0, LCAR.NumberTextSize, -1,0, LCAR.LCAR_LightPurple , LCAR.LCAR_Textbox, "88", "", "", 24, True, 6, True,0,255)'group 24
AddLCAR("B88L", 0,temp10 , temp1 + LCAR.ListItemsHeight(3),temp3, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button, LCAR.LCAR_Block, "","", 24,True, 6,True, 0,255)
AddLCAR("B88R", 0,temp10+temp3+temp0+6 , temp1 + LCAR.ListItemsHeight(3),LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_Red, LCAR.LCAR_Button, "", "","", 24,True, 6,True, 0,255)
temp= temp10 + temp11 + LCAR.leftside'start X coord of this column
'temp1 = Y first list item
temp9=temp3'width of a button
temp2 = temp3*2'width of space under the elbow
temp3= temp12-LCAR.leftside'width of CH NOL button
temp4=temp2-LCAR.leftside 'width of elbow
temp5=temp+temp4+10'X of CH NOL button
temp6= temp2-LCAR.leftside-LCAR.ItemHeight'barwidth
temp10=temp5+temp9+LCAR.leftside
temp11=temp12+17
temp12=temp10+LCAR.leftside+3'X of final col
AddLCAR("CHNOL1", 0,temp,temp7, temp4 , LCAR.ListItemsHeight(4), temp6 , LCAR.ItemHeight, LCAR.LCAR_DarkOrange, LCAR.LCAR_Elbow, "", "", "", -1, True, -2, True, 0 ,255)
AddLCAR("CHNOL2", 0,temp5, temp7, temp3 , LCAR.ItemHeight, 0,0,LCAR.LCAR_Orange, LCAR.LCAR_Button,"CH NOL", "","", 25,True, 6,True, 0,255)'group 25
AddLCAR("CHNOL3", 0,temp5+10+temp3, temp7, LCAR.leftside, LCAR.ItemHeight, 0, LCAR.leftside, LCAR.LCAR_Orange, LCAR.LCAR_Button,"", "", "", 25, True, 6, True, 0,255)
AddLCAR("CHNOL4", 0, temp, temp1, temp4, LCAR.ListItemsHeight(6), temp6, LCAR.ItemHeight*0.5, LCAR.LCAR_DarkOrange, LCAR.LCAR_Elbow,"", "","", -1,True, 5,True, 2,255)
AddLCAR("BOTBAR6", 0, temp5, temp8+3, temp11 , LCAR.ItemHeight*0.5, 0,0,LCAR.LCAR_LightOrange, LCAR.LCAR_Button,"", "","", -1,True, 5,True, -1,255)
temp=temp+temp4 -LCAR.leftside'start X coord of this column
temp11=temp11-temp9-LCAR.leftside*3-20'width of final column
temp0=temp12+temp11-1'X of final bubbles
AddLCAR("9220L", 0,temp, temp1, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_DarkOrange, LCAR.LCAR_Button, "", "","", 26,True, 6,True, 0,255)'group 26
AddLCAR("9220M", 0,temp5, temp1,temp9, LCAR.ItemHeight, 0,0,LCAR.LCAR_DarkOrange, LCAR.LCAR_Button, "9220", "","", 26,True, 4,True, 0,255)
AddLCAR("9220N", 0,temp10, temp1, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_Red, LCAR.LCAR_Button, "", "","", 26,True, 6,True, 0,255)
AddLCAR("9220O", 0,temp12, temp1, temp11, LCAR.ItemHeight, 0,0,LCAR.LCAR_Purple, LCAR.LCAR_Button, "", "","", 26,True, 6,True, 0,255)
AddLCAR("9220P", 0,temp0, temp1, LCAR.leftside, LCAR.ItemHeight, 0,LCAR.leftside,LCAR.LCAR_Purple, LCAR.LCAR_Button, "", "","", 26,True, 6,True, 0,255)
temp1=temp1+LCAR.ListItemsHeight(1)
AddLCAR("120L", 0,temp, temp1, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button, "", "","", 27,True, 6,True, 0,255)'group 27
AddLCAR("120M", 0,temp5, temp1,temp9, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button, "120", "","", 27,True, 4,True, 0,255)
AddLCAR("120N", 0,temp10, temp1, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button, "", "","", 27,True, 6,True, 0,255)
AddLCAR("120O", 0,temp12, temp1, temp11, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button, "", "","", 27,True, 6,True, 0,255)
AddLCAR("120P", 0,temp0, temp1, LCAR.leftside, LCAR.ItemHeight, 0,LCAR.leftside,LCAR.LCAR_LightPurple, LCAR.LCAR_Button, "", "","", 27,True, 6,True, 0,255)
temp1=temp1+LCAR.ListItemsHeight(1)
AddLCAR("10825L", 0,temp, temp1, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button, "", "","", 28,True, 6,True, 0,255)'group 28
AddLCAR("10825M", 0,temp5, temp1,temp9, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button, "10825", "","", 28,True, 4,True, 0,255)
AddLCAR("10825N", 0,temp10, temp1, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button, "", "","", 28,True, 6,True, 0,255)
AddLCAR("10825O", 0,temp12, temp1, temp11, LCAR.ItemHeight, 0,0,LCAR.LCAR_Red, LCAR.LCAR_Button, "", "","", 28,True, 6,True, 0,255)
AddLCAR("10825P", 0,temp0, temp1, LCAR.leftside, LCAR.ItemHeight, 0,LCAR.leftside,LCAR.LCAR_Red, LCAR.LCAR_Button, "", "","", 28,True, 6,True, 0,255)
temp1=temp1+LCAR.ListItemsHeight(1)
AddLCAR("990L", 0,temp, temp1, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_Orange, LCAR.LCAR_Button, "", "","", 29,True, 6,True, 0,255)'group 29
AddLCAR("990M", 0,temp5, temp1,temp9, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button, "990", "","", 29,True, 4,True, 0,255)
AddLCAR("990N", 0,temp10, temp1, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_Red, LCAR.LCAR_Button, "", "","", 29,True, 6,True, 0,255)
AddLCAR("990O", 0,temp12, temp1, temp11, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button, "", "","", 29,True, 6,True, 0,255)
AddLCAR("990P", 0,temp0, temp1, LCAR.leftside, LCAR.ItemHeight, 0,LCAR.leftside,LCAR.LCAR_LightPurple, LCAR.LCAR_Button, "", "","", 29,True, 6,True, 0,255)
temp1=temp1+LCAR.ListItemsHeight(1)
AddLCAR("92L", 0,temp, temp1, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_Red, LCAR.LCAR_Button, "", "","", 30,True, 6,True, 0,255)'group 30
AddLCAR("92M", 0,temp5, temp1,temp9, LCAR.ItemHeight, 0,0,LCAR.LCAR_Orange, LCAR.LCAR_Button, "92", "","", 30,True, 4,True, 0,255)
AddLCAR("92N", 0,temp10, temp1, LCAR.leftside, LCAR.ItemHeight, 0,0,LCAR.LCAR_LightPurple, LCAR.LCAR_Button, "", "","", 30,True, 6,True, 0,255)
AddLCAR("92O", 0,temp12, temp1, temp11, LCAR.ItemHeight, 0,0,LCAR.LCAR_Purple, LCAR.LCAR_Button, "", "","", 30,True, 6,True, 0,255)
AddLCAR("92P", 0,temp0, temp1, LCAR.leftside, LCAR.ItemHeight, 0,LCAR.leftside,LCAR.LCAR_Purple, LCAR.LCAR_Button, "", "","", 30,True, 6,True, 0,255)
Case 16' shuttle bay
'GroupsEnabled=False
RefreshesLive=True
tempstr="SHUTTLEBAY OPERATIONS"
temp=LCAR.ItemHeight+1'*2 'height of the buttons
temp2=API.GetTextHeight(BG, temp, tempstr,LCAR.LCARfont)
temp3=BG.MeasureStringWidth(tempstr, LCAR.LCARfont, temp2)' LCAR.NumberTextSize)
'dimensions of starship 701(width) x 370(height)
temp4= msdHeight-(temp*2) 'max height available to the starship
tempdbl=temp4/370
If tempdbl >1 Then
tempdbl= Floor(tempdbl)
temp4 = 370* tempdbl 'height of starship redone
End If
temp5 = tempdbl * 701 'width of starship at that height
temp8= LCAR.TextWidth(BG, "PRIMARY ACQUISITION ZONE") * 1.2
temp10=msdHeight/2-temp4/2'top of the ship
AddLCAR("TL", 0, 0,0,temp, temp-1, 0, 0, LCAR.LCAR_ORANGE, LCAR.LCAR_Button, "", "","", -1, True,0,True,-4 ,255)'element 0
AddLCAR("SHIP", 0, temp, temp10, temp5, temp4, 0,0, 0, LCAR.LCAR_ShuttleBay, "","","", -1,True,0,True,0,255)'element (drawn before text, cause of the shuttles)
AddLCAR("TXT", 0, temp+4,0,temp3, temp2 , -1, 0, LCAR.LCAR_Purple , LCAR.LCAR_Textbox, tempstr, "","", -1, True,0,True,0 ,255)'element
'start at 380 (0.5420827389443652), width = 150 (0.2139800285306705), max height of 60 (0.2139800285306705)
If temp10-temp>0 Then
AddLCAR("RNDnum", 0, temp + (temp5*0.50) ,temp , temp5*0.22, temp10-temp,0,0, LCAR.LCAR_Orange , LCAR.LCAR_RndNumbers, "", "", "", -1, False,0 , True ,0,0)'element
End If
temp9=Max(0, (temp5*0.87) - temp3 - temp8) 'temp3*1.2 ' width of the shuttlebay ops button
If temp9>0 Then
AddLCAR("T1", 0, temp+8+temp3, 0, temp9, temp, 0,0, LCAR.LCAR_ORANGE, LCAR.LCAR_Button, "", "","", -1, True,0,True,0 ,255)'element
Else
temp9=-4
End If
temp7=temp+12+temp3+temp9
AddLCAR("T2", 0, temp7, 0, temp8, temp, 0,0, LCAR.LCAR_ORANGE, LCAR.LCAR_Button, "SHUTTLE BAYS 2/3", "","", -1, True,7,True,0 ,255)'element
tempstr="MAIN SHUTTLE BAY"
temp3=LCAR.TextWidth(BG,tempstr)
temp7=temp7+temp8+4
temp0=temp7-temp5-temp
temp11= Max(temp3+temp*3+LCAR.LCARCornerElbow2.Width,temp0) 'width of elbow
temp12= Max(temp10, temp+LCAR.LCARCornerElbow2.height) 'height of elbow
AddLCAR("TR", 0, temp7,0, temp11, temp12, temp*3, temp, LCAR.LCAR_ORANGE, LCAR.LCAR_Elbow, tempstr, "", "", -1, True, -7, True, 1, 255)
temp0= temp7+temp11
temp11=temp0 - temp*3'x of new area
temp6=msdHeight-temp',temp
AddLCAR("BL1", 0, 0,temp6, temp,temp-1, 0, 0, LCAR.LCAR_ORANGE, LCAR.LCAR_Button, "", "","",-1, True,0,True,-4 ,255)'element
temp7=temp5*0.47
AddLCAR("BL2", 0, temp+4, temp6, temp7, temp, 0, 0, LCAR.LCAR_ORANGE, LCAR.LCAR_Button, "APPROACH VECTORS", "","", -1, True,1,True,0 ,255)'element
temp7=temp+8+temp7
temp5=temp5*0.5-8
AddLCAR("BL3", 0, temp7, temp6, temp8, temp, 0, 0, LCAR.LCAR_Purple, LCAR.LCAR_Button, "PRIMARY ACQUISITION ZONE", "","", -1, True, 1,True,0 ,255)'element
temp7=temp7+temp8+4'X
temp1 = temp0-temp7'width
AddLCAR("BR", 0, temp7, msdHeight-temp12, temp1, temp12, temp*3, temp, LCAR.LCAR_DarkPurple, LCAR.LCAR_Elbow, "TRACTOR CONTROL ZONE", "","", -1, True,-1,True,3 ,255)'element
'temp11=x temp12 +4=y
temp4=( msdHeight-(temp12+4)*2 )/2
temp5=temp12+6+temp4
temp6=temp12+2 + temp4 - temp
AddLCAR("NT", 0, temp11, temp12+2, temp*4, temp4, temp*3, temp, LCAR.LCAR_ORANGE, LCAR.LCAR_Elbow, "", "", "", -1, True, 0,True, 2 ,255)
AddLCAR("NB", 0, temp11, temp5, temp*4, temp4-1, temp*3, temp, LCAR.LCAR_ORANGE, LCAR.LCAR_Elbow, "", "", "", -1, True, 0,True, 0 ,255)
LCARSeffects2.ShuttleVehicleW = LCAR.TextWidth(BG,"SHUTTLE VEHICLE")*1.5
LCARSeffects2.StatusW = LCAR.TextWidth(BG,"STATUS")*1.5
LCARSeffects2.LocationW = LCAR.TextWidth(BG,"LOCATION")*1.5
temp2=LCARSeffects2.ShuttleVehicleW + LCARSeffects2.StatusW + LCARSeffects2.LocationW + 4
temp3=(msdHeight/2)-temp*2
temp11=temp11+temp*4+4
AddLCAR("TR1", 0, temp11, temp6, LCARSeffects2.ShuttleVehicleW, temp, 0, 0, LCAR.LCAR_ORANGE, LCAR.LCAR_Button, "SHUTTLE VEHICLE", "","", -1, True,7,True,0 ,255)'element
AddLCAR("BR1", 0, temp11, temp5, LCARSeffects2.ShuttleVehicleW, temp, 0, 0, LCAR.LCAR_ORANGE, LCAR.LCAR_Button, "2840", "","", -1, True,1,True,0 ,255)'element
AddLCAR("SHTL", 0, temp11,0, temp2, temp3, 1,0, LCAR.LCAR_Black, LCAR.LCAR_Shuttlebay, "", "", "", -1,True, 0, True,0,255)
AddLCAR("PODS", 0, temp11,temp5+temp*2, temp2, temp3, 2,0, LCAR.LCAR_Black, LCAR.LCAR_Shuttlebay, "", "", "", -1,True, 0, True,0,255)
temp11= temp11+LCARSeffects2.ShuttleVehicleW+4
AddLCAR("TR2", 0, temp11, temp6, LCARSeffects2.StatusW, temp, 0, 0, LCAR.LCAR_yellow, LCAR.LCAR_Button, "STATUS", "","", -1, True,7,True,0 ,255)'element
AddLCAR("BR2", 0, temp11, temp5, LCARSeffects2.StatusW, temp, 0, 0, LCAR.LCAR_yellow, LCAR.LCAR_Button, "9395", "","", -1, True,1,True,0 ,255)'element
temp11= temp11+LCARSeffects2.StatusW+4
AddLCAR("TR3", 0, temp11, temp6, LCARSeffects2.LocationW, temp, 0, 0, LCAR.LCAR_LightOrange, LCAR.LCAR_Button, "LOCATION", "","", -1, True,7,True,0 ,255)'element
AddLCAR("BR3", 0, temp11, temp5, LCARSeffects2.LocationW, temp, 0, 0, LCAR.LCAR_LightOrange, LCAR.LCAR_Button, "6348", "","", -1, True,1,True,0 ,255)'element
temp11= temp11+LCARSeffects2.LocationW+4
temp2=LCAR.TextWidth(BG,"0897 1324")+10
AddLCAR("TR4", 0, temp11, temp6, temp2, temp, 0, 0, LCAR.LCAR_LightOrange, LCAR.LCAR_Button, "0897 1324", "","", -1, True,7,True,0 ,255)'element
AddLCAR("BR4", 0, temp11, temp5, temp2, temp, 0, 0, LCAR.LCAR_LightOrange, LCAR.LCAR_Button, "8348 8385", "","", -1, True,1,True,0 ,255)'element
temp11= temp11+temp2+4
AddLCAR("TR5", 0, temp11, temp6, temp, temp, 0, 0, LCAR.LCAR_LightOrange, LCAR.LCAR_Button, "", "","", -1, True,7,True,-5 ,255)'element
AddLCAR("BR5", 0, temp11, temp5, temp, temp, 0, 0, LCAR.LCAR_LightOrange, LCAR.LCAR_Button, "", "","", -1, True,1,True,-5 ,255)'element
Case 22'CONN
temp0 = LCAR.ListItemsHeight(5)'height of top half
temp1 = msdHeight -LCAR.ListItemsHeight(8) + LCAR.LCARCornerElbow2.height'Y of bottom half
temp4= LCAR.leftside*3 + LCAR.TextWidth(BG,"20150")'width of the minibuttons
If temp0>100 Or temp4>100 Then ElbowSize = Min(temp0,temp4*2) * 0.5 Else ElbowSize=LCAR.LCARCornerElbow2.height' LCAR.InnerElbowSize2(temp11, temp2, False)
If temp1 < temp0 + ElbowSize Then temp1 = temp0 + ElbowSize 'force it to be below the upper half
temp3=msdHeight-temp1'height of bottom
temp11 = temp0 * LCARSeffects.DpadCenter *1.6 'width of center
temp2 = temp0 * 0.5 - (temp11*0.5)'X coord in dpad of start of middle
'Column 1
AddLCAR("DPD1", 0, temp0*0.5, 0, temp0,temp0, 0,0, LCAR.LCAR_Orange, LCAR.LCAR_Dpad, "","","", -1 ,True, 0,True, 0,0)
AddLCAR("SLNT", 0, 0, temp1, temp0*1.5, LCAR.ListItemsHeight(7)+8, 22, 0, LCAR.LCAR_DarkOrange, LCAR.LCAR_LWP, "", "","", -1,True, temp0,True,temp11,255)
'Column 2
temp = temp0*1.5+5
'temp4= LCAR.leftside*3 + LCAR.TextWidth(BG,"20150")'width of the minibuttons
temp8=temp1+LCAR.ItemHeight*2'start of items
AddLCAR("0027", 0, temp+temp4, temp1+LCAR.ItemHeight*2, temp4, LCAR.ItemHeight, 0,0, LCAR.LCAR_Orange, LCAR.LCAR_MiniButton, "27", "", "", -1, True, 6, True,0,255)
AddLCAR("0330", 0, temp+temp4, temp1+LCAR.ItemHeight*3+2, temp4, LCAR.ItemHeight, 0,0, LCAR.LCAR_Yellow, LCAR.LCAR_MiniButton, "330", "", "", -1, True, 6, True,0,255)
AddLCAR("0495", 0, temp+temp4, temp1+LCAR.ItemHeight*4+4, temp4, LCAR.ItemHeight, 0,0, LCAR.LCAR_Blue, LCAR.LCAR_MiniButton, "495", "", "", -1, True, 6, True,0,255)
AddLCAR("0023", 0, temp+temp4, temp1+LCAR.ItemHeight*5+6, temp4, LCAR.ItemHeight, 0,0, LCAR.LCAR_Orange, LCAR.LCAR_MiniButton, "23", "", "", -1, True, 6, True,0,255)
AddLCAR("0845", 0, temp+temp4, temp1+LCAR.ItemHeight*6+8, temp4, LCAR.ItemHeight, 0,0, LCAR.LCAR_Blue, LCAR.LCAR_MiniButton, "845", "", "", -1, True, 6, True,0,255)
'Column 3
temp5=temp1+LCAR.ItemHeight*2
temp6=temp+temp4*2+10
AddLCAR("300T", 0, temp6+LCAR.leftside*3+32, temp8, LCAR.NumberWhiteSpace , LCAR.NumberTextSize, -1,0, LCAR.LCAR_Yellow, LCAR.LCAR_Textbox, "300", "", "", 0, True, 6, True,0,255)'group 0
AddLCAR("300L", 0, temp6+20, temp8, LCAR.leftside, LCAR.ItemHeight-1, LCAR.leftside,0,LCAR.LCAR_Yellow, LCAR.lcar_button,"", "","", 0,True, 6,True,0,255)
AddLCAR("300M", 0, temp6+LCAR.leftside+32, temp8, LCAR.leftside*2, LCAR.ItemHeight, 0, 0, LCAR.LCAR_Yellow, LCAR.LCAR_Button,"324", "", "", 0, True, 6, True, 0,255)
AddLCAR("300R", 0, temp6+LCAR.leftside*3+LCAR.NumberWhiteSpace+34, temp8, LCAR.leftside, LCAR.ItemHeight, 0, 0, LCAR.LCAR_Yellow, LCAR.LCAR_Button,"", "", "", 0, True, 6, True, 0,255)
AddLCAR("477L", 0, temp6+20, temp8+LCAR.ItemHeight+2, LCAR.leftside, LCAR.ItemHeight-1, LCAR.leftside,0,LCAR.LCAR_LightYellow, LCAR.lcar_button,"", "","", 1,True, 6,True,0,255)'group 1
AddLCAR("477M", 0, temp6+LCAR.leftside+32, temp8+LCAR.ItemHeight+2, LCAR.leftside*2, LCAR.ItemHeight, 0, 0, LCAR.LCAR_Orange, LCAR.LCAR_Button,"4077", "", "", 1, True, 6, True, 0,255)
AddLCAR("477R", 0, temp6+LCAR.leftside*3+LCAR.NumberWhiteSpace+34, temp8+LCAR.ItemHeight+2, LCAR.leftside, LCAR.ItemHeight, 0, 0, LCAR.LCAR_LightYellow, LCAR.LCAR_Button,"", "", "", 1, True, 6, True, 0,255)
AddLCAR("947T", 0, temp6+LCAR.leftside*3+32, temp8+LCAR.ItemHeight*2+4, LCAR.NumberWhiteSpace , LCAR.NumberTextSize, -1,0, LCAR.LCAR_Blue, LCAR.LCAR_Textbox, "947", "", "", 2, True, 6, True,0,255)'group 2
AddLCAR("947L", 0, temp6+20, temp8+LCAR.ItemHeight*2+4, LCAR.leftside, LCAR.ItemHeight-1, LCAR.leftside,0,LCAR.LCAR_Blue, LCAR.lcar_button,"", "","", 2,True, 6,True,0,255)
AddLCAR("947M", 0, temp6+LCAR.leftside+32, temp8+LCAR.ItemHeight*2+4, LCAR.leftside*2, LCAR.ItemHeight, 0, 0, LCAR.LCAR_Blue, LCAR.LCAR_Button,"411", "", "", 2, True, 6, True, 0,255)
AddLCAR("947R", 0, temp6+LCAR.leftside*3+LCAR.NumberWhiteSpace+34, temp8+LCAR.ItemHeight*2+4, LCAR.leftside, LCAR.ItemHeight, 0, 0, LCAR.LCAR_Blue, LCAR.LCAR_Button,"", "", "", 2, True, 6, True, 0,255)
AddLCAR("088T", 0, temp6+LCAR.leftside*3+32, temp8+LCAR.ItemHeight*3+6, LCAR.NumberWhiteSpace , LCAR.NumberTextSize, -1,0, LCAR.LCAR_Orange, LCAR.LCAR_Textbox, "88", "", "", 3, True, 6, True,0,255)'group 3
AddLCAR("088L", 0, temp6+20, temp8+LCAR.ItemHeight*3+6, LCAR.leftside, LCAR.ItemHeight-1, LCAR.leftside,0,LCAR.LCAR_Blue, LCAR.lcar_button,"", "","", 3,True, 6,True,0,255)
AddLCAR("088M", 0, temp6+LCAR.leftside+32, temp8+LCAR.ItemHeight*3+6, LCAR.leftside*2, LCAR.ItemHeight, 0, 0, LCAR.LCAR_Orange, LCAR.LCAR_Button,"265", "", "", 3, True, 6, True, 0,255)
AddLCAR("088R", 0, temp6+LCAR.leftside*3+LCAR.NumberWhiteSpace+34, temp8+LCAR.ItemHeight*3+6, LCAR.leftside, LCAR.ItemHeight, 0, 0, LCAR.LCAR_Blue, LCAR.LCAR_Button,"", "", "", 3, True, 6, True, 0,255)
AddLCAR("083T", 0, temp6+LCAR.leftside*3+32, temp8+LCAR.ItemHeight*4+8, LCAR.NumberWhiteSpace , LCAR.NumberTextSize, -1,0, LCAR.LCAR_Blue, LCAR.LCAR_Textbox, "83", "", "", 4, True, 6, True,0,255)'group 4
AddLCAR("083L", 0, temp6+20, temp8+LCAR.ItemHeight*4+8, LCAR.leftside, LCAR.ItemHeight-1, LCAR.leftside,0,LCAR.LCAR_DarkOrange, LCAR.lcar_button,"", "","", 4,True, 6,True,0,255)