Browse Source

misc airs

shuvit 5 years ago
parent
commit
8e14facab5

BIN
scripts/__pycache__/co_ActionState.cpython-36.pyc View File


BIN
scripts/__pycache__/controller2.cpython-36.pyc View File


BIN
scripts/__pycache__/grindV2.cpython-36.pyc View File


BIN
scripts/__pycache__/scene_init.cpython-36.pyc View File


+ 25
- 2
scripts/co_ActionState.py View File

@@ -935,7 +935,30 @@ def main():
935 935
             requestAction = 'fak_air_tail to manual'                                    
936 936
             
937 937
         if l_actionState == 'fak_air_nose to nmanual' and requestAction in ['reg_land', 'fak_land'] and own['actionTimer'] > 1:
938
-            requestAction = 'fak_air_nose to nmanual'                                               
938
+            requestAction = 'fak_air_nose to nmanual'            
939
+
940
+        if requestAction in ['fak_land', 'reg_land']:  
941
+            requestAction = own['lland']
942
+        if l_actionState == 'reg_air-roll' and requestAction == 'fak_landL':
943
+            requestAction = 'reg_landL'    
944
+        if l_actionState == 'reg_air-roll' and requestAction == 'fak_landLb':
945
+            requestAction = 'reg_landLb'
946
+        if l_actionState == 'reg_air-roll' and requestAction == 'fak_landR':
947
+            requestAction = 'reg_landR'    
948
+        if l_actionState == 'reg_air-roll' and requestAction == 'fak_landRb':
949
+            requestAction = 'reg_landRb'    
950
+        if l_actionState == 'reg_air-roll' and requestAction == 'fak_land':
951
+            requestAction = 'reg_land'            
952
+        if l_actionState == 'fak_air-roll' and requestAction == 'reg_landL':
953
+            requestAction = 'fak_landL'    
954
+        if l_actionState == 'fak_air-roll' and requestAction == 'reg_landLb':
955
+            requestAction = 'fak_landLb'
956
+        if l_actionState == 'fak_air-roll' and requestAction == 'reg_landR':
957
+            requestAction = 'fak_landR'    
958
+        if l_actionState == 'fak_air-roll' and requestAction == 'reg_landRb':
959
+            requestAction = 'fak_landRb'            
960
+        if l_actionState == 'fak_air-roll' and requestAction == 'reg_land':
961
+            requestAction = 'fak_land'                
939 962
 #---------------------------------------------------                                                                                  
940 963
                                                                                   
941 964
                                                                                                                                                         
@@ -5077,7 +5100,7 @@ def main():
5077 5100
     if trans_playing:
5078 5101
         cur_frame = skater.getActionFrame(trans_layer)  
5079 5102
         cur_frame = round(cur_frame, 2)     
5080
-    #print('oG: ', og_request, 'rA:', requestAction, '|aS:', own['actionState'], 'q', queueAction, own['actionTimer'], 'cf', cur_frame)
5103
+    print('oG: ', og_request, 'rA:', requestAction, '|aS:', own['actionState'], 'q', queueAction, own['actionTimer'], 'cf', cur_frame)
5081 5104
     #print('rA:', requestAction, '|aS:', own['actionState'], own['actionTimer'], 'cf', cur_frame)
5082 5105
     cur_frame = skater.getActionFrame(trans_layer)
5083 5106
     #print(cur_frame)

+ 11
- 8
scripts/controller2.py View File

@@ -243,10 +243,10 @@ def main():
243 243
         balance = 0
244 244
     #print(balance)
245 245
     #if ground_since > 0 and ground_since < 5 and jump_timer < 30:
246
-    if ground_since > -1 and ground_since < 2000000:
246
+    if ground_since > -1 and ground_since < 200:
247 247
         #print(balance, 'balance')
248
-        sens = 2
249
-        sens2 = .6
248
+        sens = 1.8
249
+        sens2 = .2
250 250
         sens3 = 1.2
251 251
         if balance > sens or balance < - sens:
252 252
             #fall
@@ -4579,17 +4579,19 @@ def main():
4579 4579
         Distance = -2
4580 4580
         End = Vector.copy(own.worldPosition + (own.worldOrientation.col[Axis]*Distance))
4581 4581
         Start = Vector.copy(own.worldPosition)
