shuvit 6 years ago
parent
commit
fe43a13f1e
1 changed files with 574 additions and 3 deletions
  1. 574
    3
      joy_cam.py

+ 574
- 3
joy_cam.py View File

@@ -9,11 +9,25 @@ def main():
9 9
 #####
10 10
     #init
11 11
     cont = bge.logic.getCurrentController()
12
+    scene = bge.logic.getCurrentScene()
12 13
     own = cont.owner
14
+    dict = bge.logic.globalDict #Get the global dictionary
13 15
     aXis = cont.sensors['stickDirections']
14 16
     bUtt = cont.sensors['buttons'] 
15 17
     reduction = 400000
16 18
     axisTh = 0.03 
19
+    
20
+    dict['last_aBut'] = own['aBut']
21
+    dict['last_bBut'] = own['bBut']
22
+    dict['last_xBut'] = own['xBut']
23
+    dict['last_yBut'] = own['yBut']
24
+    dict['last_lBump'] = own['lBump']
25
+    dict['last_rBump'] = own['rBump']
26
+    dict['last_stBut'] = own['stBut']
27
+    dict['last_bkBut'] = own['bkBut']
28
+    dict['last_ltsBut'] = own['ltsBut']
29
+    dict['last_rtsBut'] = own['rtsBut']    
30
+    
17 31
 
18 32
 #####
19 33
     #hard controller mappings    
@@ -67,6 +81,48 @@ def main():
67 81
     udPad = bUtt.getButtonStatus(u_dp)
68 82
     ddPad = bUtt.getButtonStatus(d_dp)
69 83
 
84
+#######
85
+    #get own['idle']
86
+    idle_trig_list = [lLR, lUD, rLR, rUD, lTrig, rTrig]
87
+    idle_time = 240
88
+    idle_set = 1
89
+    for sens in idle_trig_list:
90
+        if sens > 20 or sens < -20:
91
+            idle_set = 0
92
+            own['idle_timer'] = idle_time
93
+    if idle_set == idle_time:
94
+        pass
95
+    if own['idle_timer'] == 1:
96
+        own['idle'] = True
97
+        #own['idlecampos_x'] = 0
98
+        own['idlecampos_z'] = 0
99
+    else:
100
+        own['idle'] = False    
101
+    
102
+    if own['idle_timer'] > 1:
103
+        own['idle_timer'] -= 1
104
+         
105
+    #print(own['idle_timer'], own['idle'])
106
+####    
107
+    if own['idle']:
108
+        move_len = 1080
109
+        if own['idlecampos_x'] < move_len:
110
+            own['idlecampos_x'] += 1
111
+        if own['idlecampos_x'] == move_len:
112
+           own['idlecampos_x'] = 0     
113
+            
114
+        if own['idlecampos_x'] < (move_len / 2):
115
+            move = [.0002, 0, 0]
116
+            own.applyMovement( move, True)
117
+            own.applyRotation([.00004, 0, .00005],True)
118
+            #print('idle2')
119
+        if own['idlecampos_x'] > (move_len / 2):
120
+            move = [-.0002, 0, 0]
121
+            own.applyMovement( move, True)
122
+            own.applyRotation([-.00004, 0, -.00005],True)
123
+            #print('idle2')     
124
+        #print(own['idlecampos_x'])                           
125
+    
70 126
 
71 127
 #####
72 128
     #create modified axis values
@@ -103,19 +159,26 @@ def main():
103 159
     #move camera
104 160
     damping = .95
105 161
     damping2 = 1.005
106
-    mult = .0005
162
+    mult = .0005 * own['speed_mult']
107 163
     move_x = lmUD * mult
108 164
     move_y = lmLR * mult
109 165
     move_z = (mTrig * -mult) / 4
110 166
     
111
-    rot_mult = -.00005
167
+    rot_mult = -.00015 * own['speed_mult']
112 168
     rot_x = rmUD * rot_mult
113 169
     rot_y = rmLR * rot_mult
114 170
     
115 171
     if move_x == 0 and own['last_move_x'] != 0:
