mirror of
https://github.com/open-goal/jak-project
synced 2026-09-08 03:46:51 -04:00
[decomp] finish up nav-graph, traffic-engine, traffic-manager, height-map (#2191)
Some of these were almost done, just needed a few more types.
This commit is contained in:
+16
-16
@@ -58,10 +58,10 @@
|
||||
:size-assert #x29
|
||||
:flag-assert #xd00000029
|
||||
(:methods
|
||||
(traffic-suppression-params-method-9 (_type_) symbol 9)
|
||||
(traffic-suppression-params-method-10 (_type_) symbol 10)
|
||||
(try-creating-new-suppression-box (_type_) symbol 9)
|
||||
(create-or-update-suppression-box (_type_) symbol 10)
|
||||
(has-valid-id? (_type_) none 11)
|
||||
(traffic-suppression-params-method-12 (_type_) none 12)
|
||||
(kill-suppression-box (_type_) none 12)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -88,19 +88,19 @@
|
||||
|
||||
;; definition of type traffic-object-spawn-params
|
||||
(deftype traffic-object-spawn-params (structure)
|
||||
((object-type uint8 :offset-assert 0)
|
||||
(behavior uint64 :offset-assert 8)
|
||||
(id uint32 :offset-assert 16)
|
||||
(nav-mesh nav-mesh :offset-assert 20)
|
||||
(nav-branch nav-branch :offset-assert 24)
|
||||
(position vector :inline :offset-assert 32)
|
||||
(rotation quaternion :inline :offset-assert 48)
|
||||
(velocity vector :inline :offset-assert 64)
|
||||
(handle uint64 :offset-assert 80)
|
||||
(guard-type uint8 :offset-assert 88)
|
||||
(user-data uint32 :offset-assert 92)
|
||||
(flags uint32 :offset-assert 96)
|
||||
(proc process :offset-assert 100)
|
||||
((object-type traffic-type :offset-assert 0)
|
||||
(behavior uint64 :offset-assert 8)
|
||||
(id uint32 :offset-assert 16)
|
||||
(nav-mesh nav-mesh :offset-assert 20)
|
||||
(nav-branch nav-branch :offset-assert 24)
|
||||
(position vector :inline :offset-assert 32)
|
||||
(rotation quaternion :inline :offset-assert 48)
|
||||
(velocity vector :inline :offset-assert 64)
|
||||
(handle uint64 :offset-assert 80)
|
||||
(guard-type uint8 :offset-assert 88)
|
||||
(user-data uint32 :offset-assert 92)
|
||||
(flags uint32 :offset-assert 96)
|
||||
(proc process :offset-assert 100)
|
||||
)
|
||||
:method-count-assert 9
|
||||
:size-assert #x68
|
||||
|
||||
+1
-1
@@ -84,7 +84,7 @@
|
||||
(deftype joint-exploder-static-params (basic)
|
||||
((joints (array joint-exploder-static-joint-params) :offset-assert 4)
|
||||
(collide-spec uint32 :offset-assert 8)
|
||||
(art-level basic :offset-assert 12)
|
||||
(art-level symbol :offset-assert 12)
|
||||
)
|
||||
:method-count-assert 9
|
||||
:size-assert #x10
|
||||
|
||||
+6
-6
@@ -455,7 +455,7 @@
|
||||
;; definition for method 31 of type rigid-body-platform
|
||||
;; INFO: Used lq/sq
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-31 rigid-body-platform ((obj rigid-body-platform) (arg0 rigid-body-object-constants))
|
||||
(defmethod alloc-and-init-rigid-body-control rigid-body-platform ((obj rigid-body-platform) (arg0 rigid-body-object-constants))
|
||||
(with-pp
|
||||
(set! (-> obj info-override) (the-as rigid-body-platform-constants arg0))
|
||||
(set! (-> obj rbody) (new 'process 'rigid-body-control obj))
|
||||
@@ -485,7 +485,7 @@
|
||||
|
||||
;; definition for method 32 of type rigid-body-platform
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-32 rigid-body-platform ((obj rigid-body-platform))
|
||||
(defmethod allocate-and-init-cshape rigid-body-platform ((obj rigid-body-platform))
|
||||
(let ((s5-0 (new 'process 'collide-shape-moving obj (collide-list-enum hit-by-player))))
|
||||
(set! (-> s5-0 dynam) (copy *standard-dynamics* 'process))
|
||||
(set! (-> s5-0 reaction) cshape-reaction-default)
|
||||
@@ -550,9 +550,9 @@
|
||||
|
||||
;; definition for method 33 of type rigid-body-platform
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-33 rigid-body-platform ((obj rigid-body-platform))
|
||||
(defmethod init-skel-and-rigid-body rigid-body-platform ((obj rigid-body-platform))
|
||||
(set! (-> obj float-height-offset) 0.0)
|
||||
(rigid-body-object-method-31 obj *rigid-body-platform-constants*)
|
||||
(alloc-and-init-rigid-body-control obj *rigid-body-platform-constants*)
|
||||
(let ((s5-0 (-> obj info-override control-point-count)))
|
||||
(dotimes (s4-0 s5-0)
|
||||
(let ((s3-0 (-> obj control-point-array data s4-0)))
|
||||
@@ -579,9 +579,9 @@ This commonly includes things such as:
|
||||
- loading the skeleton group / bones
|
||||
- sounds"
|
||||
(set! (-> obj mask) (logior (process-mask platform) (-> obj mask)))
|
||||
(rigid-body-object-method-32 obj)
|
||||
(allocate-and-init-cshape obj)
|
||||
(process-drawable-from-entity! obj arg0)
|
||||
(rigid-body-object-method-33 obj)
|
||||
(init-skel-and-rigid-body obj)
|
||||
(rigid-body-object-method-34 obj)
|
||||
0
|
||||
(none)
|
||||
|
||||
+9
-12
@@ -102,7 +102,7 @@
|
||||
(width float :offset-assert 60)
|
||||
(minimap_edge_flag nav-minimap-edge-flag :offset-assert 64)
|
||||
)
|
||||
:pack-me
|
||||
:allow-misaligned
|
||||
:method-count-assert 10
|
||||
:size-assert #x44
|
||||
:flag-assert #xa00000044
|
||||
@@ -229,7 +229,7 @@
|
||||
|
||||
;; definition of type mysql-nav-graph-level-info
|
||||
(deftype mysql-nav-graph-level-info (structure)
|
||||
((level string :offset-assert 0)
|
||||
((level symbol :offset-assert 0)
|
||||
(level-id uint32 :offset-assert 4)
|
||||
(node-count int32 :offset-assert 8)
|
||||
(branch-count int32 :offset-assert 12)
|
||||
@@ -367,7 +367,7 @@ otherwise, return the new size of the array"
|
||||
-1
|
||||
)
|
||||
(else
|
||||
(let ((v1-5 (the-as mysql-nav-edge (+ (+ (* 80 (-> obj edge-array length)) 12) (the-as int (-> obj edge-array)))))
|
||||
(let ((v1-5 (-> obj edge-array data (-> obj edge-array length)))
|
||||
(v0-1 (-> obj edge-array length))
|
||||
)
|
||||
(+! (-> obj edge-array length) 1)
|
||||
@@ -816,7 +816,7 @@ returns `-1` if none is found"
|
||||
"Iterate through the `edge-array` and return the index for the first [[mysql-nav-edge]] whom's `nav_edge_id` matches the provided id
|
||||
returns `-1` if none is found"
|
||||
(dotimes (v1-0 (-> obj edge-array length))
|
||||
(if (= edge-id (-> (the-as mysql-nav-edge (+ (+ (* 80 v1-0) 12) (the-as int (-> obj edge-array)))) nav_edge_id))
|
||||
(if (= edge-id (-> (the-as mysql-nav-edge (-> obj edge-array data v1-0)) nav_edge_id))
|
||||
(return v1-0)
|
||||
)
|
||||
)
|
||||
@@ -958,10 +958,7 @@ returns `-1` if none is found"
|
||||
(set! sv-32 (string->int (-> s3-3 data (+ s2-2 2))))
|
||||
(set! sv-48 (indexof-nav-node obj s0-2))
|
||||
(set! sv-64 (indexof-nav-node obj sv-32))
|
||||
(let ((nav-edge
|
||||
(the-as mysql-nav-edge (+ (+ (* 80 (-> obj edge-array length)) 12) (the-as int (-> obj edge-array))))
|
||||
)
|
||||
)
|
||||
(let ((nav-edge (-> obj edge-array data (-> obj edge-array length))))
|
||||
(when (and (!= sv-48 -1) (!= sv-64 -1))
|
||||
(set! (-> nav-edge nav_graph_id) (-> obj nav_graph_id))
|
||||
(set! (-> nav-edge nav_edge_id) (the-as uint (string->int (-> s3-3 data s2-2))))
|
||||
@@ -1190,10 +1187,10 @@ returns `-1` if none is found"
|
||||
)
|
||||
)
|
||||
(dotimes (v1-3 (-> obj edge-array length))
|
||||
(set! (-> (the-as mysql-nav-edge (+ (+ (* 80 v1-3) 12) (the-as int (-> obj edge-array)))) temp-next-edge) #f)
|
||||
(set! (-> (the-as mysql-nav-edge (-> obj edge-array data v1-3)) temp-next-edge) #f)
|
||||
)
|
||||
(countdown (v1-7 (-> obj edge-array length))
|
||||
(let ((a1-17 (the-as mysql-nav-edge (+ (+ (* 80 v1-7) 12) (the-as int (-> obj edge-array))))))
|
||||
(let ((a1-17 (-> obj edge-array data v1-7)))
|
||||
(when (not (logtest? (-> a1-17 mysql-save-flag) (mysql-save-flag delete)))
|
||||
(let ((a2-8 (-> obj node-array data (-> a1-17 runtime-node-id-1))))
|
||||
(when (not (logtest? (-> a2-8 mysql-save-flag) (mysql-save-flag delete)))
|
||||
@@ -1253,7 +1250,7 @@ returns `-1` if none is found"
|
||||
(set! (-> obj level-info-last-lookup) v1-9)
|
||||
)
|
||||
(set! s5-0 (-> obj level-info-array v1-9))
|
||||
(set! (-> s5-0 level) (the-as string (-> arg0 level_name)))
|
||||
(set! (-> s5-0 level) (-> arg0 level_name))
|
||||
(set! (-> s5-0 node-count) 0)
|
||||
(+! (-> obj level-info-array-length) 1)
|
||||
)
|
||||
@@ -1346,7 +1343,7 @@ returns `-1` if none is found"
|
||||
(format #t "Done.~%")
|
||||
(format #t "Saving edges ...~%")
|
||||
(dotimes (s5-1 (-> obj edge-array length))
|
||||
(let ((a0-7 (the-as mysql-nav-edge (+ (+ (* 80 s5-1) 12) (the-as int (-> obj edge-array))))))
|
||||
(let ((a0-7 (-> obj edge-array data s5-1)))
|
||||
(set! (-> a0-7 nav_graph_id) (-> obj nav_graph_id))
|
||||
(set! (-> a0-7 nav_node_id_1) (-> obj node-array data (-> a0-7 runtime-node-id-1) nav_node_id))
|
||||
(set! (-> a0-7 nav_node_id_2) (-> obj node-array data (-> a0-7 runtime-node-id-2) nav_node_id))
|
||||
|
||||
+1
-1
@@ -43,7 +43,7 @@
|
||||
(seat-index int8 :offset-assert 41)
|
||||
(backup-nav-radius float :offset-assert 44)
|
||||
(cam-side-shift float :offset-assert 48)
|
||||
(enable-cam-side-shift basic :offset-assert 52)
|
||||
(enable-cam-side-shift symbol :offset-assert 52)
|
||||
(gun? symbol :offset-assert 56)
|
||||
(controls vehicle-controls :inline :offset-assert 60)
|
||||
(accel-array vector 8 :inline :offset-assert 80)
|
||||
|
||||
+1
-1
@@ -71,7 +71,7 @@
|
||||
(region-array region-array :offset-assert 192)
|
||||
(collide-hash collide-hash :offset-assert 196)
|
||||
(wind-array-length int32 :offset 204)
|
||||
(bsp-header-jkh1b23 clock :offset 208)
|
||||
(city-level-info city-level-info :offset 208)
|
||||
(vis-spheres vector-array :offset 216)
|
||||
(region-tree drawable-tree-region-prim :offset 252)
|
||||
(tfrag-masks texture-masks-array :offset-assert 256)
|
||||
|
||||
+2
-2
@@ -1145,7 +1145,7 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(if (and (!= (-> obj bsp bsp-header-jkh1b23) 0) *traffic-manager*)
|
||||
(if (and (!= (-> obj bsp city-level-info) 0) *traffic-manager*)
|
||||
(send-event *traffic-manager* 'level-loaded obj)
|
||||
)
|
||||
(when (-> obj info activate-func)
|
||||
@@ -1173,7 +1173,7 @@
|
||||
(case (-> obj status)
|
||||
(('active 'alive)
|
||||
(format 0 "----------- kill ~A (status ~A)~%" obj (-> obj status))
|
||||
(if (and (!= (-> obj bsp bsp-header-jkh1b23) 0) *traffic-manager*)
|
||||
(if (and (!= (-> obj bsp city-level-info) 0) *traffic-manager*)
|
||||
(send-event *traffic-manager* 'level-killed obj)
|
||||
)
|
||||
(when (-> obj info kill-func)
|
||||
|
||||
+4
-4
@@ -464,12 +464,12 @@
|
||||
(active () _type_ :state 28)
|
||||
(rigid-body-object-method-29 (_type_ float) none 29)
|
||||
(rigid-body-object-method-30 (_type_) none 30)
|
||||
(rigid-body-object-method-31 (_type_ rigid-body-object-constants) none 31)
|
||||
(rigid-body-object-method-32 (_type_) none 32)
|
||||
(rigid-body-object-method-33 (_type_) none 33)
|
||||
(alloc-and-init-rigid-body-control (_type_ rigid-body-object-constants) none 31)
|
||||
(allocate-and-init-cshape (_type_) none 32)
|
||||
(init-skel-and-rigid-body (_type_) none 33)
|
||||
(rigid-body-object-method-34 (_type_) none 34)
|
||||
(rigid-body-object-method-35 (_type_) none 35)
|
||||
(rigid-body-object-method-36 (_type_) none 36)
|
||||
(do-engine-sounds (_type_) none 36)
|
||||
(rigid-body-object-method-37 (_type_) none 37)
|
||||
(rigid-body-object-method-38 (_type_) none 38)
|
||||
(rigid-body-object-method-39 (_type_) none 39)
|
||||
|
||||
+8
-8
@@ -1001,7 +1001,7 @@
|
||||
|
||||
;; definition for method 31 of type rigid-body-object
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-31 rigid-body-object ((obj rigid-body-object) (arg0 rigid-body-object-constants))
|
||||
(defmethod alloc-and-init-rigid-body-control rigid-body-object ((obj rigid-body-object) (arg0 rigid-body-object-constants))
|
||||
(set! (-> obj info) arg0)
|
||||
(set! (-> obj rbody) (new 'process 'rigid-body-control obj))
|
||||
(update-transforms (-> obj root-override-2))
|
||||
@@ -1025,7 +1025,7 @@
|
||||
|
||||
;; definition for method 32 of type rigid-body-object
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-32 rigid-body-object ((obj rigid-body-object))
|
||||
(defmethod allocate-and-init-cshape rigid-body-object ((obj rigid-body-object))
|
||||
(let ((s5-0 (new 'process 'collide-shape-moving obj (collide-list-enum hit-by-player))))
|
||||
(set! (-> s5-0 dynam) (copy *standard-dynamics* 'process))
|
||||
(set! (-> s5-0 reaction) cshape-reaction-default)
|
||||
@@ -1077,8 +1077,8 @@
|
||||
|
||||
;; definition for method 33 of type rigid-body-object
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-33 rigid-body-object ((obj rigid-body-object))
|
||||
(rigid-body-object-method-31 obj *rigid-body-object-constants*)
|
||||
(defmethod init-skel-and-rigid-body rigid-body-object ((obj rigid-body-object))
|
||||
(alloc-and-init-rigid-body-control obj *rigid-body-object-constants*)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
@@ -1092,9 +1092,9 @@ This commonly includes things such as:
|
||||
- collision information
|
||||
- loading the skeleton group / bones
|
||||
- sounds"
|
||||
(rigid-body-object-method-32 obj)
|
||||
(allocate-and-init-cshape obj)
|
||||
(process-drawable-from-entity! obj arg0)
|
||||
(rigid-body-object-method-33 obj)
|
||||
(init-skel-and-rigid-body obj)
|
||||
(rigid-body-object-method-34 obj)
|
||||
0
|
||||
(none)
|
||||
@@ -1102,7 +1102,7 @@ This commonly includes things such as:
|
||||
|
||||
;; definition for method 36 of type rigid-body-object
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-36 rigid-body-object ((obj rigid-body-object))
|
||||
(defmethod do-engine-sounds rigid-body-object ((obj rigid-body-object))
|
||||
0
|
||||
(none)
|
||||
)
|
||||
@@ -1111,7 +1111,7 @@ This commonly includes things such as:
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-37 rigid-body-object ((obj rigid-body-object))
|
||||
(rigid-body-object-method-30 obj)
|
||||
(rigid-body-object-method-36 obj)
|
||||
(do-engine-sounds obj)
|
||||
(let ((v1-4 (-> obj rbody))
|
||||
(a1-0 (-> obj root-override-2))
|
||||
)
|
||||
|
||||
+10
-2
@@ -186,8 +186,16 @@
|
||||
target-mech-stance
|
||||
(target-mech-start handle float symbol)
|
||||
target-mech-walk
|
||||
target-pilot-edge-grab
|
||||
(target-pilot-start handle)
|
||||
(target-pilot-clone-anim handle)
|
||||
(target-pilot-death symbol)
|
||||
(target-pilot-edge-grab pilot-edge-grab-info)
|
||||
target-pilot-get-off
|
||||
target-pilot-get-on
|
||||
target-pilot-grab
|
||||
(target-pilot-hit symbol attack-info)
|
||||
target-pilot-impact
|
||||
target-pilot-stance
|
||||
(target-pilot-start handle symbol symbol)
|
||||
(target-play-anim string handle)
|
||||
(target-pole-cycle handle)
|
||||
(target-pole-flip-forward float float float)
|
||||
|
||||
+9
-14
@@ -1225,17 +1225,14 @@
|
||||
)
|
||||
)
|
||||
(when s5-1
|
||||
(case (-> arg3 param 0)
|
||||
(('pilot-daxter 'pilot-race-daxter)
|
||||
#t
|
||||
)
|
||||
(else
|
||||
)
|
||||
)
|
||||
enter-state
|
||||
(let ((a0-93 (process->handle s5-1)))
|
||||
(-> arg3 param 3)
|
||||
(go target-pilot-start (the-as handle a0-93))
|
||||
(let* ((v1-83 (-> arg3 param 0))
|
||||
(a2-4 (if (or (= v1-83 'pilot-daxter) (= v1-83 'pilot-race-daxter))
|
||||
#t
|
||||
#f
|
||||
)
|
||||
)
|
||||
)
|
||||
(go target-pilot-start (process->handle s5-1) (the-as symbol (-> arg3 param 3)) a2-4)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1362,9 +1359,7 @@
|
||||
(label cfg-238)
|
||||
(b! (!= v1-0 'pilot-edge-grab) cfg-242 :delay (nop!))
|
||||
(b! (logtest? (-> self focus-status) (focus-status dead hit grabbed)) cfg-241 :delay (set! v0-0 #f))
|
||||
enter-state
|
||||
(-> arg3 param 0)
|
||||
(set! v0-0 (go target-pilot-edge-grab))
|
||||
(set! v0-0 (go target-pilot-edge-grab (the-as pilot-edge-grab-info (-> arg3 param 0))))
|
||||
(label cfg-241)
|
||||
(b! #t cfg-291 :delay (nop!))
|
||||
(label cfg-242)
|
||||
|
||||
+1689
File diff suppressed because it is too large
Load Diff
+7
-7
@@ -491,7 +491,7 @@
|
||||
0
|
||||
)
|
||||
)
|
||||
(vehicle-method-85 obj)
|
||||
(draw-thrusters obj)
|
||||
(none)
|
||||
)
|
||||
)
|
||||
@@ -573,7 +573,7 @@
|
||||
|
||||
;; definition for method 36 of type boat-base
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-36 boat-base ((obj boat-base))
|
||||
(defmethod do-engine-sounds boat-base ((obj boat-base))
|
||||
0
|
||||
(none)
|
||||
)
|
||||
@@ -623,8 +623,8 @@
|
||||
|
||||
;; definition for method 31 of type boat-base
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-31 boat-base ((obj boat-base) (arg0 rigid-body-vehicle-constants))
|
||||
((method-of-type vehicle rigid-body-object-method-31) obj arg0)
|
||||
(defmethod alloc-and-init-rigid-body-control boat-base ((obj boat-base) (arg0 rigid-body-vehicle-constants))
|
||||
((method-of-type vehicle alloc-and-init-rigid-body-control) obj arg0)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
@@ -788,7 +788,7 @@
|
||||
|
||||
;; definition for method 32 of type barge
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-32 barge ((obj barge))
|
||||
(defmethod allocate-and-init-cshape barge ((obj barge))
|
||||
(let ((s5-0 (new 'process 'collide-shape-moving obj (collide-list-enum usually-hit-by-player))))
|
||||
(set! (-> s5-0 dynam) (copy *standard-dynamics* 'process))
|
||||
(set! (-> s5-0 reaction) cshape-reaction-default)
|
||||
@@ -910,13 +910,13 @@
|
||||
|
||||
;; definition for method 33 of type barge
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-33 barge ((obj barge))
|
||||
(defmethod init-skel-and-rigid-body barge ((obj barge))
|
||||
(initialize-skeleton
|
||||
obj
|
||||
(the-as skeleton-group (art-group-get-by-name *level* "skel-barge" (the-as (pointer uint32) #f)))
|
||||
(the-as pair 0)
|
||||
)
|
||||
(rigid-body-object-method-31 obj *barge-constants*)
|
||||
(alloc-and-init-rigid-body-control obj *barge-constants*)
|
||||
(set! (-> obj draw lod-set lod 0 dist) 1228800.0)
|
||||
(set! (-> obj engine) (the-as uint (new-sound-id)))
|
||||
(set! (-> obj bow-wash) (the-as uint (new-sound-id)))
|
||||
|
||||
+3
-3
@@ -429,7 +429,7 @@
|
||||
)
|
||||
(set! (-> gp-0 position quad) (-> self begin-pos quad))
|
||||
(quaternion-axis-angle! (-> gp-0 rotation) 0.0 1.0 0.0 16384.0)
|
||||
(set! (-> gp-0 object-type) (the-as uint 13))
|
||||
(set! (-> gp-0 object-type) (traffic-type bikec))
|
||||
(set! (-> gp-0 behavior) (the-as uint 0))
|
||||
(set! (-> gp-0 id) (the-as uint 0))
|
||||
(set! (-> gp-0 proc) #f)
|
||||
@@ -709,7 +709,7 @@
|
||||
)
|
||||
(s5-0 (new 'stack-no-clear 'traffic-object-spawn-params))
|
||||
)
|
||||
(set! (-> s5-0 object-type) (the-as uint 6))
|
||||
(set! (-> s5-0 object-type) (traffic-type crimson-guard-1))
|
||||
(set! (-> s5-0 behavior) (the-as uint 9))
|
||||
(set! (-> s5-0 id) (the-as uint 0))
|
||||
(set! (-> s5-0 nav-mesh) #f)
|
||||
@@ -808,7 +808,7 @@
|
||||
)
|
||||
(set! (-> s5-0 position quad) (-> gp-0 bike-pos quad))
|
||||
(quaternion-axis-angle! (-> s5-0 rotation) 0.0 1.0 0.0 (-> gp-0 bike-angle))
|
||||
(set! (-> s5-0 object-type) (the-as uint 11))
|
||||
(set! (-> s5-0 object-type) (traffic-type bikea))
|
||||
(set! (-> s5-0 behavior) (the-as uint 0))
|
||||
(set! (-> s5-0 id) (the-as uint 0))
|
||||
(set! (-> s5-0 proc) #f)
|
||||
|
||||
+7
-7
@@ -22,12 +22,12 @@ all initialized from static data."
|
||||
:size-assert #x20
|
||||
:flag-assert #xf00000020
|
||||
(:methods
|
||||
(xz-height-map-method-9 (_type_ vector) float 9)
|
||||
(xz-height-map-method-10 (_type_ vector) none 10)
|
||||
(xz-height-map-method-11 (_type_) none 11)
|
||||
(xz-height-map-method-12 (_type_ vector) none 12)
|
||||
(xz-height-map-method-13 (_type_ vector) none 13)
|
||||
(xz-height-map-method-14 (_type_ vector int) none 14)
|
||||
(get-height-at-point (_type_ vector) float 9)
|
||||
(debug-draw-mesh (_type_ vector) none 10)
|
||||
(debug-print (_type_) none 11)
|
||||
(debug-draw-at-point (_type_ vector) none 12)
|
||||
(debug-draw (_type_ vector) none 13)
|
||||
(debug-add-offset (_type_ vector int) none 14)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -57,5 +57,5 @@ all initialized from static data."
|
||||
(defun get-traffic-height ((arg0 vector))
|
||||
"@returns The value of [[xz-height-map::9]] using [[*traffic-height-map*]] and the [[vector]] provided
|
||||
@see [[xz-height-map::9]]"
|
||||
(xz-height-map-method-9 *traffic-height-map* arg0)
|
||||
(get-height-at-point *traffic-height-map* arg0)
|
||||
)
|
||||
|
||||
+264
@@ -0,0 +1,264 @@
|
||||
;;-*-Lisp-*-
|
||||
(in-package goal)
|
||||
|
||||
;; definition for method 11 of type xz-height-map
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod debug-print xz-height-map ((obj xz-height-map))
|
||||
(format #t "(define *traffic-height-map*~%")
|
||||
(format #t " (static-height-map~%")
|
||||
(format
|
||||
#t
|
||||
" :offset ((meters ~M) (meters ~M) (meters ~M))~%"
|
||||
(-> obj x-offset)
|
||||
(-> obj y-offset)
|
||||
(-> obj z-offset)
|
||||
)
|
||||
(format #t " :x-spacing (meters ~M)~%" (/ 1.0 (-> obj x-inv-spacing)))
|
||||
(format #t " :z-spacing (meters ~M)~%" (/ 1.0 (-> obj z-inv-spacing)))
|
||||
(format #t " :y-scale (meters ~M)~%" (-> obj y-scale))
|
||||
(format #t " :x-dim ~d~%" (-> obj x-dim))
|
||||
(format #t " :z-dim ~d~%" (-> obj z-dim))
|
||||
(format #t " :data~%")
|
||||
(format #t " (~%")
|
||||
(let ((s5-0 0))
|
||||
(dotimes (s4-0 (-> obj z-dim))
|
||||
(dotimes (s3-0 (-> obj x-dim))
|
||||
(format #t " ~2d" (-> obj data s5-0))
|
||||
(+! s5-0 1)
|
||||
)
|
||||
(format #t "~%")
|
||||
)
|
||||
)
|
||||
(format #t "~T)~%")
|
||||
(format #t " )~%")
|
||||
(format #t " )~%~%")
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
;; definition for method 14 of type xz-height-map
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod debug-add-offset xz-height-map ((obj xz-height-map) (arg0 vector) (arg1 int))
|
||||
"Add an offset to the given point, likely for debugging purposes."
|
||||
(let ((v1-1 (the int (+ 0.5 (* (- (-> arg0 x) (-> obj x-offset)) (-> obj x-inv-spacing)))))
|
||||
(a1-1 (the int (+ 0.5 (* (- (-> arg0 z) (-> obj z-offset)) (-> obj z-inv-spacing)))))
|
||||
)
|
||||
(when (and (>= v1-1 0) (< v1-1 (-> obj x-dim)) (>= a1-1 0) (< a1-1 (-> obj z-dim)))
|
||||
(let ((v1-2 (+ v1-1 (* a1-1 (-> obj x-dim)))))
|
||||
(+! (-> obj data v1-2) arg1)
|
||||
)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
;; definition for method 12 of type xz-height-map
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod debug-draw-at-point xz-height-map ((obj xz-height-map) (arg0 vector))
|
||||
(let ((v1-1 (the int (+ 0.5 (* (- (-> arg0 x) (-> obj x-offset)) (-> obj x-inv-spacing)))))
|
||||
(a1-1 (the int (+ 0.5 (* (- (-> arg0 z) (-> obj z-offset)) (-> obj z-inv-spacing)))))
|
||||
(a2-1 (-> obj x-dim))
|
||||
(a3-0 (-> obj z-dim))
|
||||
)
|
||||
(when (and (>= v1-1 0) (< v1-1 a2-1) (>= a1-1 0) (< a1-1 a3-0))
|
||||
(let* ((a2-3 (+ v1-1 (* a1-1 a2-1)))
|
||||
(gp-0 (-> obj data a2-3))
|
||||
(s5-0 (new 'stack-no-clear 'vector))
|
||||
)
|
||||
(set! (-> s5-0 x) (+ (-> obj x-offset) (/ (the float v1-1) (-> obj x-inv-spacing))))
|
||||
(set! (-> s5-0 y) 0.0)
|
||||
(set! (-> s5-0 z) (+ (-> obj z-offset) (/ (the float a1-1) (-> obj z-inv-spacing))))
|
||||
(set! (-> s5-0 y) (get-height-at-point obj s5-0))
|
||||
(let ((s4-0 add-debug-text-3d)
|
||||
(s3-0 #t)
|
||||
(s2-0 318)
|
||||
)
|
||||
(format (clear *temp-string*) "~D" gp-0)
|
||||
(s4-0
|
||||
s3-0
|
||||
(the-as bucket-id s2-0)
|
||||
*temp-string*
|
||||
s5-0
|
||||
(font-color #dadada)
|
||||
(new 'static 'vector2h :data (new 'static 'array int16 2 0 16))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
;; definition for method 9 of type xz-height-map
|
||||
(defmethod get-height-at-point xz-height-map ((obj xz-height-map) (arg0 vector))
|
||||
(let* ((f0-1 (fmax 0.0 (* (-> obj x-inv-spacing) (- (-> arg0 x) (-> obj x-offset)))))
|
||||
(f2-4 (fmax 0.0 (* (-> obj z-inv-spacing) (- (-> arg0 z) (-> obj z-offset)))))
|
||||
(a2-0 (the int f0-1))
|
||||
(a1-1 (the int f2-4))
|
||||
(f1-7 (- f0-1 (the float a2-0)))
|
||||
(f0-4 (- f2-4 (the float a1-1)))
|
||||
(v1-0 (-> obj x-dim))
|
||||
(a3-0 (-> obj z-dim))
|
||||
(a1-7
|
||||
(the-as
|
||||
(pointer int8)
|
||||
(+ (+ (min a2-0 (+ v1-0 -2)) (* (min a1-1 (+ a3-0 -2)) v1-0) 0) (the-as int (the-as pointer (-> obj data))))
|
||||
)
|
||||
)
|
||||
(f3-3 (the float (-> a1-7 0)))
|
||||
(f4-1 (the float (-> a1-7 1)))
|
||||
(f2-8 (the float (-> a1-7 v1-0)))
|
||||
(f5-1 (the float (-> a1-7 (+ v1-0 1))))
|
||||
(f3-5 (+ (* f3-3 (- 1.0 f1-7)) (* f4-1 f1-7)))
|
||||
(f1-9 (+ (* f2-8 (- 1.0 f1-7)) (* f5-1 f1-7)))
|
||||
)
|
||||
(+ (* (+ (* f3-5 (- 1.0 f0-4)) (* f1-9 f0-4)) (-> obj y-scale)) (-> obj y-offset))
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for function point-in-bbox?
|
||||
(defun point-in-bbox? ((arg0 bounding-box) (arg1 vector))
|
||||
(and (>= (-> arg1 x) (-> arg0 min x))
|
||||
(>= (-> arg1 y) (-> arg0 min y))
|
||||
(>= (-> arg1 z) (-> arg0 min z))
|
||||
(>= (-> arg0 max x) (-> arg1 x))
|
||||
(>= (-> arg0 max y) (-> arg1 y))
|
||||
(>= (-> arg0 max z) (-> arg1 z))
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for method 10 of type xz-height-map
|
||||
;; INFO: Used lq/sq
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod debug-draw-mesh xz-height-map ((obj xz-height-map) (arg0 vector))
|
||||
(local-vars (sv-80 int) (sv-96 int))
|
||||
(rlet ((vf0 :class vf))
|
||||
(init-vf0-vector)
|
||||
(let ((s5-0 (new 'stack-no-clear 'matrix)))
|
||||
(mem-copy! (the-as pointer (-> s5-0 vector 2)) (the-as pointer arg0) 32)
|
||||
(.svf (&-> (-> s5-0 vector) 0 quad) vf0)
|
||||
(let ((f30-0 (/ 1.0 (-> obj z-inv-spacing)))
|
||||
(f28-0 (/ 1.0 (-> obj x-inv-spacing)))
|
||||
(s4-0 (-> obj x-dim))
|
||||
(s3-0 (-> obj z-dim))
|
||||
)
|
||||
(let ((s2-0 (&-> (-> obj data) 0)))
|
||||
(set! (-> s5-0 vector 0 z) (-> obj z-offset))
|
||||
(countdown (s1-0 s3-0)
|
||||
(let ((s0-0 s2-0))
|
||||
(set! (-> s5-0 vector 0 x) (-> obj x-offset))
|
||||
(set! (-> s5-0 vector 0 y) (+ (-> obj y-offset) (* (the float (-> s0-0 0)) (-> obj y-scale))))
|
||||
(set! sv-80 (+ s4-0 -1))
|
||||
(while (nonzero? sv-80)
|
||||
(set! sv-80 (+ sv-80 -1))
|
||||
(set! (-> s5-0 vector 1 quad) (-> s5-0 vector 0 quad))
|
||||
(+! (-> s5-0 vector 0 x) f28-0)
|
||||
(set! s0-0 (&-> s0-0 1))
|
||||
(set! (-> s5-0 vector 0 y) (+ (-> obj y-offset) (* (the float (-> s0-0 0)) (-> obj y-scale))))
|
||||
(if (and (point-in-bbox? (the-as bounding-box (-> s5-0 vector 2)) (the-as vector (-> s5-0 vector)))
|
||||
(point-in-bbox? (the-as bounding-box (-> s5-0 vector 2)) (-> s5-0 vector 1))
|
||||
)
|
||||
(add-debug-line
|
||||
#t
|
||||
(bucket-id debug2)
|
||||
(the-as vector (-> s5-0 vector))
|
||||
(-> s5-0 vector 1)
|
||||
*color-red*
|
||||
#f
|
||||
(the-as rgba -1)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(+! (-> s5-0 vector 0 z) f30-0)
|
||||
(&+! s2-0 s4-0)
|
||||
)
|
||||
)
|
||||
(let ((s2-1 (&-> (-> obj data) 0)))
|
||||
(set! (-> s5-0 vector 0 x) (-> obj x-offset))
|
||||
(countdown (s1-1 s4-0)
|
||||
(let ((s0-1 (the-as pointer s2-1)))
|
||||
(set! (-> s5-0 vector 0 z) (-> obj z-offset))
|
||||
(set! (-> s5-0 vector 0 y)
|
||||
(+ (-> obj y-offset) (* (the float (-> (the-as (pointer int8) s0-1) 0)) (-> obj y-scale)))
|
||||
)
|
||||
(set! sv-96 (+ s3-0 -1))
|
||||
(while (nonzero? sv-96)
|
||||
(set! sv-96 (+ sv-96 -1))
|
||||
(set! (-> s5-0 vector 1 quad) (-> s5-0 vector 0 quad))
|
||||
(+! (-> s5-0 vector 0 z) f30-0)
|
||||
(&+! s0-1 s4-0)
|
||||
(set! (-> s5-0 vector 0 y)
|
||||
(+ (-> obj y-offset) (* (the float (-> (the-as (pointer int8) s0-1))) (-> obj y-scale)))
|
||||
)
|
||||
(if (and (point-in-bbox? (the-as bounding-box (-> s5-0 vector 2)) (the-as vector (-> s5-0 vector)))
|
||||
(point-in-bbox? (the-as bounding-box (-> s5-0 vector 2)) (-> s5-0 vector 1))
|
||||
)
|
||||
(add-debug-line
|
||||
#t
|
||||
(bucket-id debug2)
|
||||
(the-as vector (-> s5-0 vector))
|
||||
(-> s5-0 vector 1)
|
||||
*color-blue*
|
||||
#f
|
||||
(the-as rgba -1)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(+! (-> s5-0 vector 0 x) f28-0)
|
||||
(set! s2-1 (&-> s2-1 1))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for method 13 of type xz-height-map
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod debug-draw xz-height-map ((obj xz-height-map) (arg0 vector))
|
||||
(rlet ((vf0 :class vf)
|
||||
(vf4 :class vf)
|
||||
(vf5 :class vf)
|
||||
(vf6 :class vf)
|
||||
)
|
||||
(init-vf0-vector)
|
||||
(let ((v1-0 (new 'stack-no-clear 'vector4w-2)))
|
||||
(let ((a1-1 (-> v1-0 vector)))
|
||||
(let ((a0-1 arg0))
|
||||
(let ((a2-1 -573440.0))
|
||||
(.mov vf6 a2-1)
|
||||
)
|
||||
(.lvf vf4 (&-> a0-1 quad))
|
||||
)
|
||||
(.add.x.vf vf5 vf0 vf0 :mask #b1000)
|
||||
(.add.x.vf vf5 vf4 vf6 :mask #b111)
|
||||
(.svf (&-> a1-1 0 quad) vf5)
|
||||
)
|
||||
(let ((a1-2 (-> v1-0 vector 1)))
|
||||
(let ((a0-2 arg0))
|
||||
(let ((a2-3 573440.0))
|
||||
(.mov vf6 a2-3)
|
||||
)
|
||||
(.lvf vf4 (&-> a0-2 quad))
|
||||
)
|
||||
(.add.x.vf vf5 vf0 vf0 :mask #b1000)
|
||||
(.add.x.vf vf5 vf4 vf6 :mask #b111)
|
||||
(.svf (&-> a1-2 quad) vf5)
|
||||
)
|
||||
(debug-draw-mesh obj (the-as vector (-> v1-0 vector)))
|
||||
)
|
||||
(debug-draw-at-point obj arg0)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
|
||||
|
||||
+53
-53
@@ -3,35 +3,35 @@
|
||||
|
||||
;; definition of type nav-branch
|
||||
(deftype nav-branch (structure)
|
||||
((node int32 2 :offset-assert 0)
|
||||
(src-node nav-node :offset 0)
|
||||
(dest-node nav-node :offset 4)
|
||||
(temp-dest-node-id int32 :offset 4)
|
||||
(speed-limit uint8 :offset-assert 8)
|
||||
(density uint8 :offset-assert 9)
|
||||
(clock-type uint8 :offset-assert 10)
|
||||
(clock-mask uint8 :offset-assert 11)
|
||||
(max-user-count uint8 :offset-assert 12)
|
||||
(user-count uint8 :offset-assert 13)
|
||||
(width uint8 :offset-assert 14)
|
||||
(flags uint8 :offset-assert 15)
|
||||
((node nav-node 2 :offset-assert 0)
|
||||
(src-node nav-node :offset 0)
|
||||
(dest-node nav-node :offset 4)
|
||||
(temp-dest-node-id int32 :offset 4)
|
||||
(speed-limit uint8 :offset-assert 8)
|
||||
(density uint8 :offset-assert 9)
|
||||
(clock-type nav-branch-clock-type :offset-assert 10)
|
||||
(clock-mask nav-branch-clock-mask :offset-assert 11)
|
||||
(max-user-count uint8 :offset-assert 12)
|
||||
(user-count uint8 :offset-assert 13)
|
||||
(width uint8 :offset-assert 14)
|
||||
(flags uint8 :offset-assert 15)
|
||||
)
|
||||
:method-count-assert 21
|
||||
:size-assert #x10
|
||||
:flag-assert #x1500000010
|
||||
(:methods
|
||||
(nav-branch-method-9 (_type_) none 9)
|
||||
(nav-branch-method-10 (_type_ object int) none 10)
|
||||
(set-default-density-speed-and-width (_type_) none 9)
|
||||
(debug-print (_type_ object int) none 10)
|
||||
(get-density (_type_) float 11)
|
||||
(get-speed-limit (_type_) float 12)
|
||||
(get-width (_type_) float 13)
|
||||
(user-limit-reached? (_type_) symbol 14)
|
||||
(dest-node-id-at-max? (_type_) symbol 15)
|
||||
(nav-branch-method-16 (_type_ float) none 16)
|
||||
(nav-branch-method-17 (_type_ float) none 17)
|
||||
(nav-branch-method-18 (_type_ float) none 18)
|
||||
(nav-branch-method-19 (_type_ nav-node) none 19)
|
||||
(nav-branch-method-20 (_type_ nav-node) none 20)
|
||||
(set-density (_type_ float) none 16)
|
||||
(set-speed-limit (_type_ float) none 17)
|
||||
(set-width (_type_ float) none 18)
|
||||
(set-src-node (_type_ nav-node) none 19)
|
||||
(set-dst-node (_type_ nav-node) none 20)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -79,15 +79,15 @@
|
||||
:size-assert #x20
|
||||
:flag-assert #x1600000020
|
||||
(:methods
|
||||
(nav-node-method-9 (_type_) none 9)
|
||||
(nav-node-method-10 (_type_ symbol string) none 10)
|
||||
(nav-node-method-11 (_type_ int) none 11)
|
||||
(nav-node-method-12 (_type_ vector nav-node) none 12)
|
||||
(nav-node-method-13 (_type_ vector) none 13)
|
||||
(nav-node-method-14 (_type_ vector) none 14)
|
||||
(nav-node-method-15 (_type_ uint) none 15)
|
||||
(nav-node-method-16 (_type_ float) none 16)
|
||||
(nav-node-method-17 (_type_ float) none 17)
|
||||
(debug-draw (_type_) none 9)
|
||||
(debug-print (_type_ symbol string) none 10)
|
||||
(remove-branch-by-idx (_type_ int) none 11)
|
||||
(init-from-pt-and-heading (_type_ vector vector) none 12)
|
||||
(set-pos-xyz (_type_ vector) none 13)
|
||||
(set-angle-from-heading (_type_ vector) none 14)
|
||||
(set-id-and-link-branches-back (_type_ uint) none 15)
|
||||
(set-radius (_type_ float) none 16)
|
||||
(set-angle (_type_ float) none 17)
|
||||
(get-position (_type_ vector) vector 18)
|
||||
(calc-sine-and-cosine! (_type_ vector) vector 19)
|
||||
(get-angle (_type_) float 20)
|
||||
@@ -261,42 +261,42 @@
|
||||
:flag-assert #x2d0000003c
|
||||
(:methods
|
||||
(new (symbol type int int int uint) _type_ 0)
|
||||
(nav-graph-method-9 (_type_) none 9)
|
||||
(debug-draw-nodes (_type_) none 9)
|
||||
(nav-graph-method-10 (_type_ vector int) none 10)
|
||||
(nav-graph-method-11 (_type_) none 11)
|
||||
(nav-graph-method-12 (_type_) none 12)
|
||||
(nav-graph-method-13 (_type_ int int) none 13)
|
||||
(nav-graph-method-14 (_type_ int int) none 14)
|
||||
(nav-graph-method-15 (_type_) none 15)
|
||||
(nav-graph-method-16 (_type_ int) nav-node 16)
|
||||
(nav-graph-method-17 (_type_ nav-node) none 17)
|
||||
(nav-graph-method-18 (_type_ nav-node int) none 18)
|
||||
(debug-reset (_type_) none 15)
|
||||
(debug-add-node (_type_ int) nav-node 16)
|
||||
(debug-link-node-to-graph (_type_ nav-node) none 17)
|
||||
(debug-reset-branch-array (_type_ nav-node int) none 18)
|
||||
(nav-graph-method-19 (_type_ int int int int int int) none 19)
|
||||
(nav-graph-method-20 (_type_ int int) none 20)
|
||||
(nav-graph-method-21 (_type_) none 21)
|
||||
(nav-graph-method-22 (_type_ int int) none 22)
|
||||
(nav-graph-method-23 (_type_ int int) none 23)
|
||||
(nav-graph-method-24 (_type_ int int) none 24)
|
||||
(nav-graph-method-25 (_type_ symbol symbol) none 25)
|
||||
(nav-graph-method-26 (_type_ symbol symbol) none 26)
|
||||
(nav-graph-method-27 (_type_ nav-node-flag-byte nav-node-flag-byte symbol) none 27)
|
||||
(nav-graph-method-28 (_type_) none 28)
|
||||
(nav-graph-method-29 (_type_ symbol) none 29)
|
||||
(nav-graph-method-30 (_type_ uint) none 30)
|
||||
(nav-graph-method-31 (_type_ float) none 31)
|
||||
(nav-graph-method-32 (_type_ float) none 32)
|
||||
(nav-graph-method-33 (_type_ float) none 33)
|
||||
(nav-graph-method-34 (_type_ float) none 34)
|
||||
(nav-graph-method-35 (_type_ int) none 35)
|
||||
(nav-graph-method-36 (_type_ int) none 36)
|
||||
(nav-graph-method-37 (_type_ vector) none 37)
|
||||
(move-selected-to-height-map-height (_type_) none 21)
|
||||
(select-nodes-in-range (_type_ int int) none 22)
|
||||
(deselect-nodes-in-range (_type_ int int) none 23)
|
||||
(toggle-select-nodes-in-range (_type_ int int) none 24)
|
||||
(select-nodes-in-level (_type_ symbol symbol) none 25)
|
||||
(select-nodes-by-nav-mesh-id (_type_ int symbol) none 26)
|
||||
(select-nodes-by-flags (_type_ nav-node-flag-byte nav-node-flag-byte symbol) none 27)
|
||||
(print-selected-nodes (_type_) none 28)
|
||||
(assign-selected-nodes-to-level (_type_ symbol) none 29)
|
||||
(assign-selected-nodes-to-nav-mesh (_type_ uint) none 30)
|
||||
(set-radius-of-selected-nodes (_type_ float) none 31)
|
||||
(set-speed-limit-of-selected (_type_ float) none 32)
|
||||
(set-density-of-selected (_type_ float) none 33)
|
||||
(set-width-of-selected (_type_ float) none 34)
|
||||
(or-flags-of-selected-nodes (_type_ nav-node-flag-byte) none 35)
|
||||
(and-flags-of-selected-nodes (_type_ nav-node-flag-byte) none 36)
|
||||
(offset-pos-of-selected (_type_ vector) none 37)
|
||||
(nav-graph-method-38 (_type_) none 38)
|
||||
(nav-graph-method-39 (_type_) none 39)
|
||||
(nav-graph-method-40 (_type_ int) int 40)
|
||||
(node-at-idx (_type_ int) nav-node 41)
|
||||
(nav-graph-method-42 (_type_) none 42)
|
||||
(nav-graph-method-43 (_type_ nav-graph-link string) none 43)
|
||||
(from-editor (_type_ nav-node symbol) none 44)
|
||||
(patch-nodes (_type_) none 42)
|
||||
(copy-to-mysql-graph (_type_ mysql-nav-graph string) none 43)
|
||||
(from-editor (_type_ mysql-nav-graph symbol) none 44)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
+1475
File diff suppressed because it is too large
Load Diff
+1072
File diff suppressed because it is too large
Load Diff
+487
@@ -0,0 +1,487 @@
|
||||
;;-*-Lisp-*-
|
||||
(in-package goal)
|
||||
|
||||
;; definition for symbol *pilot-mods*, type surface
|
||||
(define *pilot-mods* (new 'static 'surface :name 'empty :seek0 1.0 :seek90 1.0 :seek180 1.0 :fric 1.0))
|
||||
|
||||
;; definition for function target-pilot-handler
|
||||
;; WARN: Return type mismatch none vs object.
|
||||
;; WARN: rewrite_to_get_var got a none typed variable. Is there unreachable code? [OP: 59]
|
||||
;; WARN: rewrite_to_get_var got a none typed variable. Is there unreachable code? [OP: 64]
|
||||
;; WARN: rewrite_to_get_var got a none typed variable. Is there unreachable code? [OP: 82]
|
||||
;; WARN: rewrite_to_get_var got a none typed variable. Is there unreachable code? [OP: 130]
|
||||
;; WARN: rewrite_to_get_var got a none typed variable. Is there unreachable code? [OP: 150]
|
||||
;; WARN: rewrite_to_get_var got a none typed variable. Is there unreachable code? [OP: 182]
|
||||
;; WARN: rewrite_to_get_var got a none typed variable. Is there unreachable code? [OP: 96]
|
||||
;; WARN: rewrite_to_get_var got a none typed variable. Is there unreachable code? [OP: 114]
|
||||
;; WARN: disable def twice: 124. This may happen when a cond (no else) is nested inside of another conditional, but it should be rare.
|
||||
;; WARN: rewrite_to_get_var got a none typed variable. Is there unreachable code? [OP: 47]
|
||||
;; WARN: rewrite_to_get_var got a none typed variable. Is there unreachable code? [OP: 9]
|
||||
(defbehavior target-pilot-handler target ((arg0 process) (arg1 int) (arg2 symbol) (arg3 event-message-block))
|
||||
(the-as
|
||||
object
|
||||
(cond
|
||||
((and (= arg2 'query) (= (-> arg3 param 0) 'mode))
|
||||
'pilot
|
||||
)
|
||||
(else
|
||||
(case arg2
|
||||
(('end-mode)
|
||||
(let ((v1-4 (-> self pilot)))
|
||||
(when (nonzero? v1-4)
|
||||
(let ((a0-5 (handle->process (-> v1-4 vehicle))))
|
||||
(if a0-5
|
||||
(put-rider-in-seat (the-as vehicle a0-5) (-> v1-4 seat-index) (the-as process-focusable #f))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
enter-state
|
||||
(process->handle arg0)
|
||||
(go target-pilot-get-off)
|
||||
)
|
||||
(('change-mode)
|
||||
(case (-> arg3 param 0)
|
||||
(('grab)
|
||||
(when (not (logtest? (-> self focus-status) (focus-status dead)))
|
||||
(if (not (-> arg3 param 1))
|
||||
#t
|
||||
(go target-pilot-grab)
|
||||
)
|
||||
)
|
||||
)
|
||||
(('normal)
|
||||
enter-state
|
||||
(process->handle arg0)
|
||||
(go target-pilot-get-off)
|
||||
)
|
||||
(('gun)
|
||||
(if (logtest? (-> self game features) (game-feature gun))
|
||||
(target-gun-init (the-as int (-> arg3 param 2)))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(('swim)
|
||||
#f
|
||||
)
|
||||
(('clone-anim)
|
||||
(go target-pilot-clone-anim (process->handle (the-as process (-> arg3 param 0))))
|
||||
)
|
||||
(('get-vehicle)
|
||||
(if (nonzero? (-> self pilot))
|
||||
(handle->process (-> self pilot vehicle))
|
||||
)
|
||||
)
|
||||
(('attack 'attack-or-shove 'attack-invinc)
|
||||
(target-attacked
|
||||
arg2
|
||||
(the-as attack-info (-> arg3 param 1))
|
||||
arg0
|
||||
(the-as touching-shapes-entry (-> arg3 param 0))
|
||||
target-pilot-hit
|
||||
)
|
||||
)
|
||||
(('vehicle-hit)
|
||||
(speech-control-method-12 *speech-control* self (if (-> self pilot as-daxter?)
|
||||
(speech-type speech-type-1 speech-type-3 speech-type-5)
|
||||
(speech-type speech-type-0 speech-type-5)
|
||||
)
|
||||
)
|
||||
)
|
||||
(('vehicle-got-hit)
|
||||
(speech-control-method-12
|
||||
*speech-control*
|
||||
self
|
||||
(if (-> self pilot as-daxter?)
|
||||
(speech-type speech-type-0 speech-type-1 speech-type-3 speech-type-5)
|
||||
(speech-type speech-type-1 speech-type-5)
|
||||
)
|
||||
)
|
||||
)
|
||||
(else
|
||||
(target-standard-event-handler arg0 arg1 arg2 arg3)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for function target-pilot-pidax-enter
|
||||
(defbehavior target-pilot-pidax-enter target ()
|
||||
(set! (-> self pilot art-group-backup) (-> self draw art-group))
|
||||
(set! (-> self draw art-group) (-> self sidekick 0 draw art-group))
|
||||
(logior! (-> self draw status) (draw-control-status no-draw-bounds2))
|
||||
(send-event (ppointer->process (-> self sidekick)) 'matrix 'indax)
|
||||
)
|
||||
|
||||
;; definition for function target-pilot-pidax-exit
|
||||
(defbehavior target-pilot-pidax-exit target ()
|
||||
(ja-channel-set! 0)
|
||||
(set! (-> self draw art-group) (the-as art-group (-> self pilot art-group-backup)))
|
||||
(logclear! (-> self draw status) (draw-control-status no-draw-bounds2))
|
||||
(send-event (ppointer->process (-> self sidekick)) 'matrix #f)
|
||||
)
|
||||
|
||||
;; definition for function target-pilot-exit
|
||||
;; INFO: Used lq/sq
|
||||
;; WARN: Return type mismatch none vs object.
|
||||
(defbehavior target-pilot-exit target ()
|
||||
(the-as
|
||||
object
|
||||
(when (not (and (-> self next-state) (let ((v1-3 (-> self next-state name)))
|
||||
(or (= v1-3 'target-pilot-stance)
|
||||
(= v1-3 'target-pilot-impact)
|
||||
(= v1-3 'target-pilot-get-off)
|
||||
(= v1-3 'target-pilot-grab)
|
||||
(= v1-3 'target-pilot-clone-anim)
|
||||
(= v1-3 'target-pilot-hit)
|
||||
(= v1-3 'target-pilot-death)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((v1-4 (-> self manipy)))
|
||||
(when v1-4
|
||||
(deactivate (-> v1-4 0))
|
||||
(set! (-> self manipy) (the-as (pointer manipy) #f))
|
||||
)
|
||||
)
|
||||
(if (-> self pilot as-daxter?)
|
||||
(target-pilot-pidax-exit)
|
||||
)
|
||||
(let ((v1-11 (-> self pilot)))
|
||||
(when (nonzero? v1-11)
|
||||
(set! (-> self control nav-radius) (-> v1-11 backup-nav-radius))
|
||||
(let ((gp-0 (handle->process (-> v1-11 vehicle))))
|
||||
(when gp-0
|
||||
(remove-rider (the-as vehicle gp-0) self)
|
||||
(send-event gp-0 'player-get-off)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(set! (-> self neck flex-blend) 1.0)
|
||||
(let ((v1-22 (-> self control root-prim)))
|
||||
(set! (-> v1-22 prim-core collide-as) (-> self control backup-collide-as))
|
||||
(set! (-> v1-22 prim-core collide-with) (-> self control backup-collide-with))
|
||||
)
|
||||
(logclear! (-> self focus-status) (focus-status pilot-riding pilot))
|
||||
(logclear! (-> self control root-prim prim-core action) (collide-action stuck-wall-escape))
|
||||
(set! (-> self control mod-surface) *walk-mods*)
|
||||
(logclear! (-> self state-flags) (state-flags sf6))
|
||||
(enable-set! (-> self arm-ik 0) #f)
|
||||
(enable-set! (-> self arm-ik 1) #f)
|
||||
(set! (-> self control dynam gravity-max) (-> self control standard-dynamics gravity-max))
|
||||
(set! (-> self control dynam gravity-length) (-> self control standard-dynamics gravity-length))
|
||||
(let ((v1-43 (-> self node-list data)))
|
||||
(set! (-> v1-43 0 param0) (the-as (function cspace transformq none) cspace<-transformq+trans!))
|
||||
(set! (-> v1-43 0 param1) (the-as basic (-> self control trans)))
|
||||
(set! (-> v1-43 0 param2) (the-as basic (-> self control cspace-offset)))
|
||||
)
|
||||
(target-collide-set! 'normal 0.0)
|
||||
(set! (-> self control reaction) target-collision-reaction)
|
||||
(set! (-> self control cspace-offset quad) (the-as uint128 0))
|
||||
(target-exit)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for function target-pilot-init
|
||||
;; INFO: Used lq/sq
|
||||
;; WARN: Return type mismatch int vs object.
|
||||
(defbehavior target-pilot-init target ((arg0 handle) (arg1 symbol))
|
||||
(target-exit)
|
||||
(if (zero? (-> self pilot))
|
||||
(set! (-> self pilot) (new 'process 'pilot-info))
|
||||
)
|
||||
(let ((s5-0 (-> self pilot)))
|
||||
(set! (-> s5-0 backup-nav-radius) (-> self control nav-radius))
|
||||
(set! (-> s5-0 gun?) #t)
|
||||
(set! (-> s5-0 enable-cam-side-shift) #f)
|
||||
(set! (-> s5-0 as-daxter?) arg1)
|
||||
(set! (-> s5-0 entity) #f)
|
||||
(set! (-> s5-0 cam-side-shift) 0.0)
|
||||
(if (-> self pilot as-daxter?)
|
||||
(target-pilot-pidax-enter)
|
||||
)
|
||||
(cond
|
||||
((handle->process arg0)
|
||||
(set! (-> s5-0 vehicle) arg0)
|
||||
)
|
||||
(else
|
||||
(break!)
|
||||
0
|
||||
)
|
||||
)
|
||||
(let ((s4-1 (handle->process (-> s5-0 vehicle))))
|
||||
(when s4-1
|
||||
(set! (-> s5-0 entity) (-> s4-1 entity))
|
||||
(set! (-> s5-0 gun?) (logtest? (-> (the-as vehicle s4-1) info-override flags) 32))
|
||||
(set! (-> s5-0 enable-cam-side-shift) (logtest? (-> (the-as vehicle s4-1) info-override flags) 128))
|
||||
(send-event
|
||||
(ppointer->process (-> (the-as vehicle s4-1) parent))
|
||||
'player-got-on-vehicle-child
|
||||
(the-as vehicle s4-1)
|
||||
)
|
||||
(set! (-> s5-0 stance) (vehicle-method-72 (the-as vehicle s4-1)))
|
||||
(let ((s3-0 (get-seat-count (the-as vehicle s4-1))))
|
||||
(dotimes (s2-0 s3-0)
|
||||
(let ((a0-20 (get-rider-in-seat (the-as vehicle s4-1) s2-0)))
|
||||
(if (and a0-20 (send-event a0-20 'knocked-off))
|
||||
(put-rider-in-seat (the-as vehicle s4-1) s2-0 (the-as process-focusable #f))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((v1-43 (get-best-seat-for-vehicle s4-1 (-> self control trans) 1 1)))
|
||||
(set! (-> s5-0 seat-index) (max 0 v1-43))
|
||||
)
|
||||
(cond
|
||||
((-> s5-0 as-daxter?)
|
||||
(set! (-> s5-0 left-right-accel-factor) 0.0000012207031)
|
||||
(set! (-> s5-0 front-back-accel-factor) 0.0000012207031)
|
||||
(set! (-> s5-0 up-down-accel-factor) 0.0000012207031)
|
||||
)
|
||||
((zero? (-> s5-0 stance))
|
||||
(set! (-> s5-0 left-right-accel-factor) 0.0000012207031)
|
||||
(set! (-> s5-0 front-back-accel-factor) 0.0000012207031)
|
||||
(set! (-> s5-0 up-down-accel-factor) 0.00000051879886)
|
||||
)
|
||||
(else
|
||||
(set! (-> s5-0 left-right-accel-factor) 0.0000012207031)
|
||||
(set! (-> s5-0 front-back-accel-factor) 0.0000012207031)
|
||||
(set! (-> s5-0 up-down-accel-factor) 0.00000061035155)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(when (not (-> s5-0 gun?))
|
||||
(if arg1
|
||||
(set! (-> self control current-surface flags)
|
||||
(logior (surface-flag gun-fast-exit) (-> self control current-surface flags))
|
||||
)
|
||||
)
|
||||
(target-gun-end-mode arg1)
|
||||
)
|
||||
)
|
||||
(set! (-> self board latch?) #f)
|
||||
(set! (-> self control reaction) target-collision-reaction)
|
||||
(set! (-> self control transv quad) (the-as uint128 0))
|
||||
(set! (-> self control ctrl-xz-vel) 0.0)
|
||||
(set! (-> self focus-status) (logior (focus-status pilot) (-> self focus-status)))
|
||||
(set! (-> self control bend-target) 0.0)
|
||||
(let ((v1-73 (-> self node-list data)))
|
||||
(set! (-> v1-73 0 param0) (the-as (function cspace transformq none) cspace<-transformq+world-trans!))
|
||||
(set! (-> v1-73 0 param1) (the-as basic (-> self control trans)))
|
||||
(set! (-> v1-73 0 param2) (the-as basic (-> self control cspace-offset)))
|
||||
)
|
||||
(let ((v1-75 (-> self control root-prim)))
|
||||
(set! (-> v1-75 prim-core collide-as) (collide-spec))
|
||||
(set! (-> v1-75 prim-core collide-with) (collide-spec))
|
||||
)
|
||||
0
|
||||
(set! (-> self control root-prim prim-core collide-as) (collide-spec jak-vehicle))
|
||||
(set! (-> self neck flex-blend) 0.0)
|
||||
(set! (-> self control status) (collide-status))
|
||||
(the-as object 0)
|
||||
)
|
||||
|
||||
;; definition for function pilot-on-ground?
|
||||
(defbehavior pilot-on-ground? target ()
|
||||
(logtest? (-> self control status) (collide-status on-surface))
|
||||
)
|
||||
|
||||
;; definition for function target-pilot-post
|
||||
;; INFO: Used lq/sq
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defbehavior target-pilot-post target ()
|
||||
(local-vars (v1-55 symbol) (a0-44 object) (a0-56 int) (a0-58 int))
|
||||
(let* ((v1-1 (-> *perf-stats* data 17))
|
||||
(a0-0 (-> v1-1 ctrl))
|
||||
)
|
||||
(+! (-> v1-1 count) 1)
|
||||
(b! (zero? a0-0) cfg-2 :delay (nop!))
|
||||
(.mtc0 Perf 0)
|
||||
(.sync.l)
|
||||
(.sync.p)
|
||||
(.mtpc pcr0 0)
|
||||
(.mtpc pcr1 0)
|
||||
(.sync.l)
|
||||
(.sync.p)
|
||||
(.mtc0 Perf a0-0)
|
||||
)
|
||||
(.sync.l)
|
||||
(.sync.p)
|
||||
(label cfg-2)
|
||||
0
|
||||
(let ((f30-0 (-> self clock clock-ratio)))
|
||||
(let ((gp-1 (max 1 (the int (-> self clock time-adjust-ratio)))))
|
||||
(update-rates! (-> self clock) (/ f30-0 (the float gp-1)))
|
||||
(b! #t cfg-4 :delay (nop!))
|
||||
(label cfg-3)
|
||||
(+! gp-1 -1)
|
||||
(set! (-> self control remaining-ctrl-iterations) gp-1)
|
||||
(flag-setup)
|
||||
(build-conversions (-> self control transv))
|
||||
(do-rotations1)
|
||||
(do-rotations2)
|
||||
(reverse-conversions (-> self control transv))
|
||||
(vector-!
|
||||
(-> self control cspace-offset)
|
||||
(-> self control draw-offset)
|
||||
(-> self control anim-collide-offset-world)
|
||||
)
|
||||
(let ((a1-5 (new 'stack-no-clear 'overlaps-others-params)))
|
||||
(set! (-> a1-5 options) (overlaps-others-options oo0))
|
||||
(set! (-> a1-5 collide-with-filter) (the-as collide-spec -1))
|
||||
(set! (-> a1-5 tlist) *touching-list*)
|
||||
(find-overlapping-shapes (-> self control) a1-5)
|
||||
)
|
||||
(post-flag-setup)
|
||||
(label cfg-4)
|
||||
(b! (nonzero? gp-1) cfg-3 :delay (nop!))
|
||||
)
|
||||
(update-rates! (-> self clock) f30-0)
|
||||
)
|
||||
(let* ((gp-2 (-> self pilot))
|
||||
(s5-0 (handle->process (-> gp-2 vehicle)))
|
||||
)
|
||||
(when s5-0
|
||||
(compute-seat-position (the-as vehicle s5-0) (-> self control trans) (-> gp-2 seat-index))
|
||||
(set! (-> self control transv quad) (-> (the-as vehicle s5-0) root-override-2 transv quad))
|
||||
(quaternion-copy! (-> self control quat) (-> (the-as vehicle s5-0) root-override-2 quat))
|
||||
(quaternion-copy! (-> self control quat-for-control) (-> self control quat))
|
||||
(quaternion-copy! (-> self control dir-targ) (-> self control quat))
|
||||
(let ((s4-0 (-> self alt-cam-pos)))
|
||||
(when (not (logtest? (-> self focus-status) (focus-status dead)))
|
||||
(let ((s3-0 (new 'stack-no-clear 'collide-query-with-5vec)))
|
||||
(set! (-> s3-0 vec 2 x) 0.0)
|
||||
(set! (-> s3-0 vec 2 y) 20480.0)
|
||||
(let ((a0-18 (-> self node-list data 0 bone transform)))
|
||||
(set! (-> s3-0 vec 1 quad) (-> a0-18 vector 2 quad))
|
||||
)
|
||||
(set! (-> s3-0 vec 1 y) 0.0)
|
||||
(vector-rotate90-around-y! (-> s3-0 vec 1) (-> s3-0 vec 1))
|
||||
(vector-normalize! (-> s3-0 vec 1) 1.0)
|
||||
(set! (-> s3-0 vec 0 quad) (-> self control trans quad))
|
||||
(when (-> gp-2 enable-cam-side-shift)
|
||||
(let ((s2-0 0))
|
||||
(b! #t cfg-22 :delay (nop!))
|
||||
(label cfg-14)
|
||||
(let ((v1-48 (-> s3-0 cquery)))
|
||||
(set! (-> v1-48 radius) 2048.0)
|
||||
(set! (-> v1-48 collide-with) (collide-spec backgnd))
|
||||
(set! (-> v1-48 ignore-process0) #f)
|
||||
(set! (-> v1-48 ignore-process1) #f)
|
||||
(set! (-> v1-48 ignore-pat) (new 'static 'pat-surface :noentity #x1 :nojak #x1 :probe #x1 :noendlessfall #x1))
|
||||
(set! (-> v1-48 action-mask) (collide-action solid))
|
||||
)
|
||||
(set! (-> s3-0 cquery start-pos quad) (-> s3-0 vec 0 quad))
|
||||
(vector-float*! (-> s3-0 cquery move-dist) (-> s3-0 vec 1) (-> s3-0 vec 2 y))
|
||||
(let ((f0-10 (fill-and-probe-using-line-sphere *collide-cache* (-> s3-0 cquery))))
|
||||
(let ((v1-54 (>= f0-10 0.0)))
|
||||
(b! (not v1-54) cfg-19 :likely-delay (set! v1-55 v1-54))
|
||||
)
|
||||
(set! v1-55 (= (-> s3-0 cquery best-other-tri pat mode) (pat-mode wall)))
|
||||
(label cfg-19)
|
||||
(when v1-55
|
||||
(+! (-> s3-0 vec 2 x) (* -1.0 (-> s3-0 vec 2 y) (- 1.0 f0-10)))
|
||||
0
|
||||
)
|
||||
)
|
||||
(set! (-> s3-0 vec 2 y) (* -1.0 (-> s3-0 vec 2 y)))
|
||||
(+! s2-0 1)
|
||||
(label cfg-22)
|
||||
(b! (< s2-0 2) cfg-14)
|
||||
)
|
||||
(set! (-> s3-0 vec 2 x)
|
||||
(* (-> s3-0 vec 2 x) (fmax 0.25 (fmin 1.0 (* 0.000008138021 (vector-length (-> self control transv))))))
|
||||
)
|
||||
(seek! (-> gp-2 cam-side-shift) (-> s3-0 vec 2 x) (* 16384.0 (-> self clock seconds-per-frame)))
|
||||
)
|
||||
(set! (-> s4-0 x) (+ (-> s3-0 vec 0 x) (* (-> gp-2 cam-side-shift) (-> s3-0 vec 1 x))))
|
||||
(set! (-> s4-0 z) (+ (-> s3-0 vec 0 z) (* (-> gp-2 cam-side-shift) (-> s3-0 vec 1 z))))
|
||||
(set! (-> s4-0 y) (fmax (fmin (-> s4-0 y) (+ 2048.0 (-> s3-0 vec 0 y))) (+ -2048.0 (-> s3-0 vec 0 y))))
|
||||
)
|
||||
0
|
||||
)
|
||||
)
|
||||
(let ((s4-1 (new 'stack-no-clear 'matrix)))
|
||||
(vehicle-method-117 (the-as vehicle s5-0) (the-as vector (-> s4-1 vector)) (-> gp-2 seat-index) 0)
|
||||
(vehicle-method-117 (the-as vehicle s5-0) (-> s4-1 vector 1) (-> gp-2 seat-index) 1)
|
||||
(enable-set! (-> self arm-ik 0) #t)
|
||||
(enable-set! (-> self arm-ik 1) #t)
|
||||
(handle-copy! (-> self arm-ik 0) (the-as vector (-> s4-1 vector)))
|
||||
(handle-copy! (-> self arm-ik 1) (-> s4-1 vector 1))
|
||||
)
|
||||
)
|
||||
)
|
||||
(when *debug-segment*
|
||||
(let ((gp-3 (-> *display* frames (-> *display* on-screen) profile-array data 0))
|
||||
(v1-97 'target-post)
|
||||
(s5-1 *profile-target-post-color*)
|
||||
)
|
||||
(let ((a0-43 *dproc*))
|
||||
(b! (not a0-43) cfg-30 :likely-delay (set! a0-44 a0-43))
|
||||
)
|
||||
(set! a0-44 *debug-segment*)
|
||||
(label cfg-30)
|
||||
(when a0-44
|
||||
(let ((s4-2 (-> gp-3 data (-> gp-3 count))))
|
||||
(let ((s3-1 (-> gp-3 base-time)))
|
||||
(set! (-> s4-2 name) v1-97)
|
||||
(set! (-> s4-2 start-time) (the-as int (- (timer-count (the-as timer-bank #x10000800)) (the-as uint s3-1))))
|
||||
)
|
||||
(set! (-> s4-2 depth) (the-as uint (-> gp-3 depth)))
|
||||
(set! (-> s4-2 color) s5-1)
|
||||
(set! (-> gp-3 segment (-> gp-3 depth)) s4-2)
|
||||
)
|
||||
(+! (-> gp-3 count) 1)
|
||||
(+! (-> gp-3 depth) 1)
|
||||
(set! (-> gp-3 max-depth) (max (-> gp-3 max-depth) (-> gp-3 depth)))
|
||||
)
|
||||
)
|
||||
0
|
||||
)
|
||||
(ja-post)
|
||||
(when *debug-segment*
|
||||
(let ((gp-4 (-> *display* frames (-> *display* on-screen) profile-array data 0)))
|
||||
(when (and *dproc* *debug-segment*)
|
||||
(let* ((v1-121 (+ (-> gp-4 depth) -1))
|
||||
(s5-2 (-> gp-4 segment v1-121))
|
||||
(s4-3 (-> gp-4 base-time))
|
||||
)
|
||||
(when (>= v1-121 0)
|
||||
(set! (-> s5-2 end-time) (the-as int (- (timer-count (the-as timer-bank #x10000800)) (the-as uint s4-3))))
|
||||
(+! (-> gp-4 depth) -1)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
0
|
||||
)
|
||||
(joint-points)
|
||||
(update-transforms (-> self control))
|
||||
(do-target-gspot)
|
||||
(target-powerup-process)
|
||||
(let ((v1-130 (-> *perf-stats* data 17)))
|
||||
(b! (zero? (-> v1-130 ctrl)) cfg-43 :delay (nop!))
|
||||
(.mtc0 Perf 0)
|
||||
(.sync.l)
|
||||
(.sync.p)
|
||||
(.mfpc a0-56 pcr0)
|
||||
(+! (-> v1-130 accum0) a0-56)
|
||||
(.mfpc a0-58 pcr1)
|
||||
(+! (-> v1-130 accum1) a0-58)
|
||||
)
|
||||
(label cfg-43)
|
||||
0
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
|
||||
|
||||
|
||||
+508
@@ -0,0 +1,508 @@
|
||||
;;-*-Lisp-*-
|
||||
(in-package goal)
|
||||
|
||||
;; definition of type test-bike
|
||||
(deftype test-bike (bikec)
|
||||
()
|
||||
:heap-base #x320
|
||||
:method-count-assert 144
|
||||
:size-assert #x39c
|
||||
:flag-assert #x900320039c
|
||||
)
|
||||
|
||||
;; definition for method 3 of type test-bike
|
||||
(defmethod inspect test-bike ((obj test-bike))
|
||||
(when (not obj)
|
||||
(set! obj obj)
|
||||
(goto cfg-4)
|
||||
)
|
||||
(let ((t9-0 (method-of-type bikec inspect)))
|
||||
(t9-0 obj)
|
||||
)
|
||||
(label cfg-4)
|
||||
obj
|
||||
)
|
||||
|
||||
;; definition for symbol *test-bike-constants*, type rigid-body-vehicle-constants
|
||||
(define *test-bike-constants*
|
||||
(new 'static 'rigid-body-vehicle-constants
|
||||
:info (new 'static 'rigid-body-info
|
||||
:mass 2.0
|
||||
:inv-mass 0.5
|
||||
:linear-damping 0.995
|
||||
:angular-damping 0.995
|
||||
:friction-factor 0.516
|
||||
:cm-offset-joint (new 'static 'vector :z 2457.6 :w 1.0)
|
||||
:inertial-tensor-box (new 'static 'array meters 3 (meters 1.5) (meters 2) (meters 5))
|
||||
)
|
||||
:extra (new 'static 'rigid-body-object-extra-info
|
||||
:max-time-step 0.033333335
|
||||
:gravity (meters 40)
|
||||
:idle-distance (meters 50)
|
||||
:attack-force-scale 1.0
|
||||
)
|
||||
:name '*test-bike-constants*
|
||||
:flags #x11
|
||||
:object-type #xd
|
||||
:guard-type #x7
|
||||
:max-engine-thrust (meters 50)
|
||||
:inv-max-engine-thrust 0.0000048828124
|
||||
:engine-response-rate 32.0
|
||||
:engine-intake-factor 1.0
|
||||
:brake-factor 2.0
|
||||
:turbo-boost-factor 1.0
|
||||
:max-xz-speed (meters 100)
|
||||
:ground-probe-distance (meters 5)
|
||||
:ground-probe-offset (meters 0.5)
|
||||
:cos-ground-effect-angle -0.00000004371139
|
||||
:spring-lift-factor 0.35
|
||||
:air-drag-factor 1.2
|
||||
:steering-fin-angle 1820.4445
|
||||
:steering-thruster-factor 6.0
|
||||
:steering-thruster-max-gain 2.0
|
||||
:steering-thruster-half-gain-speed (meters 80)
|
||||
:tire-steering-angle 1274.3112
|
||||
:tire-static-friction 0.5
|
||||
:tire-static-friction-speed (meters 1)
|
||||
:tire-dynamic-friction 0.25
|
||||
:tire-dynamic-friction-speed (meters 3)
|
||||
:tire-inv-max-friction-speed 0.000024414063
|
||||
:airfoil-factor 8.0
|
||||
:drag-force-factor 1.0
|
||||
:speed-limiting-drag 0.75
|
||||
:pitch-control-factor 0.5
|
||||
:roll-control-factor 1.0
|
||||
:roll-angle 7281.778
|
||||
:jump-thrust-factor 0.625
|
||||
:buoyancy-factor 1.0
|
||||
:player-weight 163840.0
|
||||
:player-shift-x (meters 0.6)
|
||||
:player-shift-z (meters 0.125)
|
||||
:target-speed-offset (meters 4)
|
||||
:turning-accel (meters 20)
|
||||
:toughness-factor 1.0
|
||||
:damage-factor 4.0
|
||||
:camera-string-min-height (meters 2.5)
|
||||
:camera-string-max-height (meters 2.5)
|
||||
:camera-string-min-length (meters 5)
|
||||
:camera-string-max-length (meters 5.5)
|
||||
:camera-min-fov 16384.0
|
||||
:camera-max-fov 18204.445
|
||||
:camera-head-offset 4096.0
|
||||
:camera-foot-offset -4096.0
|
||||
:camera-air-max-angle-offset 5461.3335
|
||||
:camera-max-lookaround-speed 40960.0
|
||||
:seat-count 2
|
||||
:section-count 2
|
||||
:grab-rail-count 2
|
||||
:grab-rail-array (new 'static 'inline-array vehicle-grab-rail-info 2
|
||||
(new 'static 'vehicle-grab-rail-info
|
||||
:local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 2048.0 :w 1.0)
|
||||
(new 'static 'vector :x 2048.0 :z 8192.0 :w 1.0)
|
||||
)
|
||||
:normal (new 'static 'vector :x 1.0 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-grab-rail-info
|
||||
:local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x -2048.0 :z 8192.0 :w 1.0)
|
||||
(new 'static 'vector :x -2048.0 :w 1.0)
|
||||
)
|
||||
:normal (new 'static 'vector :x -1.0 :w 1.0)
|
||||
)
|
||||
)
|
||||
:seat-array (new 'static 'inline-array vehicle-seat-info 4
|
||||
(new 'static 'vehicle-seat-info
|
||||
:position (new 'static 'vector :y 802.816 :z 1318.912 :w (the-as float #x10000))
|
||||
)
|
||||
(new 'static 'vehicle-seat-info
|
||||
:position (new 'static 'vector :y 2048.0 :z -4096.0 :w (the-as float #x40000))
|
||||
)
|
||||
(new 'static 'vehicle-seat-info)
|
||||
(new 'static 'vehicle-seat-info)
|
||||
)
|
||||
:rider-hand-offset (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 2457.6 :y 409.6 :z 4710.4 :w 1.0)
|
||||
(new 'static 'vector :x -2457.6 :y 409.6 :z 4710.4 :w 1.0)
|
||||
)
|
||||
:section-bike-front (new 'static 'vehicle-section-info
|
||||
:damage-seg-array (new 'static 'array uint64 3 #x20 #x8 #x2)
|
||||
:damage-seg-count 3
|
||||
)
|
||||
:section-bike-rear (new 'static 'vehicle-section-info
|
||||
:damage-seg-array (new 'static 'array uint64 3 #x40 #x10 #x4)
|
||||
:damage-seg-count 3
|
||||
)
|
||||
:explosion #f
|
||||
:engine-pitch-scale 0.25
|
||||
:engine-pitch-offset -0.25
|
||||
:engine-pitch-mod-amp 0.05
|
||||
:engine-sound-select 2
|
||||
:engine-sound (static-sound-name "vehicle-engine")
|
||||
:thrust-sound (static-sound-name "bike-thrust")
|
||||
:scrape-sound (static-sound-name "bike-scrape-stn")
|
||||
:glance-sound (static-sound-name "bike-glance-stn")
|
||||
:impact-sound (static-sound-name "bike-impact-stn")
|
||||
:extra-sound (static-sound-name "car-by-1")
|
||||
:explosion-part #xa1
|
||||
:headlight-count 1
|
||||
:taillight-count 1
|
||||
:thruster-flame-width (meters 0.6)
|
||||
:thruster-flame-length (meters 2)
|
||||
:thruster-local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 1024.0 :z -3276.8 :w 1.0)
|
||||
(new 'static 'vector :x -1024.0 :z -3276.8 :w 1.0)
|
||||
)
|
||||
:exhaust-local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 1024.0 :y 204.8 :z -3276.8 :w 1.0)
|
||||
(new 'static 'vector :x -1024.0 :y 204.8 :z -3276.8 :w 1.0)
|
||||
)
|
||||
:exhaust-local-dir (new 'static 'inline-array vector 2 (new 'static 'vector :z -1.0 :w 1.0) (new 'static 'vector :z -1.0 :w 1.0))
|
||||
:smoke-local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 1638.4 :y -2048.0 :z 7372.8 :w 1.0)
|
||||
(new 'static 'vector :x -1638.4 :y -2048.0 :z 7372.8 :w 1.0)
|
||||
)
|
||||
:smoke-local-vel (new 'static 'inline-array vector 2 (new 'static 'vector :w 1.0) (new 'static 'vector :w 1.0))
|
||||
:headlight-local-pos (new 'static 'inline-array vector 3
|
||||
(new 'static 'vector :y -614.4 :z 13721.6 :w 1.0)
|
||||
(new 'static 'vector)
|
||||
(new 'static 'vector)
|
||||
)
|
||||
:taillight-local-pos (new 'static 'inline-array vector 2 (new 'static 'vector :y 614.4 :z -7168.0 :w 1.0) (new 'static 'vector))
|
||||
:lift-thruster-count 2
|
||||
:roll-thruster-count 2
|
||||
:steering-thruster-count 2
|
||||
:stabilizer-count 4
|
||||
:inv-lift-thruster-count 0.5
|
||||
:lift-thruster-array (new 'static 'inline-array vehicle-control-point 2
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z 7372.8003 :w 1.0)
|
||||
:normal (new 'static 'vector :y -1.0 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z -2457.6 :w 1.0)
|
||||
:normal (new 'static 'vector :y -1.0 :w 1.0)
|
||||
)
|
||||
)
|
||||
:roll-thruster-array (new 'static 'inline-array vehicle-control-point 2
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :x 6963.2 :y 819.2 :z 2457.6 :w 1.0)
|
||||
:normal (new 'static 'vector :x 0.3 :y -0.6 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :x -6963.2 :y 819.2 :z 2457.6 :w 1.0)
|
||||
:normal (new 'static 'vector :x -0.3 :y -0.6 :w 1.0)
|
||||
)
|
||||
)
|
||||
:steering-thruster-array (new 'static 'inline-array vehicle-control-point 2
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z 10240.0 :w 1.0)
|
||||
:normal (new 'static 'vector :x 1.0 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z -5324.8 :w 1.0)
|
||||
:normal (new 'static 'vector :x -1.0 :w 1.0)
|
||||
)
|
||||
)
|
||||
:stabilizer-array (new 'static 'inline-array vehicle-control-point 6
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z -5734.4 :w 1.0)
|
||||
:normal (new 'static 'vector :x 1.0 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z 10649.6 :w 1.0)
|
||||
:normal (new 'static 'vector :x 1.0 :w 0.25)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z 2457.6 :w 1.0)
|
||||
:normal (new 'static 'vector :x 1.0 :w 0.75)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z -5734.4 :w 1.0)
|
||||
:normal (new 'static 'vector :y 1.0 :w 0.25)
|
||||
)
|
||||
(new 'static 'vehicle-control-point)
|
||||
(new 'static 'vehicle-control-point)
|
||||
)
|
||||
:engine-thrust-local-pos (new 'static 'vector :z -3276.7998 :w 1.0)
|
||||
:brake-local-pos (new 'static 'vector :z -3276.7998 :w 1.0)
|
||||
:color-option-count 1
|
||||
:color-option-array (new 'static 'inline-array vector 1 (new 'static 'vector :x 1.0 :y 1.0 :z 1.0 :w 1.0))
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for method 33 of type test-bike
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod init-skel-and-rigid-body test-bike ((obj test-bike))
|
||||
(initialize-skeleton
|
||||
obj
|
||||
(the-as skeleton-group (art-group-get-by-name *level* "skel-bikec" (the-as (pointer uint32) #f)))
|
||||
(the-as pair 0)
|
||||
)
|
||||
(alloc-and-init-rigid-body-control obj *test-bike-constants*)
|
||||
(set! (-> obj fin-fl) (new 'process 'joint-mod-rotate-local obj 7 #t))
|
||||
(set! (-> obj fin-fr) (new 'process 'joint-mod-rotate-local obj 6 #t))
|
||||
(set! (-> obj fin-rl) (new 'process 'joint-mod-rotate-local obj 9 #t))
|
||||
(set! (-> obj fin-rr) (new 'process 'joint-mod-rotate-local obj 10 #t))
|
||||
(set! (-> obj fin2-fl) (new 'process 'joint-mod-rotate-local obj 4 #t))
|
||||
(set! (-> obj fin2-fr) (new 'process 'joint-mod-rotate-local obj 5 #t))
|
||||
(set! (-> obj rudder) (new 'process 'joint-mod-rotate-local obj 8 #t))
|
||||
(set! (-> obj brake-l) (new 'process 'joint-mod-rotate-local obj 11 #t))
|
||||
(set! (-> obj brake-r) (new 'process 'joint-mod-rotate-local obj 12 #t))
|
||||
(set! (-> obj spoiler-l) (new 'process 'joint-mod-rotate-local obj 13 #t))
|
||||
(set! (-> obj spoiler-r) (new 'process 'joint-mod-rotate-local obj 14 #t))
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
;; definition of type evan-test-bike
|
||||
(deftype evan-test-bike (bikea)
|
||||
()
|
||||
:heap-base #x310
|
||||
:method-count-assert 144
|
||||
:size-assert #x38c
|
||||
:flag-assert #x900310038c
|
||||
)
|
||||
|
||||
;; definition for method 3 of type evan-test-bike
|
||||
(defmethod inspect evan-test-bike ((obj evan-test-bike))
|
||||
(when (not obj)
|
||||
(set! obj obj)
|
||||
(goto cfg-4)
|
||||
)
|
||||
(let ((t9-0 (method-of-type bikea inspect)))
|
||||
(t9-0 obj)
|
||||
)
|
||||
(label cfg-4)
|
||||
obj
|
||||
)
|
||||
|
||||
;; definition for symbol *evan-test-bike-constants*, type rigid-body-vehicle-constants
|
||||
(define *evan-test-bike-constants*
|
||||
(new 'static 'rigid-body-vehicle-constants
|
||||
:info (new 'static 'rigid-body-info
|
||||
:mass 2.0
|
||||
:inv-mass 0.5
|
||||
:linear-damping 0.995
|
||||
:angular-damping 0.995
|
||||
:bounce-factor 0.4
|
||||
:friction-factor 0.05
|
||||
:bounce-mult-factor 1.22
|
||||
:cm-offset-joint (new 'static 'vector :z 2457.6 :w 1.0)
|
||||
:inertial-tensor-box (new 'static 'array meters 3 (meters 3) (meters 4) (meters 6))
|
||||
)
|
||||
:extra (new 'static 'rigid-body-object-extra-info
|
||||
:max-time-step 0.033333335
|
||||
:gravity (meters 40)
|
||||
:idle-distance (meters 50)
|
||||
:attack-force-scale 1.0
|
||||
)
|
||||
:name '*evan-test-bike-constants*
|
||||
:flags #x70
|
||||
:object-type #xb
|
||||
:guard-type #x7
|
||||
:max-engine-thrust (meters 50)
|
||||
:inv-max-engine-thrust 0.0000048828124
|
||||
:engine-response-rate 30.0
|
||||
:engine-intake-factor 1.0
|
||||
:brake-factor 2.0
|
||||
:turbo-boost-factor 1.0
|
||||
:max-xz-speed (meters 40)
|
||||
:ground-probe-distance (meters 5)
|
||||
:cos-ground-effect-angle 0.42261824
|
||||
:spring-lift-factor 0.3
|
||||
:air-drag-factor 1.0
|
||||
:steering-thruster-factor 5.0
|
||||
:steering-thruster-max-gain 4.0
|
||||
:steering-thruster-half-gain-speed (meters 15)
|
||||
:tire-friction-factor 0.5
|
||||
:tire-static-friction 0.55
|
||||
:tire-dynamic-friction 0.4
|
||||
:tire-dynamic-friction-speed (meters 2)
|
||||
:tire-inv-max-friction-speed 0.000024414063
|
||||
:airfoil-factor 1.0
|
||||
:drag-force-factor 1.0
|
||||
:speed-scrubbing-drag 10.0
|
||||
:speed-limiting-drag 0.75
|
||||
:pitch-control-factor 1.0
|
||||
:roll-control-factor 1.0
|
||||
:jump-thrust-factor 0.625
|
||||
:buoyancy-factor 1.0
|
||||
:player-weight 163840.0
|
||||
:player-shift-x (meters 0.6)
|
||||
:player-shift-z (meters 1)
|
||||
:target-speed-offset (meters 4)
|
||||
:turning-accel (meters 20)
|
||||
:toughness-factor 1.0
|
||||
:damage-factor 4.0
|
||||
:camera-string-min-height (meters 4.5)
|
||||
:camera-string-max-height (meters 4.5)
|
||||
:camera-string-min-length (meters 5)
|
||||
:camera-string-max-length (meters 12.5)
|
||||
:camera-min-fov 15109.688
|
||||
:camera-max-fov 17476.268
|
||||
:camera-head-offset 8192.0
|
||||
:camera-foot-offset 4096.0
|
||||
:camera-normal-max-angle-offset 5461.3335
|
||||
:camera-air-max-angle-offset 5461.3335
|
||||
:camera-max-lookaround-speed 40960.0
|
||||
:seat-count 2
|
||||
:section-count 2
|
||||
:grab-rail-count 2
|
||||
:grab-rail-array (new 'static 'inline-array vehicle-grab-rail-info 2
|
||||
(new 'static 'vehicle-grab-rail-info
|
||||
:local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 2048.0 :w 1.0)
|
||||
(new 'static 'vector :x 2048.0 :z 4096.0 :w 1.0)
|
||||
)
|
||||
:normal (new 'static 'vector :x 1.0 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-grab-rail-info
|
||||
:local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x -2048.0 :z 4096.0 :w 1.0)
|
||||
(new 'static 'vector :x -2048.0 :w 1.0)
|
||||
)
|
||||
:normal (new 'static 'vector :x -1.0 :w 1.0)
|
||||
)
|
||||
)
|
||||
:seat-array (new 'static 'inline-array vehicle-seat-info 4
|
||||
(new 'static 'vehicle-seat-info :position (new 'static 'vector :w (the-as float #x10000)))
|
||||
(new 'static 'vehicle-seat-info
|
||||
:position (new 'static 'vector :y 2048.0 :z -4096.0 :w (the-as float #x40000))
|
||||
)
|
||||
(new 'static 'vehicle-seat-info)
|
||||
(new 'static 'vehicle-seat-info)
|
||||
)
|
||||
:rider-hand-offset (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 2457.6 :y 409.6 :z 4710.4 :w 1.0)
|
||||
(new 'static 'vector :x -2457.6 :y 409.6 :z 4710.4 :w 1.0)
|
||||
)
|
||||
:section-bike-front (new 'static 'vehicle-section-info
|
||||
:damage-seg-array (new 'static 'array uint64 3 #x10 #x8 #x2)
|
||||
:damage-seg-count 3
|
||||
)
|
||||
:section-bike-rear (new 'static 'vehicle-section-info
|
||||
:damage-seg-array (new 'static 'array uint64 3 #x20 #x4 #x0)
|
||||
:damage-seg-count 2
|
||||
)
|
||||
:explosion #f
|
||||
:engine-pitch-scale 0.25
|
||||
:engine-pitch-offset -0.25
|
||||
:engine-pitch-mod-amp 0.05
|
||||
:engine-sound-select 1
|
||||
:engine-sound (static-sound-name "vehicle-engine")
|
||||
:thrust-sound (static-sound-name "bike-thrust")
|
||||
:scrape-sound (static-sound-name "bike-scrape-stn")
|
||||
:glance-sound (static-sound-name "bike-glance-stn")
|
||||
:impact-sound (static-sound-name "bike-impact-stn")
|
||||
:extra-sound (static-sound-name "bike-by-1")
|
||||
:explosion-part #xa1
|
||||
:headlight-count 1
|
||||
:taillight-count 1
|
||||
:thruster-flame-width (meters 0.6)
|
||||
:thruster-flame-length (meters 2)
|
||||
:thruster-local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 1024.0 :z -3276.8 :w 1.0)
|
||||
(new 'static 'vector :x -1024.0 :z -3276.8 :w 1.0)
|
||||
)
|
||||
:exhaust-local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 1024.0 :y 204.8 :z -3276.8 :w 1.0)
|
||||
(new 'static 'vector :x -1024.0 :y 204.8 :z -3276.8 :w 1.0)
|
||||
)
|
||||
:exhaust-local-dir (new 'static 'inline-array vector 2 (new 'static 'vector :z -1.0 :w 1.0) (new 'static 'vector :z -1.0 :w 1.0))
|
||||
:smoke-local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 1638.4 :y -2048.0 :z 7372.8 :w 1.0)
|
||||
(new 'static 'vector :x -1638.4 :y -2048.0 :z 7372.8 :w 1.0)
|
||||
)
|
||||
:smoke-local-vel (new 'static 'inline-array vector 2 (new 'static 'vector :w 1.0) (new 'static 'vector :w 1.0))
|
||||
:headlight-local-pos (new 'static 'inline-array vector 3
|
||||
(new 'static 'vector :y -819.2 :z 10240.0 :w 1.0)
|
||||
(new 'static 'vector)
|
||||
(new 'static 'vector)
|
||||
)
|
||||
:taillight-local-pos (new 'static 'inline-array vector 2 (new 'static 'vector :y 1433.6 :z -10240.0 :w 1.0) (new 'static 'vector))
|
||||
:lift-thruster-count 2
|
||||
:roll-thruster-count 2
|
||||
:steering-thruster-count 2
|
||||
:stabilizer-count 4
|
||||
:inv-lift-thruster-count 0.5
|
||||
:lift-thruster-array (new 'static 'inline-array vehicle-control-point 2
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :y 819.2 :z 7372.8003 :w 1.0)
|
||||
:normal (new 'static 'vector :y -1.0 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :y 819.2 :z -2457.6 :w 1.0)
|
||||
:normal (new 'static 'vector :y -1.0 :w 1.0)
|
||||
)
|
||||
)
|
||||
:roll-thruster-array (new 'static 'inline-array vehicle-control-point 2
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :x 6963.2 :y 819.2 :z 2457.6 :w 1.0)
|
||||
:normal (new 'static 'vector :x 0.3 :y -0.6 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :x -6963.2 :y 819.2 :z 2457.6 :w 1.0)
|
||||
:normal (new 'static 'vector :x -0.3 :y -0.6 :w 1.0)
|
||||
)
|
||||
)
|
||||
:steering-thruster-array (new 'static 'inline-array vehicle-control-point 2
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z 10240.0 :w 1.0)
|
||||
:normal (new 'static 'vector :x 1.0 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z -5324.8 :w 1.0)
|
||||
:normal (new 'static 'vector :x -1.0 :w 1.0)
|
||||
)
|
||||
)
|
||||
:stabilizer-array (new 'static 'inline-array vehicle-control-point 6
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z -5734.4 :w 1.0)
|
||||
:normal (new 'static 'vector :x 1.0 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z 10649.6 :w 1.0)
|
||||
:normal (new 'static 'vector :x 1.0 :w 0.5)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z 2457.6 :w 1.0)
|
||||
:normal (new 'static 'vector :x 1.0 :w 2.0)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z -5734.4 :w 1.0)
|
||||
:normal (new 'static 'vector :y 1.0 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-control-point)
|
||||
(new 'static 'vehicle-control-point)
|
||||
)
|
||||
:engine-thrust-local-pos (new 'static 'vector :z -3276.7998 :w 1.0)
|
||||
:brake-local-pos (new 'static 'vector :z -3276.7998 :w 1.0)
|
||||
:color-option-count 1
|
||||
:color-option-array (new 'static 'inline-array vector 1 (new 'static 'vector :x 0.6 :y 0.6 :z 1.5 :w 1.0))
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for method 33 of type evan-test-bike
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod init-skel-and-rigid-body evan-test-bike ((obj evan-test-bike))
|
||||
(initialize-skeleton
|
||||
obj
|
||||
(the-as skeleton-group (art-group-get-by-name *level* "skel-bikea" (the-as (pointer uint32) #f)))
|
||||
(the-as pair 0)
|
||||
)
|
||||
(alloc-and-init-rigid-body-control obj *evan-test-bike-constants*)
|
||||
(set! (-> obj fin-fl) (new 'process 'joint-mod-rotate-local obj 8 #t))
|
||||
(set! (-> obj fin-fr) (new 'process 'joint-mod-rotate-local obj 7 #t))
|
||||
(set! (-> obj fin-rl) (new 'process 'joint-mod-rotate-local obj 6 #t))
|
||||
(set! (-> obj fin-rr) (new 'process 'joint-mod-rotate-local obj 5 #t))
|
||||
(set! (-> obj rudder) (new 'process 'joint-mod-rotate-local obj 4 #t))
|
||||
(set! (-> obj brake-l) (new 'process 'joint-mod-rotate-local obj 9 #t))
|
||||
(set! (-> obj brake-r) (new 'process 'joint-mod-rotate-local obj 10 #t))
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
|
||||
|
||||
|
||||
+304
@@ -0,0 +1,304 @@
|
||||
;;-*-Lisp-*-
|
||||
(in-package goal)
|
||||
|
||||
;; definition of type test-car
|
||||
(deftype test-car (cara)
|
||||
()
|
||||
:heap-base #x320
|
||||
:method-count-assert 144
|
||||
:size-assert #x398
|
||||
:flag-assert #x9003200398
|
||||
)
|
||||
|
||||
;; definition for method 3 of type test-car
|
||||
(defmethod inspect test-car ((obj test-car))
|
||||
(when (not obj)
|
||||
(set! obj obj)
|
||||
(goto cfg-4)
|
||||
)
|
||||
(let ((t9-0 (method-of-type cara inspect)))
|
||||
(t9-0 obj)
|
||||
)
|
||||
(label cfg-4)
|
||||
obj
|
||||
)
|
||||
|
||||
;; definition for symbol *test-car-constants*, type rigid-body-vehicle-constants
|
||||
(define *test-car-constants*
|
||||
(new 'static 'rigid-body-vehicle-constants
|
||||
:info (new 'static 'rigid-body-info
|
||||
:mass 8.0
|
||||
:inv-mass 0.125
|
||||
:linear-damping 0.995
|
||||
:angular-damping 0.995
|
||||
:bounce-factor 0.4
|
||||
:friction-factor 0.05
|
||||
:bounce-mult-factor 1.22
|
||||
:cm-offset-joint (new 'static 'vector :w 1.0)
|
||||
:inertial-tensor-box (new 'static 'array meters 3 (meters 4) (meters 3) (meters 6))
|
||||
)
|
||||
:extra (new 'static 'rigid-body-object-extra-info
|
||||
:max-time-step 0.033333335
|
||||
:gravity (meters 40)
|
||||
:idle-distance (meters 50)
|
||||
:attack-force-scale 1.0
|
||||
)
|
||||
:name '*test-car-constants*
|
||||
:flags #x68
|
||||
:object-type #xe
|
||||
:guard-type #x7
|
||||
:max-engine-thrust (meters 39)
|
||||
:inv-max-engine-thrust 0.000006260016
|
||||
:engine-response-rate 20.0
|
||||
:engine-intake-factor 1.0
|
||||
:brake-factor 1.0
|
||||
:turbo-boost-factor 1.0
|
||||
:max-xz-speed (meters 40)
|
||||
:ground-probe-distance (meters 4.5)
|
||||
:cos-ground-effect-angle 0.42261824
|
||||
:spring-lift-factor 0.4
|
||||
:air-drag-factor 1.0
|
||||
:steering-thruster-factor 3.0
|
||||
:steering-thruster-max-gain 3.5
|
||||
:steering-thruster-half-gain-speed (meters 15)
|
||||
:tire-friction-factor 0.6
|
||||
:tire-static-friction 0.55
|
||||
:tire-dynamic-friction 0.4
|
||||
:tire-dynamic-friction-speed (meters 2)
|
||||
:tire-inv-max-friction-speed 0.000024414063
|
||||
:airfoil-factor 1.0
|
||||
:drag-force-factor 1.0
|
||||
:speed-scrubbing-drag 10.0
|
||||
:speed-limiting-drag 0.7
|
||||
:pitch-control-factor 0.5
|
||||
:roll-control-factor 1.0
|
||||
:jump-thrust-factor 0.5
|
||||
:buoyancy-factor 1.0
|
||||
:player-weight 163840.0
|
||||
:player-shift-x (meters 0.6)
|
||||
:player-shift-z (meters 1)
|
||||
:target-speed-offset (meters 3)
|
||||
:turning-accel (meters 20)
|
||||
:toughness-factor 1.0
|
||||
:damage-factor 2.5
|
||||
:camera-string-min-height (meters 4.5)
|
||||
:camera-string-max-height (meters 4.5)
|
||||
:camera-string-min-length (meters 5)
|
||||
:camera-string-max-length (meters 12.5)
|
||||
:camera-min-fov 15109.688
|
||||
:camera-max-fov 17476.268
|
||||
:camera-head-offset 8192.0
|
||||
:camera-foot-offset 4096.0
|
||||
:camera-normal-max-angle-offset 5461.3335
|
||||
:camera-air-max-angle-offset 5461.3335
|
||||
:camera-max-lookaround-speed 40960.0
|
||||
:seat-count 3
|
||||
:section-count 4
|
||||
:rider-stance #x1
|
||||
:grab-rail-count #x6
|
||||
:grab-rail-array (new 'static 'inline-array vehicle-grab-rail-info 6
|
||||
(new 'static 'vehicle-grab-rail-info
|
||||
:local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 4505.6 :y -2662.4 :z 15360.0 :w 1.0)
|
||||
(new 'static 'vector :x -4505.6 :y -2662.4 :z 15360.0 :w 1.0)
|
||||
)
|
||||
:normal (new 'static 'vector :z 1.0 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-grab-rail-info
|
||||
:local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 7372.8 :y -819.2 :z -4096.0 :w 1.0)
|
||||
(new 'static 'vector :x 7372.8 :y -819.2 :z 4096.0 :w 1.0)
|
||||
)
|
||||
:normal (new 'static 'vector :x 1.0 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-grab-rail-info
|
||||
:local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x -7372.8 :y -819.2 :z 4096.0 :w 1.0)
|
||||
(new 'static 'vector :x -7372.8 :y -819.2 :z -4096.0 :w 1.0)
|
||||
)
|
||||
:normal (new 'static 'vector :x -1.0 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-grab-rail-info
|
||||
:local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x -3686.4 :y -409.6 :z -14950.4 :w 1.0)
|
||||
(new 'static 'vector :x 3686.4 :y -409.6 :z -14950.4 :w 1.0)
|
||||
)
|
||||
:normal (new 'static 'vector :z -1.0 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-grab-rail-info
|
||||
:local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 3837.952 :y -409.6 :z -14950.4 :w 1.0)
|
||||
(new 'static 'vector :x 6041.6 :y -614.4 :z -9011.2 :w 1.0)
|
||||
)
|
||||
:normal (new 'static 'vector :x 0.707 :z -0.707 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-grab-rail-info
|
||||
:local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x -6041.6 :y -614.4 :z -9011.2 :w 1.0)
|
||||
(new 'static 'vector :x -3837.952 :y -409.6 :z -14950.4 :w 1.0)
|
||||
)
|
||||
:normal (new 'static 'vector :x -0.707 :z -0.707 :w 1.0)
|
||||
)
|
||||
)
|
||||
:seat-array (new 'static 'inline-array vehicle-seat-info 4
|
||||
(new 'static 'vehicle-seat-info
|
||||
:position (new 'static 'vector :x 4079.616 :y 819.2 :z -311.296 :w (the-as float #x30000))
|
||||
)
|
||||
(new 'static 'vehicle-seat-info
|
||||
:position (new 'static 'vector :x -4079.616 :y 819.2 :z -311.296 :w (the-as float #x30000))
|
||||
)
|
||||
(new 'static 'vehicle-seat-info
|
||||
:position (new 'static 'vector :y 3751.936 :z -10563.584 :w (the-as float #x40000))
|
||||
)
|
||||
(new 'static 'vehicle-seat-info)
|
||||
)
|
||||
:rider-hand-offset (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 614.4 :y 614.4 :z 1433.6 :w 1.0)
|
||||
(new 'static 'vector :x 614.4 :y 614.4 :z -1433.6 :w 1.0)
|
||||
)
|
||||
:section-bike-front (new 'static 'vehicle-section-info
|
||||
:damage-seg-array (new 'static 'array uint64 3 #x200 #x20 #x2)
|
||||
:damage-seg-count 3
|
||||
)
|
||||
:section-bike-rear (new 'static 'vehicle-section-info
|
||||
:damage-seg-array (new 'static 'array uint64 3 #x400 #x40 #x4)
|
||||
:damage-seg-count 3
|
||||
)
|
||||
:section-car-front-right (new 'static 'vehicle-section-info
|
||||
:damage-seg-array (new 'static 'array uint64 3 #x800 #x80 #x8)
|
||||
:damage-seg-count 3
|
||||
)
|
||||
:section-car-rear-right (new 'static 'vehicle-section-info
|
||||
:damage-seg-array (new 'static 'array uint64 3 #x1000 #x100 #x10)
|
||||
:damage-seg-count 3
|
||||
)
|
||||
:explosion #f
|
||||
:engine-pitch-scale 0.09
|
||||
:engine-pitch-mod-amp 0.01
|
||||
:engine-sound-select 5
|
||||
:engine-sound (static-sound-name "vehicle-engine")
|
||||
:thrust-sound (static-sound-name "bike-thrust")
|
||||
:scrape-sound (static-sound-name "car-scrape-stn")
|
||||
:glance-sound (static-sound-name "car-glance-stn")
|
||||
:impact-sound (static-sound-name "car-impact-stn")
|
||||
:extra-sound (static-sound-name "car-by-5")
|
||||
:explosion-part #xa1
|
||||
:headlight-count 2
|
||||
:taillight-count 2
|
||||
:thruster-flame-width (meters 0.6)
|
||||
:thruster-flame-length (meters 2)
|
||||
:thruster-local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 3072.0 :z -14336.0 :w 1.0)
|
||||
(new 'static 'vector :x -3072.0 :z -14336.0 :w 1.0)
|
||||
)
|
||||
:exhaust-local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 6963.2 :y -1024.0 :z -7372.8 :w 1.0)
|
||||
(new 'static 'vector :x -6963.2 :y -1024.0 :z -7372.8 :w 1.0)
|
||||
)
|
||||
:exhaust-local-dir (new 'static 'inline-array vector 2 (new 'static 'vector :z -1.0 :w 1.0) (new 'static 'vector :z -1.0 :w 1.0))
|
||||
:smoke-local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 3072.0 :z -13926.4 :w 1.0)
|
||||
(new 'static 'vector :x -3072.0 :z -13926.4 :w 1.0)
|
||||
)
|
||||
:smoke-local-vel (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 12288.0 :w 1.0)
|
||||
(new 'static 'vector :x -12288.0 :w 1.0)
|
||||
)
|
||||
:headlight-local-pos (new 'static 'inline-array vector 3
|
||||
(new 'static 'vector :x 4915.2 :z 15564.8 :w 1.0)
|
||||
(new 'static 'vector :x -4915.2 :z 15564.8 :w 1.0)
|
||||
(new 'static 'vector)
|
||||
)
|
||||
:taillight-local-pos (new 'static 'inline-array vector 2
|
||||
(new 'static 'vector :x 3276.8 :y 3276.8 :z -14131.2 :w 1.0)
|
||||
(new 'static 'vector :x -3276.8 :y 3276.8 :z -14131.2 :w 1.0)
|
||||
)
|
||||
:lift-thruster-count 2
|
||||
:roll-thruster-count 2
|
||||
:steering-thruster-count 2
|
||||
:stabilizer-count 4
|
||||
:inv-lift-thruster-count 0.5
|
||||
:lift-thruster-array (new 'static 'inline-array vehicle-control-point 2
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :y 819.2 :z 8192.0 :w 1.0)
|
||||
:normal (new 'static 'vector :y -1.0 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :y 819.2 :z -8192.0 :w 1.0)
|
||||
:normal (new 'static 'vector :y -1.0 :w 1.0)
|
||||
)
|
||||
)
|
||||
:roll-thruster-array (new 'static 'inline-array vehicle-control-point 2
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :x 6963.2 :y 819.2 :w 1.0)
|
||||
:normal (new 'static 'vector :x 0.3 :y -0.6 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :x -6963.2 :y 819.2 :w 1.0)
|
||||
:normal (new 'static 'vector :x -0.3 :y -0.6 :w 1.0)
|
||||
)
|
||||
)
|
||||
:steering-thruster-array (new 'static 'inline-array vehicle-control-point 2
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z 7782.4 :w 1.0)
|
||||
:normal (new 'static 'vector :x 1.0 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z -7782.4 :w 1.0)
|
||||
:normal (new 'static 'vector :x -1.0 :w 1.0)
|
||||
)
|
||||
)
|
||||
:stabilizer-array (new 'static 'inline-array vehicle-control-point 6
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z -8192.0 :w 1.0)
|
||||
:normal (new 'static 'vector :x 1.0 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z 8192.0 :w 1.0)
|
||||
:normal (new 'static 'vector :x 1.0 :w 0.5)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :w 1.0)
|
||||
:normal (new 'static 'vector :x 1.0 :w 2.0)
|
||||
)
|
||||
(new 'static 'vehicle-control-point
|
||||
:local-pos (new 'static 'vector :z -8192.0 :w 1.0)
|
||||
:normal (new 'static 'vector :y 1.0 :w 1.0)
|
||||
)
|
||||
(new 'static 'vehicle-control-point)
|
||||
(new 'static 'vehicle-control-point)
|
||||
)
|
||||
:engine-thrust-local-pos (new 'static 'vector :z -5734.4 :w 1.0)
|
||||
:brake-local-pos (new 'static 'vector :z -8192.0 :w 1.0)
|
||||
:color-option-count 1
|
||||
:color-option-array (new 'static 'inline-array vector 1 (new 'static 'vector :x 0.5 :y 1.0 :z 0.5 :w 1.0))
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for method 33 of type test-car
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod init-skel-and-rigid-body test-car ((obj test-car))
|
||||
(initialize-skeleton
|
||||
obj
|
||||
(the-as skeleton-group (art-group-get-by-name *level* "skel-cara" (the-as (pointer uint32) #f)))
|
||||
(the-as pair 0)
|
||||
)
|
||||
(alloc-and-init-rigid-body-control obj *test-car-constants*)
|
||||
(set! (-> obj rider-hand-joint-array 0) 11)
|
||||
(set! (-> obj rider-hand-joint-array 1) 12)
|
||||
(set! (-> obj steering-wheel-l) (new 'process 'joint-mod-rotate-local obj 11 #t))
|
||||
(set! (-> obj steering-wheel-r) (new 'process 'joint-mod-rotate-local obj 12 #t))
|
||||
(set! (-> obj fin-fl) (new 'process 'joint-mod-rotate-local obj 4 #t))
|
||||
(set! (-> obj fin-fr) (new 'process 'joint-mod-rotate-local obj 5 #t))
|
||||
(set! (-> obj fin-rl) (new 'process 'joint-mod-rotate-local obj 6 #t))
|
||||
(set! (-> obj fin-rr) (new 'process 'joint-mod-rotate-local obj 8 #t))
|
||||
(set! (-> obj rudder) (new 'process 'joint-mod-rotate-local obj 10 #t))
|
||||
(set! (-> obj rudder-l) (new 'process 'joint-mod-rotate-local obj 7 #t))
|
||||
(set! (-> obj rudder-r) (new 'process 'joint-mod-rotate-local obj 9 #t))
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
|
||||
|
||||
|
||||
+111
-108
@@ -57,8 +57,8 @@
|
||||
:size-assert #x20
|
||||
:flag-assert #xb00000020
|
||||
(:methods
|
||||
(vis-cell-method-9 (_type_) none 9)
|
||||
(vis-cell-method-10 (_type_) none 10)
|
||||
(reset-segment-counts (_type_) none 9)
|
||||
(debug-draw (_type_) none 10)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -203,11 +203,11 @@
|
||||
:size-assert #x40
|
||||
:flag-assert #xe00000040
|
||||
(:methods
|
||||
(grid-info-method-9 (_type_ (pointer bounding-box) int int) none 9)
|
||||
(grid-info-method-10 (_type_ vis-grid-pos vector) none 10)
|
||||
(grid-info-method-11 (_type_ vis-grid-box vector) none 11)
|
||||
(grid-info-method-12 (_type_ rgba) none 12)
|
||||
(grid-info-method-13 (_type_ vis-grid-pos rgba) none 13)
|
||||
(setup-grid-from-bounding-box (_type_ (pointer bounding-box) int int) none 9)
|
||||
(lookup-cell-for-point (_type_ vis-grid-pos vector) none 10)
|
||||
(lookup-box-for-sphere (_type_ vis-grid-box vector) none 11)
|
||||
(debug-draw-grid (_type_ rgba) none 12)
|
||||
(debug-draw-cell (_type_ vis-grid-pos rgba) none 13)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -229,28 +229,28 @@
|
||||
|
||||
;; definition of type city-level-info
|
||||
(deftype city-level-info (structure)
|
||||
((grid-info grid-info :inline :offset-assert 0)
|
||||
(cell-array (inline-array vis-cell) :offset-assert 64)
|
||||
(segment-count int16 :offset-assert 68)
|
||||
(cell-count uint16 :offset-assert 70)
|
||||
(segment-array uint32 :offset-assert 72)
|
||||
(nav-graph nav-graph :offset-assert 76)
|
||||
(camera-ceiling meters :offset-assert 80)
|
||||
(pad-array int8 56 :offset-assert 84)
|
||||
((grid-info grid-info :inline :offset-assert 0)
|
||||
(cell-array (inline-array vis-cell) :offset-assert 64)
|
||||
(segment-count int16 :offset-assert 68)
|
||||
(cell-count uint16 :offset-assert 70)
|
||||
(segment-array (inline-array nav-segment) :offset-assert 72)
|
||||
(nav-graph nav-graph :offset-assert 76)
|
||||
(camera-ceiling meters :offset-assert 80)
|
||||
(pad-array int8 56 :offset-assert 84)
|
||||
)
|
||||
:method-count-assert 19
|
||||
:size-assert #x8c
|
||||
:flag-assert #x130000008c
|
||||
(:methods
|
||||
(city-level-info-method-9 (_type_) symbol 9)
|
||||
(city-level-info-method-10 (_type_ vis-ray vector vector) none 10)
|
||||
(init-vis-ray (_type_ vis-ray vector vector) none 10)
|
||||
(city-level-info-method-11 (_type_ vis-ray) none 11)
|
||||
(city-level-info-method-12 (_type_ vector nav-branch vector) vector 12)
|
||||
(city-level-info-method-13 (_type_ vector) none 13)
|
||||
(city-level-info-method-14 (_type_ vis-grid-box) vis-cell 14)
|
||||
(city-level-info-method-15 (_type_ int int) symbol 15)
|
||||
(city-level-info-method-16 (_type_ vector int traffic-find-segment-struct (function traffic-find-segment-struct object none)) none 16)
|
||||
(city-level-info-method-17 (_type_ traffic-engine) none 17)
|
||||
(lookup-cell-by-position (_type_ vector) vis-cell 13)
|
||||
(get-first-cell-in-box (_type_ vis-grid-box) vis-cell 14)
|
||||
(sphere-in-grid? (_type_ int int) symbol 15)
|
||||
(callback-on-nav-segments-in-sphere (_type_ vector int traffic-find-segment-struct (function traffic-find-segment-struct nav-segment none)) none 16)
|
||||
(update-suppressions-from-traffic-engine (_type_ traffic-engine) none 17)
|
||||
(city-level-info-method-18 (_type_) none 18)
|
||||
)
|
||||
)
|
||||
@@ -287,12 +287,12 @@
|
||||
:size-assert #x820
|
||||
:flag-assert #xf00000820
|
||||
(:methods
|
||||
(traffic-level-data-method-9 (_type_) none 9)
|
||||
(traffic-level-data-method-10 (_type_ vis-cell) none 10)
|
||||
(traffic-level-data-method-11 (_type_ int) none 11)
|
||||
(traffic-level-data-method-12 (_type_ vis-cell) none 12)
|
||||
(traffic-level-data-method-13 (_type_) vis-cell 13)
|
||||
(traffic-level-data-method-14 (_type_) none 14)
|
||||
(reset (_type_) none 9)
|
||||
(add-active-cell (_type_ vis-cell) none 10)
|
||||
(remove-active-cell (_type_ int) none 11)
|
||||
(add-newly-active-cell (_type_ vis-cell) none 12)
|
||||
(per-frame-cell-update (_type_) none 13)
|
||||
(debug-draw (_type_) none 14)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -315,10 +315,10 @@
|
||||
|
||||
;; definition of type traffic-suppression-box
|
||||
(deftype traffic-suppression-box (structure)
|
||||
((data uint8 32 :offset-assert 0)
|
||||
(bbox bounding-box :inline :offset 0)
|
||||
(flags uint8 :offset 12)
|
||||
(duration uint32 :offset 28)
|
||||
((data uint8 32 :offset-assert 0)
|
||||
(bbox bounding-box :inline :offset 0)
|
||||
(flags traffic-suppression-box-flags :offset 12)
|
||||
(duration uint32 :offset 28)
|
||||
)
|
||||
:method-count-assert 9
|
||||
:size-assert #x20
|
||||
@@ -335,19 +335,19 @@
|
||||
(format #t "~1Tdata[32] @ #x~X~%" (-> obj bbox))
|
||||
(format #t "~1Tbbox: #<bounding-box @ #x~X>~%" (-> obj bbox))
|
||||
(format #t "~1Tflags: ~D~%" (-> obj flags))
|
||||
(format #t "~1Tduration: ~D~%" (-> obj bbox max w))
|
||||
(format #t "~1Tduration: ~D~%" (-> obj duration))
|
||||
(label cfg-4)
|
||||
obj
|
||||
)
|
||||
|
||||
;; definition of type traffic-guard-type-info
|
||||
(deftype traffic-guard-type-info (structure)
|
||||
((object-type uint8 :offset-assert 0)
|
||||
(max-target-count int8 :offset-assert 1)
|
||||
(min-target-count int8 :offset-assert 2)
|
||||
(target-count int8 :offset-assert 3)
|
||||
(count int8 :offset-assert 4)
|
||||
(change-to-type uint8 :offset-assert 5)
|
||||
((object-type traffic-type :offset-assert 0)
|
||||
(max-target-count int8 :offset-assert 1)
|
||||
(min-target-count int8 :offset-assert 2)
|
||||
(target-count int8 :offset-assert 3)
|
||||
(count int8 :offset-assert 4)
|
||||
(change-to-type uint8 :offset-assert 5)
|
||||
)
|
||||
:method-count-assert 9
|
||||
:size-assert #x6
|
||||
@@ -498,7 +498,7 @@
|
||||
(duration uint32 :offset-assert 16)
|
||||
(start-time time-frame :offset-assert 24)
|
||||
(notify-time time-frame :offset-assert 32)
|
||||
(alarm-sound-id uint32 :offset-assert 40)
|
||||
(alarm-sound-id sound-id :offset-assert 40)
|
||||
(target-status-array traffic-target-status 3 :inline :offset-assert 48)
|
||||
(settings traffic-alert-state-settings :inline :offset-assert 288)
|
||||
(guard-type-info-array traffic-guard-type-info 6 :inline :offset-assert 384)
|
||||
@@ -508,7 +508,7 @@
|
||||
:size-assert #x3d8
|
||||
:flag-assert #xa000003d8
|
||||
(:methods
|
||||
(traffic-alert-state-method-9 (_type_) none 9)
|
||||
(reset (_type_) none 9)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -604,19 +604,19 @@
|
||||
|
||||
;; definition of type traffic-suppressor
|
||||
(deftype traffic-suppressor (structure)
|
||||
((flags uint8 :offset-assert 0)
|
||||
(bbox bounding-box :inline :offset-assert 16)
|
||||
(array traffic-suppression-box 16 :inline :offset-assert 48)
|
||||
((flags traffic-suppression-flags :offset-assert 0)
|
||||
(bbox bounding-box :inline :offset-assert 16)
|
||||
(array traffic-suppression-box 16 :inline :offset-assert 48)
|
||||
)
|
||||
:method-count-assert 14
|
||||
:size-assert #x230
|
||||
:flag-assert #xe00000230
|
||||
(:methods
|
||||
(traffic-suppressor-method-9 (_type_) none 9)
|
||||
(traffic-suppressor-method-10 (_type_ traffic-suppression-params) none 10)
|
||||
(traffic-suppressor-method-11 (_type_ int) none 11)
|
||||
(traffic-suppressor-method-12 (_type_ traffic-suppression-params) none 12)
|
||||
(traffic-suppressor-method-13 (_type_) none 13)
|
||||
(reset-boxes (_type_) none 9)
|
||||
(add-new-supression-box (_type_ traffic-suppression-params) none 10)
|
||||
(remove-box-by-id (_type_ int) none 11)
|
||||
(update-box-from-params (_type_ traffic-suppression-params) none 12)
|
||||
(debug-draw (_type_) none 13)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -643,7 +643,7 @@
|
||||
(active-object-count uint8 :offset-assert 13)
|
||||
(inactive-object-count int8 :offset-assert 14)
|
||||
(active-object-list handle 126 :offset-assert 16)
|
||||
(active-object-type-list uint8 126 :offset-assert 1024)
|
||||
(active-object-type-list traffic-type 126 :offset-assert 1024)
|
||||
)
|
||||
:method-count-assert 27
|
||||
:size-assert #x47e
|
||||
@@ -652,21 +652,21 @@
|
||||
(traffic-tracker-method-9 (_type_) none 9)
|
||||
(traffic-tracker-method-10 (_type_) none 10)
|
||||
(traffic-tracker-method-11 (_type_) none 11)
|
||||
(traffic-tracker-method-12 (_type_ uint handle) none 12)
|
||||
(traffic-tracker-method-13 (_type_ int) handle 13)
|
||||
(traffic-tracker-method-14 (_type_ int handle) none 14)
|
||||
(traffic-tracker-method-15 (_type_ int) handle 15)
|
||||
(traffic-tracker-method-16 (_type_ int handle) handle 16)
|
||||
(traffic-tracker-method-17 (_type_ int handle) none 17)
|
||||
(traffic-tracker-method-18 (_type_ process) none 18)
|
||||
(traffic-tracker-method-19 (_type_ handle) none 19)
|
||||
(traffic-tracker-method-20 (_type_ int symbol) none 20)
|
||||
(traffic-tracker-method-21 (_type_ traffic-object-spawn-params) none 21)
|
||||
(traffic-tracker-method-22 (_type_ int nav-segment float) none 22)
|
||||
(traffic-tracker-method-23 (_type_ traffic-object-spawn-params) none 23)
|
||||
(traffic-tracker-method-24 (_type_ uint traffic-engine) none 24)
|
||||
(traffic-tracker-method-25 (_type_ (function process-focusable traffic-object-type-info none)) none 25)
|
||||
(traffic-tracker-method-26 (_type_ int (function process-tree none)) none 26)
|
||||
(add-active-process (_type_ traffic-type handle) none 12)
|
||||
(remove-active-process (_type_ int) handle 13)
|
||||
(add-reserved-process (_type_ traffic-type handle) none 14)
|
||||
(get-from-inactive-by-type (_type_ traffic-type) handle 15)
|
||||
(get-from-inactive-by-handle (_type_ traffic-type handle) handle 16)
|
||||
(deactivate-object (_type_ int symbol) none 17)
|
||||
(set-process-to-killed (_type_ process) none 18)
|
||||
(deactivate-all (_type_ symbol) none 19)
|
||||
(deactivate-all-of-type (_type_ traffic-type symbol) none 20)
|
||||
(activate-from-params (_type_ traffic-object-spawn-params) none 21)
|
||||
(activate-by-type (_type_ traffic-type nav-segment float) none 22)
|
||||
(activate-by-handle (_type_ traffic-object-spawn-params) none 23)
|
||||
(reset (_type_ uint traffic-engine) none 24)
|
||||
(for-all-active-processes (_type_ (function process-focusable traffic-object-type-info none)) none 25)
|
||||
(for-all-active-processes-of-type (_type_ traffic-type (function process-focusable traffic-object-type-info none)) none 26)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -692,7 +692,7 @@
|
||||
;; definition of type traffic-engine
|
||||
(deftype traffic-engine (basic)
|
||||
((object-hash spatial-hash :offset-assert 4)
|
||||
(manager uint64 :offset-assert 8)
|
||||
(manager handle :offset-assert 8)
|
||||
(inv-density-factor float :offset-assert 16)
|
||||
(sync-clock uint8 :offset-assert 20)
|
||||
(sync-mask-8 uint8 :offset-assert 21)
|
||||
@@ -704,6 +704,8 @@
|
||||
(level-data-array traffic-level-data 2 :inline :offset-assert 1040)
|
||||
(object-type-info-array traffic-object-type-info 21 :inline :offset-assert 5200)
|
||||
(tracker-array traffic-tracker 2 :inline :offset-assert 5872)
|
||||
(citizen-tracker-array traffic-tracker :inline :offset 5872)
|
||||
(vehicle-tracker-array traffic-tracker :inline :offset 7024)
|
||||
(inactive-object-array handle 420 :offset-assert 8176)
|
||||
(suppressor traffic-suppressor :inline :offset-assert 11536)
|
||||
(danger-sphere-count int8 :offset-assert 12096)
|
||||
@@ -714,33 +716,34 @@
|
||||
:size-assert #x3050
|
||||
:flag-assert #x4a00003050
|
||||
(:methods
|
||||
(traffic-engine-method-9 (_type_) none 9)
|
||||
(traffic-engine-method-10 (_type_ process) none 10)
|
||||
(traffic-engine-method-11 (_type_) none 11)
|
||||
(traffic-engine-method-12 (_type_) none 12)
|
||||
(add-object (_type_ int process) none 13)
|
||||
(traffic-engine-method-14 (_type_ object object) symbol 14)
|
||||
(traffic-engine-method-15 (_type_ nav-segment float) none 15)
|
||||
(traffic-engine-method-16 (_type_ nav-segment float) none 16)
|
||||
(traffic-engine-method-17 (_type_ nav-branch) symbol 17)
|
||||
(new (symbol type) _type_ 0)
|
||||
(update-traffic (_type_) none 9)
|
||||
(reset-and-init-from-manager (_type_ process) none 10)
|
||||
(stop-alarm-sound (_type_) none 11)
|
||||
(debug-unused (_type_) none 12)
|
||||
(add-object (_type_ traffic-type process) none 13)
|
||||
(sphere-in-loaded-city-infos? (_type_ int vector) symbol 14)
|
||||
(activate-one-citizen (_type_ nav-segment float) none 15)
|
||||
(activate-one-vehicle (_type_ nav-segment float) none 16)
|
||||
(can-dest-be-used? (_type_ nav-branch) symbol 17)
|
||||
(child-killed (_type_ process) none 18)
|
||||
(traffic-engine-method-19 (_type_ object) none 19)
|
||||
(traffic-engine-method-20 (_type_ vector vector int) nav-segment 20)
|
||||
(traffic-engine-method-21 (_type_ vector int traffic-find-segment-struct function) none 21)
|
||||
(add-danger-sphere (_type_ traffic-danger-info) none 22)
|
||||
(traffic-engine-method-23 (_type_) none 23)
|
||||
(deactivate-all-from-level (_type_ symbol) none 19)
|
||||
(find-best-segment (_type_ vector vector int) nav-segment 20)
|
||||
(callback-on-nav-segments-in-sphere (_type_ vector int traffic-find-segment-struct (function traffic-find-segment-struct nav-segment none)) none 21)
|
||||
(add-danger (_type_ traffic-danger-info) none 22)
|
||||
(guard-count (_type_) int 23)
|
||||
(set-target-level (_type_ float) none 24)
|
||||
(set-guard-target-level (_type_ float) none 25)
|
||||
(deactivate-all (_type_) none 26)
|
||||
(deactivate-by-type (_type_ int) none 27)
|
||||
(traffic-engine-method-28 (_type_) symbol 28)
|
||||
(deactivate-by-type (_type_ traffic-type) none 27)
|
||||
(maybe-increase-guard-aim-count (_type_) symbol 28)
|
||||
(restore-default-settings (_type_) none 29)
|
||||
(increase-alert-level (_type_ object target) none 30)
|
||||
(decrease-alert-level (_type_ object) none 31)
|
||||
(set-alert-level (_type_ object) none 32)
|
||||
(set-max-alert-level (_type_ object) none 33)
|
||||
(set-alert-duration (_type_ object) none 34)
|
||||
(get-alert-level (_type_) symbol 35)
|
||||
(increase-alert-level (_type_ int target) none 30)
|
||||
(decrease-alert-level (_type_ int) none 31)
|
||||
(set-alert-level (_type_ int) none 32)
|
||||
(set-max-alert-level (_type_ int) none 33)
|
||||
(set-alert-duration (_type_ int) none 34)
|
||||
(get-alert-level (_type_) int 35)
|
||||
(get-target (_type_) target 36)
|
||||
(set-object-target-level (_type_ int float) none 37)
|
||||
(set-object-target-count (_type_ int int) none 38)
|
||||
@@ -748,37 +751,37 @@
|
||||
(get-object-reserve-count (_type_ int) int 40)
|
||||
(get-object-remaining-count (_type_ int) int 41)
|
||||
(activate-object (_type_ traffic-object-spawn-params) none 42)
|
||||
(traffic-engine-method-43 (_type_ traffic-object-spawn-params) none 43)
|
||||
(traffic-engine-method-44 (_type_ int float) none 44)
|
||||
(traffic-engine-method-45 (_type_) int 45)
|
||||
(new-suppression-box (_type_ object) none 46)
|
||||
(traffic-engine-method-47 (_type_ traffic-suppression-params) none 47)
|
||||
(activate-by-handle (_type_ traffic-object-spawn-params) none 43)
|
||||
(set-parking-spot-prob (_type_ int float) none 44)
|
||||
(get-random-parking-spot-type (_type_) traffic-type 45)
|
||||
(new-suppression-box (_type_ traffic-suppression-params) none 46)
|
||||
(remove-suppression-box (_type_ traffic-suppression-params) none 47)
|
||||
(update-suppression-box (_type_ traffic-suppression-params) none 48)
|
||||
(traffic-engine-method-49 (_type_ object int traffic-target-status) traffic-target-status 49)
|
||||
(traffic-engine-method-50 (_type_ process-drawable int) process-focusable 50)
|
||||
(traffic-engine-method-51 (_type_ (function none)) none 51)
|
||||
(traffic-engine-method-52 (_type_) none 52)
|
||||
(end-pursuit-by-type (_type_ int) none 53)
|
||||
(find-closest-to-with-collide-lists (_type_ process-drawable collide-spec) process-focusable 50)
|
||||
(for-all-active-processes (_type_ (function process-focusable traffic-object-type-info none)) none 51)
|
||||
(send-alert-events (_type_) none 52)
|
||||
(end-pursuit-by-type (_type_ traffic-type) none 53)
|
||||
(get-traffic-guard-type-settings (_type_ int) traffic-guard-type-settings 54)
|
||||
(get-guard-type-for-traffic-obj (_type_ int) uint 55)
|
||||
(get-traffic-guard-change-to-type (_type_ int) uint 56)
|
||||
(set-guard-target-count-range (_type_ int int int) none 57)
|
||||
(set-object-auto-activate (_type_ object object) none 58)
|
||||
(traffic-engine-method-59 (_type_ object int) none 59)
|
||||
(set-object-auto-activate (_type_ int object) none 58)
|
||||
(debug-check-proc-in-tracker (_type_ process int) none 59)
|
||||
(kill-traffic-sphere (_type_ sphere) none 60)
|
||||
(level-loaded (_type_ level) none 61)
|
||||
(level-killed (_type_ level) none 62)
|
||||
(traffic-engine-method-63 (_type_) none 63)
|
||||
(traffic-engine-method-64 (_type_) none 64)
|
||||
(traffic-engine-method-65 (_type_ vis-cell) none 65)
|
||||
(traffic-engine-method-66 (_type_) none 66)
|
||||
(traffic-engine-method-67 (_type_) none 67)
|
||||
(traffic-engine-method-68 (_type_) none 68)
|
||||
(traffic-engine-method-69 (_type_) none 69)
|
||||
(traffic-engine-method-70 (_type_) none 70)
|
||||
(traffic-engine-method-71 (_type_) none 71)
|
||||
(traffic-engine-method-72 (_type_) none 72)
|
||||
(traffic-engine-method-73 (_type_) none 73)
|
||||
(handle-new-vis-cell (_type_ vis-cell) none 65)
|
||||
(update-sync-from-frame-counter (_type_) none 66)
|
||||
(per-frame-guard-update (_type_) none 67)
|
||||
(per-frame-activate-deactivate (_type_) none 68)
|
||||
(per-frame-danger-update (_type_) none 69)
|
||||
(update-danger-from-target (_type_) none 70)
|
||||
(per-frame-alert-update (_type_) none 71)
|
||||
(per-frame-suppressor-update (_type_) none 72)
|
||||
(recompute-supressions (_type_) none 73)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -801,7 +804,7 @@
|
||||
(format #t "~1Talert-state: #<traffic-alert-state @ #x~X>~%" (-> obj alert-state))
|
||||
(format #t "~1Tlevel-data-array[2] @ #x~X~%" (-> obj level-data-array))
|
||||
(format #t "~1Tobject-type-info-array[21] @ #x~X~%" (-> obj object-type-info-array))
|
||||
(format #t "~1Ttracker-array[2] @ #x~X~%" (-> obj tracker-array))
|
||||
(format #t "~1Ttracker-array[2] @ #x~X~%" (-> obj citizen-tracker-array))
|
||||
(format #t "~1Tinactive-object-array[420] @ #x~X~%" (-> obj inactive-object-array))
|
||||
(format #t "~1Tsuppressor: #<traffic-suppressor @ #x~X>~%" (-> obj suppressor))
|
||||
(format #t "~1Tdanger-sphere-count: ~D~%" (-> obj danger-sphere-count))
|
||||
|
||||
+4053
File diff suppressed because it is too large
Load Diff
+84
-82
@@ -54,8 +54,8 @@
|
||||
(let ((v1-0 (-> arg0 grid-info box)))
|
||||
(add-debug-box #t (bucket-id debug2) (-> v1-0 min) (-> v1-0 max) *color-yellow*)
|
||||
)
|
||||
(grid-info-method-12 (-> arg0 grid-info) *color-gray*)
|
||||
(grid-info-method-13 (-> arg0 grid-info) arg1 *color-red*)
|
||||
(debug-draw-grid (-> arg0 grid-info) *color-gray*)
|
||||
(debug-draw-cell (-> arg0 grid-info) arg1 *color-red*)
|
||||
(let* ((v1-8 (+ (-> arg1 x)
|
||||
(* (-> arg1 z) (-> arg0 grid-info dimension-array 0))
|
||||
(* (* (-> arg1 y) (-> arg0 grid-info dimension-array 0)) (-> arg0 grid-info dimension-array 2))
|
||||
@@ -72,14 +72,14 @@
|
||||
;; definition for method 16 of type traffic-manager
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod traffic-manager-method-16 traffic-manager ((obj traffic-manager))
|
||||
(traffic-engine-method-9 (-> obj traffic-engine))
|
||||
(update-traffic (-> obj traffic-engine))
|
||||
(traffic-manager-method-18 obj)
|
||||
(spawn-all obj)
|
||||
(if *debug-segment*
|
||||
(traffic-engine-method-12 (-> obj traffic-engine))
|
||||
(debug-unused (-> obj traffic-engine))
|
||||
)
|
||||
(if *display-traffic-height-map*
|
||||
(xz-height-map-method-13 *traffic-height-map* (target-pos 0))
|
||||
(debug-draw *traffic-height-map* (target-pos 0))
|
||||
)
|
||||
(when *display-trail-graph*
|
||||
(let ((a0-7 *trail-graph*))
|
||||
@@ -101,9 +101,11 @@
|
||||
(when (logtest? (-> v1-2 flags) 2)
|
||||
(let ((a0-5 (+ (-> v1-2 active-count) (-> v1-2 inactive-count))))
|
||||
(when (< (-> v1-2 want-count) a0-5)
|
||||
(let ((a0-10 (handle->process
|
||||
(traffic-tracker-method-15 (-> obj traffic-engine tracker-array (-> v1-2 tracker-index)) s5-0)
|
||||
)
|
||||
(let ((a0-10 (handle->process (get-from-inactive-by-type
|
||||
(-> obj traffic-engine tracker-array (-> v1-2 tracker-index))
|
||||
(the-as traffic-type s5-0)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if a0-10
|
||||
@@ -128,9 +130,11 @@
|
||||
(while (< (the-as uint s5-0) (the-as uint 21))
|
||||
(let ((s4-0 (-> obj traffic-engine object-type-info-array s5-0)))
|
||||
(countdown (s3-0 (-> s4-0 inactive-count))
|
||||
(let ((a0-6 (handle->process
|
||||
(traffic-tracker-method-15 (-> obj traffic-engine tracker-array (-> s4-0 tracker-index)) s5-0)
|
||||
)
|
||||
(let ((a0-6 (handle->process (get-from-inactive-by-type
|
||||
(-> obj traffic-engine tracker-array (-> s4-0 tracker-index))
|
||||
(the-as traffic-type s5-0)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if a0-6
|
||||
@@ -184,7 +188,7 @@
|
||||
)
|
||||
(set! (-> s2-0 flags) (logand -9 (-> s2-0 flags)))
|
||||
(b!
|
||||
(not (and (= (-> s2-0 object-type) 6)
|
||||
(not (and (= (-> s2-0 object-type) (traffic-type crimson-guard-1))
|
||||
(> (-> obj dark-guard-ratio) 0)
|
||||
(zero? (mod v1-21 (-> obj dark-guard-ratio)))
|
||||
)
|
||||
@@ -197,7 +201,7 @@
|
||||
(label cfg-25)
|
||||
(let ((a2-0 (traffic-object-spawn obj s2-0)))
|
||||
(b! (not a2-0) cfg-27 :delay (nop!))
|
||||
(add-object (-> obj traffic-engine) (the-as int s1-0) a2-0)
|
||||
(add-object (-> obj traffic-engine) s1-0 a2-0)
|
||||
)
|
||||
(+! (-> s0-0 reserve-count) -1)
|
||||
)
|
||||
@@ -217,7 +221,7 @@
|
||||
(if (>= (the-as uint v1-37) (the-as uint 21))
|
||||
(set! v1-37 0)
|
||||
)
|
||||
(set! (-> s2-0 object-type) (the-as uint v1-37))
|
||||
(set! (-> s2-0 object-type) (the-as traffic-type v1-37))
|
||||
)
|
||||
)
|
||||
(label cfg-36)
|
||||
@@ -280,60 +284,58 @@
|
||||
;; definition for function traffic-object-spawn
|
||||
(defun traffic-object-spawn ((arg0 process) (arg1 traffic-object-spawn-params))
|
||||
(let ((v0-0 (the-as process-drawable #f)))
|
||||
(let ((v1-0 (-> arg1 object-type)))
|
||||
(cond
|
||||
((= v1-0 11)
|
||||
(set! v0-0 (vehicle-spawn arg0 bikea arg1))
|
||||
)
|
||||
((= v1-0 12)
|
||||
(set! v0-0 (vehicle-spawn arg0 bikeb arg1))
|
||||
)
|
||||
((= v1-0 13)
|
||||
(set! v0-0 (vehicle-spawn arg0 bikec arg1))
|
||||
)
|
||||
((= v1-0 14)
|
||||
(set! v0-0 (vehicle-spawn arg0 cara arg1))
|
||||
)
|
||||
((= v1-0 15)
|
||||
(set! v0-0 (vehicle-spawn arg0 carb arg1))
|
||||
)
|
||||
((= v1-0 16)
|
||||
(set! v0-0 (vehicle-spawn arg0 carc arg1))
|
||||
)
|
||||
((= v1-0 18)
|
||||
(set! v0-0 (vehicle-spawn arg0 guard-bike arg1))
|
||||
)
|
||||
((= v1-0 19)
|
||||
(set! v0-0 (vehicle-spawn arg0 hellcat arg1))
|
||||
)
|
||||
((zero? v1-0)
|
||||
(set! v0-0 (citizen-spawn arg0 citizen-norm arg1))
|
||||
)
|
||||
((= v1-0 1)
|
||||
(set! v0-0 (citizen-spawn arg0 citizen-chick arg1))
|
||||
)
|
||||
((= v1-0 2)
|
||||
(set! v0-0 (citizen-spawn arg0 citizen-fat arg1))
|
||||
)
|
||||
((= v1-0 3)
|
||||
(set! v0-0 (citizen-spawn arg0 citizen-norm arg1))
|
||||
)
|
||||
((= v1-0 10)
|
||||
(set! v0-0 (citizen-spawn arg0 metalhead-predator arg1))
|
||||
)
|
||||
((= v1-0 8)
|
||||
(set! v0-0 (citizen-spawn arg0 metalhead-grunt arg1))
|
||||
)
|
||||
((= v1-0 9)
|
||||
(set! v0-0 (citizen-spawn arg0 metalhead-flitter arg1))
|
||||
)
|
||||
((= v1-0 6)
|
||||
(set! v0-0 (citizen-spawn arg0 crimson-guard arg1))
|
||||
)
|
||||
((= v1-0 4)
|
||||
(set! v0-0 (citizen-spawn arg0 crimson-guard arg1))
|
||||
)
|
||||
)
|
||||
(case (-> arg1 object-type)
|
||||
(((traffic-type bikea))
|
||||
(set! v0-0 (vehicle-spawn arg0 bikea arg1))
|
||||
)
|
||||
(((traffic-type bikeb))
|
||||
(set! v0-0 (vehicle-spawn arg0 bikeb arg1))
|
||||
)
|
||||
(((traffic-type bikec))
|
||||
(set! v0-0 (vehicle-spawn arg0 bikec arg1))
|
||||
)
|
||||
(((traffic-type cara))
|
||||
(set! v0-0 (vehicle-spawn arg0 cara arg1))
|
||||
)
|
||||
(((traffic-type carb))
|
||||
(set! v0-0 (vehicle-spawn arg0 carb arg1))
|
||||
)
|
||||
(((traffic-type carc))
|
||||
(set! v0-0 (vehicle-spawn arg0 carc arg1))
|
||||
)
|
||||
(((traffic-type guard-bike))
|
||||
(set! v0-0 (vehicle-spawn arg0 guard-bike arg1))
|
||||
)
|
||||
(((traffic-type hellcat))
|
||||
(set! v0-0 (vehicle-spawn arg0 hellcat arg1))
|
||||
)
|
||||
(((traffic-type citizen-norm-1))
|
||||
(set! v0-0 (citizen-spawn arg0 citizen-norm arg1))
|
||||
)
|
||||
(((traffic-type citizen-chick))
|
||||
(set! v0-0 (citizen-spawn arg0 citizen-chick arg1))
|
||||
)
|
||||
(((traffic-type citizen-fat))
|
||||
(set! v0-0 (citizen-spawn arg0 citizen-fat arg1))
|
||||
)
|
||||
(((traffic-type citizen-norm-2))
|
||||
(set! v0-0 (citizen-spawn arg0 citizen-norm arg1))
|
||||
)
|
||||
(((traffic-type metalhead-predator))
|
||||
(set! v0-0 (citizen-spawn arg0 metalhead-predator arg1))
|
||||
)
|
||||
(((traffic-type metalhead-grunt))
|
||||
(set! v0-0 (citizen-spawn arg0 metalhead-grunt arg1))
|
||||
)
|
||||
(((traffic-type metalhead-flitter))
|
||||
(set! v0-0 (citizen-spawn arg0 metalhead-flitter arg1))
|
||||
)
|
||||
(((traffic-type crimson-guard-1))
|
||||
(set! v0-0 (citizen-spawn arg0 crimson-guard arg1))
|
||||
)
|
||||
(((traffic-type crimson-guard-0))
|
||||
(set! v0-0 (citizen-spawn arg0 crimson-guard arg1))
|
||||
)
|
||||
)
|
||||
v0-0
|
||||
)
|
||||
@@ -385,7 +387,7 @@
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod traffic-manager-method-20 traffic-manager ((obj traffic-manager))
|
||||
(set! (-> obj traffic-engine) *traffic-engine*)
|
||||
(traffic-engine-method-10 (-> obj traffic-engine) obj)
|
||||
(reset-and-init-from-manager (-> obj traffic-engine) obj)
|
||||
(restore-city-speeches)
|
||||
0
|
||||
(none)
|
||||
@@ -403,7 +405,7 @@
|
||||
|
||||
;; definition for method 10 of type traffic-manager
|
||||
(defmethod deactivate traffic-manager ((obj traffic-manager))
|
||||
(traffic-engine-method-11 (-> obj traffic-engine))
|
||||
(stop-alarm-sound (-> obj traffic-engine))
|
||||
(set! *traffic-manager* #f)
|
||||
(remove-setting *setting-control* obj 'task-mask)
|
||||
(apply-settings *setting-control*)
|
||||
@@ -444,7 +446,7 @@
|
||||
)
|
||||
)
|
||||
(let ((s5-1 (-> obj spawn-params)))
|
||||
(set! (-> s5-1 object-type) (the-as uint 6))
|
||||
(set! (-> s5-1 object-type) (traffic-type crimson-guard-1))
|
||||
(set! (-> s5-1 behavior) (the-as uint 1))
|
||||
(set! (-> s5-1 id) (the-as uint 0))
|
||||
(set! (-> s5-1 nav-mesh) #f)
|
||||
@@ -484,23 +486,23 @@
|
||||
(('increase-alert-level)
|
||||
(when *target*
|
||||
(let ((a1-4 (-> arg3 param 0)))
|
||||
(increase-alert-level (-> self traffic-engine) a1-4 *target*)
|
||||
(increase-alert-level (-> self traffic-engine) (the-as int a1-4) *target*)
|
||||
)
|
||||
)
|
||||
)
|
||||
(('decrease-alert-level)
|
||||
(let ((a1-5 (-> arg3 param 0)))
|
||||
(decrease-alert-level (-> self traffic-engine) a1-5)
|
||||
(decrease-alert-level (-> self traffic-engine) (the-as int a1-5))
|
||||
)
|
||||
)
|
||||
(('set-alert-level)
|
||||
(let ((a1-6 (-> arg3 param 0)))
|
||||
(set-alert-level (-> self traffic-engine) a1-6)
|
||||
(set-alert-level (-> self traffic-engine) (the-as int a1-6))
|
||||
)
|
||||
)
|
||||
(('set-max-alert-level)
|
||||
(let ((a1-7 (-> arg3 param 0)))
|
||||
(set-max-alert-level (-> self traffic-engine) a1-7)
|
||||
(set-max-alert-level (-> self traffic-engine) (the-as int a1-7))
|
||||
)
|
||||
)
|
||||
(('get-alert-level)
|
||||
@@ -508,7 +510,7 @@
|
||||
)
|
||||
(('set-alert-duration)
|
||||
(let ((a1-8 (-> arg3 param 0)))
|
||||
(set-alert-duration (-> self traffic-engine) a1-8)
|
||||
(set-alert-duration (-> self traffic-engine) (the-as int a1-8))
|
||||
)
|
||||
)
|
||||
(('deactivate-all)
|
||||
@@ -529,7 +531,7 @@
|
||||
)
|
||||
(('add-danger-sphere)
|
||||
(let ((a1-11 (-> arg3 param 0)))
|
||||
(add-danger-sphere (-> self traffic-engine) (the-as traffic-danger-info a1-11))
|
||||
(add-danger (-> self traffic-engine) (the-as traffic-danger-info a1-11))
|
||||
)
|
||||
)
|
||||
(('spawn-object)
|
||||
@@ -583,12 +585,12 @@
|
||||
)
|
||||
(('deactivate-by-type)
|
||||
(let ((a1-20 (-> arg3 param 0)))
|
||||
(deactivate-by-type (-> self traffic-engine) (the-as int a1-20))
|
||||
(deactivate-by-type (-> self traffic-engine) (the-as traffic-type a1-20))
|
||||
)
|
||||
)
|
||||
(('new-suppression-box)
|
||||
(let ((a1-21 (-> arg3 param 0)))
|
||||
(new-suppression-box (-> self traffic-engine) a1-21)
|
||||
(new-suppression-box (-> self traffic-engine) (the-as traffic-suppression-params a1-21))
|
||||
)
|
||||
)
|
||||
(('update-suppression-box)
|
||||
@@ -625,7 +627,7 @@
|
||||
(let ((a1-26 (-> arg3 param 0))
|
||||
(a2-6 (-> arg3 param 1))
|
||||
)
|
||||
(set-object-auto-activate (-> self traffic-engine) a1-26 a2-6)
|
||||
(set-object-auto-activate (-> self traffic-engine) (the-as int a1-26) a2-6)
|
||||
)
|
||||
)
|
||||
(('set-guard-force-visible)
|
||||
@@ -640,7 +642,7 @@
|
||||
)
|
||||
(('end-pursuit-by-type)
|
||||
(let ((a1-28 (-> arg3 param 0)))
|
||||
(end-pursuit-by-type (-> self traffic-engine) (the-as int a1-28))
|
||||
(end-pursuit-by-type (-> self traffic-engine) (the-as traffic-type a1-28))
|
||||
)
|
||||
)
|
||||
(('level-loaded)
|
||||
@@ -658,7 +660,7 @@
|
||||
(let ((a1-32 (-> arg3 param 0))
|
||||
(a2-8 (-> arg3 param 1))
|
||||
)
|
||||
(add-object (-> self traffic-engine) (the-as int a1-32) (the-as process a2-8))
|
||||
(add-object (-> self traffic-engine) (the-as traffic-type a1-32) (the-as process a2-8))
|
||||
)
|
||||
)
|
||||
(('kill-all)
|
||||
|
||||
+3
-3
@@ -83,7 +83,7 @@
|
||||
(defstate idle (vehicle-turret)
|
||||
:virtual #t
|
||||
:trans (behavior ()
|
||||
(turret-control-method-12 (-> self turret) (the-as joint-mod-rotate-local (-> self turret-jm)))
|
||||
(update-joint-mod (-> self turret) (the-as joint-mod-rotate-local (-> self turret-jm)))
|
||||
(vehicle-turret-method-29 self)
|
||||
(when (and (nonzero? (-> self target)) (handle->process (-> self target)))
|
||||
(let* ((s5-0 (handle->process (-> self target)))
|
||||
@@ -164,7 +164,7 @@
|
||||
;; WARN: Return type mismatch object vs none.
|
||||
(defbehavior vehicle-turret-init-by-other vehicle-turret ((arg0 turret-control-info))
|
||||
(vehicle-turret-method-28 self)
|
||||
(turret-control-method-15 (-> self turret) arg0)
|
||||
(set-info (-> self turret) arg0)
|
||||
(logior! (-> self turret flags) (turret-flag targetting-laser no-rot-y-clamp))
|
||||
(vehicle-turret-method-29 self)
|
||||
(vector-identity! (-> self root-override scale))
|
||||
@@ -509,7 +509,7 @@
|
||||
(with-pp
|
||||
(when (>= (- (-> pp clock frame-counter) (-> obj last-guard-spawn-time)) 0)
|
||||
(let ((s5-0 (new 'stack 'traffic-object-spawn-params)))
|
||||
(set! (-> s5-0 object-type) (the-as uint 6))
|
||||
(set! (-> s5-0 object-type) (traffic-type crimson-guard-1))
|
||||
(set! (-> s5-0 behavior) (the-as uint 6))
|
||||
(set! (-> s5-0 id) (the-as uint 0))
|
||||
(set! (-> s5-0 nav-mesh) (-> obj nav-mesh))
|
||||
|
||||
+4
-4
@@ -4,7 +4,7 @@
|
||||
;; definition for method 36 of type vehicle
|
||||
;; INFO: Used lq/sq
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-36 vehicle ((obj vehicle))
|
||||
(defmethod do-engine-sounds vehicle ((obj vehicle))
|
||||
(local-vars (v1-36 float))
|
||||
(with-pp
|
||||
(rlet ((acc :class vf)
|
||||
@@ -225,7 +225,7 @@
|
||||
;; definition for method 84 of type vehicle
|
||||
;; INFO: Used lq/sq
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod vehicle-method-84 vehicle ((obj vehicle) (arg0 vector) (arg1 vector) (arg2 float) (arg3 float))
|
||||
(defmethod draw-thruster vehicle ((obj vehicle) (arg0 vector) (arg1 vector) (arg2 float) (arg3 float))
|
||||
(rlet ((acc :class vf)
|
||||
(vf0 :class vf)
|
||||
(vf4 :class vf)
|
||||
@@ -317,7 +317,7 @@
|
||||
;; definition for method 85 of type vehicle
|
||||
;; INFO: Used lq/sq
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod vehicle-method-85 vehicle ((obj vehicle))
|
||||
(defmethod draw-thrusters vehicle ((obj vehicle))
|
||||
(local-vars (sv-272 sparticle-launcher) (sv-276 sparticle-launcher))
|
||||
(with-pp
|
||||
(when (= (-> obj controller traffic sync-mask-32) (ash 1 (logand (-> obj traffic-priority-id) 31)))
|
||||
@@ -440,7 +440,7 @@
|
||||
)
|
||||
(dotimes (s4-2 2)
|
||||
(vector-matrix*! (the-as vector (-> s5-0 0)) (-> obj info-override thruster-local-pos s4-2) (-> s5-0 1))
|
||||
(vehicle-method-84 obj (the-as vector (-> s5-0 0)) (-> s5-0 0 vector 1) f28-3 f30-2)
|
||||
(draw-thruster obj (the-as vector (-> s5-0 0)) (-> s5-0 0 vector 1) f28-3 f30-2)
|
||||
)
|
||||
)
|
||||
(when (logtest? (rigid-body-object-flag ignition) (-> obj flags))
|
||||
|
||||
+7
-7
@@ -99,10 +99,10 @@
|
||||
(turret-control-method-9 (_type_ vehicle vector vector) none 9)
|
||||
(turret-control-method-10 (_type_ vehicle) none 10)
|
||||
(turret-control-method-11 (_type_ object object vector) none 11)
|
||||
(turret-control-method-12 (_type_ joint-mod-rotate-local) none 12)
|
||||
(update-joint-mod (_type_ joint-mod-rotate-local) none 12)
|
||||
(turret-control-method-13 (_type_) none 13)
|
||||
(turret-control-method-14 (_type_) none 14)
|
||||
(turret-control-method-15 (_type_ turret-control-info) none 15)
|
||||
(set-info (_type_ turret-control-info) none 15)
|
||||
(turret-control-method-16 (_type_ float float) none 16)
|
||||
(turret-control-method-17 (_type_ vehicle) none 17)
|
||||
)
|
||||
@@ -161,7 +161,7 @@
|
||||
|
||||
;; definition for method 15 of type turret-control
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod turret-control-method-15 turret-control ((obj turret-control) (arg0 turret-control-info))
|
||||
(defmethod set-info turret-control ((obj turret-control) (arg0 turret-control-info))
|
||||
(set! (-> obj info) arg0)
|
||||
(set! (-> obj owner-handle) (the-as handle #f))
|
||||
0
|
||||
@@ -170,7 +170,7 @@
|
||||
|
||||
;; definition for method 12 of type turret-control
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod turret-control-method-12 turret-control ((obj turret-control) (arg0 joint-mod-rotate-local))
|
||||
(defmethod update-joint-mod turret-control ((obj turret-control) (arg0 joint-mod-rotate-local))
|
||||
(let ((v1-0 (new 'stack-no-clear 'vector)))
|
||||
(set! (-> v1-0 x) (- (-> obj aim-rot-x)))
|
||||
(set! (-> v1-0 y) (-> obj aim-rot-y))
|
||||
@@ -967,7 +967,7 @@
|
||||
(set! (-> a1-2 flags) (traffic-danger-flags tdf0))
|
||||
(set! (-> a1-2 danger-type) (traffic-danger-type tdt6))
|
||||
(set! (-> a1-2 handle) (the-as uint #f))
|
||||
(add-danger-sphere (-> obj controller traffic) a1-2)
|
||||
(add-danger (-> obj controller traffic) a1-2)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1139,8 +1139,8 @@
|
||||
|
||||
;; definition for method 31 of type vehicle-guard
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-31 vehicle-guard ((obj vehicle-guard) (arg0 rigid-body-vehicle-constants))
|
||||
(let ((t9-0 (method-of-type vehicle rigid-body-object-method-31)))
|
||||
(defmethod alloc-and-init-rigid-body-control vehicle-guard ((obj vehicle-guard) (arg0 rigid-body-vehicle-constants))
|
||||
(let ((t9-0 (method-of-type vehicle alloc-and-init-rigid-body-control)))
|
||||
(t9-0 obj arg0)
|
||||
)
|
||||
(set! (-> obj mask) (logior (process-mask enemy guard) (-> obj mask)))
|
||||
|
||||
+11
-11
@@ -636,7 +636,7 @@
|
||||
:size-assert #x370
|
||||
:flag-assert #x9002f00370
|
||||
(:methods
|
||||
(rigid-body-object-method-31 (_type_ rigid-body-vehicle-constants) none :replace 31)
|
||||
(alloc-and-init-rigid-body-control (_type_ rigid-body-vehicle-constants) none :replace 31)
|
||||
(inactive () _type_ :state 53)
|
||||
(waiting () _type_ :state 54)
|
||||
(vehicle-method-55 () _type_ :state 55)
|
||||
@@ -649,16 +649,16 @@
|
||||
(vehicle-method-62 (_type_ float) none 62)
|
||||
(vehicle-method-63 (_type_ float) none 63)
|
||||
(vehicle-method-64 () none 64)
|
||||
(vehicle-method-65 (_type_) none 65)
|
||||
(start-jump (_type_) none 65)
|
||||
(vehicle-method-66 () none 66)
|
||||
(vehicle-method-67 (_type_) none 67)
|
||||
(vehicle-method-68 (_type_ vector int) none 68)
|
||||
(vehicle-method-69 (_type_ int) process 69)
|
||||
(get-seat-count (_type_) int 67)
|
||||
(compute-seat-position (_type_ vector int) none 68)
|
||||
(get-rider-in-seat (_type_ int) process 69)
|
||||
(vehicle-method-70 (_type_) process 70)
|
||||
(vehicle-method-71 (_type_ int process-focusable) none 71)
|
||||
(put-rider-in-seat (_type_ int process-focusable) none 71)
|
||||
(vehicle-method-72 (_type_) uint 72)
|
||||
(vehicle-method-73 (_type_ vector int int) int 73)
|
||||
(vehicle-method-74 (_type_ process) none 74)
|
||||
(get-best-seat-for-vehicle (_type_ vector int int) int 73)
|
||||
(remove-rider (_type_ process) none 74)
|
||||
(vehicle-method-75 (_type_) float 75)
|
||||
(vehicle-method-76 (_type_ int uint) none 76)
|
||||
(vehicle-method-77 (_type_) none 77)
|
||||
@@ -668,9 +668,9 @@
|
||||
(vehicle-method-81 (_type_) none 81)
|
||||
(vehicle-method-82 (_type_) none 82)
|
||||
(vehicle-method-83 (_type_) none 83)
|
||||
(vehicle-method-84 (_type_ vector vector float float) none 84)
|
||||
(vehicle-method-85 (_type_) none 85)
|
||||
(vehicle-method-86 () none 86)
|
||||
(draw-thruster (_type_ vector vector float float) none 84)
|
||||
(draw-thrusters (_type_) none 85)
|
||||
(update-joint-mods (_type_) none 86)
|
||||
(vehicle-method-87 (_type_) none 87)
|
||||
(vehicle-method-88 (_type_) none 88)
|
||||
(vehicle-method-89 (_type_) none 89)
|
||||
|
||||
+1
-1
@@ -743,7 +743,7 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((s1-4 (new 'stack-no-clear 'inline-array 'vehicle-control-point 2)))
|
||||
(let ((s1-4 (new 'stack-no-clear 'inline-array 'vehicle-control-point 24)))
|
||||
(quad-copy!
|
||||
(the-as pointer s1-4)
|
||||
(the-as pointer (-> s4-0 stabilizer-array))
|
||||
|
||||
+4
-4
@@ -68,7 +68,7 @@
|
||||
(if (and s5-0 (nonzero? (vehicle-method-72 s5-0)))
|
||||
(logior! (-> obj flags) 4)
|
||||
)
|
||||
(vehicle-method-71 s5-0 (-> obj seat-index) obj)
|
||||
(put-rider-in-seat s5-0 (-> obj seat-index) obj)
|
||||
)
|
||||
(set! (-> obj anim-speed) (rand-vu-float-range 0.8 1.2))
|
||||
0
|
||||
@@ -80,7 +80,7 @@
|
||||
(defmethod vehicle-rider-method-35 vehicle-rider ((obj vehicle-rider))
|
||||
(logior! (-> obj draw status) (draw-control-status no-draw))
|
||||
(let ((v1-3 (-> obj parent-override)))
|
||||
(vehicle-method-71
|
||||
(put-rider-in-seat
|
||||
(the-as vehicle (if v1-3
|
||||
(-> v1-3 0 self-override)
|
||||
)
|
||||
@@ -172,7 +172,7 @@
|
||||
(('knocked-off)
|
||||
(let ((gp-0 (new 'stack 'traffic-object-spawn-params)))
|
||||
(let ((v1-14 (find-nearest-nav-mesh (-> self root-override trans) (the-as float #x7f800000))))
|
||||
(set! (-> gp-0 object-type) (the-as uint 0))
|
||||
(set! (-> gp-0 object-type) (traffic-type citizen-norm-1))
|
||||
(set! (-> gp-0 behavior) (the-as uint 11))
|
||||
(set! (-> gp-0 id) (the-as uint 0))
|
||||
(set! (-> gp-0 nav-mesh) v1-14)
|
||||
@@ -186,7 +186,7 @@
|
||||
(vector-reset! (-> gp-0 velocity))
|
||||
(when (logtest? (-> self flags) 8)
|
||||
(send-event *traffic-manager* 'increase-alert-level 2)
|
||||
(set! (-> gp-0 object-type) (the-as uint 6))
|
||||
(set! (-> gp-0 object-type) (traffic-type crimson-guard-1))
|
||||
)
|
||||
(set! (-> gp-0 position quad) (-> self root-override trans quad))
|
||||
(quaternion-copy! (-> gp-0 rotation) (-> self root-override quat))
|
||||
|
||||
+1
-1
@@ -429,7 +429,7 @@
|
||||
)
|
||||
(send-event-function (handle->process (-> self rider-array gp-1)) a1-2)
|
||||
)
|
||||
(vehicle-method-71 self gp-1 (the-as process-focusable #f))
|
||||
(put-rider-in-seat self gp-1 (the-as process-focusable #f))
|
||||
)
|
||||
(logior! (-> self focus-status) (focus-status dead))
|
||||
(set! (-> self crash-level) 3)
|
||||
|
||||
+20
-22
@@ -297,9 +297,9 @@ This commonly includes things such as:
|
||||
(s4-1 #f)
|
||||
(s3-0 #f)
|
||||
)
|
||||
(let ((a2-2 (vehicle-method-73 obj (-> s5-0 matrices 0 vector 1) 1 0)))
|
||||
(let ((a2-2 (get-best-seat-for-vehicle obj (-> s5-0 matrices 0 vector 1) 1 0)))
|
||||
(when (!= a2-2 -1)
|
||||
(vehicle-method-68 obj (-> s5-0 matrices 0 vector 2) a2-2)
|
||||
(compute-seat-position obj (-> s5-0 matrices 0 vector 2) a2-2)
|
||||
(vector+float*!
|
||||
(-> s5-0 matrices 0 vector 2)
|
||||
(-> s5-0 matrices 0 vector 2)
|
||||
@@ -503,7 +503,7 @@ This commonly includes things such as:
|
||||
|
||||
;; definition for method 65 of type vehicle
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod vehicle-method-65 vehicle ((obj vehicle))
|
||||
(defmethod start-jump vehicle ((obj vehicle))
|
||||
(when (logtest? (-> obj info-override flags) 16)
|
||||
(when (not (logtest? (rigid-body-object-flag jump-sound) (-> obj flags)))
|
||||
(set! (-> obj flags) (logior (rigid-body-object-flag jump-sound) (-> obj flags)))
|
||||
@@ -523,16 +523,14 @@ This commonly includes things such as:
|
||||
)
|
||||
|
||||
;; definition for method 67 of type vehicle
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod vehicle-method-67 vehicle ((obj vehicle))
|
||||
(defmethod get-seat-count vehicle ((obj vehicle))
|
||||
(-> obj info-override seat-count)
|
||||
(none)
|
||||
)
|
||||
|
||||
;; definition for method 68 of type vehicle
|
||||
;; INFO: Used lq/sq
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod vehicle-method-68 vehicle ((obj vehicle) (arg0 vector) (arg1 int))
|
||||
(defmethod compute-seat-position vehicle ((obj vehicle) (arg0 vector) (arg1 int))
|
||||
(let ((v1-0 (new 'stack-no-clear 'vector)))
|
||||
(set! (-> v1-0 quad) (-> obj info-override seat-array arg1 position quad))
|
||||
(set! (-> v1-0 w) 1.0)
|
||||
@@ -543,7 +541,7 @@ This commonly includes things such as:
|
||||
)
|
||||
|
||||
;; definition for method 69 of type vehicle
|
||||
(defmethod vehicle-method-69 vehicle ((obj vehicle) (arg0 int))
|
||||
(defmethod get-rider-in-seat vehicle ((obj vehicle) (arg0 int))
|
||||
(let ((v0-0 (the-as process #f)))
|
||||
(if (< arg0 (-> obj info-override seat-count))
|
||||
(set! v0-0 (handle->process (-> obj rider-array arg0)))
|
||||
@@ -557,7 +555,7 @@ This commonly includes things such as:
|
||||
(let ((gp-0 (the-as process #f)))
|
||||
(countdown (s4-0 (-> obj info-override seat-count))
|
||||
(when (logtest? (-> obj info-override seat-array s4-0 flags) 1)
|
||||
(let ((v1-7 (vehicle-method-69 obj s4-0)))
|
||||
(let ((v1-7 (get-rider-in-seat obj s4-0)))
|
||||
(if v1-7
|
||||
(set! gp-0 v1-7)
|
||||
)
|
||||
@@ -569,7 +567,7 @@ This commonly includes things such as:
|
||||
)
|
||||
|
||||
;; definition for method 73 of type vehicle
|
||||
(defmethod vehicle-method-73 vehicle ((obj vehicle) (arg0 vector) (arg1 int) (arg2 int))
|
||||
(defmethod get-best-seat-for-vehicle vehicle ((obj vehicle) (arg0 vector) (arg1 int) (arg2 int))
|
||||
(let ((gp-0 -1))
|
||||
(let ((f30-0 (the-as float #x7f800000))
|
||||
(s1-0 (new 'stack-no-clear 'vector))
|
||||
@@ -582,16 +580,16 @@ This commonly includes things such as:
|
||||
#t
|
||||
)
|
||||
((= v1-7 1)
|
||||
(not (vehicle-method-69 obj s0-0))
|
||||
(not (get-rider-in-seat obj s0-0))
|
||||
)
|
||||
((= v1-7 2)
|
||||
(vehicle-method-69 obj s0-0)
|
||||
(get-rider-in-seat obj s0-0)
|
||||
)
|
||||
(else
|
||||
#f
|
||||
)
|
||||
)
|
||||
(vehicle-method-68 obj s1-0 s0-0)
|
||||
(compute-seat-position obj s1-0 s0-0)
|
||||
(let ((f0-0 (vector-vector-distance-squared arg0 s1-0)))
|
||||
(when (< f0-0 f30-0)
|
||||
(set! f30-0 f0-0)
|
||||
@@ -609,7 +607,7 @@ This commonly includes things such as:
|
||||
|
||||
;; definition for method 74 of type vehicle
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod vehicle-method-74 vehicle ((obj vehicle) (arg0 process))
|
||||
(defmethod remove-rider vehicle ((obj vehicle) (arg0 process))
|
||||
(let ((v1-1 (-> obj info-override seat-count)))
|
||||
(dotimes (a2-0 v1-1)
|
||||
(if (= arg0 (handle->process (-> obj rider-array a2-0)))
|
||||
@@ -623,7 +621,7 @@ This commonly includes things such as:
|
||||
|
||||
;; definition for method 71 of type vehicle
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod vehicle-method-71 vehicle ((obj vehicle) (arg0 int) (arg1 process-focusable))
|
||||
(defmethod put-rider-in-seat vehicle ((obj vehicle) (arg0 int) (arg1 process-focusable))
|
||||
(if (< arg0 (-> obj info-override seat-count))
|
||||
(set! (-> obj rider-array arg0) (process->handle arg1))
|
||||
)
|
||||
@@ -786,7 +784,7 @@ This commonly includes things such as:
|
||||
(set! (-> obj power-level) 1.0)
|
||||
(set! (-> obj flight-level-index) 0)
|
||||
(let ((a1-0 (-> obj root-override-2 trans)))
|
||||
(set! (-> obj flight-level) (xz-height-map-method-9 *traffic-height-map* a1-0))
|
||||
(set! (-> obj flight-level) (get-height-at-point *traffic-height-map* a1-0))
|
||||
)
|
||||
(set! (-> obj lights-factor) 0.0)
|
||||
(let ((a0-8 (-> obj info-override color-option-select)))
|
||||
@@ -1220,7 +1218,7 @@ This commonly includes things such as:
|
||||
(let ((a0-1 (-> obj controller traffic)))
|
||||
(when (and (nonzero? a0-1) arg1)
|
||||
(if #t
|
||||
(increase-alert-level a0-1 arg0 arg1)
|
||||
(increase-alert-level a0-1 (the-as int arg0) arg1)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1231,7 +1229,7 @@ This commonly includes things such as:
|
||||
;; definition for method 112 of type vehicle
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod vehicle-method-112 vehicle ((obj vehicle) (arg0 object))
|
||||
(decrease-alert-level (-> obj controller traffic) arg0)
|
||||
(decrease-alert-level (-> obj controller traffic) (the-as int arg0))
|
||||
0
|
||||
(none)
|
||||
)
|
||||
@@ -1416,7 +1414,7 @@ This commonly includes things such as:
|
||||
)
|
||||
)
|
||||
(dotimes (s5-1 (-> obj info-override seat-count))
|
||||
(vehicle-method-71 obj s5-1 (the-as process-focusable #f))
|
||||
(put-rider-in-seat obj s5-1 (the-as process-focusable #f))
|
||||
)
|
||||
(vehicle-method-142 obj)
|
||||
(vehicle-controller-method-11 (-> obj controller))
|
||||
@@ -1553,7 +1551,7 @@ This commonly includes things such as:
|
||||
|
||||
;; definition for method 86 of type vehicle
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod vehicle-method-86 vehicle ()
|
||||
(defmethod update-joint-mods vehicle ((obj vehicle))
|
||||
0
|
||||
(none)
|
||||
)
|
||||
@@ -1570,7 +1568,7 @@ This commonly includes things such as:
|
||||
(set! (-> s5-0 local-pos w) 40960.0)
|
||||
(let ((s4-0 0))
|
||||
(label cfg-1)
|
||||
(let ((v1-7 (traffic-engine-method-20 (-> obj controller traffic) (-> s5-0 local-pos) (-> s5-0 normal) 0)))
|
||||
(let ((v1-7 (find-best-segment (-> obj controller traffic) (-> s5-0 local-pos) (-> s5-0 normal) 0)))
|
||||
(when (and (not v1-7) (< s4-0 3))
|
||||
(set! (-> s5-0 local-pos w) (+ 40960.0 (-> s5-0 local-pos w)))
|
||||
(+! s4-0 1)
|
||||
@@ -1594,7 +1592,7 @@ This commonly includes things such as:
|
||||
(dotimes (s5-0 (-> obj info-override seat-count))
|
||||
(let ((s4-0 (handle->process (-> obj rider-array s5-0))))
|
||||
(when (and s4-0 (logtest? (-> (the-as vehicle-rider s4-0) focus-status) (focus-status pilot-riding)))
|
||||
(vehicle-method-68 obj (-> (the-as vehicle-rider s4-0) root-override trans) s5-0)
|
||||
(compute-seat-position obj (-> (the-as vehicle-rider s4-0) root-override trans) s5-0)
|
||||
(set! (-> (the-as vehicle-rider s4-0) root-override transv quad) (-> obj root-override-2 transv quad))
|
||||
(let ((f0-1 (the float (-> obj info-override seat-array s5-0 angle))))
|
||||
(quaternion-rotate-local-y!
|
||||
|
||||
+16
-16
@@ -208,7 +208,7 @@
|
||||
(with-pp
|
||||
(when (= (-> obj controller traffic sync-mask-8) (ash 1 (logand (-> obj traffic-priority-id) 7)))
|
||||
(let ((a1-0 (-> obj root-override-2 trans)))
|
||||
(set! (-> obj flight-level) (xz-height-map-method-9 *traffic-height-map* a1-0))
|
||||
(set! (-> obj flight-level) (get-height-at-point *traffic-height-map* a1-0))
|
||||
)
|
||||
)
|
||||
(set! (-> obj target-acceleration y)
|
||||
@@ -417,7 +417,7 @@
|
||||
(vehicle-method-95 obj (the-as vector (&-> s5-0 x)))
|
||||
)
|
||||
(if (or (cpad-hold? 0 l1) (and (logtest? (-> obj info-override flags) 512) (cpad-hold? 0 r1)))
|
||||
(vehicle-method-65 obj)
|
||||
(start-jump obj)
|
||||
)
|
||||
(if (cpad-pressed? 0 circle)
|
||||
((method-of-object obj vehicle-method-66))
|
||||
@@ -620,10 +620,10 @@
|
||||
(dotimes (v1-4 (-> *level* length))
|
||||
(let ((a0-5 (-> *level* level v1-4)))
|
||||
(when (= (-> a0-5 status) 'active)
|
||||
(let ((a0-7 (-> a0-5 bsp bsp-header-jkh1b23)))
|
||||
(let ((a0-7 (-> a0-5 bsp city-level-info)))
|
||||
(when (nonzero? a0-7)
|
||||
(let ((f1-0 (-> a0-7 frames-per-second)))
|
||||
(if (= f1-0 0.0)
|
||||
(let ((f1-0 (the-as float (-> a0-7 camera-ceiling))))
|
||||
(if (= (the-as meters f1-0) 0.0)
|
||||
(set! f1-0 40960000.0)
|
||||
)
|
||||
(set! f0-0 (fmax f0-0 f1-0))
|
||||
@@ -943,18 +943,18 @@
|
||||
(f1-0 245760.0)
|
||||
)
|
||||
(if (< f0-1 (* f1-0 f1-0))
|
||||
(rigid-body-object-method-36 obj)
|
||||
(do-engine-sounds obj)
|
||||
)
|
||||
)
|
||||
(when (logtest? (-> obj draw status) (draw-control-status on-screen))
|
||||
(if #t
|
||||
(vehicle-method-85 obj)
|
||||
(draw-thrusters obj)
|
||||
)
|
||||
(let ((f0-2 (-> obj camera-dist2))
|
||||
(f1-3 245760.0)
|
||||
)
|
||||
(if (< f0-2 (* f1-3 f1-3))
|
||||
((method-of-object obj vehicle-method-86))
|
||||
(update-joint-mods obj)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1031,7 +1031,7 @@
|
||||
)
|
||||
(vehicle-method-96 obj)
|
||||
(let ((a1-0 (-> obj rbody state position)))
|
||||
(set! (-> obj flight-level) (xz-height-map-method-9 *traffic-height-map* a1-0))
|
||||
(set! (-> obj flight-level) (get-height-at-point *traffic-height-map* a1-0))
|
||||
)
|
||||
0
|
||||
(none)
|
||||
@@ -1321,13 +1321,13 @@
|
||||
(let ((f0-10 (vector-length (-> obj root-override-2 transv))))
|
||||
(seek! (-> obj engine-power-factor) (* 0.000016276043 f0-10) (* 6.0 (-> pp clock seconds-per-frame)))
|
||||
)
|
||||
(rigid-body-object-method-36 obj)
|
||||
(do-engine-sounds obj)
|
||||
)
|
||||
)
|
||||
(when (logtest? (-> obj draw status) (draw-control-status on-screen))
|
||||
(when #t
|
||||
(set! (-> obj node-list data 0 bone transform trans quad) (-> obj root-override-2 trans quad))
|
||||
(vehicle-method-85 obj)
|
||||
(draw-thrusters obj)
|
||||
)
|
||||
)
|
||||
(let ((v1-70 (-> *perf-stats* data 19)))
|
||||
@@ -1407,7 +1407,7 @@
|
||||
|
||||
;; definition for method 31 of type vehicle
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-31 vehicle ((obj vehicle) (arg0 rigid-body-vehicle-constants))
|
||||
(defmethod alloc-and-init-rigid-body-control vehicle ((obj vehicle) (arg0 rigid-body-vehicle-constants))
|
||||
(if (logtest? (-> arg0 flags) 8)
|
||||
(iterate-prims
|
||||
(-> obj root-override-2)
|
||||
@@ -1493,7 +1493,7 @@
|
||||
(new 'static 'pat-surface :noentity #x1 :nopilot #x1 :probe #x1)
|
||||
)
|
||||
(set! (-> obj root-override-2 event-self) 'touched)
|
||||
(let ((t9-3 (method-of-type rigid-body-object rigid-body-object-method-31)))
|
||||
(let ((t9-3 (method-of-type rigid-body-object alloc-and-init-rigid-body-control)))
|
||||
(t9-3 obj arg0)
|
||||
)
|
||||
(logior! (-> obj rbody state flags) (rigid-body-flag enable-collision))
|
||||
@@ -1913,7 +1913,7 @@
|
||||
(when s5-3
|
||||
(format #t "vehicle::event-handler: pilot-on (pid ~d) from pid ~d~%" (-> obj pid) (-> arg0 pid))
|
||||
(logior! (-> obj flags) (rigid-body-object-flag riding))
|
||||
(vehicle-method-71 obj (the-as int s3-2) (the-as process-focusable s5-3))
|
||||
(put-rider-in-seat obj (the-as int s3-2) (the-as process-focusable s5-3))
|
||||
(if (logtest? (-> s5-3 mask) (process-mask target))
|
||||
(logior! (-> obj flags) (rigid-body-object-flag player-driving))
|
||||
)
|
||||
@@ -1954,13 +1954,13 @@
|
||||
(defbehavior vehicle-init-by-other vehicle ((arg0 traffic-object-spawn-params))
|
||||
(stack-size-set! (-> self main-thread) 16)
|
||||
(set! (-> self mask) (logior (process-mask vehicle) (-> self mask)))
|
||||
(rigid-body-object-method-32 self)
|
||||
(allocate-and-init-cshape self)
|
||||
(set! (-> self root-override-2 trans quad) (-> arg0 position quad))
|
||||
(quaternion-copy! (-> self root-override-2 quat) (-> arg0 rotation))
|
||||
(if (not (logtest? (-> arg0 flags) 1))
|
||||
(lwide-entity-hack)
|
||||
)
|
||||
(rigid-body-object-method-33 self)
|
||||
(init-skel-and-rigid-body self)
|
||||
(set! (-> self traffic-priority-id) (the-as int (-> arg0 id)))
|
||||
(vehicle-method-136 self arg0)
|
||||
(none)
|
||||
|
||||
Generated
Vendored
+1
-1
@@ -241,7 +241,7 @@
|
||||
)
|
||||
(set! (-> traffic-obj-params position quad) (-> self begin-pos quad))
|
||||
(quaternion-axis-angle! (-> traffic-obj-params rotation) 0.0 1.0 0.0 16384.0)
|
||||
(set! (-> traffic-obj-params object-type) (the-as uint 13))
|
||||
(set! (-> traffic-obj-params object-type) (traffic-type bikec))
|
||||
(set! (-> traffic-obj-params behavior) (the-as uint 0))
|
||||
(set! (-> traffic-obj-params id) (the-as uint 0))
|
||||
(set! (-> traffic-obj-params proc) #f)
|
||||
|
||||
+4
-7
@@ -136,6 +136,7 @@ This commonly includes things such as:
|
||||
)
|
||||
|
||||
;; definition for function krew-package-spawn
|
||||
;; WARN: Return type mismatch (pointer process) vs (pointer krew-package).
|
||||
(defun krew-package-spawn ((arg0 process) (arg1 process))
|
||||
(process-spawn krew-package arg1 :to arg0)
|
||||
)
|
||||
@@ -163,7 +164,7 @@ This commonly includes things such as:
|
||||
(let ((s5-0 (new 'stack 'traffic-object-spawn-params)))
|
||||
(set! (-> s5-0 position quad) (-> (new 'static 'vector :x 4698112.0 :y 45875.2 :z 81920.0 :w 1.0) quad))
|
||||
(quaternion-axis-angle! (-> s5-0 rotation) 0.0 1.0 0.0 32768.0)
|
||||
(set! (-> s5-0 object-type) (the-as uint 11))
|
||||
(set! (-> s5-0 object-type) (traffic-type bikea))
|
||||
(set! (-> s5-0 behavior) (the-as uint 0))
|
||||
(set! (-> s5-0 id) (the-as uint 0))
|
||||
(set! (-> s5-0 proc) #f)
|
||||
@@ -271,7 +272,7 @@ This commonly includes things such as:
|
||||
)
|
||||
(s5-0 (new 'stack-no-clear 'traffic-object-spawn-params))
|
||||
)
|
||||
(set! (-> s5-0 object-type) (the-as uint 6))
|
||||
(set! (-> s5-0 object-type) (traffic-type crimson-guard-1))
|
||||
(set! (-> s5-0 behavior) (the-as uint 9))
|
||||
(set! (-> s5-0 id) (the-as uint 0))
|
||||
(set! (-> s5-0 nav-mesh) #f)
|
||||
@@ -344,7 +345,7 @@ This commonly includes things such as:
|
||||
)
|
||||
(s5-0 (new 'stack-no-clear 'traffic-object-spawn-params))
|
||||
)
|
||||
(set! (-> s5-0 object-type) (the-as uint 6))
|
||||
(set! (-> s5-0 object-type) (traffic-type crimson-guard-1))
|
||||
(set! (-> s5-0 behavior) (the-as uint 9))
|
||||
(set! (-> s5-0 id) (the-as uint 0))
|
||||
(set! (-> s5-0 nav-mesh) #f)
|
||||
@@ -567,7 +568,3 @@ This commonly includes things such as:
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
+1
-1
@@ -1806,7 +1806,7 @@
|
||||
)
|
||||
(set! (-> s5-0 position quad) (-> self begin-pos quad))
|
||||
(quaternion-axis-angle! (-> s5-0 rotation) 0.0 1.0 0.0 0.0)
|
||||
(set! (-> s5-0 object-type) (the-as uint 13))
|
||||
(set! (-> s5-0 object-type) (traffic-type bikec))
|
||||
(set! (-> s5-0 behavior) (the-as uint 0))
|
||||
(set! (-> s5-0 id) (the-as uint 0))
|
||||
(set! (-> s5-0 proc) #f)
|
||||
|
||||
+4
-5
@@ -1495,7 +1495,7 @@
|
||||
)
|
||||
(set! (-> gp-0 position quad) (-> *bb-ring-info* (-> self info index) start-pos quad))
|
||||
(quaternion-axis-angle! (-> gp-0 rotation) 0.0 1.0 0.0 (-> *bb-ring-info* (-> self info index) rotation))
|
||||
(set! (-> gp-0 object-type) (the-as uint 11))
|
||||
(set! (-> gp-0 object-type) (traffic-type bikea))
|
||||
(set! (-> gp-0 behavior) (the-as uint 0))
|
||||
(set! (-> gp-0 id) (the-as uint 0))
|
||||
(set! (-> gp-0 proc) #f)
|
||||
@@ -1925,16 +1925,19 @@ This commonly includes things such as:
|
||||
)
|
||||
|
||||
;; definition for function bush-collect-spawn
|
||||
;; WARN: Return type mismatch (pointer process) vs (pointer bush-collect).
|
||||
(defun bush-collect-spawn ((arg0 task-manager) (arg1 vector))
|
||||
(process-spawn bush-collect arg1 :to arg0)
|
||||
)
|
||||
|
||||
;; definition for function bush-collect-homing-beacon-spawn
|
||||
;; WARN: Return type mismatch (pointer process) vs (pointer bush-collect).
|
||||
(defun bush-collect-homing-beacon-spawn ((arg0 task-manager) (arg1 vector))
|
||||
(process-spawn bush-collect :init bush-collect-homing-beacon-init-by-other arg1 :to arg0)
|
||||
)
|
||||
|
||||
;; definition for function bush-collect-dark-eco-spawn
|
||||
;; WARN: Return type mismatch (pointer process) vs (pointer bush-collect).
|
||||
(defun bush-collect-dark-eco-spawn ((arg0 task-manager) (arg1 vector))
|
||||
(process-spawn bush-collect :init bush-collect-dark-eco-init-by-other arg1 :to arg0)
|
||||
)
|
||||
@@ -3309,7 +3312,3 @@ This commonly includes things such as:
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
+1
-1
@@ -914,7 +914,7 @@
|
||||
(set! (-> a1-0 decay-rate) 0.0)
|
||||
(set! (-> a1-0 flags) (traffic-danger-flags tdf0))
|
||||
(set! (-> a1-0 danger-type) (traffic-danger-type tdt0))
|
||||
(add-danger-sphere *traffic-engine* a1-0)
|
||||
(add-danger *traffic-engine* a1-0)
|
||||
)
|
||||
(none)
|
||||
)
|
||||
|
||||
+3
-3
@@ -56,7 +56,7 @@
|
||||
|
||||
;; definition for method 32 of type dig-sinking-plat
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-32 dig-sinking-plat ((obj dig-sinking-plat))
|
||||
(defmethod allocate-and-init-cshape dig-sinking-plat ((obj dig-sinking-plat))
|
||||
(let ((s5-0 (new 'process 'collide-shape-moving obj (collide-list-enum usually-hit-by-player))))
|
||||
(set! (-> s5-0 dynam) (copy *standard-dynamics* 'process))
|
||||
(set! (-> s5-0 reaction) cshape-reaction-default)
|
||||
@@ -267,13 +267,13 @@
|
||||
;; definition for method 33 of type dig-sinking-plat
|
||||
;; INFO: Used lq/sq
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-33 dig-sinking-plat ((obj dig-sinking-plat))
|
||||
(defmethod init-skel-and-rigid-body dig-sinking-plat ((obj dig-sinking-plat))
|
||||
(initialize-skeleton
|
||||
obj
|
||||
(the-as skeleton-group (art-group-get-by-name *level* "skel-dig-sinking-plat" (the-as (pointer uint32) #f)))
|
||||
(the-as pair 0)
|
||||
)
|
||||
(rigid-body-object-method-31 obj *dig-sinking-platform-constants*)
|
||||
(alloc-and-init-rigid-body-control obj *dig-sinking-platform-constants*)
|
||||
(set! (-> obj anchor-point quad) (-> obj root-override-2 trans quad))
|
||||
(set! (-> obj surface-height) (+ -4096.0 (-> obj root-override-2 trans y)))
|
||||
(let ((s5-1 (-> obj info-override control-point-count)))
|
||||
|
||||
+5
-5
@@ -784,7 +784,7 @@
|
||||
|
||||
;; definition for method 32 of type dig-bomb-crate-cylinder
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-32 dig-bomb-crate-cylinder ((obj dig-bomb-crate-cylinder))
|
||||
(defmethod allocate-and-init-cshape dig-bomb-crate-cylinder ((obj dig-bomb-crate-cylinder))
|
||||
(let ((s5-0 (new 'process 'collide-shape-moving obj (collide-list-enum usually-hit-by-player))))
|
||||
(set! (-> s5-0 dynam) (copy *standard-dynamics* 'process))
|
||||
(set! (-> s5-0 reaction) cshape-reaction-default)
|
||||
@@ -835,7 +835,7 @@
|
||||
|
||||
;; definition for method 33 of type dig-bomb-crate-cylinder
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-33 dig-bomb-crate-cylinder ((obj dig-bomb-crate-cylinder))
|
||||
(defmethod init-skel-and-rigid-body dig-bomb-crate-cylinder ((obj dig-bomb-crate-cylinder))
|
||||
(initialize-skeleton
|
||||
obj
|
||||
(the-as
|
||||
@@ -844,7 +844,7 @@
|
||||
)
|
||||
(the-as pair 0)
|
||||
)
|
||||
(rigid-body-object-method-31 obj *dig-bomb-crate-cylinder-constants*)
|
||||
(alloc-and-init-rigid-body-control obj *dig-bomb-crate-cylinder-constants*)
|
||||
(logclear! (-> obj mask) (process-mask actor-pause))
|
||||
(logior! (-> obj rbody state flags) (rigid-body-flag enable-collision))
|
||||
(set! (-> obj draw light-index) (the-as uint 10))
|
||||
@@ -857,10 +857,10 @@
|
||||
;; WARN: Return type mismatch object vs none.
|
||||
(defbehavior dig-bomb-crate-cylinder-init-by-other dig-bomb-crate-cylinder ((arg0 dig-bomb-crate-cylinder-spawn-params) (arg1 entity-actor))
|
||||
(process-entity-set! self arg1)
|
||||
(rigid-body-object-method-32 self)
|
||||
(allocate-and-init-cshape self)
|
||||
(set! (-> self root-override-2 trans quad) (-> arg0 pos quad))
|
||||
(quaternion-copy! (-> self root-override-2 quat) (-> arg0 quat))
|
||||
(rigid-body-object-method-33 self)
|
||||
(init-skel-and-rigid-body self)
|
||||
(set! (-> self mask) (logior (process-mask platform) (-> self mask)))
|
||||
(vector-float*! (-> self rbody state lin-momentum) (-> arg0 vel) (-> self info info mass))
|
||||
(vector-float*! (-> self rbody state ang-momentum) (-> arg0 avel) (-> self info info mass))
|
||||
|
||||
+8
-8
@@ -1610,7 +1610,7 @@ This commonly includes things such as:
|
||||
|
||||
;; definition for method 32 of type dig-tipping-rock
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-32 dig-tipping-rock ((obj dig-tipping-rock))
|
||||
(defmethod allocate-and-init-cshape dig-tipping-rock ((obj dig-tipping-rock))
|
||||
(let ((s5-0 (new 'process 'collide-shape-moving obj (collide-list-enum hit-by-player))))
|
||||
(set! (-> s5-0 dynam) (copy *standard-dynamics* 'process))
|
||||
(set! (-> s5-0 reaction) cshape-reaction-default)
|
||||
@@ -1646,14 +1646,14 @@ This commonly includes things such as:
|
||||
;; definition for method 33 of type dig-tipping-rock
|
||||
;; INFO: Used lq/sq
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-33 dig-tipping-rock ((obj dig-tipping-rock))
|
||||
(defmethod init-skel-and-rigid-body dig-tipping-rock ((obj dig-tipping-rock))
|
||||
(initialize-skeleton
|
||||
obj
|
||||
(the-as skeleton-group (art-group-get-by-name *level* "skel-dig-tipping-rock" (the-as (pointer uint32) #f)))
|
||||
(the-as pair 0)
|
||||
)
|
||||
(quaternion-rotate-local-x! (-> obj root-override-2 quat) (-> obj root-override-2 quat) -2555.2202)
|
||||
(rigid-body-object-method-31 obj *dig-tipping-rock-constants*)
|
||||
(alloc-and-init-rigid-body-control obj *dig-tipping-rock-constants*)
|
||||
(set! (-> obj anchor-point quad) (-> obj rbody state position quad))
|
||||
(let ((v1-8 (-> obj control-point-array)))
|
||||
(let ((a0-8 (-> v1-8 data)))
|
||||
@@ -1990,7 +1990,7 @@ This commonly includes things such as:
|
||||
|
||||
;; definition for method 32 of type dig-stomp-block
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-32 dig-stomp-block ((obj dig-stomp-block))
|
||||
(defmethod allocate-and-init-cshape dig-stomp-block ((obj dig-stomp-block))
|
||||
(let ((s5-0 (new 'process 'collide-shape-moving obj (collide-list-enum usually-hit-by-player))))
|
||||
(set! (-> s5-0 dynam) (copy *standard-dynamics* 'process))
|
||||
(set! (-> s5-0 reaction) cshape-reaction-default)
|
||||
@@ -2087,13 +2087,13 @@ This commonly includes things such as:
|
||||
|
||||
;; definition for method 33 of type dig-stomp-block
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-33 dig-stomp-block ((obj dig-stomp-block))
|
||||
(defmethod init-skel-and-rigid-body dig-stomp-block ((obj dig-stomp-block))
|
||||
(initialize-skeleton
|
||||
obj
|
||||
(the-as skeleton-group (art-group-get-by-name *level* "skel-dig-stomp-block" (the-as (pointer uint32) #f)))
|
||||
(the-as pair 0)
|
||||
)
|
||||
(rigid-body-object-method-31 obj *dig-stomp-block-constants*)
|
||||
(alloc-and-init-rigid-body-control obj *dig-stomp-block-constants*)
|
||||
(logclear! (-> obj mask) (process-mask actor-pause))
|
||||
(logior! (-> obj rbody state flags) (rigid-body-flag enable-collision))
|
||||
(set! (-> obj draw light-index) (the-as uint 10))
|
||||
@@ -2107,10 +2107,10 @@ This commonly includes things such as:
|
||||
;; WARN: Return type mismatch object vs none.
|
||||
(defbehavior dig-stomp-block-init-by-other dig-stomp-block ((arg0 vector))
|
||||
(set! (-> self mask) (logior (process-mask platform) (-> self mask)))
|
||||
(rigid-body-object-method-32 self)
|
||||
(allocate-and-init-cshape self)
|
||||
(set! (-> self root-override-2 trans quad) (-> arg0 quad))
|
||||
(set-vector! (-> self root-override-2 quat) 0.0 1.0 0.0 0.0)
|
||||
(rigid-body-object-method-33 self)
|
||||
(init-skel-and-rigid-body self)
|
||||
(transform-post)
|
||||
(go-virtual waiting)
|
||||
(none)
|
||||
|
||||
+3
-3
@@ -42,7 +42,7 @@
|
||||
|
||||
;; definition for method 32 of type sinking-plat
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-32 sinking-plat ((obj sinking-plat))
|
||||
(defmethod allocate-and-init-cshape sinking-plat ((obj sinking-plat))
|
||||
(let ((s5-0 (new 'process 'collide-shape-moving obj (collide-list-enum hit-by-player))))
|
||||
(set! (-> s5-0 dynam) (copy *standard-dynamics* 'process))
|
||||
(set! (-> s5-0 reaction) cshape-reaction-default)
|
||||
@@ -107,14 +107,14 @@
|
||||
;; definition for method 33 of type sinking-plat
|
||||
;; INFO: Used lq/sq
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-33 sinking-plat ((obj sinking-plat))
|
||||
(defmethod init-skel-and-rigid-body sinking-plat ((obj sinking-plat))
|
||||
(initialize-skeleton
|
||||
obj
|
||||
(the-as skeleton-group (art-group-get-by-name *level* "skel-sinking-plat" (the-as (pointer uint32) #f)))
|
||||
(the-as pair 0)
|
||||
)
|
||||
(set! (-> obj float-height-offset) 4096.0)
|
||||
(rigid-body-object-method-31 obj *ruins-sinking-platform-constants*)
|
||||
(alloc-and-init-rigid-body-control obj *ruins-sinking-platform-constants*)
|
||||
(set! (-> obj anchor-point quad) (-> obj root-override-2 trans quad))
|
||||
(let ((s5-1 (-> obj info-override control-point-count)))
|
||||
(dotimes (s4-1 s5-1)
|
||||
|
||||
+3
-3
@@ -1013,7 +1013,7 @@ This commonly includes things such as:
|
||||
|
||||
;; definition for method 32 of type under-buoy-plat
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-32 under-buoy-plat ((obj under-buoy-plat))
|
||||
(defmethod allocate-and-init-cshape under-buoy-plat ((obj under-buoy-plat))
|
||||
(let ((s5-0 (new 'process 'collide-shape-moving obj (collide-list-enum usually-hit-by-player))))
|
||||
(set! (-> s5-0 dynam) (copy *standard-dynamics* 'process))
|
||||
(set! (-> s5-0 reaction) cshape-reaction-default)
|
||||
@@ -1104,13 +1104,13 @@ This commonly includes things such as:
|
||||
;; definition for method 33 of type under-buoy-plat
|
||||
;; INFO: Used lq/sq
|
||||
;; WARN: Return type mismatch int vs none.
|
||||
(defmethod rigid-body-object-method-33 under-buoy-plat ((obj under-buoy-plat))
|
||||
(defmethod init-skel-and-rigid-body under-buoy-plat ((obj under-buoy-plat))
|
||||
(initialize-skeleton
|
||||
obj
|
||||
(the-as skeleton-group (art-group-get-by-name *level* "skel-under-buoy-plat" (the-as (pointer uint32) #f)))
|
||||
(the-as pair 0)
|
||||
)
|
||||
(rigid-body-object-method-31 obj *under-buoy-plat-platform-constants*)
|
||||
(alloc-and-init-rigid-body-control obj *under-buoy-plat-platform-constants*)
|
||||
(set! (-> obj orig-trans quad) (-> obj root-override-2 trans quad))
|
||||
(set! (-> obj anchor-point quad) (-> obj root-override-2 trans quad))
|
||||
(set! (-> obj surface-height) (-> obj root-override-2 trans y))
|
||||
|
||||
@@ -296,7 +296,10 @@
|
||||
"(method 193 grunt-mech)", // .mula.s
|
||||
"(method 3 sig-path-sample)",
|
||||
"debug-eyes", // unused debug function
|
||||
"(method 11 pal-grind-ring-center)" // same thing defined twice
|
||||
"(method 11 pal-grind-ring-center)", // same thing defined twice
|
||||
"(method 49 traffic-engine)", // float stuff
|
||||
"(method 14 nav-graph)",
|
||||
"target-pilot-init"
|
||||
],
|
||||
|
||||
"skip_compile_states": {
|
||||
@@ -311,6 +314,7 @@
|
||||
"(fall ruins-pillar-collapse)": ["code"], // missing cast to art-joint-anim
|
||||
"(hit drill-wall)": ["code"], // missing cast to art-joint-anim
|
||||
"(hit drill-crane)": ["code"], // missing cast to art-joint-anim
|
||||
"(hit under-break-door)": ["code"] // missing cast to art-joint-anim
|
||||
"(hit under-break-door)": ["code"], // missing cast to art-joint-anim
|
||||
"(target-pilot-get-on target)": ["trans"] // missint cast
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user