4582
-        localRay_v = own.rayCast(End, Start, 0, 'vert', 1, 0, 0)
4582
+        localRay_v = own.rayCast(End, Start, 0, 'vert', 1, 0, 0, 61439)
4583 4583
         if localRay_v[0] and own['LAST_GRIND'] == False and rBump == 0 and ((own['framenum'] - own['last_transition_frame'] < 10) or (own['framenum'] - own['last_vert_frame'] < 10)):
4584 4584
             own['vert'] = 1
4585
+            print('vert hit')
4585 4586
             own['last_vert_frame'] = own['framenum']
4586 4587
             localHitDist = Vector.copy(Start - localRay_v[1]).length
4587 4588
             own.linearVelocity.x *= .98
4588 4589
             own.linearVelocity.z = .1
4589 4590
             #if localHitDist < .8 and (dict['lUD'] < .04 or dict['lUD'] > -.04):
4590
-            if localHitDist < .8:    
4591
+            #if localHitDist < .8:    
4592
+            if localHitDist < 1.5:        
4591 4593
                 #own.applyMovement((0,0,((.4 - (localHitDist) * .1))), True)
4592
-                own.applyMovement((0, 0, (.4 - localHitDist)), True)
4594
+                own.applyMovement((0, 0, (.3 - localHitDist)), True)
4593 4595
                 #print('moving vert ray')
4594 4596
                 if localRay_v[2] != [0, 0, -1] and grindHit == 0:
4595 4597
                 #if localRay_v[2] != [0,0,-1]:
@@ -4621,10 +4623,9 @@ def main():
4621 4623
             aligned = True
4622 4624
             print('rayb hit')
4623 4625
 
4624
-    #print(raytof, raytob)
4625 4626
 
4626 4627
     if not aligned:
4627
-        own.alignAxisToVect([0.0, 0.0, 1.0], 2, .03)
4628
+        own.alignAxisToVect([0.0, 0.0, 1.0], 2, .00003)
4628 4629
 
4629 4630
     if own.linearVelocity.x > 12:
4630 4631
         own.linearVelocity.x = 12
@@ -4664,3 +4665,5 @@ def main():
4664 4665
         elif land_overRideRb == True:
4665 4666
             own['requestAction'] = 'fak_landRb'
4666 4667
             print('requesting unbalanced land2b')
4668
+    if own['requestAction'] in ['fak_land', 'reg_land', 'fak_landL', 'reg_landR', 'fak_landRb', 'reg_landLb']:
4669
+        own['lland'] = own['requestAction']

+ 9
- 8
scripts/grindV2.py View File

@@ -92,13 +92,12 @@ def main():
92 92
         no_grind = 0
93 93
         own['no_grind_timer'] -= 1
94 94
 
95
-    if grindold == 1:
96
-        no_grind = 0
95
+    
97 96
 
98
-    if frames_since_ground > 30 or since_jumped < 120:
99
-        no_grind = 0
100
-    if jump_timer > 50:
101
-        no_grind = 1
97
+    # if frames_since_ground > 30 or since_jumped < 120:
98
+    #     no_grind = 0
99
+    # if jump_timer > 50:
100
+    #     no_grind = 1
102 101
 
103 102
     if (own['fak_nmanual'] == 1 or own['reg_nmanual'] == 1 or own['fak_manual'] == 1 or own['reg_manual'] == 1):
104 103
         manual = 1
@@ -111,12 +110,14 @@ def main():
111 110
     if (framenum - own['last_vert_frame'] < 40) and own['vert'] == 0:
112 111
         no_grind = 1
113 112
         print('no_grind = 1 last vert = ', (framenum - own['last_vert_frame']))
114
-    if dict['rBump'] == 1:
113
+    if dict['rBump'] == 1 or (framenum - own['last_vert_frame'] > 40):
115 114
         no_grind = 0
116 115
 
117 116
     if own['LAST_GRIND']:
118 117
         no_grind = 0
119
-    
118
+
119
+    if grindold == 1:
120
+        no_grind = 0
120 121
 #---------###########___###########-----------
121 122
 #start new                     #######
122 123
 ##----------##############----------############

+ 1
- 0
scripts/scene_init.py View File

@@ -146,6 +146,7 @@ def main():
146 146
         own['last_vert_frame'] = 0
147 147
         own['ragdoll_active'] = False
148 148
         own['rd_to_delete'] = None
149
+        own['lland'] = ''
149 150
         
150 151
         colors.update_shirt_tex() 
151 152
         colors.update_truck_tex()

Loading…
Cancel
Save