mirror of
https://github.com/open-goal/jak-project
synced 2026-07-27 14:52:44 -04:00
[decompiler] detect seek! and seekl! macros (#1317)
* detect `seek!` and `seekl!` * fancy struct instead of pair mess * fixes * i think this was wrong? * update refs * update source * More logical branching * even better branching
This commit is contained in:
@@ -222,7 +222,7 @@
|
||||
(let* ((f0-5 (sqrtf (+ (* (-> s5-0 x) (-> s5-0 x)) (* (-> s5-0 z) (-> s5-0 z)))))
|
||||
(f0-6 (atan (-> s5-0 y) f0-5))
|
||||
)
|
||||
(set! (-> obj head-tilt) (seek (-> obj head-tilt) f0-6 (* 5461.3335 (-> *display* seconds-per-frame))))
|
||||
(seek! (-> obj head-tilt) f0-6 (* 5461.3335 (-> *display* seconds-per-frame)))
|
||||
)
|
||||
)
|
||||
(set! (-> obj head-tilt) (fmin 8192.0 (fmax -5461.3335 (-> obj head-tilt))))
|
||||
|
||||
@@ -445,9 +445,7 @@
|
||||
(go pelican-fly-to-end (-> self path-to-nest2) (-> *PELICAN-bank* run-away-time))
|
||||
)
|
||||
(pelican-path-update 364088.88 30 0.0 0.0 #t)
|
||||
(set! (-> self path-pos)
|
||||
(seek (-> self path-pos) (-> self path-max) (* (-> self path-speed) (-> *display* seconds-per-frame)))
|
||||
)
|
||||
(seek! (-> self path-pos) (-> self path-max) (* (-> self path-speed) (-> *display* seconds-per-frame)))
|
||||
(if (= (-> self path-pos) (-> self path-max))
|
||||
(go pelican-to-nest (-> self path-cache) (the-as int (-> self time-cache)))
|
||||
)
|
||||
@@ -530,9 +528,7 @@
|
||||
:trans
|
||||
(behavior ()
|
||||
(pelican-path-update 546133.3 30 0.0 0.0 #f)
|
||||
(set! (-> self path-pos)
|
||||
(seek (-> self path-pos) (-> self path-max) (* (-> self path-speed) (-> *display* seconds-per-frame)))
|
||||
)
|
||||
(seek! (-> self path-pos) (-> self path-max) (* (-> self path-speed) (-> *display* seconds-per-frame)))
|
||||
(if (= (-> self path-pos) (-> self path-max))
|
||||
(go pelican-wait-at-nest #f)
|
||||
)
|
||||
@@ -885,7 +881,7 @@
|
||||
(pickup-type fuel-cell)
|
||||
(the float (-> self entity extra perm task))
|
||||
#f
|
||||
(the-as process-drawable *entity-pool*)
|
||||
*entity-pool*
|
||||
(the-as fact-info #f)
|
||||
)
|
||||
)
|
||||
@@ -929,9 +925,7 @@
|
||||
:trans
|
||||
(behavior ()
|
||||
(pelican-path-update 131072.0 150 0.0 0.0 #f)
|
||||
(set! (-> self path-pos)
|
||||
(seek (-> self path-pos) (-> self path-max) (* (-> self path-speed) (-> *display* seconds-per-frame)))
|
||||
)
|
||||
(seek! (-> self path-pos) (-> self path-max) (* (-> self path-speed) (-> *display* seconds-per-frame)))
|
||||
(if (= (-> self path-pos) (-> self path-max))
|
||||
(go pelican-dive (-> self path-dive1) (-> self path-to-nest1) (-> *PELICAN-bank* to-nest1-time))
|
||||
)
|
||||
@@ -973,9 +967,7 @@
|
||||
:trans
|
||||
(behavior ()
|
||||
(pelican-path-update 546133.3 30 0.0 0.0 #f)
|
||||
(set! (-> self path-pos)
|
||||
(seek (-> self path-pos) (-> self path-max) (* (-> self path-speed) (-> *display* seconds-per-frame)))
|
||||
)
|
||||
(seek! (-> self path-pos) (-> self path-max) (* (-> self path-speed) (-> *display* seconds-per-frame)))
|
||||
(if (= (-> self path-pos) (-> self path-max))
|
||||
(go pelican-wait-at-end #f)
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user