mirror of
https://github.com/open-goal/jak-project
synced 2026-08-22 07:04:29 -04:00
@@ -1276,7 +1276,16 @@ FormElement* rewrite_joint_macro(LetElement* in, const Env& env, FormPool& pool)
|
||||
Form* num_form = nullptr;
|
||||
// check the num! arg
|
||||
if (prelim_num == "identity") {
|
||||
if (set_fn2) {
|
||||
if (env.version == GameVersion::Jak2 && set_fn && !set_fn2) {
|
||||
// jak 2-specific made-up thing!
|
||||
// this has only appeared once so far.
|
||||
if (set_fn->to_form(env).is_float(0.0)) {
|
||||
num_form = pool.form<ConstantTokenElement>("zero");
|
||||
set_fn = nullptr;
|
||||
} else {
|
||||
return nullptr;
|
||||
}
|
||||
} else if (set_fn2) {
|
||||
auto obj_fn2 = set_fn2->to_form(env);
|
||||
if (obj_fn2.is_float(0.0)) {
|
||||
num_form = pool.form<ConstantTokenElement>("min");
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
"disassemble_data": false,
|
||||
|
||||
// unpack textures to assets folder
|
||||
"process_tpages": true,
|
||||
"process_tpages": false,
|
||||
// unpack game text to assets folder
|
||||
"process_game_text": true,
|
||||
// unpack game count to assets folder
|
||||
|
||||
@@ -273,6 +273,7 @@
|
||||
- (chan channel) = copy frame from another channel.
|
||||
- min = the start of the animation.
|
||||
- max = the end of the animation.
|
||||
- zero = frame zero.
|
||||
"
|
||||
|
||||
(let* ((num-args (if (pair? num!) (cdr num!) '()))
|
||||
@@ -281,7 +282,7 @@
|
||||
((or (eq? num! 'identity)
|
||||
(eq? num! 'min)
|
||||
(eq? num! 'max)
|
||||
)
|
||||
(eq? num! 'zero))
|
||||
'num-func-identity)
|
||||
((eq? num! 'none) 'num-func-none)
|
||||
((eq? num! '+!) 'num-func-+!)
|
||||
@@ -313,11 +314,13 @@
|
||||
(cond
|
||||
((eq? num! 'seek!) (if (or (null? num-args) (null? (cdr num-args))) 1.0 (cadr num-args)))
|
||||
)))
|
||||
(frame-num (if (eq? 'max frame-num) (if group!
|
||||
(frame-num (cond
|
||||
((eq? 'max frame-num) (if group!
|
||||
`(the float (1- (-> (the art-joint-anim ,group!) frames num-frames)))
|
||||
`(the float (1- (-> ja-ch frame-group frames num-frames)))
|
||||
)
|
||||
frame-num))
|
||||
))
|
||||
((eq? 'zero frame-num) 0)
|
||||
(#t frame-num)))
|
||||
(frame-group (if (or p0 p1 frame-num (not nf)) group! #f))
|
||||
)
|
||||
`(let ((ja-ch (-> self skel root-channel ,chan)))
|
||||
|
||||
+7
-4
@@ -825,6 +825,7 @@
|
||||
- (chan channel) = copy frame from another channel.
|
||||
- min = the start of the animation.
|
||||
- max = the end of the animation.
|
||||
- zero = frame zero.
|
||||
"
|
||||
|
||||
(let* ((num-args (if (pair? num!) (cdr num!) '()))
|
||||
@@ -833,7 +834,7 @@
|
||||
((or (eq? num! 'identity)
|
||||
(eq? num! 'min)
|
||||
(eq? num! 'max)
|
||||
)
|
||||
(eq? num! 'zero))
|
||||
'num-func-identity)
|
||||
((eq? num! 'none) 'num-func-none)
|
||||
((eq? num! '+!) 'num-func-+!)
|
||||
@@ -865,11 +866,13 @@
|
||||
(cond
|
||||
((eq? num! 'seek!) (if (or (null? num-args) (null? (cdr num-args))) 1.0 (cadr num-args)))
|
||||
)))
|
||||
(frame-num (if (eq? 'max frame-num) (if group!
|
||||
(frame-num (cond
|
||||
((eq? 'max frame-num) (if group!
|
||||
`(the float (1- (-> (the art-joint-anim ,group!) frames num-frames)))
|
||||
`(the float (1- (-> ja-ch frame-group frames num-frames)))
|
||||
)
|
||||
frame-num))
|
||||
))
|
||||
((eq? 'zero frame-num) 0)
|
||||
(#t frame-num)))
|
||||
(frame-group (if (or p0 p1 frame-num (not nf)) group! #f))
|
||||
)
|
||||
`(let ((ja-ch (-> self skel root-channel ,chan)))
|
||||
|
||||
Reference in New Issue
Block a user