mirror of
https://github.com/open-goal/jak-project
synced 2026-09-02 18:12:50 -04:00
[decompiler] rewrite set lets as just sets (#1858)
Rewrites specific kinds of lets where the return value of the `set!` itself is meant to be used to just be `set!`s. Implemented at the let rewrite level. Seems to work for Jak 2 so far. Fixes #1854 .
This commit is contained in:
@@ -73,11 +73,12 @@ struct LetRewriteStats {
|
||||
int attack_info = 0;
|
||||
int vector_dot = 0;
|
||||
int rand_float_gen = 0;
|
||||
int set_let = 0;
|
||||
|
||||
int total() const {
|
||||
return dotimes + countdown + abs + abs2 + unused + ja + case_no_else + case_with_else +
|
||||
set_vector + set_vector2 + send_event + font_context_meth + proc_new + attack_info +
|
||||
vector_dot + rand_float_gen;
|
||||
vector_dot + rand_float_gen + set_let;
|
||||
}
|
||||
|
||||
std::string print() const {
|
||||
@@ -99,6 +100,7 @@ struct LetRewriteStats {
|
||||
out += fmt::format(" attack_info: {}\n", attack_info);
|
||||
out += fmt::format(" vector_dot: {}\n", vector_dot);
|
||||
out += fmt::format(" rand_float_gen: {}\n", rand_float_gen);
|
||||
out += fmt::format(" set_let: {}\n", set_let);
|
||||
return out;
|
||||
}
|
||||
|
||||
@@ -120,6 +122,7 @@ struct LetRewriteStats {
|
||||
result.attack_info = attack_info + other.attack_info;
|
||||
result.vector_dot = vector_dot + other.vector_dot;
|
||||
result.rand_float_gen = rand_float_gen + other.rand_float_gen;
|
||||
result.set_let = rand_float_gen + other.set_let;
|
||||
return result;
|
||||
}
|
||||
|
||||
@@ -140,6 +143,7 @@ struct LetRewriteStats {
|
||||
attack_info += other.attack_info;
|
||||
vector_dot += other.vector_dot;
|
||||
rand_float_gen += other.rand_float_gen;
|
||||
set_let += other.set_let;
|
||||
return *this;
|
||||
}
|
||||
};
|
||||
|
||||
@@ -699,6 +699,56 @@ FormElement* rewrite_empty_let(LetElement* in, const Env&, FormPool&) {
|
||||
return in->entries().at(0).src->try_as_single_element();
|
||||
}
|
||||
|
||||
FormElement* rewrite_set_let(LetElement* in, const Env& env, FormPool& pool) {
|
||||
/*
|
||||
* (let ((dest-var src))
|
||||
* (set! something dest-var)
|
||||
* dest-var
|
||||
* )
|
||||
* to:
|
||||
* (set! something src)
|
||||
*/
|
||||
|
||||
if (in->entries().size() != 1) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
if (in->body()->elts().size() != 2) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
auto var = in->entries().at(0).dest;
|
||||
auto reg = var.reg();
|
||||
if (reg.get_kind() == Reg::GPR && !reg.allowed_local_gpr()) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
auto set_elt = dynamic_cast<SetFormFormElement*>(in->body()->at(0));
|
||||
if (!set_elt) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
auto expr_elt = dynamic_cast<SimpleExpressionElement*>(in->body()->at(1));
|
||||
if (!expr_elt || !expr_elt->expr().is_var()) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
if (env.get_variable_name(var) != env.get_variable_name(expr_elt->expr().var())) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
auto set_src_elt = set_elt->src()->try_as_element<SimpleExpressionElement>();
|
||||
if (!set_src_elt || !set_src_elt->expr().is_var()) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
if (env.get_variable_name(var) != env.get_variable_name(set_src_elt->expr().var())) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return pool.alloc_element<SetFormFormElement>(set_elt->dst(), in->entries().at(0).src);
|
||||
}
|
||||
|
||||
Form* strip_truthy(Form* in) {
|
||||
auto as_ge = in->try_as_element<GenericElement>();
|
||||
if (as_ge) {
|
||||
@@ -1631,6 +1681,9 @@ FormElement* rewrite_attack_info(LetElement* in, const Env& env, FormPool& pool)
|
||||
* Attempt to rewrite a let as another form. If it cannot be rewritten, this will return nullptr.
|
||||
*/
|
||||
FormElement* rewrite_let(LetElement* in, const Env& env, FormPool& pool, LetRewriteStats& stats) {
|
||||
// these are ordered based on frequency. for best performance, you check the most likely rewrites
|
||||
// first!
|
||||
|
||||
auto as_unused = rewrite_empty_let(in, env, pool);
|
||||
if (as_unused) {
|
||||
stats.unused++;
|
||||
@@ -1703,6 +1756,12 @@ FormElement* rewrite_let(LetElement* in, const Env& env, FormPool& pool, LetRewr
|
||||
return as_proc_new;
|
||||
}
|
||||
|
||||
auto as_set_let = rewrite_set_let(in, env, pool);
|
||||
if (as_set_let) {
|
||||
stats.set_let++;
|
||||
return as_set_let;
|
||||
}
|
||||
|
||||
auto as_attack_info = rewrite_attack_info(in, env, pool);
|
||||
if (as_attack_info) {
|
||||
stats.attack_info++;
|
||||
|
||||
@@ -22988,26 +22988,26 @@
|
||||
(define-extern sp-copy-to-spr (function int pointer int none)) ;; TODO - these are all actually uints, but this is needed to get the casts right...
|
||||
(define-extern sp-copy-from-spr (function int pointer int none)) ;; TODO - these are all actually uints, but this is needed to get the casts right...
|
||||
(define-extern memcpy function) ;; TODO - was done manually as well?
|
||||
(define-extern sp-process-block (function sparticle-system int sprite-array-2d int none)) ;;
|
||||
(define-extern sp-process-particle-system (function sparticle-system int sprite-array-2d none)) ;;
|
||||
(define-extern sp-process-block (function sparticle-system int sprite-array-2d int none))
|
||||
(define-extern sp-process-particle-system (function sparticle-system int sprite-array-2d none))
|
||||
(define-extern *particles-flag* symbol) ;;
|
||||
(define-extern forall-particles-with-key-runner (function sparticle-launch-control (function sparticle-system sparticle-cpuinfo none) sparticle-system none)) ;;
|
||||
(define-extern forall-particles-with-key (function sparticle-launch-control (function sparticle-system sparticle-cpuinfo none) symbol symbol none))
|
||||
(define-extern sparticle-kill-it (function sparticle-system sparticle-cpuinfo none)) ;;
|
||||
(define-extern sparticle-kill-it-level0 (function sparticle-system sparticle-cpuinfo none)) ;; (function sparticle-system sparticle-cpuinfo none)
|
||||
(define-extern sparticle-kill-it-level1 (function sparticle-system sparticle-cpuinfo none)) ;; (function sparticle-system sparticle-cpuinfo none)
|
||||
(define-extern sparticle-kill-it (function sparticle-system sparticle-cpuinfo none))
|
||||
(define-extern sparticle-kill-it-level0 (function sparticle-system sparticle-cpuinfo none))
|
||||
(define-extern sparticle-kill-it-level1 (function sparticle-system sparticle-cpuinfo none))
|
||||
(define-extern sparticle-kill-it-level2 (function sparticle-system sparticle-cpuinfo none))
|
||||
(define-extern sparticle-kill-it-level3 (function sparticle-system sparticle-cpuinfo none))
|
||||
(define-extern sparticle-kill-it-level4 (function sparticle-system sparticle-cpuinfo none))
|
||||
(define-extern sparticle-kill-it-level5 (function sparticle-system sparticle-cpuinfo none))
|
||||
(define-extern sparticle-60-to-50 (function sparticle-system sparticle-cpuinfo pointer none)) ;;
|
||||
(define-extern sparticle-50-to-60 (function sparticle-system sparticle-cpuinfo pointer none)) ;; (function sparticle-system sparticle-cpuinfo pointer none)
|
||||
(define-extern kill-all-particles-with-key (function sparticle-launch-control none)) ;;
|
||||
(define-extern forall-particles-runner (function (function sparticle-system sparticle-cpuinfo pointer none) sparticle-system none)) ;;
|
||||
(define-extern forall-particles (function function symbol symbol none)) ;;
|
||||
(define-extern sparticle-60-to-50 (function sparticle-system sparticle-cpuinfo pointer none))
|
||||
(define-extern sparticle-50-to-60 (function sparticle-system sparticle-cpuinfo pointer none))
|
||||
(define-extern kill-all-particles-with-key (function sparticle-launch-control none))
|
||||
(define-extern forall-particles-runner (function (function sparticle-system sparticle-cpuinfo pointer none) sparticle-system none))
|
||||
(define-extern forall-particles (function function symbol symbol none))
|
||||
(define-extern kill-all-particles-in-level (function level int))
|
||||
(define-extern all-particles-50-to-60 (function none)) ;;
|
||||
(define-extern all-particles-60-to-50 (function none)) ;; (function none)
|
||||
(define-extern all-particles-50-to-60 (function none))
|
||||
(define-extern all-particles-60-to-50 (function none))
|
||||
(define-extern remap-particle (function sparticle-system sparticle-cpuinfo pointer none))
|
||||
(define-extern remap-all-particles (function none))
|
||||
(define-extern process-particles (function none))
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
@echo off
|
||||
cd ..\..
|
||||
out\build\Release\bin\offline-test -d --iso_data_path iso_data\jak1\ --game jak1
|
||||
scripts\update_decomp_reference.py failures\ test\decompiler\reference\
|
||||
scripts\update_decomp_reference.py failures\ test\decompiler\reference\jak1\
|
||||
RMDIR /Q/S failures
|
||||
pause
|
||||
@@ -1,6 +1,6 @@
|
||||
@echo off
|
||||
cd ..\..
|
||||
out\build\Release\bin\offline-test -d --iso_data_path iso_data\jak2\ --game jak2
|
||||
scripts\update_decomp_reference.py failures\ test\decompiler\reference\
|
||||
scripts\update_decomp_reference.py failures\ test\decompiler\reference\jak2\
|
||||
RMDIR /Q/S failures
|
||||
pause
|
||||
+3
-12
@@ -13,26 +13,17 @@
|
||||
((-> arg3 param 0)
|
||||
(set! (-> self tracking use-point-of-interest) #t)
|
||||
(set! (-> self tracking point-of-interest quad) (-> (the-as vector (-> arg3 param 0)) quad))
|
||||
(let ((f0-0 1.0))
|
||||
(set! (-> self tracking point-of-interest-blend target) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> self tracking point-of-interest-blend target) 1.0)
|
||||
)
|
||||
(else
|
||||
(set! (-> self tracking use-point-of-interest) #f)
|
||||
(let ((f0-1 0.0))
|
||||
(set! (-> self tracking point-of-interest-blend target) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> self tracking point-of-interest-blend target) 0.0)
|
||||
)
|
||||
)
|
||||
)
|
||||
((= v1-0 'set-interpolation)
|
||||
(set! (-> self interp-val) 0.0)
|
||||
(let ((f0-4 (/ 5.0 (the float (-> arg3 param 0)))))
|
||||
(set! (-> self interp-step) f0-4)
|
||||
f0-4
|
||||
)
|
||||
(set! (-> self interp-step) (/ 5.0 (the float (-> arg3 param 0))))
|
||||
)
|
||||
((= v1-0 'teleport)
|
||||
(when (nonzero? (-> self tracking-status))
|
||||
|
||||
+1
-4
@@ -455,10 +455,7 @@
|
||||
(set! (-> *volume-normal* data *volume-normal-current* quad) (-> s0-0 quad))
|
||||
(set! (-> *volume-normal* data (+ *volume-normal-current* 1) quad) (-> s3-0 s1-0 quad))
|
||||
(set! *volume-normal-current* (+ *volume-normal-current* 2))
|
||||
(let ((v1-132 (+ (-> s2-0 normal-count) 2)))
|
||||
(set! (-> s2-0 normal-count) v1-132)
|
||||
v1-132
|
||||
)
|
||||
(set! (-> s2-0 normal-count) (+ (-> s2-0 normal-count) 2))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+5
-12
@@ -52,10 +52,7 @@
|
||||
(set! (-> self tpos-old-adj quad) (-> self tpos-old quad))
|
||||
(set! (-> self tpos-curr-adj quad) (-> self tpos-old quad))
|
||||
(set! (-> self tpos-tgt quad) (-> self tpos-old quad))
|
||||
(let ((f0-0 0.0))
|
||||
(set! (-> self upspeed) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> self upspeed) 0.0)
|
||||
)
|
||||
|
||||
;; definition for function reset-target-tracking
|
||||
@@ -137,10 +134,7 @@
|
||||
(set! (-> self tpos-curr quad) (-> self tpos-old quad))
|
||||
(set! (-> self tpos-old-adj quad) (-> self tpos-old quad))
|
||||
(set! (-> self tpos-curr-adj quad) (-> self tpos-old quad))
|
||||
(let ((f0-0 0.0))
|
||||
(set! (-> self upspeed) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> self upspeed) 0.0)
|
||||
)
|
||||
|
||||
;; definition for function reset-drawable-tracking
|
||||
@@ -633,10 +627,9 @@
|
||||
(if (logtest? #x10000 (cam-slave-get-flags (-> self cam-entity) 'flags))
|
||||
(send-event *camera* 'set-slave-option #x10000)
|
||||
)
|
||||
(let ((f0-12 (cam-slave-get-float arg0 'tiltAdjust (-> *CAMERA-bank* default-tilt-adjust))))
|
||||
(set! (-> *camera-combiner* tracking tilt-adjust target) f0-12)
|
||||
f0-12
|
||||
)
|
||||
(set! (-> *camera-combiner* tracking tilt-adjust target)
|
||||
(cam-slave-get-float arg0 'tiltAdjust (-> *CAMERA-bank* default-tilt-adjust))
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for function setup-slave-for-hopefull
|
||||
|
||||
+8
-15
@@ -1096,18 +1096,14 @@
|
||||
)
|
||||
(vector+! (-> self circular-follow) (-> self circular-follow) (-> self pivot-pt))
|
||||
(cam-circular-position #t)
|
||||
(when (!= (-> self fov1) 0.0)
|
||||
(let ((f0-7 (lerp-clamp
|
||||
(-> self fov0)
|
||||
(-> self fov1)
|
||||
(parameter-ease-sin-clamp (dummy-10 (-> self fov-index) (-> *camera* tpos-curr-adj)))
|
||||
)
|
||||
)
|
||||
)
|
||||
(set! (-> self fov) f0-7)
|
||||
f0-7
|
||||
(if (!= (-> self fov1) 0.0)
|
||||
(set! (-> self fov) (lerp-clamp
|
||||
(-> self fov0)
|
||||
(-> self fov1)
|
||||
(parameter-ease-sin-clamp (dummy-10 (-> self fov-index) (-> *camera* tpos-curr-adj)))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
;; failed to figure out what this is:
|
||||
@@ -2852,10 +2848,7 @@
|
||||
(set! (-> self string-max-val quad) (-> (the-as vector (-> arg3 param 1)) quad))
|
||||
(set! (-> self string-max-val x) (fmax (-> self string-max-val x) (-> self string-min-val x)))
|
||||
(set! (-> self string-max-val y) (fmax (-> self string-max-val y) (-> self string-min-val y)))
|
||||
(let ((f0-7 (fmax (-> self string-max-val z) (-> self string-min-val z))))
|
||||
(set! (-> self string-max-val z) f0-7)
|
||||
f0-7
|
||||
)
|
||||
(set! (-> self string-max-val z) (fmax (-> self string-max-val z) (-> self string-min-val z)))
|
||||
)
|
||||
(else
|
||||
(set! (-> self string-val-locked) #f)
|
||||
|
||||
+1
-4
@@ -260,10 +260,7 @@
|
||||
;; definition for method 12 of type cam-float-seeker
|
||||
(defmethod jump-to-target! cam-float-seeker ((obj cam-float-seeker) (arg0 float))
|
||||
(set! (-> obj value) (+ (-> obj target) arg0))
|
||||
(let ((f0-2 0.0))
|
||||
(set! (-> obj vel) f0-2)
|
||||
f0-2
|
||||
)
|
||||
(set! (-> obj vel) 0.0)
|
||||
)
|
||||
|
||||
;; definition of type cam-vector-seeker
|
||||
|
||||
+2
-8
@@ -1118,17 +1118,11 @@
|
||||
((-> arg3 param 0)
|
||||
(set! (-> self tracking use-point-of-interest) #t)
|
||||
(set! (-> self tracking point-of-interest quad) (-> (the-as vector (-> arg3 param 0)) quad))
|
||||
(let ((f0-0 1.0))
|
||||
(set! (-> self tracking point-of-interest-blend target) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> self tracking point-of-interest-blend target) 1.0)
|
||||
)
|
||||
(else
|
||||
(set! (-> self tracking use-point-of-interest) #f)
|
||||
(let ((f0-1 0.0))
|
||||
(set! (-> self tracking point-of-interest-blend target) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> self tracking point-of-interest-blend target) 0.0)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+21
-26
@@ -233,32 +233,27 @@
|
||||
)
|
||||
)
|
||||
(set! (-> self mask-to-clear) (process-mask movie enemy platform projectile))
|
||||
(set! (-> self event-hook) (lambda :behavior pov-camera
|
||||
((arg0 process) (arg1 int) (arg2 symbol) (arg3 event-message-block))
|
||||
(let ((v1-0 arg2))
|
||||
(the-as object (cond
|
||||
((= v1-0 'mask)
|
||||
(let ((v0-0 (the-as number (-> arg3 param 0))))
|
||||
(set! (-> self mask-to-clear) (the-as process-mask v0-0))
|
||||
v0-0
|
||||
)
|
||||
)
|
||||
((= v1-0 'music-movie-volume)
|
||||
(let ((f0-0 (the-as float (-> arg3 param 0))))
|
||||
(set! (-> self music-volume-movie) f0-0)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
((= v1-0 'sfx-movie-volume)
|
||||
(let ((f0-1 (the-as float (-> arg3 param 0))))
|
||||
(set! (-> self sfx-volume-movie) f0-1)
|
||||
f0-1
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(set! (-> self event-hook)
|
||||
(lambda :behavior pov-camera
|
||||
((arg0 process) (arg1 int) (arg2 symbol) (arg3 event-message-block))
|
||||
(let ((v1-0 arg2))
|
||||
(the-as object (cond
|
||||
((= v1-0 'mask)
|
||||
(let ((v0-0 (the-as number (-> arg3 param 0))))
|
||||
(set! (-> self mask-to-clear) (the-as process-mask v0-0))
|
||||
v0-0
|
||||
)
|
||||
)
|
||||
((= v1-0 'music-movie-volume)
|
||||
(set! (-> self music-volume-movie) (the-as float (-> arg3 param 0)))
|
||||
)
|
||||
((= v1-0 'sfx-movie-volume)
|
||||
(set! (-> self sfx-volume-movie) (the-as float (-> arg3 param 0)))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(pre-startup-callback self)
|
||||
(go-virtual pov-camera-startup)
|
||||
|
||||
+2
-5
@@ -767,12 +767,9 @@
|
||||
(set! (-> v1-1 mult-hook)
|
||||
(the-as
|
||||
(function surface surface surface int none)
|
||||
(lambda ((arg0 surface) (arg1 object) (arg2 object) (arg3 int)) (when (= arg3 1)
|
||||
(let ((f0-0 151756.8))
|
||||
(set! (-> arg0 fric) f0-0)
|
||||
f0-0
|
||||
(lambda ((arg0 surface) (arg1 object) (arg2 object) (arg3 int)) (if (= arg3 1)
|
||||
(set! (-> arg0 fric) 151756.8)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+1
-4
@@ -967,10 +967,7 @@
|
||||
(set! (-> self anim-last) (-> arg0 first-frame))
|
||||
)
|
||||
(set! (-> self anim-gspeed) (fabs (-> self anim-gspeed)))
|
||||
(let ((f0-13 (fabs (-> self anim-speed))))
|
||||
(set! (-> self anim-speed) f0-13)
|
||||
f0-13
|
||||
)
|
||||
(set! (-> self anim-speed) (fabs (-> self anim-speed)))
|
||||
)
|
||||
|
||||
;; definition for function anim-tester-reset
|
||||
|
||||
+6
-27
@@ -3492,17 +3492,10 @@
|
||||
"sfx-volume"
|
||||
#f
|
||||
(lambda ((arg0 int) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *setting-control* default sfx-volume) f0-0)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
(else
|
||||
(if (= arg1 (debug-menu-msg press))
|
||||
(set! (-> *setting-control* default sfx-volume) arg2)
|
||||
(-> *setting-control* default sfx-volume)
|
||||
)
|
||||
)
|
||||
)
|
||||
2
|
||||
1
|
||||
@@ -3515,17 +3508,10 @@
|
||||
"music-volume"
|
||||
#f
|
||||
(lambda ((arg0 int) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *setting-control* default music-volume) f0-0)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
(else
|
||||
(if (= arg1 (debug-menu-msg press))
|
||||
(set! (-> *setting-control* default music-volume) arg2)
|
||||
(-> *setting-control* default music-volume)
|
||||
)
|
||||
)
|
||||
)
|
||||
2
|
||||
1
|
||||
@@ -3538,17 +3524,10 @@
|
||||
"dialog-volume"
|
||||
#f
|
||||
(lambda ((arg0 int) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *setting-control* default dialog-volume) f0-0)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
(else
|
||||
(if (= arg1 (debug-menu-msg press))
|
||||
(set! (-> *setting-control* default dialog-volume) arg2)
|
||||
(-> *setting-control* default dialog-volume)
|
||||
)
|
||||
)
|
||||
)
|
||||
2
|
||||
1
|
||||
|
||||
+11
-19
@@ -42,18 +42,16 @@
|
||||
|
||||
;; definition for function num-func-+!
|
||||
(defun num-func-+! ((arg0 joint-control-channel) (arg1 float) (arg2 float))
|
||||
(let ((f0-1 (+ (-> arg0 frame-num) (* arg1 (* (-> arg0 frame-group speed) (-> *display* time-adjust-ratio))))))
|
||||
(set! (-> arg0 frame-num) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> arg0 frame-num)
|
||||
(+ (-> arg0 frame-num) (* arg1 (* (-> arg0 frame-group speed) (-> *display* time-adjust-ratio))))
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for function num-func--!
|
||||
(defun num-func--! ((arg0 joint-control-channel) (arg1 float) (arg2 float))
|
||||
(let ((f0-1 (- (-> arg0 frame-num) (* arg1 (* (-> arg0 frame-group speed) (-> *display* time-adjust-ratio))))))
|
||||
(set! (-> arg0 frame-num) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> arg0 frame-num)
|
||||
(- (-> arg0 frame-num) (* arg1 (* (-> arg0 frame-group speed) (-> *display* time-adjust-ratio))))
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for function num-func-loop!
|
||||
@@ -62,10 +60,8 @@
|
||||
(after-inc
|
||||
(+ (-> chan frame-num) duration (* inc (* (-> chan frame-group speed) (-> *display* time-adjust-ratio))))
|
||||
)
|
||||
(wrapped (- after-inc (* (the float (the int (/ after-inc duration))) duration)))
|
||||
)
|
||||
(set! (-> chan frame-num) wrapped)
|
||||
wrapped
|
||||
(set! (-> chan frame-num) (- after-inc (* (the float (the int (/ after-inc duration))) duration)))
|
||||
)
|
||||
)
|
||||
|
||||
@@ -95,15 +91,11 @@
|
||||
|
||||
;; definition for function num-func-chan
|
||||
(defun num-func-chan ((arg0 joint-control-channel) (arg1 float) (arg2 float))
|
||||
(let ((f0-2
|
||||
(-> (the-as joint-control-channel (+ (the-as uint arg0) (* 48 (- (the int arg1) (-> arg0 group-sub-index)))))
|
||||
frame-num
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 frame-num)
|
||||
(-> (the-as joint-control-channel (+ (the-as uint arg0) (* 48 (- (the int arg1) (-> arg0 group-sub-index)))))
|
||||
frame-num
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 frame-num) f0-2)
|
||||
f0-2
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for function num-func-identity
|
||||
|
||||
+1
-4
@@ -324,10 +324,7 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((f0-18 (+ (-> obj money) amount)))
|
||||
(set! (-> obj money) f0-18)
|
||||
f0-18
|
||||
)
|
||||
(set! (-> obj money) (+ (-> obj money) amount))
|
||||
)
|
||||
(('fuel-cell)
|
||||
(let ((s5-1 (the int amount)))
|
||||
|
||||
+2
-8
@@ -333,10 +333,7 @@
|
||||
v0-0
|
||||
)
|
||||
((= v1-0 'max-vis-dist)
|
||||
(let ((f0-0 (the-as float (-> arg3 param 0))))
|
||||
(set! (-> self draw lod-set lod (-> self draw lod-set max-lod) dist) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> self draw lod-set lod (-> self draw lod-set max-lod) dist) (the-as float (-> arg3 param 0)))
|
||||
)
|
||||
((= v1-0 'grab)
|
||||
(set! (-> self cur-grab-handle) (process->handle (the-as process (-> arg3 param 0))))
|
||||
@@ -430,10 +427,7 @@
|
||||
((= v1-0 'set-frame-num)
|
||||
(let ((v1-73 (-> self skel root-channel 0)))
|
||||
(set! (-> v1-73 num-func) num-func-identity)
|
||||
(let ((f0-2 (the-as float (-> arg3 param 0))))
|
||||
(set! (-> v1-73 frame-num) f0-2)
|
||||
f0-2
|
||||
)
|
||||
(set! (-> v1-73 frame-num) (the-as float (-> arg3 param 0)))
|
||||
)
|
||||
)
|
||||
(else
|
||||
|
||||
+1
-4
@@ -158,10 +158,7 @@
|
||||
(set! (-> arg2 data (-> arg2 length) quad) (-> s1-0 quad))
|
||||
(set! (-> arg2 data (+ (-> arg2 length) 1) quad) (-> s2-0 s3-0 quad))
|
||||
(+! (-> arg2 length) 2)
|
||||
(let ((v1-112 (+ (-> obj normal-count) 2)))
|
||||
(set! (-> obj normal-count) v1-112)
|
||||
v1-112
|
||||
)
|
||||
(set! (-> obj normal-count) (+ (-> obj normal-count) 2))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+1
-4
@@ -571,10 +571,7 @@
|
||||
(set! (-> v1-3 trans quad) (-> arg3 quad))
|
||||
)
|
||||
(set! (-> v1-3 fade) (fmax 0.0 (fmin 1.993 arg1)))
|
||||
(let ((f0-3 arg2))
|
||||
(set! (-> v1-3 actor-dist) f0-3)
|
||||
f0-3
|
||||
)
|
||||
(set! (-> v1-3 actor-dist) arg2)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+1
-4
@@ -1555,10 +1555,7 @@
|
||||
(when (< arg3 f0-2)
|
||||
(let ((f0-3 (/ arg3 f0-2)))
|
||||
(set! (-> arg0 x) (* (-> arg0 x) f0-3))
|
||||
(let ((f0-4 (* (-> arg0 z) f0-3)))
|
||||
(set! (-> arg0 z) f0-4)
|
||||
f0-4
|
||||
)
|
||||
(set! (-> arg0 z) (* (-> arg0 z) f0-3))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+1
-4
@@ -251,10 +251,7 @@
|
||||
(send-event arg0 'touch (-> arg3 param 0))
|
||||
)
|
||||
((= v1-0 'dry)
|
||||
(let ((f0-9 0.0))
|
||||
(set! (-> self water drip-wetness) f0-9)
|
||||
f0-9
|
||||
)
|
||||
(set! (-> self water drip-wetness) 0.0)
|
||||
)
|
||||
((= v1-0 'reset-height)
|
||||
(set! (-> self control unknown-vector52 quad) (-> self control trans quad))
|
||||
|
||||
+1
-4
@@ -577,10 +577,7 @@
|
||||
(set! (-> self control root-prim local-sphere w) (* (-> self control root-prim local-sphere w) f30-0))
|
||||
(set! (-> s4-0 local-sphere w) (* (-> s4-0 local-sphere w) f30-0))
|
||||
(set! (-> s5-0 local-sphere w) (* (-> s5-0 local-sphere w) f30-0))
|
||||
(let ((f0-37 (* (-> gp-0 local-sphere w) f30-0)))
|
||||
(set! (-> gp-0 local-sphere w) f0-37)
|
||||
f0-37
|
||||
)
|
||||
(set! (-> gp-0 local-sphere w) (* (-> gp-0 local-sphere w) f30-0))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+1
-4
@@ -1998,10 +1998,7 @@
|
||||
(seek! (-> self control unknown-float131) (the-as float -6144.0) (* 4096.0 (-> *display* seconds-per-frame)))
|
||||
(seek! (-> self control unknown-float131) (the-as float 0.0) (* 2048.0 (-> *display* seconds-per-frame)))
|
||||
)
|
||||
(let ((f0-20 (-> self control unknown-float131)))
|
||||
(set! (-> self control unknown-vector11 y) f0-20)
|
||||
f0-20
|
||||
)
|
||||
(set! (-> self control unknown-vector11 y) (-> self control unknown-float131))
|
||||
)
|
||||
|
||||
;; failed to figure out what this is:
|
||||
|
||||
+7
-10
@@ -2731,17 +2731,14 @@
|
||||
(send-event
|
||||
(ppointer->process s5-1)
|
||||
'function
|
||||
(lambda ((arg0 target)) (let ((f0-3 (seek
|
||||
(-> arg0 control root-prim local-sphere w)
|
||||
(the-as float 28672.0)
|
||||
(* 286720.0 (-> *display* seconds-per-frame))
|
||||
)
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 control root-prim local-sphere w) f0-3)
|
||||
f0-3
|
||||
)
|
||||
(lambda ((arg0 target))
|
||||
(set! (-> arg0 control root-prim local-sphere w) (seek
|
||||
(-> arg0 control root-prim local-sphere w)
|
||||
(the-as float 28672.0)
|
||||
(* 286720.0 (-> *display* seconds-per-frame))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+3
-5
@@ -230,12 +230,10 @@
|
||||
(combined-offset
|
||||
(+ (* (- wrapped-user-offset current-time-wrapped) period-float) period-float (-> obj offset))
|
||||
)
|
||||
(combined-offset-wrapped
|
||||
(- combined-offset (* (the float (the int (/ combined-offset period-float))) period-float))
|
||||
)
|
||||
)
|
||||
(set! (-> obj offset) combined-offset-wrapped)
|
||||
combined-offset-wrapped
|
||||
(set! (-> obj offset)
|
||||
(- combined-offset (* (the float (the int (/ combined-offset period-float))) period-float))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
+7
-10
@@ -1480,15 +1480,12 @@
|
||||
|
||||
;; definition (debug) for function beach-rock-trigger
|
||||
(defun-debug beach-rock-trigger ()
|
||||
(let ((gp-0 600))
|
||||
(set! (-> (the-as
|
||||
seagullflock
|
||||
(search-process-tree *active-pool* (lambda ((arg0 process)) (= (-> arg0 type) seagullflock)))
|
||||
)
|
||||
teleport-frames
|
||||
(set! (-> (the-as
|
||||
seagullflock
|
||||
(search-process-tree *active-pool* (lambda ((arg0 process)) (= (-> arg0 type) seagullflock)))
|
||||
)
|
||||
gp-0
|
||||
)
|
||||
gp-0
|
||||
)
|
||||
teleport-frames
|
||||
)
|
||||
600
|
||||
)
|
||||
)
|
||||
|
||||
+1
-4
@@ -1147,10 +1147,7 @@
|
||||
(let ((s5-1 (handle->process (-> self robotboss))))
|
||||
(when s5-1
|
||||
(format 0 "robotboss activated ent ~A~%" gp-0)
|
||||
(let ((f0-0 327680.0))
|
||||
(set! (-> (the-as process-drawable s5-1) draw bounds w) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> (the-as process-drawable s5-1) draw bounds w) 327680.0)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+1
-4
@@ -329,10 +329,7 @@
|
||||
(set! (-> obj event-down) #f)
|
||||
(set! (-> obj event-going-up) #f)
|
||||
(set! (-> obj event-up) #f)
|
||||
(let ((f0-1 1.0))
|
||||
(set! (-> obj anim-speed) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> obj anim-speed) 1.0)
|
||||
)
|
||||
|
||||
;; definition for method 28 of type basebutton
|
||||
|
||||
+1
-4
@@ -149,10 +149,7 @@
|
||||
(else
|
||||
(set! (-> v1-4 fact pickup-type) (-> self final-pickup-type))
|
||||
(set! (-> v1-4 fact pickup-amount) 1.0)
|
||||
(let ((f0-1 0.0))
|
||||
(set! (-> v1-4 fact pickup-spawn-amount) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> v1-4 fact pickup-spawn-amount) 0.0)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+1
-4
@@ -1896,10 +1896,7 @@ nav-enemy-default-event-handler
|
||||
(set! (-> obj neck nose) (the-as uint 2))
|
||||
(set! (-> obj neck ear) (the-as uint 0))
|
||||
(set! (-> obj neck max-dist) 102400.0)
|
||||
(let ((f0-6 16384.0))
|
||||
(set! (-> obj neck ignore-angle) f0-6)
|
||||
f0-6
|
||||
)
|
||||
(set! (-> obj neck ignore-angle) 16384.0)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
+1
-5
@@ -82,11 +82,7 @@
|
||||
(-> self root-override)
|
||||
(the-as uint 1)
|
||||
)
|
||||
(or (not (-> self should-grab-player?)) (let ((v0-3 (process-grab? *target*)))
|
||||
(set! (-> self grab-player?) v0-3)
|
||||
v0-3
|
||||
)
|
||||
)
|
||||
(or (not (-> self should-grab-player?)) (set! (-> self grab-player?) (process-grab? *target*)))
|
||||
)
|
||||
(go-virtual plat-button-pressed)
|
||||
)
|
||||
|
||||
+1
-4
@@ -248,10 +248,7 @@ nav-enemy-default-event-handler
|
||||
)
|
||||
(set! (-> self collide-info trans quad) (-> self spawn-point quad))
|
||||
(forward-up->quaternion (-> self collide-info quat) (-> self dir) *up-vector*)
|
||||
(let ((f0-6 0.0))
|
||||
(set! (-> self momentum-speed) f0-6)
|
||||
f0-6
|
||||
)
|
||||
(set! (-> self momentum-speed) 0.0)
|
||||
)
|
||||
|
||||
;; failed to figure out what this is:
|
||||
|
||||
+3
-12
@@ -192,10 +192,7 @@
|
||||
)
|
||||
)
|
||||
(set! (-> self particles 0 trans quad) (-> self root trans quad))
|
||||
(let ((f0-1 (+ 12288.0 (-> self particles 0 trans y))))
|
||||
(set! (-> self particles 0 trans y) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> self particles 0 trans y) (+ 12288.0 (-> self particles 0 trans y)))
|
||||
)
|
||||
((= v1-0 'beam-on)
|
||||
(let ((s5-0 (-> arg3 param 0)))
|
||||
@@ -217,10 +214,7 @@
|
||||
)
|
||||
)
|
||||
(set! (-> self particles 2 trans quad) (-> (the-as vector (-> arg3 param 2)) quad))
|
||||
(let ((f0-5 (+ 81920.0 (-> self particles 2 trans y))))
|
||||
(set! (-> self particles 2 trans y) f0-5)
|
||||
f0-5
|
||||
)
|
||||
(set! (-> self particles 2 trans y) (+ 81920.0 (-> self particles 2 trans y)))
|
||||
)
|
||||
((= v1-0 'beam-off)
|
||||
(set! (-> self particles 1 kind) #f)
|
||||
@@ -353,10 +347,7 @@
|
||||
:event (behavior ((arg0 process) (arg1 int) (arg2 symbol) (arg3 event-message-block))
|
||||
(case arg2
|
||||
(('open)
|
||||
(let ((f0-0 (the-as float (-> arg3 param 0))))
|
||||
(set! (-> self part-opened) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> self part-opened) (the-as float (-> arg3 param 0)))
|
||||
)
|
||||
(('hide)
|
||||
(go-virtual hidden)
|
||||
|
||||
+2
-8
@@ -210,10 +210,7 @@
|
||||
)
|
||||
(set! (-> self y-vel) (* 0.5 (- (sqrtf (- (* f0-6 f0-6) (* 4.0 f3-1))) f0-6)))
|
||||
)
|
||||
(let ((f0-12 (/ (- (* (-> self y-vel) (-> self y-vel))) (* 2.0 v1-2))))
|
||||
(set! (-> self grav) f0-12)
|
||||
f0-12
|
||||
)
|
||||
(set! (-> self grav) (/ (- (* (-> self y-vel) (-> self y-vel))) (* 2.0 v1-2)))
|
||||
)
|
||||
)
|
||||
|
||||
@@ -223,10 +220,7 @@
|
||||
(vector-lerp! arg0 (-> self from) (-> self to) s5-0)
|
||||
(set! (-> arg0 y) (-> self from y))
|
||||
(+! (-> arg0 y) (* (-> self y-vel) s5-0))
|
||||
(let ((f0-6 (+ (-> arg0 y) (* 0.5 s5-0 s5-0 (-> self grav)))))
|
||||
(set! (-> arg0 y) f0-6)
|
||||
f0-6
|
||||
)
|
||||
(set! (-> arg0 y) (+ (-> arg0 y) (* 0.5 s5-0 s5-0 (-> self grav))))
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
+2
-8
@@ -368,10 +368,7 @@
|
||||
(local-vars (v0-0 object))
|
||||
(case arg2
|
||||
(('flash)
|
||||
(let ((f0-1 (* 0.0078125 (the-as float (-> arg3 param 0)))))
|
||||
(set! (-> self palette-val) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> self palette-val) (* 0.0078125 (the-as float (-> arg3 param 0))))
|
||||
)
|
||||
(('bomb-done)
|
||||
(set! (-> self des-cam-entity) #f)
|
||||
@@ -409,10 +406,7 @@
|
||||
(let ((v1-0 arg2))
|
||||
(the-as object (cond
|
||||
((= v1-0 'flash)
|
||||
(let ((f0-1 (* 0.0078125 (the-as float (-> arg3 param 0)))))
|
||||
(set! (-> self palette-val) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> self palette-val) (* 0.0078125 (the-as float (-> arg3 param 0))))
|
||||
)
|
||||
((= v1-0 'attack)
|
||||
(when (>= arg1 2)
|
||||
|
||||
+3
-12
@@ -92,10 +92,7 @@
|
||||
(case arg2
|
||||
(('target)
|
||||
(process-entity-status! self (entity-perm-status complete) #t)
|
||||
(let ((f0-0 (the-as float (-> arg3 param 0))))
|
||||
(set! (-> self force-dest) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> self force-dest) (the-as float (-> arg3 param 0)))
|
||||
)
|
||||
(('ridden 'edge-grabbed)
|
||||
(if (>= (- (-> *display* base-frame-counter) (-> self touch-time)) (seconds 2))
|
||||
@@ -635,16 +632,10 @@
|
||||
:event (behavior ((arg0 process) (arg1 int) (arg2 symbol) (arg3 event-message-block))
|
||||
(case arg2
|
||||
(('fade)
|
||||
(let ((f0-0 1.0))
|
||||
(set! (-> self credit-fade) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> self credit-fade) 1.0)
|
||||
)
|
||||
(('flash)
|
||||
(let ((f0-1 1.9921875))
|
||||
(set! (-> self palette-val) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> self palette-val) 1.9921875)
|
||||
)
|
||||
(('activate-particle)
|
||||
(let ((v0-0 (the-as object #t)))
|
||||
|
||||
+1
-4
@@ -511,10 +511,7 @@
|
||||
(let ((a0-15 (-> v1-0 draw color-emissive quad)))
|
||||
(set! (-> self draw color-emissive quad) a0-15)
|
||||
)
|
||||
(let ((f0-0 (-> v1-0 draw secondary-interp)))
|
||||
(set! (-> self draw secondary-interp) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> self draw secondary-interp) (-> v1-0 draw secondary-interp))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+4
-16
@@ -214,10 +214,7 @@
|
||||
(let ((v1-0 arg2))
|
||||
(the-as object (when (= v1-0 'stop)
|
||||
(process-entity-status! self (entity-perm-status complete) #t)
|
||||
(let ((f0-0 0.0))
|
||||
(set! (-> self speed) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> self speed) 0.0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -323,10 +320,7 @@
|
||||
(let ((v1-0 arg2))
|
||||
(the-as object (when (= v1-0 'stop)
|
||||
(process-entity-status! self (entity-perm-status complete) #t)
|
||||
(let ((f0-0 0.0))
|
||||
(set! (-> self speed) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> self speed) 0.0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -455,10 +449,7 @@
|
||||
(let ((v1-0 arg2))
|
||||
(the-as object (when (= v1-0 'stop)
|
||||
(process-entity-status! self (entity-perm-status complete) #t)
|
||||
(let ((f0-0 0.0))
|
||||
(set! (-> self speed) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> self speed) 0.0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -585,10 +576,7 @@
|
||||
(let ((v1-0 arg2))
|
||||
(the-as object (when (= v1-0 'stop)
|
||||
(process-entity-status! self (entity-perm-status complete) #t)
|
||||
(let ((f0-0 0.0))
|
||||
(set! (-> self speed) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> self speed) 0.0)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+5
-14
@@ -1305,10 +1305,7 @@
|
||||
)
|
||||
(set! (-> *palette-fade-controls* control 2 fade) (-> self palette-val))
|
||||
(set! (-> (the-as process-drawable v1-2) root scale x) 1.25)
|
||||
(let ((f0-6 1.25))
|
||||
(set! (-> (the-as process-drawable v1-2) root scale z) f0-6)
|
||||
f0-6
|
||||
)
|
||||
(set! (-> (the-as process-drawable v1-2) root scale z) 1.25)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1355,12 +1352,9 @@
|
||||
(defstate energyhub-stop (energyhub)
|
||||
:event (behavior ((arg0 process) (arg1 int) (arg2 symbol) (arg3 event-message-block))
|
||||
(let ((v1-0 arg2))
|
||||
(the-as object (when (= v1-0 'flash)
|
||||
(let ((f0-0 1.9921875))
|
||||
(set! (-> self palette-val) f0-0)
|
||||
f0-0
|
||||
(the-as object (if (= v1-0 'flash)
|
||||
(set! (-> self palette-val) 1.9921875)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1440,12 +1434,9 @@
|
||||
(defstate energyhub-idle (energyhub)
|
||||
:event (behavior ((arg0 process) (arg1 int) (arg2 symbol) (arg3 event-message-block))
|
||||
(let ((v1-0 arg2))
|
||||
(the-as object (when (= v1-0 'flash)
|
||||
(let ((f0-0 1.9921875))
|
||||
(set! (-> self palette-val) f0-0)
|
||||
f0-0
|
||||
(the-as object (if (= v1-0 'flash)
|
||||
(set! (-> self palette-val) 1.9921875)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+3
-4
@@ -668,10 +668,9 @@
|
||||
)
|
||||
(else
|
||||
(set! (-> self leak (+ (-> self hits) -1) offset quad) (-> self root-override trans quad))
|
||||
(let ((f0-1 (+ -49152.0 (-> self leak (+ (-> self hits) -1) offset y))))
|
||||
(set! (-> self leak (+ (-> self hits) -1) offset y) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> self leak (+ (-> self hits) -1) offset y)
|
||||
(+ -49152.0 (-> self leak (+ (-> self hits) -1) offset y))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+2
-8
@@ -743,10 +743,7 @@
|
||||
(vector-normalize! (the-as vector (-> gp-0 orient-mat)) 1.0)
|
||||
(set! (-> gp-0 orient-mat vector 0 w) 0.0)
|
||||
(set! (-> gp-0 orient-mat vector 1 w) 0.0)
|
||||
(let ((f0-27 0.0))
|
||||
(set! (-> gp-0 orient-mat vector 2 w) f0-27)
|
||||
f0-27
|
||||
)
|
||||
(set! (-> gp-0 orient-mat vector 2 w) 0.0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -874,10 +871,7 @@
|
||||
)
|
||||
)
|
||||
(vector+! arg2 arg2 (-> obj post-trans))
|
||||
(let ((f0-11 (+ 4096.0 (-> arg2 y))))
|
||||
(set! (-> arg2 y) f0-11)
|
||||
f0-11
|
||||
)
|
||||
(set! (-> arg2 y) (+ 4096.0 (-> arg2 y)))
|
||||
)
|
||||
|
||||
;; definition for method 30 of type gnawer
|
||||
|
||||
+1
-4
@@ -1059,10 +1059,7 @@
|
||||
)
|
||||
(vector<-cspace! s5-0 (-> obj node-list data 3))
|
||||
(vector-! gp-0 s5-0 (-> obj root-override trans))
|
||||
(let ((f0-0 17408.0))
|
||||
(set! (-> gp-0 w) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> gp-0 w) 17408.0)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
+2
-7
@@ -441,10 +441,8 @@
|
||||
0
|
||||
(let* ((f3-0 (vector-vector-distance (-> s5-0 intersect) (-> obj root-override trans)))
|
||||
(f0-14 (* 0.000030517578 (fmin 32768.0 (fmax 0.0 (+ -57344.0 f3-0)))))
|
||||
(f0-15 (lerp 409600.0 40960.0 f0-14))
|
||||
)
|
||||
(set! (-> obj draw shadow-ctrl settings shadow-dir w) f0-15)
|
||||
f0-15
|
||||
(set! (-> obj draw shadow-ctrl settings shadow-dir w) (lerp 409600.0 40960.0 f0-14))
|
||||
)
|
||||
)
|
||||
(else
|
||||
@@ -1720,10 +1718,7 @@
|
||||
(vector-normalize! (-> arg0 vector 1) 1.0)
|
||||
(set! (-> arg0 vector 0 w) 0.0)
|
||||
(set! (-> arg0 vector 1 w) 0.0)
|
||||
(let ((f0-8 0.0))
|
||||
(set! (-> arg0 vector 2 w) f0-8)
|
||||
f0-8
|
||||
)
|
||||
(set! (-> arg0 vector 2 w) 0.0)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
+2
-8
@@ -91,18 +91,12 @@
|
||||
((< (-> arg0 parametric-index) 0.0)
|
||||
(set! (-> arg0 parametric-index) 0.0)
|
||||
(set! (-> arg0 nearest-point quad) (-> arg0 segment 0 quad))
|
||||
(let ((f0-10 (vector-vector-distance (-> arg0 nearest-point) (-> arg0 point))))
|
||||
(set! (-> arg0 distance-to-segment) f0-10)
|
||||
f0-10
|
||||
)
|
||||
(set! (-> arg0 distance-to-segment) (vector-vector-distance (-> arg0 nearest-point) (-> arg0 point)))
|
||||
)
|
||||
((< 1.0 (-> arg0 parametric-index))
|
||||
(set! (-> arg0 parametric-index) 1.0)
|
||||
(set! (-> arg0 nearest-point quad) (-> arg0 segment 1 quad))
|
||||
(let ((f0-13 (vector-vector-distance (-> arg0 nearest-point) (-> arg0 point))))
|
||||
(set! (-> arg0 distance-to-segment) f0-13)
|
||||
f0-13
|
||||
)
|
||||
(set! (-> arg0 distance-to-segment) (vector-vector-distance (-> arg0 nearest-point) (-> arg0 point)))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+2
-5
@@ -559,12 +559,9 @@
|
||||
;; definition for function inc-angle
|
||||
(defun inc-angle ((arg0 (pointer float)) (arg1 float))
|
||||
(+! (-> arg0 0) arg1)
|
||||
(when (< 65536.0 (-> arg0 0))
|
||||
(let ((f0-4 (+ -65536.0 (-> arg0 0))))
|
||||
(set! (-> arg0 0) f0-4)
|
||||
f0-4
|
||||
(if (< 65536.0 (-> arg0 0))
|
||||
(set! (-> arg0 0) (+ -65536.0 (-> arg0 0)))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for function quicksandlurker-post
|
||||
|
||||
+2
-8
@@ -527,16 +527,10 @@
|
||||
:event (behavior ((arg0 process) (arg1 int) (arg2 symbol) (arg3 event-message-block))
|
||||
(case arg2
|
||||
(('speedup)
|
||||
(let ((f0-1 (* 1.3 (-> self speed))))
|
||||
(set! (-> self speed) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> self speed) (* 1.3 (-> self speed)))
|
||||
)
|
||||
(('grow-faster)
|
||||
(let ((f0-2 1.0))
|
||||
(set! (-> self grow-rate) f0-2)
|
||||
f0-2
|
||||
)
|
||||
(set! (-> self grow-rate) 1.0)
|
||||
)
|
||||
(('go-throw)
|
||||
(go ogreboss-super-boulder-throw)
|
||||
|
||||
+8
-17
@@ -41,26 +41,20 @@
|
||||
)
|
||||
)
|
||||
(('heat)
|
||||
(let ((f0-7 (fmax 0.0 (fmin (+ (-> self racer heat) (the-as float (-> arg3 param 0))) (-> *RACER-bank* heat-max))))
|
||||
(set! (-> self racer heat)
|
||||
(fmax 0.0 (fmin (+ (-> self racer heat) (the-as float (-> arg3 param 0))) (-> *RACER-bank* heat-max)))
|
||||
)
|
||||
(set! (-> self racer heat) f0-7)
|
||||
f0-7
|
||||
)
|
||||
)
|
||||
(('boost)
|
||||
(sound-play "get-blue-eco")
|
||||
(set! (-> self racer boost-sound-id) (sound-play "zoom-boost"))
|
||||
(set! (-> self racer boost-time) (-> *display* base-frame-counter))
|
||||
(let ((f0-12 (seek
|
||||
(-> self racer boost-level)
|
||||
(-> *RACER-bank* boost-level-max)
|
||||
(* (-> *RACER-bank* boost-level-inc) (the-as float (-> arg3 param 0)))
|
||||
)
|
||||
)
|
||||
(set! (-> self racer boost-level) (seek
|
||||
(-> self racer boost-level)
|
||||
(-> *RACER-bank* boost-level-max)
|
||||
(* (-> *RACER-bank* boost-level-inc) (the-as float (-> arg3 param 0)))
|
||||
)
|
||||
)
|
||||
(set! (-> self racer boost-level) f0-12)
|
||||
f0-12
|
||||
)
|
||||
)
|
||||
(('smack)
|
||||
(go target-racing-smack (-> self control unknown-float01) #t)
|
||||
@@ -257,10 +251,7 @@
|
||||
(let ((a0-11 (-> (the-as target v1-0) draw color-emissive quad)))
|
||||
(set! (-> self draw color-emissive quad) a0-11)
|
||||
)
|
||||
(let ((f0-0 (-> (the-as target v1-0) draw secondary-interp)))
|
||||
(set! (-> self draw secondary-interp) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> self draw secondary-interp) (-> (the-as target v1-0) draw secondary-interp))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+7
-14
@@ -216,16 +216,12 @@
|
||||
(parameter-ease-sin-clamp (* 0.00081380206 (+ -409.6 f30-0)))
|
||||
)
|
||||
)
|
||||
(let ((f0-9 (lerp-clamp
|
||||
(-> self flee-info min-stop-chase-dist)
|
||||
(-> self flee-info max-stop-chase-dist)
|
||||
(parameter-ease-sin-clamp (* 0.00081380206 (+ -409.6 f30-0)))
|
||||
)
|
||||
)
|
||||
(set! (-> self nav-info stop-chase-distance) (lerp-clamp
|
||||
(-> self flee-info min-stop-chase-dist)
|
||||
(-> self flee-info max-stop-chase-dist)
|
||||
(parameter-ease-sin-clamp (* 0.00081380206 (+ -409.6 f30-0)))
|
||||
)
|
||||
)
|
||||
(set! (-> self nav-info stop-chase-distance) f0-9)
|
||||
f0-9
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -368,12 +364,9 @@
|
||||
(quaternion->matrix s5-0 (-> self collide-info quat))
|
||||
(set! (-> self run-blend-interp) (acos (vector-dot (-> s5-0 vector 2) (-> gp-0 vector 2))))
|
||||
(set! (-> self run-blend-interp) (/ (-> self run-blend-interp) (-> self flee-info blend_interp_angle)))
|
||||
(when (< (vector-dot (-> s5-0 vector 2) (the-as vector (-> gp-0 vector))) 0.0)
|
||||
(let ((f0-8 (- (-> self run-blend-interp))))
|
||||
(set! (-> self run-blend-interp) f0-8)
|
||||
f0-8
|
||||
(if (< (vector-dot (-> s5-0 vector 2) (the-as vector (-> gp-0 vector))) 0.0)
|
||||
(set! (-> self run-blend-interp) (- (-> self run-blend-interp)))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
+1
-4
@@ -1057,10 +1057,7 @@
|
||||
)
|
||||
(set! (-> self coord vector 3 w) 1.0)
|
||||
(set! (-> self radius) arg2)
|
||||
(let ((f0-2 arg3))
|
||||
(set! (-> self thickness) f0-2)
|
||||
f0-2
|
||||
)
|
||||
(set! (-> self thickness) arg3)
|
||||
)
|
||||
|
||||
;; definition of type gorge-start
|
||||
|
||||
+1
-4
@@ -278,10 +278,7 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((f0-34 (+ (-> self root-override trans y) (-> self y-offset))))
|
||||
(set! (-> self root-override trans y) f0-34)
|
||||
f0-34
|
||||
)
|
||||
(set! (-> self root-override trans y) (+ (-> self root-override trans y) (-> self y-offset)))
|
||||
)
|
||||
|
||||
;; definition for function robber-calc-speed
|
||||
|
||||
+1
-4
@@ -497,10 +497,7 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((f0-25 (+ -36864.0 (-> obj root-override transv y))))
|
||||
(set! (-> obj root-override transv y) f0-25)
|
||||
f0-25
|
||||
)
|
||||
(set! (-> obj root-override transv y) (+ -36864.0 (-> obj root-override transv y)))
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
+1
-4
@@ -748,10 +748,7 @@
|
||||
(let ((s5-3 (new 'stack-no-clear 'vector)))
|
||||
(set! (-> s5-3 quad) (-> obj basetrans quad))
|
||||
(get-nav-point! (-> obj basetrans) obj (-> obj reset-trans) 40960.0)
|
||||
(let ((f0-29 (-> s5-3 y)))
|
||||
(set! (-> obj basetrans y) f0-29)
|
||||
f0-29
|
||||
)
|
||||
(set! (-> obj basetrans y) (-> s5-3 y))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+4
-7
@@ -606,14 +606,11 @@
|
||||
|
||||
;; definition for method 20 of type exit-chamber
|
||||
(defmethod dummy-20 exit-chamber ((obj exit-chamber) (arg0 float))
|
||||
(let ((f0-5 (+ (-> obj orig-trans y)
|
||||
(* 2252.8 arg0 (cos (* 36.40889 (the float (mod (-> *display* base-frame-counter) 1800)))))
|
||||
)
|
||||
)
|
||||
(set! (-> obj root-override trans y)
|
||||
(+ (-> obj orig-trans y)
|
||||
(* 2252.8 arg0 (cos (* 36.40889 (the float (mod (-> *display* base-frame-counter) 1800)))))
|
||||
)
|
||||
)
|
||||
(set! (-> obj root-override trans y) f0-5)
|
||||
f0-5
|
||||
)
|
||||
)
|
||||
|
||||
;; failed to figure out what this is:
|
||||
|
||||
+6
-22
@@ -191,20 +191,10 @@
|
||||
(f1-3 (- (-> obj targ-local-path-offset x) f0-8))
|
||||
)
|
||||
(when (< (fabs f1-3) 12288.0)
|
||||
(cond
|
||||
((>= f1-3 0.0)
|
||||
(let ((f0-10 (fmin (+ 12288.0 f0-8) (-> obj max-local-path-offset x))))
|
||||
(set! (-> obj targ-local-path-offset x) f0-10)
|
||||
f0-10
|
||||
)
|
||||
)
|
||||
(else
|
||||
(let ((f0-12 (fmax (+ -12288.0 f0-8) (- (-> obj max-local-path-offset x)))))
|
||||
(set! (-> obj targ-local-path-offset x) f0-12)
|
||||
f0-12
|
||||
)
|
||||
(if (>= f1-3 0.0)
|
||||
(set! (-> obj targ-local-path-offset x) (fmin (+ 12288.0 f0-8) (-> obj max-local-path-offset x)))
|
||||
(set! (-> obj targ-local-path-offset x) (fmax (+ -12288.0 f0-8) (- (-> obj max-local-path-offset x))))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -280,10 +270,7 @@
|
||||
(the-as art-joint-anim (-> obj draw art-group data 6))
|
||||
num-func-identity
|
||||
)
|
||||
(let ((f0-4 0.0))
|
||||
(set! (-> s5-0 frame-num) f0-4)
|
||||
f0-4
|
||||
)
|
||||
(set! (-> s5-0 frame-num) 0.0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -359,12 +346,9 @@
|
||||
(TODO-RENAME-14 (-> obj path) s4-0 (-> obj path-u))
|
||||
(set-vector! (-> obj facing-rot) 0.0 (atan (-> s4-0 x) (-> s4-0 z)) 0.0 1.0)
|
||||
)
|
||||
(when (< (-> obj path-dir) 0.0)
|
||||
(let ((f0-52 (- (-> obj facing-rot y))))
|
||||
(set! (-> obj facing-rot y) f0-52)
|
||||
f0-52
|
||||
(if (< (-> obj path-dir) 0.0)
|
||||
(set! (-> obj facing-rot y) (- (-> obj facing-rot y)))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for function sunkenfisha-init-by-other
|
||||
|
||||
+1
-4
@@ -937,10 +937,7 @@
|
||||
(+! (-> (the-as billy-snack s5-1) num-rats) 1)
|
||||
(set! (-> gp-0 dest-type) (the-as uint 2))
|
||||
(set! (-> gp-0 destination quad) (-> (the-as billy-snack s5-1) root trans quad))
|
||||
(let ((f0-8 (+ 6799.36 (-> gp-0 destination x))))
|
||||
(set! (-> gp-0 destination x) f0-8)
|
||||
f0-8
|
||||
)
|
||||
(set! (-> gp-0 destination x) (+ 6799.36 (-> gp-0 destination x)))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+4
-8
@@ -234,10 +234,9 @@ swamp-bat-slave-event-handler
|
||||
)
|
||||
(set! (-> self idle-path y-axis w) 1.0)
|
||||
(vector+! (-> self idle-position) (the-as vector (-> self idle-path)) (-> self idle-path x-axis))
|
||||
(let ((f0-8 (the float (+ (-> self parent-process 0 path-list (-> self path-select) curve num-cverts) -1))))
|
||||
(set! (-> self path-point-count) f0-8)
|
||||
f0-8
|
||||
)
|
||||
(set! (-> self path-point-count)
|
||||
(the float (+ (-> self parent-process 0 path-list (-> self path-select) curve num-cverts) -1))
|
||||
)
|
||||
)
|
||||
|
||||
;; failed to figure out what this is:
|
||||
@@ -535,10 +534,7 @@ swamp-bat-slave-event-handler
|
||||
)
|
||||
(set! (-> gp-1 y) 0.0)
|
||||
(vector-normalize! gp-1 1.0)
|
||||
(let ((f0-3 (- (vector-dot s5-1 gp-1))))
|
||||
(set! (-> gp-1 w) f0-3)
|
||||
f0-3
|
||||
)
|
||||
(set! (-> gp-1 w) (- (vector-dot s5-1 gp-1)))
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
+1
-4
@@ -191,10 +191,7 @@ swamp-rat-default-event-handler
|
||||
)
|
||||
(set! (-> self delta-wiggle-angle) (* 910.2222 f1-1))
|
||||
(set! (-> self wiggle-factor) (* 1.5 f2-4))
|
||||
(let ((f0-3 (* 28672.0 f0-2)))
|
||||
(set! (-> self target-speed) f0-3)
|
||||
f0-3
|
||||
)
|
||||
(set! (-> self target-speed) (* 28672.0 f0-2))
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
+1
-4
@@ -1060,10 +1060,7 @@
|
||||
|
||||
;; definition for function set-period
|
||||
(defun set-period ((arg0 cyclegen) (arg1 int))
|
||||
(let ((f0-1 (/ 5.0 (the float arg1))))
|
||||
(set! (-> arg0 inc) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> arg0 inc) (/ 5.0 (the float arg1)))
|
||||
)
|
||||
|
||||
;; definition for function update-clock
|
||||
|
||||
+1
-4
@@ -1622,10 +1622,7 @@
|
||||
)
|
||||
(quaternion-normalize! (-> self root-override quat))
|
||||
(vector+! (-> self root-override trans) (-> self trans-at-init) (-> self pos-oscillator value))
|
||||
(let ((f0-34 (+ (-> self root-override trans y) (-> self y-offset))))
|
||||
(set! (-> self root-override trans y) f0-34)
|
||||
f0-34
|
||||
)
|
||||
(set! (-> self root-override trans y) (+ (-> self root-override trans y) (-> self y-offset)))
|
||||
)
|
||||
|
||||
;; failed to figure out what this is:
|
||||
|
||||
+2
-8
@@ -138,17 +138,11 @@
|
||||
(let ((f0-1 (the float (-> arg3 param 0))))
|
||||
(cond
|
||||
((>= 0.0 f0-1)
|
||||
(let ((f0-2 1.0))
|
||||
(set! (-> self interp-val) f0-2)
|
||||
f0-2
|
||||
)
|
||||
(set! (-> self interp-val) 1.0)
|
||||
)
|
||||
(else
|
||||
(set! (-> self interp-val) 0.0)
|
||||
(let ((f0-3 (/ 5.0 f0-1)))
|
||||
(set! (-> self interp-step) f0-3)
|
||||
f0-3
|
||||
)
|
||||
(set! (-> self interp-step) (/ 5.0 f0-1))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+4
-16
@@ -150,18 +150,12 @@
|
||||
(+! (-> arg1 y) f26-0)
|
||||
(+! (-> arg1 z) f22-0)
|
||||
(+! (-> arg0 x) f24-0)
|
||||
(let ((f0-13 (+ (-> arg0 y) f0-12)))
|
||||
(set! (-> arg0 y) f0-13)
|
||||
f0-13
|
||||
)
|
||||
(set! (-> arg0 y) (+ (-> arg0 y) f0-12))
|
||||
)
|
||||
)
|
||||
(else
|
||||
(+! (-> arg0 y) (* (- (-> v1-0 x)) (-> *CAM_FREE-bank* rot-speed)))
|
||||
(let ((f0-17 (+ (-> arg0 x) (* (-> v1-0 y) (-> *CAM_FREE-bank* rot-speed)))))
|
||||
(set! (-> arg0 x) f0-17)
|
||||
f0-17
|
||||
)
|
||||
(set! (-> arg0 x) (+ (-> arg0 x) (* (-> v1-0 y) (-> *CAM_FREE-bank* rot-speed))))
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -169,17 +163,11 @@
|
||||
)
|
||||
((logtest? (-> *mouse* button0-abs 0) 2)
|
||||
(+! (-> arg1 x) (* (-> v1-0 x) (-> *CAM_FREE-bank* speed)))
|
||||
(let ((f0-21 (+ (-> arg1 z) (* (-> v1-0 y) (-> *CAM_FREE-bank* speed)))))
|
||||
(set! (-> arg1 z) f0-21)
|
||||
f0-21
|
||||
)
|
||||
(set! (-> arg1 z) (+ (-> arg1 z) (* (-> v1-0 y) (-> *CAM_FREE-bank* speed))))
|
||||
)
|
||||
((logtest? (-> *mouse* button0-abs 0) 4)
|
||||
(+! (-> arg1 x) (* (-> v1-0 x) (-> *CAM_FREE-bank* speed)))
|
||||
(let ((f0-25 (+ (-> arg1 y) (* (-> v1-0 y) (-> *CAM_FREE-bank* speed)))))
|
||||
(set! (-> arg1 y) f0-25)
|
||||
f0-25
|
||||
)
|
||||
(set! (-> arg1 y) (+ (-> arg1 y) (* (-> v1-0 y) (-> *CAM_FREE-bank* speed))))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+3
-12
@@ -5099,10 +5099,7 @@
|
||||
)
|
||||
(set! (-> self string-max-val x) (fmax (-> self string-max-val x) (-> self string-min-val x)))
|
||||
(set! (-> self string-max-val y) (fmax (-> self string-max-val y) (-> self string-min-val y)))
|
||||
(let ((f0-31 (fmax (-> self string-max-val z) (-> self string-min-val z))))
|
||||
(set! (-> self string-max-val z) f0-31)
|
||||
f0-31
|
||||
)
|
||||
(set! (-> self string-max-val z) (fmax (-> self string-max-val z) (-> self string-min-val z)))
|
||||
)
|
||||
(else
|
||||
(set! (-> self string-val-locked) #f)
|
||||
@@ -5118,10 +5115,7 @@
|
||||
(set! (-> self string-max-val quad) (-> (the-as vector (-> arg3 param 1)) quad))
|
||||
(set! (-> self string-max-val x) (fmax (-> self string-max-val x) (-> self string-min-val x)))
|
||||
(set! (-> self string-max-val y) (fmax (-> self string-max-val y) (-> self string-min-val y)))
|
||||
(let ((f0-37 (fmax (-> self string-max-val z) (-> self string-min-val z))))
|
||||
(set! (-> self string-max-val z) f0-37)
|
||||
f0-37
|
||||
)
|
||||
(set! (-> self string-max-val z) (fmax (-> self string-max-val z) (-> self string-min-val z)))
|
||||
)
|
||||
(else
|
||||
(set! (-> self string-val-locked) #f)
|
||||
@@ -5146,10 +5140,7 @@
|
||||
)
|
||||
)
|
||||
((= v1-0 'set-max-angle-offset)
|
||||
(let ((f0-38 (the-as float (-> arg3 param 0))))
|
||||
(set! (-> self max-angle-offset) f0-38)
|
||||
f0-38
|
||||
)
|
||||
(set! (-> self max-angle-offset) (the-as float (-> arg3 param 0)))
|
||||
)
|
||||
((= v1-0 'blocked-side?)
|
||||
(-> self los-state)
|
||||
|
||||
+2
-8
@@ -10,10 +10,7 @@
|
||||
(set! (-> (&-> arg0 0 data arg4) 0) (-> s4-0 x))
|
||||
(set! (-> (&-> arg0 0 data arg4) 4) (-> s4-0 y))
|
||||
(set! (-> (&-> arg0 0 data arg4) 8) (-> s4-0 z))
|
||||
(let ((f0-5 (-> s4-0 w)))
|
||||
(set! (-> (&-> arg0 0 data arg4) 12) f0-5)
|
||||
f0-5
|
||||
)
|
||||
(set! (-> (&-> arg0 0 data arg4) 12) (-> s4-0 w))
|
||||
)
|
||||
)
|
||||
|
||||
@@ -22,10 +19,7 @@
|
||||
(set! (-> arg0 x) arg1)
|
||||
(set! (-> arg0 y) arg2)
|
||||
(set! (-> arg0 z) arg3)
|
||||
(let ((f0-3 1.0))
|
||||
(set! (-> arg0 w) f0-3)
|
||||
f0-3
|
||||
)
|
||||
(set! (-> arg0 w) 1.0)
|
||||
)
|
||||
|
||||
;; definition for function update-view-planes
|
||||
|
||||
+88
-199
@@ -4281,12 +4281,9 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *setting-control* (nonzero? *setting-control*))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *setting-control* user-default sfx-volume) f0-0)
|
||||
f0-0
|
||||
(if (and *setting-control* (nonzero? *setting-control*))
|
||||
(set! (-> *setting-control* user-default sfx-volume) arg2)
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *setting-control*) (zero? *setting-control*))
|
||||
0.0
|
||||
@@ -4309,12 +4306,9 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *setting-control* (nonzero? *setting-control*))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *setting-control* user-default ambient-volume) f0-0)
|
||||
f0-0
|
||||
(if (and *setting-control* (nonzero? *setting-control*))
|
||||
(set! (-> *setting-control* user-default ambient-volume) arg2)
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *setting-control*) (zero? *setting-control*))
|
||||
0.0
|
||||
@@ -4337,12 +4331,9 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *setting-control* (nonzero? *setting-control*))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *setting-control* user-default music-volume) f0-0)
|
||||
f0-0
|
||||
(if (and *setting-control* (nonzero? *setting-control*))
|
||||
(set! (-> *setting-control* user-default music-volume) arg2)
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *setting-control*) (zero? *setting-control*))
|
||||
0.0
|
||||
@@ -4365,12 +4356,9 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *setting-control* (nonzero? *setting-control*))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *setting-control* user-default dialog-volume) f0-0)
|
||||
f0-0
|
||||
(if (and *setting-control* (nonzero? *setting-control*))
|
||||
(set! (-> *setting-control* user-default dialog-volume) arg2)
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *setting-control*) (zero? *setting-control*))
|
||||
0.0
|
||||
@@ -5519,12 +5507,9 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *mood-control* (nonzero? *mood-control*))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *mood-control* overide cloud) f0-0)
|
||||
f0-0
|
||||
(if (and *mood-control* (nonzero? *mood-control*))
|
||||
(set! (-> *mood-control* overide cloud) arg2)
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *mood-control*) (zero? *mood-control*))
|
||||
0.0
|
||||
@@ -5547,12 +5532,9 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *mood-control* (nonzero? *mood-control*))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *mood-control* overide fog) f0-0)
|
||||
f0-0
|
||||
(if (and *mood-control* (nonzero? *mood-control*))
|
||||
(set! (-> *mood-control* overide fog) arg2)
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *mood-control*) (zero? *mood-control*))
|
||||
0.0
|
||||
@@ -5587,19 +5569,16 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *overide-mood-color-table* (nonzero? *overide-mood-color-table*))
|
||||
(let ((f0-0 arg2))
|
||||
(if (and *overide-mood-color-table* (nonzero? *overide-mood-color-table*))
|
||||
(set! (-> *overide-mood-color-table*
|
||||
data
|
||||
(logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2))
|
||||
amb-color
|
||||
x
|
||||
)
|
||||
f0-0
|
||||
arg2
|
||||
)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *overide-mood-color-table*) (zero? *overide-mood-color-table*))
|
||||
0.0
|
||||
@@ -5627,19 +5606,16 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *overide-mood-color-table* (nonzero? *overide-mood-color-table*))
|
||||
(let ((f0-0 arg2))
|
||||
(if (and *overide-mood-color-table* (nonzero? *overide-mood-color-table*))
|
||||
(set! (-> *overide-mood-color-table*
|
||||
data
|
||||
(logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2))
|
||||
amb-color
|
||||
y
|
||||
)
|
||||
f0-0
|
||||
arg2
|
||||
)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *overide-mood-color-table*) (zero? *overide-mood-color-table*))
|
||||
0.0
|
||||
@@ -5667,19 +5643,16 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *overide-mood-color-table* (nonzero? *overide-mood-color-table*))
|
||||
(let ((f0-0 arg2))
|
||||
(if (and *overide-mood-color-table* (nonzero? *overide-mood-color-table*))
|
||||
(set! (-> *overide-mood-color-table*
|
||||
data
|
||||
(logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2))
|
||||
amb-color
|
||||
z
|
||||
)
|
||||
f0-0
|
||||
arg2
|
||||
)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *overide-mood-color-table*) (zero? *overide-mood-color-table*))
|
||||
0.0
|
||||
@@ -5707,19 +5680,16 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *overide-mood-color-table* (nonzero? *overide-mood-color-table*))
|
||||
(let ((f0-0 arg2))
|
||||
(if (and *overide-mood-color-table* (nonzero? *overide-mood-color-table*))
|
||||
(set! (-> *overide-mood-color-table*
|
||||
data
|
||||
(logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2))
|
||||
amb-color
|
||||
w
|
||||
)
|
||||
f0-0
|
||||
arg2
|
||||
)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *overide-mood-color-table*) (zero? *overide-mood-color-table*))
|
||||
0.0
|
||||
@@ -5747,19 +5717,16 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *overide-mood-color-table* (nonzero? *overide-mood-color-table*))
|
||||
(let ((f0-0 arg2))
|
||||
(if (and *overide-mood-color-table* (nonzero? *overide-mood-color-table*))
|
||||
(set! (-> *overide-mood-color-table*
|
||||
data
|
||||
(logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2))
|
||||
lgt-color
|
||||
x
|
||||
)
|
||||
f0-0
|
||||
arg2
|
||||
)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *overide-mood-color-table*) (zero? *overide-mood-color-table*))
|
||||
0.0
|
||||
@@ -5787,19 +5754,16 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *overide-mood-color-table* (nonzero? *overide-mood-color-table*))
|
||||
(let ((f0-0 arg2))
|
||||
(if (and *overide-mood-color-table* (nonzero? *overide-mood-color-table*))
|
||||
(set! (-> *overide-mood-color-table*
|
||||
data
|
||||
(logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2))
|
||||
lgt-color
|
||||
y
|
||||
)
|
||||
f0-0
|
||||
arg2
|
||||
)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *overide-mood-color-table*) (zero? *overide-mood-color-table*))
|
||||
0.0
|
||||
@@ -5827,19 +5791,16 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *overide-mood-color-table* (nonzero? *overide-mood-color-table*))
|
||||
(let ((f0-0 arg2))
|
||||
(if (and *overide-mood-color-table* (nonzero? *overide-mood-color-table*))
|
||||
(set! (-> *overide-mood-color-table*
|
||||
data
|
||||
(logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2))
|
||||
lgt-color
|
||||
z
|
||||
)
|
||||
f0-0
|
||||
arg2
|
||||
)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *overide-mood-color-table*) (zero? *overide-mood-color-table*))
|
||||
0.0
|
||||
@@ -5867,19 +5828,16 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *overide-mood-color-table* (nonzero? *overide-mood-color-table*))
|
||||
(let ((f0-0 arg2))
|
||||
(if (and *overide-mood-color-table* (nonzero? *overide-mood-color-table*))
|
||||
(set! (-> *overide-mood-color-table*
|
||||
data
|
||||
(logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2))
|
||||
lgt-color
|
||||
w
|
||||
)
|
||||
f0-0
|
||||
arg2
|
||||
)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *overide-mood-color-table*) (zero? *overide-mood-color-table*))
|
||||
0.0
|
||||
@@ -5931,17 +5889,14 @@
|
||||
)
|
||||
1.0
|
||||
)
|
||||
(let ((f0-1 1.0))
|
||||
(set! (-> *overide-mood-color-table*
|
||||
data
|
||||
(logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2))
|
||||
amb-color
|
||||
w
|
||||
)
|
||||
f0-1
|
||||
)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> *overide-mood-color-table*
|
||||
data
|
||||
(logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2))
|
||||
amb-color
|
||||
w
|
||||
)
|
||||
1.0
|
||||
)
|
||||
)
|
||||
)
|
||||
(function
|
||||
@@ -5978,19 +5933,16 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *overide-mood-fog-table* (nonzero? *overide-mood-fog-table*))
|
||||
(let ((f0-0 arg2))
|
||||
(if (and *overide-mood-fog-table* (nonzero? *overide-mood-fog-table*))
|
||||
(set! (-> *overide-mood-fog-table*
|
||||
data
|
||||
(the-as uint (logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2)))
|
||||
fog-color
|
||||
x
|
||||
)
|
||||
f0-0
|
||||
arg2
|
||||
)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *overide-mood-fog-table*) (zero? *overide-mood-fog-table*))
|
||||
0.0
|
||||
@@ -6018,19 +5970,16 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *overide-mood-fog-table* (nonzero? *overide-mood-fog-table*))
|
||||
(let ((f0-0 arg2))
|
||||
(if (and *overide-mood-fog-table* (nonzero? *overide-mood-fog-table*))
|
||||
(set! (-> *overide-mood-fog-table*
|
||||
data
|
||||
(the-as uint (logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2)))
|
||||
fog-color
|
||||
y
|
||||
)
|
||||
f0-0
|
||||
arg2
|
||||
)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *overide-mood-fog-table*) (zero? *overide-mood-fog-table*))
|
||||
0.0
|
||||
@@ -6058,19 +6007,16 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *overide-mood-fog-table* (nonzero? *overide-mood-fog-table*))
|
||||
(let ((f0-0 arg2))
|
||||
(if (and *overide-mood-fog-table* (nonzero? *overide-mood-fog-table*))
|
||||
(set! (-> *overide-mood-fog-table*
|
||||
data
|
||||
(the-as uint (logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2)))
|
||||
fog-color
|
||||
z
|
||||
)
|
||||
f0-0
|
||||
arg2
|
||||
)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *overide-mood-fog-table*) (zero? *overide-mood-fog-table*))
|
||||
0.0
|
||||
@@ -6098,19 +6044,16 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *overide-mood-fog-table* (nonzero? *overide-mood-fog-table*))
|
||||
(let ((f0-0 arg2))
|
||||
(if (and *overide-mood-fog-table* (nonzero? *overide-mood-fog-table*))
|
||||
(set! (-> *overide-mood-fog-table*
|
||||
data
|
||||
(the-as uint (logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2)))
|
||||
fog-color
|
||||
w
|
||||
)
|
||||
f0-0
|
||||
arg2
|
||||
)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *overide-mood-fog-table*) (zero? *overide-mood-fog-table*))
|
||||
0.0
|
||||
@@ -6138,19 +6081,16 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *overide-mood-fog-table* (nonzero? *overide-mood-fog-table*))
|
||||
(let ((f0-0 arg2))
|
||||
(if (and *overide-mood-fog-table* (nonzero? *overide-mood-fog-table*))
|
||||
(set! (-> *overide-mood-fog-table*
|
||||
data
|
||||
(the-as uint (logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2)))
|
||||
fog-dists
|
||||
x
|
||||
)
|
||||
f0-0
|
||||
arg2
|
||||
)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *overide-mood-fog-table*) (zero? *overide-mood-fog-table*))
|
||||
0.0
|
||||
@@ -6178,19 +6118,16 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *overide-mood-fog-table* (nonzero? *overide-mood-fog-table*))
|
||||
(let ((f0-0 arg2))
|
||||
(if (and *overide-mood-fog-table* (nonzero? *overide-mood-fog-table*))
|
||||
(set! (-> *overide-mood-fog-table*
|
||||
data
|
||||
(the-as uint (logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2)))
|
||||
fog-dists
|
||||
y
|
||||
)
|
||||
f0-0
|
||||
arg2
|
||||
)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *overide-mood-fog-table*) (zero? *overide-mood-fog-table*))
|
||||
0.0
|
||||
@@ -6218,19 +6155,16 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *overide-mood-fog-table* (nonzero? *overide-mood-fog-table*))
|
||||
(let ((f0-0 arg2))
|
||||
(if (and *overide-mood-fog-table* (nonzero? *overide-mood-fog-table*))
|
||||
(set! (-> *overide-mood-fog-table*
|
||||
data
|
||||
(the-as uint (logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2)))
|
||||
fog-dists
|
||||
w
|
||||
)
|
||||
f0-0
|
||||
arg2
|
||||
)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *overide-mood-fog-table*) (zero? *overide-mood-fog-table*))
|
||||
0.0
|
||||
@@ -6258,19 +6192,16 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *overide-mood-fog-table* (nonzero? *overide-mood-fog-table*))
|
||||
(let ((f0-0 arg2))
|
||||
(if (and *overide-mood-fog-table* (nonzero? *overide-mood-fog-table*))
|
||||
(set! (-> *overide-mood-fog-table*
|
||||
data
|
||||
(the-as uint (logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2)))
|
||||
fog-dists
|
||||
z
|
||||
)
|
||||
f0-0
|
||||
arg2
|
||||
)
|
||||
f0-0
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *overide-mood-fog-table*) (zero? *overide-mood-fog-table*))
|
||||
0.0
|
||||
@@ -6337,27 +6268,21 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((f0-4
|
||||
(* 0.00024414062
|
||||
(-> *overide-mood-fog-table*
|
||||
data
|
||||
(the-as uint (logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2)))
|
||||
fog-dists
|
||||
y
|
||||
)
|
||||
)
|
||||
)
|
||||
(set! (-> *overide-mood-fog-table*
|
||||
data
|
||||
(the-as uint (logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2)))
|
||||
fog-dists
|
||||
y
|
||||
)
|
||||
(* 0.00024414062
|
||||
(-> *overide-mood-fog-table*
|
||||
data
|
||||
(the-as uint (logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2)))
|
||||
fog-dists
|
||||
y
|
||||
)
|
||||
)
|
||||
)
|
||||
(set! (-> *overide-mood-fog-table*
|
||||
data
|
||||
(the-as uint (logand (-> *time-of-day-context* mode) (time-of-day-palette-id unk0 unk1 unk2)))
|
||||
fog-dists
|
||||
y
|
||||
)
|
||||
f0-4
|
||||
)
|
||||
f0-4
|
||||
)
|
||||
)
|
||||
)
|
||||
(function
|
||||
@@ -6395,12 +6320,9 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *time-of-day-context* times (-> *time-of-day-context* overide-palette) x) f0-0)
|
||||
f0-0
|
||||
(if (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(set! (-> *time-of-day-context* times (-> *time-of-day-context* overide-palette) x) arg2)
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *time-of-day-context*) (zero? *time-of-day-context*))
|
||||
0.0
|
||||
@@ -6423,12 +6345,9 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *time-of-day-context* times (-> *time-of-day-context* overide-palette) y) f0-0)
|
||||
f0-0
|
||||
(if (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(set! (-> *time-of-day-context* times (-> *time-of-day-context* overide-palette) y) arg2)
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *time-of-day-context*) (zero? *time-of-day-context*))
|
||||
0.0
|
||||
@@ -6451,12 +6370,9 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *time-of-day-context* times (-> *time-of-day-context* overide-palette) z) f0-0)
|
||||
f0-0
|
||||
(if (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(set! (-> *time-of-day-context* times (-> *time-of-day-context* overide-palette) z) arg2)
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *time-of-day-context*) (zero? *time-of-day-context*))
|
||||
0.0
|
||||
@@ -6479,12 +6395,9 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *time-of-day-context* times (-> *time-of-day-context* overide-palette) w) f0-0)
|
||||
f0-0
|
||||
(if (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(set! (-> *time-of-day-context* times (-> *time-of-day-context* overide-palette) w) arg2)
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *time-of-day-context*) (zero? *time-of-day-context*))
|
||||
0.0
|
||||
@@ -6529,12 +6442,9 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *time-of-day-context* filter-color x) f0-0)
|
||||
f0-0
|
||||
(if (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(set! (-> *time-of-day-context* filter-color x) arg2)
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *time-of-day-context*) (zero? *time-of-day-context*))
|
||||
0.0
|
||||
@@ -6557,12 +6467,9 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *time-of-day-context* filter-color y) f0-0)
|
||||
f0-0
|
||||
(if (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(set! (-> *time-of-day-context* filter-color y) arg2)
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *time-of-day-context*) (zero? *time-of-day-context*))
|
||||
0.0
|
||||
@@ -6585,12 +6492,9 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *time-of-day-context* filter-color z) f0-0)
|
||||
f0-0
|
||||
(if (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(set! (-> *time-of-day-context* filter-color z) arg2)
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *time-of-day-context*) (zero? *time-of-day-context*))
|
||||
0.0
|
||||
@@ -6613,12 +6517,9 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *time-of-day-context* filter-color w) f0-0)
|
||||
f0-0
|
||||
(if (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(set! (-> *time-of-day-context* filter-color w) arg2)
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *time-of-day-context*) (zero? *time-of-day-context*))
|
||||
0.0
|
||||
@@ -6653,12 +6554,9 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *time-of-day-context* current-clouds cloud-min) f0-0)
|
||||
f0-0
|
||||
(if (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(set! (-> *time-of-day-context* current-clouds cloud-min) arg2)
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *time-of-day-context*) (zero? *time-of-day-context*))
|
||||
0.0
|
||||
@@ -6681,12 +6579,9 @@
|
||||
(lambda ((arg0 object) (arg1 debug-menu-msg) (arg2 float))
|
||||
(cond
|
||||
((= arg1 (debug-menu-msg press))
|
||||
(when (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(let ((f0-0 arg2))
|
||||
(set! (-> *time-of-day-context* current-clouds cloud-max) f0-0)
|
||||
f0-0
|
||||
(if (and *time-of-day-context* (nonzero? *time-of-day-context*))
|
||||
(set! (-> *time-of-day-context* current-clouds cloud-max) arg2)
|
||||
)
|
||||
)
|
||||
)
|
||||
((or (not *time-of-day-context*) (zero? *time-of-day-context*))
|
||||
0.0
|
||||
@@ -6708,10 +6603,7 @@
|
||||
#f
|
||||
(lambda ()
|
||||
(set! (-> *time-of-day-context* current-clouds cloud-min) (-> *mood-control* mood-clouds cloud-min))
|
||||
(let ((f0-1 (-> *mood-control* mood-clouds cloud-max)))
|
||||
(set! (-> *time-of-day-context* current-clouds cloud-max) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> *time-of-day-context* current-clouds cloud-max) (-> *mood-control* mood-clouds cloud-max))
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -6740,10 +6632,7 @@
|
||||
)
|
||||
(set-vector! (-> *time-of-day-context* filter-color) 1.0 1.0 1.0 1.0)
|
||||
(set! (-> *time-of-day-context* current-clouds cloud-min) (-> *mood-control* mood-clouds cloud-min))
|
||||
(let ((f0-16 (-> *mood-control* mood-clouds cloud-max)))
|
||||
(set! (-> *time-of-day-context* current-clouds cloud-max) f0-16)
|
||||
f0-16
|
||||
)
|
||||
(set! (-> *time-of-day-context* current-clouds cloud-max) (-> *mood-control* mood-clouds cloud-max))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+43
-115
@@ -1073,11 +1073,8 @@
|
||||
(defun set-sewer-turret-flash! ()
|
||||
(let ((v1-1 (level-get *level* 'sewerb)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (the-as sewer-states (-> v1-1 mood-context state)))
|
||||
(f0-0 1.0)
|
||||
)
|
||||
(set! (-> v1-2 turret-value) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (the-as sewer-states (-> v1-1 mood-context state))))
|
||||
(set! (-> v1-2 turret-value) 1.0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1087,11 +1084,8 @@
|
||||
(defun set-sewesc-explosion! ()
|
||||
(let ((v1-1 (level-get *level* 'sewescb)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (the-as sewer-states (-> v1-1 mood-context state)))
|
||||
(f0-0 1.9921875)
|
||||
)
|
||||
(set! (-> v1-2 explosion) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (the-as sewer-states (-> v1-1 mood-context state))))
|
||||
(set! (-> v1-2 explosion) 1.9921875)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1484,11 +1478,8 @@
|
||||
|
||||
;; definition for function init-mood-tombc
|
||||
(defun init-mood-tombc ((arg0 mood-context))
|
||||
(let ((v1-0 (the-as tombc-states (-> arg0 state)))
|
||||
(f0-0 1.0)
|
||||
)
|
||||
(set! (-> v1-0 electricity scale) f0-0)
|
||||
f0-0
|
||||
(let ((v1-0 (the-as tombc-states (-> arg0 state))))
|
||||
(set! (-> v1-0 electricity scale) 1.0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -1518,11 +1509,8 @@
|
||||
(defun set-tombc-electricity-scale! ((arg0 float))
|
||||
(let ((v1-1 (level-get *level* 'tombc)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (the-as tombc-states (-> v1-1 mood-context state)))
|
||||
(f0-0 arg0)
|
||||
)
|
||||
(set! (-> v1-2 electricity scale) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (the-as tombc-states (-> v1-1 mood-context state))))
|
||||
(set! (-> v1-2 electricity scale) arg0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1842,11 +1830,8 @@
|
||||
(defun set-tombboss-gem-light! ((arg0 float))
|
||||
(let ((v1-1 (level-get *level* 'tombboss)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (the-as tombboss-states (-> v1-1 mood-context state)))
|
||||
(f0-0 arg0)
|
||||
)
|
||||
(set! (-> v1-2 gem-light) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (the-as tombboss-states (-> v1-1 mood-context state))))
|
||||
(set! (-> v1-2 gem-light) arg0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1965,11 +1950,8 @@
|
||||
|
||||
;; definition for function init-mood-fordumpa
|
||||
(defun init-mood-fordumpa ((arg0 mood-context))
|
||||
(let ((v1-0 (the-as fordumpa-states (-> arg0 state)))
|
||||
(f0-0 0.0)
|
||||
)
|
||||
(set! (-> v1-0 electricity scale) f0-0)
|
||||
f0-0
|
||||
(let ((v1-0 (the-as fordumpa-states (-> arg0 state))))
|
||||
(set! (-> v1-0 electricity scale) 0.0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -2008,11 +1990,8 @@
|
||||
(defun set-fordumpa-turret-flash! ((arg0 int))
|
||||
(let ((v1-1 (level-get *level* 'fordumpa)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (the-as fordumpa-states (-> v1-1 mood-context state)))
|
||||
(f0-0 1.0)
|
||||
)
|
||||
(set! (-> v1-2 turret-value arg0) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (the-as fordumpa-states (-> v1-1 mood-context state))))
|
||||
(set! (-> v1-2 turret-value arg0) 1.0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -2022,11 +2001,8 @@
|
||||
(defun set-fordumpa-electricity-scale! ((arg0 float))
|
||||
(let ((v1-1 (level-get *level* 'fordumpa)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (the-as fordumpa-states (-> v1-1 mood-context state)))
|
||||
(f0-0 arg0)
|
||||
)
|
||||
(set! (-> v1-2 electricity scale) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (the-as fordumpa-states (-> v1-1 mood-context state))))
|
||||
(set! (-> v1-2 electricity scale) arg0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -2131,10 +2107,7 @@
|
||||
(defun init-mood-forresca ((arg0 mood-context))
|
||||
(let ((v1-0 (the-as forresca-states (-> arg0 state))))
|
||||
(set! (-> v1-0 electricity 0 scale) 1.0)
|
||||
(let ((f0-1 1.0))
|
||||
(set! (-> v1-0 electricity 1 scale) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> v1-0 electricity 1 scale) 1.0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -2163,11 +2136,8 @@
|
||||
(defun set-forresca-electricity-scale! ((arg0 float) (arg1 int))
|
||||
(let ((v1-1 (level-get *level* 'forresca)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state)))
|
||||
(f0-0 arg0)
|
||||
)
|
||||
(set! (-> (the-as forresca-states v1-2) electricity arg1 scale) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state))))
|
||||
(set! (-> (the-as forresca-states v1-2) electricity arg1 scale) arg0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -2200,10 +2170,7 @@
|
||||
(defun init-mood-forrescb ((arg0 mood-context))
|
||||
(let ((v1-0 (the-as forrescb-states (-> arg0 state))))
|
||||
(set! (-> v1-0 electricity 0 scale) 1.0)
|
||||
(let ((f0-1 1.0))
|
||||
(set! (-> v1-0 electricity 1 scale) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> v1-0 electricity 1 scale) 1.0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -2242,11 +2209,8 @@
|
||||
(defun set-forrescb-turret-flash! ((arg0 int))
|
||||
(let ((v1-1 (level-get *level* 'forrescb)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (-> v1-1 mood-context state))
|
||||
(f0-0 1.0)
|
||||
)
|
||||
(set! (-> (the-as forrescb-states (+ (* arg0 4) (the-as int v1-2))) turret 0) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (-> v1-1 mood-context state)))
|
||||
(set! (-> (the-as forrescb-states (+ (* arg0 4) (the-as int v1-2))) turret 0) 1.0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -2256,11 +2220,8 @@
|
||||
(defun set-forrescb-electricity-scale! ((arg0 float) (arg1 int))
|
||||
(let ((v1-1 (level-get *level* 'forrescb)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state)))
|
||||
(f0-0 arg0)
|
||||
)
|
||||
(set! (-> (the-as forrescb-states v1-2) electricity arg1 scale) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state))))
|
||||
(set! (-> (the-as forrescb-states v1-2) electricity arg1 scale) arg0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -2309,10 +2270,7 @@
|
||||
(defun init-mood-prison ((arg0 mood-context))
|
||||
(let ((v1-0 (the-as prison-states (-> arg0 state))))
|
||||
(set! (-> v1-0 torture-flag) #f)
|
||||
(let ((f0-0 0.0))
|
||||
(set! (-> v1-0 torture) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> v1-0 torture) 0.0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -2527,10 +2485,7 @@
|
||||
(set! (-> gp-1 dir0 extra x) 0.5)
|
||||
(set! (-> gp-1 dir1 extra x) 0.0)
|
||||
(set! (-> gp-1 dir2 extra x) 0.0)
|
||||
(let ((f0-90 0.5))
|
||||
(set! (-> gp-1 ambi extra x) f0-90)
|
||||
f0-90
|
||||
)
|
||||
(set! (-> gp-1 ambi extra x) 0.5)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -2596,11 +2551,8 @@
|
||||
)
|
||||
(let ((v1-4 (level-get *level* 'underb)))
|
||||
(when v1-4
|
||||
(let ((v1-5 (the-as object (-> v1-4 mood-context state)))
|
||||
(f0-1 arg0)
|
||||
)
|
||||
(set! (-> (the-as under-states v1-5) laser) f0-1)
|
||||
f0-1
|
||||
(let ((v1-5 (the-as object (-> v1-4 mood-context state))))
|
||||
(set! (-> (the-as under-states v1-5) laser) arg0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -2617,11 +2569,8 @@
|
||||
)
|
||||
(let ((v1-4 (level-get *level* 'underb)))
|
||||
(when v1-4
|
||||
(let ((v1-5 (the-as object (-> v1-4 mood-context state)))
|
||||
(f0-1 arg0)
|
||||
)
|
||||
(set! (-> (the-as under-states v1-5) fog-interp) f0-1)
|
||||
f0-1
|
||||
(let ((v1-5 (the-as object (-> v1-4 mood-context state))))
|
||||
(set! (-> (the-as under-states v1-5) fog-interp) arg0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -2712,11 +2661,8 @@
|
||||
|
||||
;; definition for function init-mood-dig1
|
||||
(defun init-mood-dig1 ((arg0 mood-context))
|
||||
(let ((v1-0 (the-as object (-> arg0 state)))
|
||||
(f0-0 0.0)
|
||||
)
|
||||
(set! (-> (the-as dig1-states v1-0) explosion) f0-0)
|
||||
f0-0
|
||||
(let ((v1-0 (the-as object (-> arg0 state))))
|
||||
(set! (-> (the-as dig1-states v1-0) explosion) 0.0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -2935,11 +2881,8 @@
|
||||
(defun set-dig1-explosion! ((arg0 float))
|
||||
(let ((v1-1 (level-get *level* 'dig1)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state)))
|
||||
(f0-0 1.9921875)
|
||||
)
|
||||
(set! (-> (the-as dig1-states v1-2) explosion) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state))))
|
||||
(set! (-> (the-as dig1-states v1-2) explosion) 1.9921875)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -3103,11 +3046,8 @@
|
||||
)
|
||||
(let ((v1-4 (level-get *level* 'lintcstb)))
|
||||
(when v1-4
|
||||
(let ((v1-5 (the-as object (-> v1-4 mood-context state)))
|
||||
(f0-1 1.0)
|
||||
)
|
||||
(set! (-> (the-as vortex-states v1-5) flash) f0-1)
|
||||
f0-1
|
||||
(let ((v1-5 (the-as object (-> v1-4 mood-context state))))
|
||||
(set! (-> (the-as vortex-states v1-5) flash) 1.0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -3127,10 +3067,7 @@
|
||||
(when v1-4
|
||||
(let ((v1-5 (the-as vortex-states (-> v1-4 mood-context state))))
|
||||
(set! (-> v1-5 white) arg0)
|
||||
(let ((f0-1 0.0))
|
||||
(set! (-> v1-5 white-count) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> v1-5 white-count) 0.0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -3215,11 +3152,8 @@
|
||||
(defun set-nestb-purple! ((arg0 float))
|
||||
(let ((v1-1 (level-get *level* 'nestb)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state)))
|
||||
(f0-0 arg0)
|
||||
)
|
||||
(set! (-> (the-as nestb-states v1-2) purple) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state))))
|
||||
(set! (-> (the-as nestb-states v1-2) purple) arg0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -3438,11 +3372,8 @@
|
||||
|
||||
;; definition for function init-mood-castle
|
||||
(defun init-mood-castle ((arg0 mood-context))
|
||||
(let ((v1-0 (the-as object (-> arg0 state)))
|
||||
(f0-0 1.0)
|
||||
)
|
||||
(set! (-> (the-as castle-states v1-0) electricity scale) f0-0)
|
||||
f0-0
|
||||
(let ((v1-0 (the-as object (-> arg0 state))))
|
||||
(set! (-> (the-as castle-states v1-0) electricity scale) 1.0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -3484,11 +3415,8 @@
|
||||
(defun set-castle-electricity-scale! ((arg0 float))
|
||||
(let ((v1-1 (level-get *level* 'castle)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state)))
|
||||
(f0-0 arg0)
|
||||
)
|
||||
(set! (-> (the-as castle-states v1-2) electricity scale) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state))))
|
||||
(set! (-> (the-as castle-states v1-2) electricity scale) arg0)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+24
-66
@@ -334,10 +334,7 @@
|
||||
(set! (-> gp-0 spec-1) (get-field-spec-by-id a0-2 (sp-field-id spt-a)))
|
||||
)
|
||||
)
|
||||
(let ((f0-0 (rand-vu-float-range 0.8 1.0)))
|
||||
(set! (-> gp-0 neon-min-bright) f0-0)
|
||||
f0-0
|
||||
)
|
||||
(set! (-> gp-0 neon-min-bright) (rand-vu-float-range 0.8 1.0))
|
||||
)
|
||||
)
|
||||
|
||||
@@ -726,11 +723,8 @@
|
||||
|
||||
;; definition for function init-mood-palcab
|
||||
(defun init-mood-palcab ((arg0 mood-context))
|
||||
(let ((v1-0 (the-as object (-> arg0 state)))
|
||||
(f0-0 1.0)
|
||||
)
|
||||
(set! (-> (the-as palcab-states v1-0) electricity scale) f0-0)
|
||||
f0-0
|
||||
(let ((v1-0 (the-as object (-> arg0 state))))
|
||||
(set! (-> (the-as palcab-states v1-0) electricity scale) 1.0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -767,11 +761,8 @@
|
||||
(defun set-palcab-turret-flash! ((arg0 float))
|
||||
(let ((v1-1 (level-get *level* 'palcab)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state)))
|
||||
(f0-0 arg0)
|
||||
)
|
||||
(set! (-> (the-as palcab-states v1-2) turret-value) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state))))
|
||||
(set! (-> (the-as palcab-states v1-2) turret-value) arg0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1207,11 +1198,8 @@
|
||||
|
||||
;; definition for function init-mood-atoll
|
||||
(defun init-mood-atoll ((arg0 mood-context))
|
||||
(let ((v1-0 (the-as object (-> arg0 state)))
|
||||
(f0-0 0.0)
|
||||
)
|
||||
(set! (-> (the-as atoll-states v1-0) explosion) f0-0)
|
||||
f0-0
|
||||
(let ((v1-0 (the-as object (-> arg0 state))))
|
||||
(set! (-> (the-as atoll-states v1-0) explosion) 0.0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -1238,11 +1226,8 @@
|
||||
(defun set-atoll-explosion! ((arg0 float))
|
||||
(let ((v1-1 (level-get *level* 'atoll)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state)))
|
||||
(f0-0 arg0)
|
||||
)
|
||||
(set! (-> (the-as atoll-states v1-2) explosion) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state))))
|
||||
(set! (-> (the-as atoll-states v1-2) explosion) arg0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1415,11 +1400,8 @@
|
||||
)
|
||||
(let ((v1-5 (level-get *level* 'drillmid)))
|
||||
(when v1-5
|
||||
(let ((v1-6 (the-as object (-> v1-5 mood-context state)))
|
||||
(f0-1 arg0)
|
||||
)
|
||||
(set! (-> (the-as drill-states v1-6) electricity arg1 scale) f0-1)
|
||||
f0-1
|
||||
(let ((v1-6 (the-as object (-> v1-5 mood-context state))))
|
||||
(set! (-> (the-as drill-states v1-6) electricity arg1 scale) arg0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1576,10 +1558,7 @@
|
||||
(set-vector! (-> gp-0 ambi color) 0.2 0.2 0.25 1.0)
|
||||
(set! (-> gp-0 dir0 extra x) 0.65)
|
||||
(set! (-> gp-0 dir1 extra x) 1.0)
|
||||
(let ((f0-38 0.7))
|
||||
(set! (-> gp-0 ambi extra x) f0-38)
|
||||
f0-38
|
||||
)
|
||||
(set! (-> gp-0 ambi extra x) 0.7)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -1608,11 +1587,8 @@
|
||||
(defun set-casboss-explosion! ()
|
||||
(let ((v1-1 (level-get *level* 'ctywide)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state)))
|
||||
(f0-0 1.0)
|
||||
)
|
||||
(set! (-> (the-as casboss-states v1-2) explosion) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state))))
|
||||
(set! (-> (the-as casboss-states v1-2) explosion) 1.0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1758,10 +1734,7 @@
|
||||
(defun init-mood-palroof ((arg0 mood-context))
|
||||
(let ((v1-0 (the-as palroof-states (-> arg0 state))))
|
||||
(set! (-> v1-0 electricity 0 scale) 1.0)
|
||||
(let ((f0-1 1.0))
|
||||
(set! (-> v1-0 electricity 1 scale) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> v1-0 electricity 1 scale) 1.0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -1785,11 +1758,8 @@
|
||||
(defun set-palroof-electricity-scale! ((arg0 float) (arg1 int))
|
||||
(let ((v1-1 (level-get *level* 'palroof)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state)))
|
||||
(f0-0 arg0)
|
||||
)
|
||||
(set! (-> (the-as palroof-states v1-2) electricity arg1 scale) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state))))
|
||||
(set! (-> (the-as palroof-states v1-2) electricity arg1 scale) arg0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1842,11 +1812,8 @@
|
||||
(defun set-palent-turret-flash! ((arg0 float))
|
||||
(let ((v1-1 (level-get *level* 'palent)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state)))
|
||||
(f0-1 (* 0.5 arg0))
|
||||
)
|
||||
(set! (-> (the-as palent-states v1-2) turret-value) f0-1)
|
||||
f0-1
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state))))
|
||||
(set! (-> (the-as palent-states v1-2) turret-value) (* 0.5 arg0))
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1971,10 +1938,7 @@
|
||||
(set! (-> v1-0 0 dir0 extra x) (* 0.5 (-> v1-0 0 dir0 extra x)))
|
||||
(set! (-> v1-0 0 dir1 extra x) (* 0.5 (-> v1-0 0 dir1 extra x)))
|
||||
(set! (-> v1-0 0 dir2 extra x) (* 0.5 (-> v1-0 0 dir2 extra x)))
|
||||
(let ((f0-7 (* 0.75 (-> v1-0 0 ambi extra x))))
|
||||
(set! (-> v1-0 0 ambi extra x) f0-7)
|
||||
f0-7
|
||||
)
|
||||
(set! (-> v1-0 0 ambi extra x) (* 0.75 (-> v1-0 0 ambi extra x)))
|
||||
)
|
||||
)
|
||||
|
||||
@@ -2106,11 +2070,8 @@
|
||||
(defun set-consite-flash! ()
|
||||
(let ((v1-1 (level-get *level* 'consite)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state)))
|
||||
(f0-0 2.0)
|
||||
)
|
||||
(set! (-> (the-as consite-states v1-2) flash) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (the-as object (-> v1-1 mood-context state))))
|
||||
(set! (-> (the-as consite-states v1-2) flash) 2.0)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -2157,11 +2118,8 @@
|
||||
(defun set-mincan-beam! ((arg0 int) (arg1 float))
|
||||
(let ((v1-1 (level-get *level* 'mincan)))
|
||||
(when v1-1
|
||||
(let ((v1-2 (-> v1-1 mood-context state))
|
||||
(f0-0 arg1)
|
||||
)
|
||||
(set! (-> (the-as mincan-states (+ (* arg0 4) (the-as int v1-2))) beams 0) f0-0)
|
||||
f0-0
|
||||
(let ((v1-2 (-> v1-1 mood-context state)))
|
||||
(set! (-> (the-as mincan-states (+ (* arg0 4) (the-as int v1-2))) beams 0) arg1)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+21
-50
@@ -624,10 +624,7 @@
|
||||
(set! (-> v1-0 0 dir0 extra x) 1.0)
|
||||
(set! (-> v1-0 0 dir1 extra x) 0.0)
|
||||
(set! (-> v1-0 0 dir2 extra x) 0.0)
|
||||
(let ((f0-35 1.0))
|
||||
(set! (-> v1-0 0 ambi extra x) f0-35)
|
||||
f0-35
|
||||
)
|
||||
(set! (-> v1-0 0 ambi extra x) 1.0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -676,27 +673,20 @@
|
||||
(set! (-> gp-0 time) 0.0)
|
||||
(set! (-> gp-0 length) (the-as uint (the int (* (rand-vu-float-range 7.0 15.0) arg6))))
|
||||
(set! (-> gp-0 height) (the-as uint (the int (rand-vu-float-range 0.0 255.0))))
|
||||
(let ((f0-11 arg4))
|
||||
(set! (-> arg0 times s4-0 w) f0-11)
|
||||
f0-11
|
||||
)
|
||||
(set! (-> arg0 times s4-0 w) arg4)
|
||||
)
|
||||
(else
|
||||
(let ((f0-14 (sin (* 32768.0 (/ f0-0 (the float v1-2))))))
|
||||
(set! (-> arg0 times s4-0 w) (+ (* (the float s0-0) f0-14 arg5) arg4))
|
||||
)
|
||||
(when (not (paused?))
|
||||
(let ((f0-19 (+ (-> gp-0 time) (if (= (-> *display* bg-clock clock-ratio) 0.0)
|
||||
1.0
|
||||
(-> self clock time-adjust-ratio)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(set! (-> gp-0 time) f0-19)
|
||||
f0-19
|
||||
(if (not (paused?))
|
||||
(set! (-> gp-0 time) (+ (-> gp-0 time) (if (= (-> *display* bg-clock clock-ratio) 0.0)
|
||||
1.0
|
||||
(-> self clock time-adjust-ratio)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -868,10 +858,7 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((f0-16 (+ f0-15 arg7)))
|
||||
(set! (-> gp-0 time) f0-16)
|
||||
f0-16
|
||||
)
|
||||
(set! (-> gp-0 time) (+ f0-15 arg7))
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -907,12 +894,9 @@
|
||||
(set! (-> arg0 times arg1 w) (+ arg3 (* f0-1 arg4)))
|
||||
(set! (-> arg0 times (+ arg1 1) w) (+ arg3 (* (- f0-1) arg4)))
|
||||
)
|
||||
(when (not (paused?))
|
||||
(let ((f0-6 (+ (-> gp-0 lava) arg5)))
|
||||
(set! (-> gp-0 lava) f0-6)
|
||||
f0-6
|
||||
(if (not (paused?))
|
||||
(set! (-> gp-0 lava) (+ (-> gp-0 lava) arg5))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -1010,16 +994,10 @@
|
||||
)
|
||||
(cond
|
||||
((>= (-> gp-0 delay2) (-> gp-0 delay))
|
||||
(let ((f0-5 (rand-vu-float-range 1.0 1.5)))
|
||||
(set! (-> gp-0 value) f0-5)
|
||||
f0-5
|
||||
)
|
||||
(set! (-> gp-0 value) (rand-vu-float-range 1.0 1.5))
|
||||
)
|
||||
((< (-> gp-0 delay2) (-> gp-0 delay))
|
||||
(let ((f0-6 1.5))
|
||||
(set! (-> gp-0 value) f0-6)
|
||||
f0-6
|
||||
)
|
||||
(set! (-> gp-0 value) 1.5)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1128,11 +1106,8 @@
|
||||
)
|
||||
)
|
||||
(when (not (paused?))
|
||||
(let* ((f0-5 (+ (-> gp-0 time) arg4))
|
||||
(f0-6 (- f0-5 (* (the float (the int (/ f0-5 32.0))) 32.0)))
|
||||
)
|
||||
(set! (-> gp-0 time) f0-6)
|
||||
f0-6
|
||||
(let ((f0-5 (+ (-> gp-0 time) arg4)))
|
||||
(set! (-> gp-0 time) (- f0-5 (* (the float (the int (/ f0-5 32.0))) 32.0)))
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1140,7 +1115,9 @@
|
||||
|
||||
;; definition for function update-mood-caustics
|
||||
(defun update-mood-caustics ((arg0 mood-context) (arg1 int) (arg2 float) (arg3 float) (arg4 float) (arg5 float))
|
||||
(let* ((f0-2 (sin (+ arg2 arg3))) (f0-4 (+ arg4 (* f0-2 arg5)))) (set! (-> arg0 times arg1 w) f0-4) f0-4)
|
||||
(let ((f0-2 (sin (+ arg2 arg3))))
|
||||
(set! (-> arg0 times arg1 w) (+ arg4 (* f0-2 arg5)))
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for method 13 of type mood-control
|
||||
@@ -1446,16 +1423,10 @@
|
||||
)
|
||||
)
|
||||
((and (level-get-target-inside *level*) (= (-> (level-get-target-inside *level*) name) 'nest))
|
||||
(let ((f0-11 (rand-vu-float-range 3.0 5.0)))
|
||||
(set! (-> obj lightning-time2) f0-11)
|
||||
f0-11
|
||||
)
|
||||
(set! (-> obj lightning-time2) (rand-vu-float-range 3.0 5.0))
|
||||
)
|
||||
(else
|
||||
(let ((f0-12 (rand-vu-float-range 15.0 20.0)))
|
||||
(set! (-> obj lightning-time2) f0-12)
|
||||
f0-12
|
||||
)
|
||||
(set! (-> obj lightning-time2) (rand-vu-float-range 15.0 20.0))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
Generated
Vendored
+1
-4
@@ -2839,10 +2839,7 @@
|
||||
(let ((f0-1 (+ (-> arg1 key origin trans y) (-> arg1 user-float))))
|
||||
(when (and (< (-> arg2 launchrot y) f0-1) (< (-> arg1 vel-sxvel y) 0.0))
|
||||
(set! (-> arg2 launchrot y) f0-1)
|
||||
(let ((f0-4 (* (-> arg1 vel-sxvel y) (- (rand-vu-float-range 0.6 0.8)))))
|
||||
(set! (-> arg1 vel-sxvel y) f0-4)
|
||||
f0-4
|
||||
)
|
||||
(set! (-> arg1 vel-sxvel y) (* (-> arg1 vel-sxvel y) (- (rand-vu-float-range 0.6 0.8))))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
+14
-28
@@ -42,28 +42,24 @@
|
||||
|
||||
;; definition for function num-func-+!
|
||||
(defbehavior num-func-+! process ((arg0 joint-control-channel) (arg1 float) (arg2 float) (arg3 float))
|
||||
(let ((f0-1 (+ (-> arg0 frame-num) (* arg1 (* (-> arg0 frame-group speed) (-> self clock time-adjust-ratio))))))
|
||||
(set! (-> arg0 frame-num) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> arg0 frame-num)
|
||||
(+ (-> arg0 frame-num) (* arg1 (* (-> arg0 frame-group speed) (-> self clock time-adjust-ratio))))
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for function num-func--!
|
||||
(defbehavior num-func--! process ((arg0 joint-control-channel) (arg1 float) (arg2 float) (arg3 float))
|
||||
(let ((f0-1 (- (-> arg0 frame-num) (* arg1 (* (-> arg0 frame-group speed) (-> self clock time-adjust-ratio))))))
|
||||
(set! (-> arg0 frame-num) f0-1)
|
||||
f0-1
|
||||
)
|
||||
(set! (-> arg0 frame-num)
|
||||
(- (-> arg0 frame-num) (* arg1 (* (-> arg0 frame-group speed) (-> self clock time-adjust-ratio))))
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for function num-func-loop!
|
||||
(defbehavior num-func-loop! process ((arg0 joint-control-channel) (arg1 float) (arg2 float) (arg3 float))
|
||||
(let* ((f0-1 (the float (+ (-> arg0 frame-group frames num-frames) -1)))
|
||||
(f1-2 (+ (-> arg0 frame-num) f0-1 (* arg1 (* (-> arg0 frame-group speed) (-> self clock time-adjust-ratio)))))
|
||||
(f0-3 (- f1-2 (* (the float (the int (/ f1-2 f0-1))) f0-1)))
|
||||
)
|
||||
(set! (-> arg0 frame-num) f0-3)
|
||||
f0-3
|
||||
(set! (-> arg0 frame-num) (- f1-2 (* (the float (the int (/ f1-2 f0-1))) f0-1)))
|
||||
)
|
||||
)
|
||||
|
||||
@@ -71,22 +67,16 @@
|
||||
(defbehavior num-func-loop-speedless! process ((arg0 joint-control-channel) (arg1 float) (arg2 float) (arg3 float))
|
||||
(let* ((f0-1 (the float (+ (-> arg0 frame-group frames num-frames) -1)))
|
||||
(f1-2 (+ (-> arg0 frame-num) f0-1 arg1))
|
||||
(f0-3 (- f1-2 (* (the float (the int (/ f1-2 f0-1))) f0-1)))
|
||||
)
|
||||
(set! (-> arg0 frame-num) f0-3)
|
||||
f0-3
|
||||
(set! (-> arg0 frame-num) (- f1-2 (* (the float (the int (/ f1-2 f0-1))) f0-1)))
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for function num-func-seek!
|
||||
(defbehavior num-func-seek! process ((arg0 joint-control-channel) (arg1 float) (arg2 float) (arg3 float))
|
||||
(let ((f0-3
|
||||
(seek (-> arg0 frame-num) arg1 (* arg2 (* (-> arg0 frame-group speed) (-> self clock time-adjust-ratio))))
|
||||
)
|
||||
(set! (-> arg0 frame-num)
|
||||
(seek (-> arg0 frame-num) arg1 (* arg2 (* (-> arg0 frame-group speed) (-> self clock time-adjust-ratio))))
|
||||
)
|
||||
(set! (-> arg0 frame-num) f0-3)
|
||||
f0-3
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for function num-func-blend-in!
|
||||
@@ -175,15 +165,11 @@
|
||||
|
||||
;; definition for function num-func-chan
|
||||
(defbehavior num-func-chan process ((arg0 joint-control-channel) (arg1 float) (arg2 float) (arg3 float))
|
||||
(let ((f0-2
|
||||
(-> (the-as joint-control-channel (+ (the-as uint arg0) (* (- (the int arg1) (-> arg0 group-sub-index)) 64)))
|
||||
frame-num
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 frame-num)
|
||||
(-> (the-as joint-control-channel (+ (the-as uint arg0) (* (- (the int arg1) (-> arg0 group-sub-index)) 64)))
|
||||
frame-num
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 frame-num) f0-2)
|
||||
f0-2
|
||||
)
|
||||
)
|
||||
|
||||
;; definition for function num-func-identity
|
||||
|
||||
Reference in New Issue
Block a user