116 172
         move_x = own['last_move_x'] * damping
117 173
     if move_y == 0 and own['last_move_y'] != 0:
118
-        move_y = own['last_move_y'] * damping                  
174
+        move_y = own['last_move_y'] * damping 
175
+    if move_z == 0 and own['last_move_z'] != 0:
176
+        move_z = own['last_move_z'] * damping         
177
+    if rot_x == 0 and own['last_rot_x'] != 0:
178
+        rot_x = own['last_rot_x'] * damping
179
+    if rot_y == 0 and own['last_rot_y'] != 0:
180
+        rot_y = own['last_rot_y'] * damping         
181
+                         
119 182
     
120 183
     move = [move_y, 0, move_x]
121 184
     own.applyMovement( move, True)
@@ -123,6 +186,487 @@ def main():
123 186
     own.applyRotation([rot_x, 0, 0],True)
124 187
     own.applyRotation([0, 0, rot_y],False)
125 188
 
189
+    mult = .1 #* own['speed_mult']
190
+    if lBump == True and own['lBump'] == False:
191
+        if own['speed_mult'] > .1:
192
+            own['speed_mult'] = round(own['speed_mult'] - mult, 2)
193
+    if rBump == True and own['rBump'] == False:
194
+        if own['speed_mult'] < 5.5:
195
+            own['speed_mult'] = round(own['speed_mult'] + mult, 2)            
196
+
197
+    if stBut == True and own['stBut'] != True:
198
+        if own['menu_on'] == False:
199
+            own['menu_on'] = True
200
+
201
+        else:    
202
+            own['menu_on'] = False            
203
+    #if own['menu_on'] == True:
204
+        #empty = scene.objects["menuEmpty"]
205
+        #bg = scene.objects['menu_background']
206
+        #h1 = scene.objects['h1Text']
207
+        #bg.worldPosition = empty.worldPosition
208
+        #bg.orientation = empty.orientation
209
+        #h1.worldPosition = empty.worldPosition
210
+        #h1.orientation = empty.orientation   
211
+        #h1 = scene.objects['h1Text']
212
+        #h1.text = str("user@shuvit.org~:\\") 
213
+        
214
+        
215
+    menu_item = own['menu_item']    
216
+    #menu_list = ['Brightness/Contrast: ', 'Brightness Value: ', 'Contrast Value: ', 'FXAA: ', 'FXAA Span Max: ', 'SSAO: ', 'SSAO Only: ', 'SSAO Width: ', 'SSAO Radius: ', 'HDR: ', 'HDR Amount: ', 'HDR AvgL: ', 'Camera Focal Length: ',  'Restart  ', 'Exit  ']
217
+    menu_list = ['Brightness/Contrast: ', 'FXAA: ', 'SSAO: ', 'HDR: ', 'Camera: ',  'Restart: ', 'Exit: ']
218
+    
219
+    brightnesscontrast_opt = ['On/Off: ', 'Brightness Value: ', 'Contrast Value: ', 'Back: ']
220
+    fxaa_opt = ['On/Off: ', 'FXAA Span Max: ', 'Back: ']
221
+    ssao_opt = ['On/Off: ', 'SSAO Only: ', 'SSAO Width: ', 'SSAO Radius: ', 'Back: ']
222
+    hdr_opt = ['On/Off: ', 'HDR Amount: ', 'HDR AvgL: ', 'Back: ']
223
+    camera_opt = ['Focal Length: ', 'Back: ']
224
+################    
225
+    
226
+    submenu_on = own['submenu_on']
227
+    if aBut == False and own['aBut'] == True:
228
+        if submenu_on:
229
+            own['submenu_item'] += 1
230
+        else: 
231
+            if own['menu_item'] < (len(menu_list) - 1):   
232
+                own['menu_item'] += 1
233
+    if yBut == False and own['yBut'] == True:
234
+        if submenu_on:
235
+            own['submenu_item'] -= 1
236
+        else:    
237
+            if own['menu_item'] > 0:
238
+                own['menu_item'] -= 1
239
+    menu_item = own['menu_item']
240
+    submenu_item = own['submenu_item']
241
+    dict['menuText'] = menu_list[menu_item] 
242
+    #dict['submenuText'] = menu_list[submenu_item] 
243
+    
244
+    if menu_list[menu_item] == 'Brightness/Contrast: ':
245
+        if submenu_on == True:
246
+            try:
247
+                dict['submenuText'] = brightnesscontrast_opt[submenu_item]
248
+            except:
249
+                submenu_item = 0
250
+                own['submenu_item'] = 0
251
+                dict['submenuText'] = brightnesscontrast_opt[submenu_item]    
252
+            if brightnesscontrast_opt[submenu_item] == 'On/Off: ':
253
+                if own['bc'] == False:
254
+                    dict['optionText'] = 'Off'
255
+                if own['bc'] == True:
256
+                    dict['optionText'] = 'On'
257
+            if brightnesscontrast_opt[submenu_item] == 'Brightness Value: ':
258
+                dict['optionText'] = round(own['BC_BRIGHTNESS'], 2)
259
+            if brightnesscontrast_opt[submenu_item] == 'Contrast Value: ': 
260
+                dict['optionText'] = round(own['BC_CONTRAST'], 2)
261
+            if brightnesscontrast_opt[submenu_item] == 'Back: ': 
262
+                dict['optionText'] = '_'       
263
+        else:
264
+            dict['optionText'] = ''                             
265
+
266
+    if menu_list[menu_item] == 'FXAA: ':
267
+        if submenu_on == True:
268
+            try:
269
+                dict['submenuText'] = fxaa_opt[submenu_item]
270
+            except:
271
+                submenu_item = 0
272
+                own['submenu_item'] = 0
273
+                dict['submenuText'] = fxaa_opt[submenu_item]    
274
+            if fxaa_opt[submenu_item] == 'On/Off: ':
275
+                if own['bc'] == False:
276
+                    dict['optionText'] = 'Off'
277
+                if own['bc'] == True:
278
+                    dict['optionText'] = 'On'
279
+            if fxaa_opt[submenu_item] == 'FXAA Span Max: ':
280
+                dict['optionText'] = round(own['FXAA_SPAN_MAX'], 2)
281
+            if fxaa_opt[submenu_item] == 'Back: ': 
282
+                dict['optionText'] = '_'       
283
+        else:
284
+            dict['optionText'] = ''
285
+
286
+
287
+
288
+    #     if own['fxaa'] == False:
289
+    #         dict['optionText'] = 'Off'
290
+    #     if own['fxaa'] == True:
291
+    #         dict['optionText'] = 'On' 
292
+    # if menu_list[menu_item] == 'FXAA Span Max: ':
293
+    #     dict['optionText'] = round(own['FXAA_SPAN_MAX'], 2)
294
+
295
+    if menu_list[menu_item] == 'HDR: ':
296
+
297
+
298
+        if submenu_on == True:
299
+            try:
300
+                dict['submenuText'] = hdr_opt[submenu_item]
301
+            except:
302
+                submenu_item = 0
303
+                own['submenu_item'] = 0
304
+                dict['submenuText'] = hdr_opt[submenu_item]    
305
+            if hdr_opt[submenu_item] == 'On/Off: ':
306
+                if own['bc'] == False:
307
+                    dict['optionText'] = 'Off'
308
+                if own['bc'] == True:
309
+                    dict['optionText'] = 'On'
310
+            if hdr_opt[submenu_item] == 'HDR Amount: ':
311
+                dict['optionText'] = round(own['HDRamount'], 2)
312
+            if hdr_opt[submenu_item] == 'HDR AvgL: ': 
313
+                dict['optionText'] = round(own['avgL'], 2)
314
+            if hdr_opt[submenu_item] == 'Back: ': 
315
+                dict['optionText'] = '_'       
316
+        else:
317
+            dict['optionText'] = '' 
318
+
319
+
320
+        # if own['hdr'] == False:
321
+        #     dict['optionText'] = 'Off'
322
+        # if own['hdr'] == True:
323
+        #     dict['optionText'] = 'On' 
324
+
325
+    # if menu_list[menu_item] == 'HDR Amount: ':
326
+    #     dict['optionText'] = round(own['HDRamount'], 2)
327
+    # if menu_list[menu_item] == 'HDR AvgL: ':
328
+    #     dict['optionText'] = round(own['avgL'], 2)                 
329
+                        
330
+ 
331
+    if menu_list[menu_item] == 'SSAO: ':
332
+        if submenu_on == True:
333
+            try:
334
+                dict['submenuText'] = ssao_opt[submenu_item]
335
+            except:
336
+                submenu_item = 0
337
+                own['submenu_item'] = 0
338
+                dict['submenuText'] = ssao_opt[submenu_item]    
339
+            if ssao_opt[submenu_item] == 'On/Off: ':
340
+                if own['ao'] == False:
341
+                    dict['optionText'] = 'Off'
342
+                if own['ao'] == True:
343
+                    dict['optionText'] = 'On'
344
+            if ssao_opt[submenu_item] == 'SSAO Only: ':
345
+                if own['onlyAO'] == False:
346
+                    dict['optionText'] = 'Off'
347
+                if own['onlyAO'] == True:
348
+                    dict['optionText'] = 'On'                    
349
+            
350
+            if ssao_opt[submenu_item] == 'SSAO Width: ': 
351
+                dict['optionText'] = round(own['aowidth'], 2)
352
+            if ssao_opt[submenu_item] == 'SSAO Radius: ': 
353
+                dict['optionText'] = round(own['aoradius'], 2)                
354
+            if ssao_opt[submenu_item] == 'Back: ': 
355
+                dict['optionText'] = '_'       
356
+        else:
357
+            dict['optionText'] = ''
358
+
359
+
360
+    #     if own['ao'] == False:
361
+    #         dict['optionText'] = 'Off'
362
+    #     if own['ao'] == True:
363
+    #         dict['optionText'] = 'On' 
364
+    # if menu_list[menu_item] == 'SSAO Only: ':
365
+    #     print('ssao menu', own['onlyAO'])
366
+    #     if own['onlyAO'] == False:
367
+    #         dict['optionText'] = 'Off'
368
+    #     if own['onlyAO'] == True:
369
+    #         dict['optionText'] = 'On'
370
+    # if menu_list[menu_item] == 'SSAO Width: ': 
371
+    #     dict['optionText'] = round(own['aowidth'], 2) 
372
+    # if menu_list[menu_item] == 'SSAO Radius: ': 
373
+    #     dict['optionText'] = round(own['aoradius'], 2)                           
374
+
375
+    if menu_list[menu_item] == 'Camera: ':
376
+
377
+
378
+        if submenu_on == True:
379
+            try:
380
+                dict['submenuText'] = camera_opt[submenu_item]
381
+            except:
382
+                submenu_item = 0
383
+                own['submenu_item'] = 0
384
+                dict['submenuText'] = camera_opt[submenu_item]    
385
+            if camera_opt[submenu_item] == 'Focal Length: ':
386
+                dict['optionText'] = round(own['cam_focal_length'], 2) 
387
+            if camera_opt[submenu_item] == 'Back: ': 
388
+                dict['optionText'] = '_'                      
389
+        else:
390
+            dict['optionText'] = ''  
391
+
392
+
393
+        
394
+        
395
+    if menu_list[menu_item] == 'Restart: ':
396
+        dict['optionText'] = ''
397
+    if menu_list[menu_item] == 'Exit: ': 
398
+        dict['optionText'] = ''                               
399
+            
400
+           
401
+                               
402
+    if bBut == False and own['bBut'] == True:
403
+        if menu_list[menu_item] == 'Brightness/Contrast: ':
404
+            if submenu_on == False:
405
+                submenu_on = True
406
+                own['submenu_on'] = True
407
+            elif submenu_on:
408
+                if brightnesscontrast_opt[submenu_item] == 'On/Off: ':
409
+                    if own['bc'] == False:
410
+                        own['bc'] = True
411
+                        act = cont.actuators['bc_act']
412
+                        cont.activate(act)
413
+                        dict['optionText'] = 'On'                    
414
+                if brightnesscontrast_opt[submenu_item] == 'Brightness Value: ':
415
+                    own['BC_BRIGHTNESS'] += .025
416
+                if brightnesscontrast_opt[submenu_item] == 'Contrast Value: ': 
417
+                    own['BC_CONTRAST'] += .025
418
+                if brightnesscontrast_opt[submenu_item] == 'Back: ': 
419
+                    own['submenu_on'] = False 
420
+                    dict['optionText'] = '_'  
421
+                    own['submenu_item'] = 0                  
422
+
423
+                          
424
+        if menu_list[menu_item] == 'FXAA: ':
425
+            if submenu_on == False:
426
+                submenu_on = True
427
+                own['submenu_on'] = True
428
+
429
+            elif submenu_on:
430
+                if fxaa_opt[submenu_item] == 'On/Off: ':
431
+                    if own['bc'] == False:
432
+                        own['bc'] = True
433
+                        act = cont.actuators['fxaa']
434
+                        cont.activate(act)
435
+                        dict['optionText'] = 'On'                    
436
+                if fxaa_opt[submenu_item] == 'FXAA Span Max: ':
437
+                    own['FXAA_SPAN_MAX'] += 1
438
+                if fxaa_opt[submenu_item] == 'Back: ': 
439
+                    own['submenu_on'] = False 
440
+                    dict['optionText'] = '_'  
441
+                    own['submenu_item'] = 0 
442
+
443
+
444
+
445
+ 
446
+        if menu_list[menu_item] == 'SSAO: ':
447
+
448
+
449
+            if submenu_on == False:
450
+                submenu_on = True
451
+                own['submenu_on'] = True
452
+            elif submenu_on:
453
+                if ssao_opt[submenu_item] == 'On/Off: ':
454
+                    if own['ao'] == False:
455
+                        own['ao'] = True
456
+                        act = cont.actuators['ao_act']
457
+                        cont.activate(act)
458
+                        dict['optionText'] = 'On'                    
459
+                if ssao_opt[submenu_item] == 'SSAO Only: ':
460
+                    if own['onlyAO'] == False:
461
+                        own['onlyAO'] = True
462
+                if ssao_opt[submenu_item] == 'SSAO Width: ': 
463
+                    own['aowidth'] += 1
464
+                if ssao_opt[submenu_item] == 'SSAO Radius: ': 
465
+                    own['aoradius'] += 1                    
466
+                if ssao_opt[submenu_item] == 'Back: ': 
467
+                    own['submenu_on'] = False 
468
+                    dict['optionText'] = '_'  
469
+                    own['submenu_item'] = 0
470
+                              
471
+                                
472
+
473
+
474
+
475
+
476
+
477
+
478
+
479
+        if menu_list[menu_item] == 'HDR: ':
480
+
481
+
482
+            if submenu_on == False:
483
+                submenu_on = True
484
+                own['submenu_on'] = True
485
+            elif submenu_on:
486
+                if hdr_opt[submenu_item] == 'On/Off: ':
487
+                    if own['hdr'] == False:
488
+                        own['hdr'] = True
489
+                        act = cont.actuators['hdr_act']
490
+                        cont.activate(act)
491
+                        dict['optionText'] = 'On'                    
492
+                if hdr_opt[submenu_item] == 'HDR Amount: ':
493
+                    own['HDRamount'] += .05
494
+                if hdr_opt[submenu_item] == 'HDR AvgL: ': 
495
+                    own['avgL'] += .05
496
+                if hdr_opt[submenu_item] == 'Back: ': 
497
+                    own['submenu_on'] = False 
498
+                    dict['optionText'] = '_'  
499
+                    own['submenu_item'] = 0 
500
+
501
+
502
+            
503
+        if menu_list[menu_item] == 'Camera: ':
504
+            if submenu_on == False:
505
+                submenu_on = True
506
+                own['submenu_on'] = True
507
+            elif submenu_on:
508
+                if camera_opt[submenu_item] == 'Focal Length: ':        
509
+                    own['cam_focal_length'] += 1
510
+                    own.lens = own['cam_focal_length']
511
+                if camera_opt[submenu_item] == 'Back: ': 
512
+                    own['submenu_on'] = False 
513
+                    dict['optionText'] = '_'  
514
+                    own['submenu_item'] = 0                     
515
+
516
+                       
517
+        if menu_list[menu_item] == 'Restart: ':
518
+            scene.restart()
519
+        if menu_list[menu_item] == 'Exit: ': 
520
+            bge.logic.endGame() 
521
+                         
522
+
523
+#333333333333333333333333333333
524
+                            
525
+    if xBut == False and own['xBut'] == True:
526
+
527
+
528
+
529
+
530
+        if menu_list[menu_item] == 'Brightness/Contrast: ':
531
+            if submenu_on == False:
532
+                submenu_on = True
533
+                own['submenu_on'] = True
534
+            if submenu_on:
535
+                if brightnesscontrast_opt[submenu_item] == 'On/Off: ':
536
+                    if own['bc'] == True:
537
+                        own['bc'] = False
538
+                        act = cont.actuators['bc_off']
539
+                        cont.activate(act)
540
+                        dict['optionText'] = 'Off'                    
541
+                if brightnesscontrast_opt[submenu_item] == 'Brightness Value: ':
542
+                    own['BC_BRIGHTNESS'] -= .025
543
+                if brightnesscontrast_opt[submenu_item] == 'Contrast Value: ': 
544
+                    own['BC_CONTRAST'] -= .025
545
+                if brightnesscontrast_opt[submenu_item] == 'Back: ': 
546
+                    own['submenu_on'] = False 
547
+                    dict['optionText'] = '_' 
548
+                    own['submenu_item'] = 0
549
+
550
+
551
+
552
+
553
+
554
+
555
+#         
556
+#        if menu_list[menu_item] == 'Brightness/Contrast: ':
557
+#            if own['bc'] == True:
558
+#                own['bc'] = False
559
+#                act = cont.actuators['bc_off']
560
+#                cont.activate(act)
561
+#                dict['optionText'] = 'Off'
562
+#        if menu_list[menu_item] == 'Brightness Value: ':
563
+#            own['BC_BRIGHTNESS'] -= .025
564
+#        if menu_list[menu_item] == 'Contrast Value: ':
565
+#            own['BC_CONTRAST'] -= .025            
566
+                                    
567
+        if menu_list[menu_item] == 'FXAA: ':     
568
+        
569
+            if submenu_on == False:
570
+                submenu_on = True
571
+                own['submenu_on'] = True
572
+            if submenu_on:
573
+                if fxaa_opt[submenu_item] == 'On/Off: ':
574
+                    if own['fxaa'] == True:
575
+                        own['fxaa'] = False
576
+                        act = cont.actuators['fxaa_off']
577
+                        cont.activate(act)
578
+                        dict['optionText'] = 'Off'                    
579
+                if fxaa_opt[submenu_item] == 'FXAA Span Max: ':
580
+                    own['FXAA_SPAN_MAX'] -= 1
581
+                if fxaa_opt[submenu_item] == 'Back: ': 
582
+                    own['submenu_on'] = False 
583
+                    dict['optionText'] = '_' 
584
+                    own['submenu_item'] = 0
585
+
586
+
587
+
588
+
589
+
590
+
591
+        if menu_list[menu_item] == 'SSAO: ' : 
592
+
593
+
594
+
595
+            if submenu_on == False:
596
+                submenu_on = True
597
+                own['submenu_on'] = True
598
+            if submenu_on:
599
+                if ssao_opt[submenu_item] == 'On/Off: ':
600
+                    if own['ao'] == True:
601
+                        own['ao'] = False
602
+                        act = cont.actuators['ao_off']
603
+                        cont.activate(act)
604
+                        dict['optionText'] = 'Off'                    
605
+                if ssao_opt[submenu_item] == 'SSAO Only: ':
606
+                    if own['onlyAO'] == True:
607
+                        own['onlyAO'] = False                    
608
+                    
609
+                if ssao_opt[submenu_item] == 'SSAO Width: ': 
610
+                    own['aowidth'] -= 1
611
+                if ssao_opt[submenu_item] == 'SSAO Radius: ': 
612
+                    own['aoradius'] -= 1                    
613
+                if ssao_opt[submenu_item] == 'Back: ': 
614
+                    own['submenu_on'] = False 
615
+                    dict['optionText'] = '_' 
616
+                    own['submenu_item'] = 0
617
+
618
+
619
+
620
+
621
+
622
+
623
+
624
+
625
+
626
+
627
+
628
+
629
+
630
+        if menu_list[menu_item] == 'HDR: ': 
631
+            
632
+
633
+
634
+            if submenu_on == False:
635
+                submenu_on = True
636
+                own['submenu_on'] = True
637
+            if submenu_on:
638
+                if hdr_opt[submenu_item] == 'On/Off: ':
639
+                    if own['hdr'] == True:
640
+                        own['hdr'] = False
641
+                        act = cont.actuators['hdr_off']
642
+                        cont.activate(act)
643
+                        dict['optionText'] = 'Off'                    
644
+                if hdr_opt[submenu_item] == 'HDR Amount: ':
645
+                    own['HDRamount'] -= .05
646
+                if hdr_opt[submenu_item] == 'HDR AvgL: ': 
647
+                    own['avgL'] -= .05
648
+                if hdr_opt[submenu_item] == 'Back: ': 
649
+                    own['submenu_on'] = False 
650
+                    dict['optionText'] = '_' 
651
+                    own['submenu_item'] = 0
652
+
653
+
654
+            
655
+
656
+        if menu_list[menu_item] == 'Camera: ':
657
+            if submenu_on == False:
658
+                submenu_on = True
659
+                own['submenu_on'] = True
660
+            elif submenu_on:
661
+                if camera_opt[submenu_item] == 'Focal Length: ':        
662
+                    own['cam_focal_length'] -= 1
663
+                    own.lens = own['cam_focal_length']
664
+                if camera_opt[submenu_item] == 'Back: ': 
665
+                    own['submenu_on'] = False 
666
+                    dict['optionText'] = '_'  
667
+                    own['submenu_item'] = 0 
668
+                                                                                           
669
+                    
126 670
     own['lmLR'] = lmLR
