Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
water111 committed Feb 16, 2025
1 parent bf3bc36 commit 1f64cba
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 12 deletions.
4 changes: 2 additions & 2 deletions goal_src/jak3/engine/anim/aligner-h.gc
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ The animation format has two special parent-like joints: prejoint and align.
The prejoint is the parent for all joints, so it causes all bones to move.
The align joint has no children, but the convention is that moving align will
cause the entire process-drawable's root to move, effectively moving the entire character.
Most of the time, this is the preferable way to move a character as part of an animation -
it will update their velocity and when the animation ends or is canceled,
Most of the time, this is the preferable way to move a character as part of an animation -
it will update their velocity and when the animation ends or is canceled,
the offset in position from playing the animation will stay. For example, if Jak punches,
his velocity will increase due to the animated align in the punch animation.
To implement this, the align-control computes the relative transform between align frames.
Expand Down
2 changes: 2 additions & 0 deletions goal_src/jak3/engine/target/gun/gun-red-shot.gc
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,7 @@
(when s1-1
(when (and (!= s4-0 s1-1)
(not (focus-test? (the-as process-focusable s1-1) disable dead inactive))
(pc-check-focus-fix (the-as process-focusable s1-1)) ;; og:preserve-this
(logtest? (process-mask crate enemy guard vehicle civilian) (-> s1-1 mask))
(nonzero? (-> (the-as process-focusable s1-1) root root-prim prim-core collide-with))
)
Expand Down Expand Up @@ -269,6 +270,7 @@
(when (and s3-1 (< (vector-vector-distance (get-trans s3-1 0) s5-0) (-> s5-0 w)))
(when (and (!= s4-0 s3-1)
(not (focus-test? s3-1 disable dead inactive))
(pc-check-focus-fix (the-as process-focusable s3-1)) ;; og:preserve-this
(logtest? (process-mask crate enemy guard vehicle civilian) (-> s3-1 mask))
(nonzero? (-> s3-1 control root-prim prim-core collide-with))
)
Expand Down
2 changes: 1 addition & 1 deletion goal_src/jak3/engine/target/target-lightjak.gc
Original file line number Diff line number Diff line change
Expand Up @@ -2283,7 +2283,7 @@
(f30-0 4096.0)
)
(let ((f0-4 (* 0.00013563369 (tan (/ (-> *math-camera* fov) 2)) f30-0)))
(set-vector! (-> this root scale) f0-4 f0-4 f0-4 1.0)
(set-vector! (-> this root scale) (* f0-4 (if (-> *pc-settings* use-vis?) 1.0 (-> *pc-settings* aspect-ratio-scale))) f0-4 f0-4 1.0)
)
(vector-copy! gp-0 (camera-pos))
(vector-normalize-copy! s5-0 (-> s3-0 fvec) 1.0)
Expand Down
9 changes: 2 additions & 7 deletions goal_src/jak3/engine/target/target.gc
Original file line number Diff line number Diff line change
Expand Up @@ -3692,13 +3692,8 @@
:exit target-exit
:trans (behavior ()
(when (and (!= (-> self control unknown-spool-anim00) 'stuck) (!= (-> self state-time) (current-time)))
(if (and (logtest? (logior (logior (-> *cpad-list* cpads (-> self control cpad number) button0-rel 0)
(-> *cpad-list* cpads (-> self control cpad number) button0-rel 1)
)
(-> *cpad-list* cpads (-> self control cpad number) button0-rel 2)
)
(pad-buttons circle)
)
;; og:preserve-this - High FPS Fix
(if (and (recently-pressed? circle)
(can-feet? #f)
)
(go target-attack-air 'flop)
Expand Down
4 changes: 2 additions & 2 deletions goal_src/jak3/levels/title/title-obs.gc
Original file line number Diff line number Diff line change
Expand Up @@ -1276,8 +1276,8 @@
(set! (-> self zoom) (fmax (fmin (-> self zoom) (-> self char zoom-max)) (-> self char zoom-min)))
)
)
(let ((f1-11 (the float (-> v1-7 abutton 9)))
(f0-18 (the float (-> v1-7 abutton 8)))
(let ((f1-11 (the float (-> v1-7 abutton (abutton-idx r1)))) ;; og:preserve-this abutton indexing
(f0-18 (the float (-> v1-7 abutton (abutton-idx l1)))) ;; og:preserve-this abutton indexing
)
(+! (-> self updown) (* 50.0 (seconds-per-frame) f1-11))
(set! (-> self updown) (- (-> self updown) (* 50.0 (seconds-per-frame) f0-18)))
Expand Down

0 comments on commit 1f64cba

Please sign in to comment.