mirror of
https://github.com/open-goal/jak-project
synced 2026-08-17 05:31:46 -04:00
jak2 ref
This commit is contained in:
+3
-3
@@ -45,7 +45,7 @@
|
||||
|
||||
;; definition for function time-to-apex
|
||||
(defun time-to-apex ((arg0 float) (arg1 float))
|
||||
(the int (/ arg0 (- (* 0.0033333334 arg1))))
|
||||
(the int (/ arg0 (- (/ arg1 300))))
|
||||
)
|
||||
|
||||
;; definition for function time-to-ground
|
||||
@@ -54,8 +54,8 @@
|
||||
(v0-0 0)
|
||||
)
|
||||
(while (< (- arg2) f0-0)
|
||||
(set! arg0 (- arg0 (* 0.0033333334 arg1)))
|
||||
(+! f0-0 (* 0.0033333334 arg0))
|
||||
(set! arg0 (- arg0 (/ arg1 300)))
|
||||
(+! f0-0 (/ arg0 300))
|
||||
(+! v0-0 1)
|
||||
)
|
||||
v0-0
|
||||
|
||||
+2
-2
@@ -51,7 +51,7 @@
|
||||
)
|
||||
(matrix-identity! (-> this inertial-tensor))
|
||||
(matrix-identity! (-> this inv-inertial-tensor))
|
||||
(let ((f0-4 (* 0.083333336 f24-0)))
|
||||
(let ((f0-4 (/ f24-0 12)))
|
||||
(let* ((f1-1 f30-0)
|
||||
(f1-3 (* f1-1 f1-1))
|
||||
(f2-0 f26-0)
|
||||
@@ -1515,7 +1515,7 @@
|
||||
(f0-9 (/ 163840.0 (get-inv-mass a0-38)))
|
||||
)
|
||||
(vector-reset! (-> this player-force))
|
||||
(set! (-> this player-force y) (* -0.1 f0-9 f30-2))
|
||||
(set! (-> this player-force y) (* (/ f0-9 -10) f30-2))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+2
-2
@@ -4,7 +4,7 @@
|
||||
;; definition for method 9 of type trajectory
|
||||
(defmethod compute-trans-at-time ((this trajectory) (arg0 float) (arg1 vector))
|
||||
(vector+float*! arg1 (-> this initial-position) (-> this initial-velocity) arg0)
|
||||
(+! (-> arg1 y) (* 0.5 arg0 arg0 (-> this gravity)))
|
||||
(+! (-> arg1 y) (* (/ arg0 2) arg0 (-> this gravity)))
|
||||
arg1
|
||||
)
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
(vector-! (-> this initial-velocity) arg1 arg0)
|
||||
(vector-xz-normalize! (-> this initial-velocity) f0-3)
|
||||
)
|
||||
(set! (-> this initial-velocity y) (- (/ (- (-> arg1 y) (-> arg0 y)) arg2) (* 0.5 arg2 (-> this gravity))))
|
||||
(set! (-> this initial-velocity y) (- (/ (- (-> arg1 y) (-> arg0 y)) arg2) (* (/ arg2 2) (-> this gravity))))
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user