127 671
     own['lmUD'] = lmUD
128 672
     own['rmLR'] = rmLR
@@ -130,6 +674,9 @@ def main():
130 674
     own['mTrig'] = mTrig
131 675
     own['last_move_x'] = move_x
132 676
     own['last_move_y'] = move_y
677
+    own['last_move_z'] = move_z    
678
+    own['last_rot_x'] = rot_x
679
+    own['last_rot_y'] = rot_y    
133 680
     own['aBut'] = aBut
134 681
     own['bBut'] = bBut
135 682
     own['xBut'] = xBut
@@ -141,5 +688,29 @@ def main():
141 688
     own['ltsBut'] = ltsBut
142 689
     own['rtsBut'] = rtsBut
143 690
 
691
+    dict['aBut'] = aBut
692
+    dict['bBut'] = bBut
693
+    dict['xBut'] = xBut
694
+    dict['yBut'] = yBut
695
+    dict['lBump'] = lBump
696
+    dict['rBump'] = rBump
697
+    dict['stBut'] = stBut
698
+    dict['bkBut'] = bkBut
699
+    dict['ltsBut'] = ltsBut
700
+    dict['rtsBut'] = rtsBut
701
+    dict['menu_on'] = own['menu_on']
702
+    dict['submenu_on'] = own['submenu_on']
703
+    dict['menu_item'] = own['menu_item']
704
+    dict['submenu_item'] = own['submenu_item']
705
+    dict['fxaa'] = own['fxaa']
706
+    
707
+    
708
+    
709
+        
710
+    
711
+    print(own['submenu_on'])
712
+    #print(own['menu_item'])
713
+    #print(rot_x)
714
+
144 715
 main()
145 716
 

Loading…
Cancel
Save