;;-*-Lisp-*- (in-package goal) ;; name: surface-h.gc ;; name in dgo: surface-h ;; dgos: ENGINE, GAME (declare-type target process-focusable) (define-extern rail-surface-touch (function none :behavior target)) (define-extern gravel-surface-touch (function none)) (defenum surface-flag :bitfield #t :type uint32 (look-around 0) ;; 1 (xz-local 1) ;; 2 (smooth-collision 2) ;; 4 (no-turn-around 3) ;; 8 (turn-to-pad 4) ;; 16 (turn-to-vel 5) ;; 32 (no-jump 6) ;; 64 (no-attack 7) ;; 128 (no-hands 8) ;; 256 (no-feet 9) ;; 512 (check-edge 10) ;; 1024 (air 11) ;; 2048 (attack 12) ;; 4096 (duck 13) ;; 8192 (momentum 14) ;; 16384 (turn-when-centered 15) ;; 32768 (turn-to-alt 16) ;; hi 1 (spin 17) ;; hi 2 (super 18) ;; hi 4 (gun-inactive 19) ;; hi 8 (gun-hide 20) ;; hi 16 (gun-off 21) ;; hi 32 (gun-fast-exit 22) ;; hi 64 (gun-direct 23) ;; hi 128 (gun-strafe 24) ;; hi 256 (gun-no-twist 25) ;; hi 512 (laser-hide 26) ;; hi 1024 (no-board 27) ;; hi 2048 (gun-turn-fast 28) ;; hi 4096 ) (declare-type collide-shape trsqv) (declare-type collide-shape-moving collide-shape) (declare-type control-info collide-shape-moving) (declare-type surface basic) (define-extern *dark-jump-mods* surface) (define-extern *flop-land-mods* surface) (define-extern *pole-mods* surface) (define-extern *grab-mods* surface) (define-extern *edge-grab-mods* surface) (define-extern *stone-surface* surface) (define-extern *gravel-surface* surface) (define-extern *edge-surface* surface) (define-extern *wade-surface* surface) (define-extern *quicksand-surface* surface) (define-extern *tar-surface* surface) (define-extern *ice-surface* surface) (define-extern *rail-surface* surface) ;; DECOMP BEGINS (deftype surface (basic) ((name symbol :offset-assert 4) (turnv float :offset-assert 8) (turnvv float :offset-assert 12) (tiltv float :offset-assert 16) (tiltvv float :offset-assert 20) (transv-max float :offset-assert 24) (target-speed float :offset-assert 28) (seek0 float :offset-assert 32) (seek90 float :offset-assert 36) (seek180 float :offset-assert 40) (fric float :offset-assert 44) (nonlin-fric-dist float :offset-assert 48) (slip-factor float :offset-assert 52) (slide-factor float :offset-assert 56) (slope-up-factor float :offset-assert 60) (slope-down-factor float :offset-assert 64) (slope-slip-angle float :offset-assert 68) (impact-fric float :offset-assert 72) (bend-factor float :offset-assert 76) (bend-speed float :offset-assert 80) (alignv float :offset-assert 84) (slope-up-traction float :offset-assert 88) (align-speed float :offset-assert 92) (slope-change-preserve float :offset-assert 96) (turnvf float :offset-assert 100) (turnvvf float :offset-assert 104) (tiltvf float :offset-assert 108) (tiltvvf float :offset-assert 112) (vel-turn float :offset-assert 116) (active-hook (function none) :offset 128) (touch-hook (function none) :offset 132) (impact-hook (function control-info (pointer float) vector none) :offset 136) (mult-hook (function surface surface surface int none) :offset-assert 140) (exit-hook function :offset-assert 144) (mode symbol :offset-assert 148) (flags surface-flag :offset-assert 152) (data float 30 :offset 8) (hook function 4 :offset 128) (dataw uint32 2 :offset 148) ) :method-count-assert 9 :size-assert #x9c :flag-assert #x90000009c ) (defun calc-terminal-vel ((arg0 float) (arg1 float) (arg2 float)) (- (* (/ (- (* 0.016666668 arg0) arg1) arg2) (- 1.0 arg2)) arg1) ) (defun calc-terminal2-vel ((arg0 float) (arg1 float) (arg2 float) (arg3 float)) (let ((f0-4 (sqrtf (/ (- (* 0.016666668 arg0) arg1) arg2)))) (- f0-4 (+ arg1 (* arg2 (* f0-4 f0-4)))) ) ) (defun calc-terminal4-vel ((arg0 float) (arg1 float) (arg2 float)) (let ((f0-5 (sqrtf (sqrtf (/ (- (* 0.016666668 arg0) arg1) arg2))))) (- f0-5 (+ arg1 (* arg2 (* f0-5 f0-5 f0-5 f0-5)))) ) ) ;; ERROR: Function may read a register that is not set: t3 (defmethod print surface ((obj surface)) (local-vars (t3-0 none)) (format #t "# obj turnv) (-> obj turnvv) (-> obj tiltv) (-> obj tiltvv) (-> obj transv-max) t3-0 ) (format #t " tm:~m rv:~R rvv:~R @ #x~X>" (-> obj target-speed) (-> obj seek0) (-> obj seek90) obj) obj ) (defun surface-interp! ((arg0 surface) (arg1 surface) (arg2 surface) (arg3 float)) (dotimes (v1-0 30) (set! (-> arg0 data v1-0) (+ (* (-> arg2 data v1-0) arg3) (* (-> arg1 data v1-0) (- 1.0 arg3)))) ) (dotimes (v1-3 5) (set! (-> arg0 hook v1-3) (cond ((and (nonzero? (-> arg2 hook v1-3)) (!= (-> arg2 hook v1-3) nothing)) (-> arg2 hook v1-3) ) ((and (nonzero? (-> arg1 hook v1-3)) (!= (-> arg1 hook v1-3) nothing)) (-> arg1 hook v1-3) ) (else nothing ) ) ) ) (dotimes (v1-6 2) (set! (-> arg0 dataw v1-6) (-> arg2 dataw v1-6)) ) arg0 ) (defun surface-mult! ((arg0 surface) (arg1 surface) (arg2 surface)) (dotimes (v1-0 30) (set! (-> arg0 data v1-0) (* (-> arg2 data v1-0) (-> arg1 data v1-0))) ) (dotimes (v1-3 5) (set! (-> arg0 hook v1-3) (cond ((and (nonzero? (-> arg2 hook v1-3)) (!= (-> arg2 hook v1-3) nothing)) (-> arg2 hook v1-3) ) ((and (nonzero? (-> arg1 hook v1-3)) (!= (-> arg1 hook v1-3) nothing)) (-> arg1 hook v1-3) ) (else nothing ) ) ) ) (dotimes (v1-6 2) (set! (-> arg0 dataw v1-6) (-> arg2 dataw v1-6)) ) (set! (-> arg0 flags) (logior (-> arg1 flags) (-> arg2 flags))) ((-> arg0 mult-hook) arg0 arg1 arg2 1) arg0 ) ;; WARN: Return type mismatch float vs none. (defun surface-clamp-speed ((arg0 surface) (arg1 surface) (arg2 surface) (arg3 int)) (when (= arg3 1) (set! (-> arg0 transv-max) (fmin (-> arg0 transv-max) (-> arg1 transv-max))) (set! (-> arg0 target-speed) (fmin (-> arg0 target-speed) (-> arg1 target-speed))) ) (none) ) (define *walk-mods* (new 'static 'surface :name 'run :turnv 131072.0 :turnvv 524288.0 :tiltv 65536.0 :tiltvv 262144.0 :transv-max 40960.0 :target-speed 40960.0 :seek0 1.0 :seek90 1.0 :seek180 1.0 :fric 1.0 :nonlin-fric-dist 1.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 1.0 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :turnvf 30.0 :turnvvf 30.0 :tiltvf 150.0 :tiltvvf 15.0 :flags (surface-flag look-around) ) ) (define *walk-no-turn-mods* (new 'static 'surface :name 'run :tiltv 65536.0 :tiltvv 262144.0 :transv-max 40960.0 :target-speed 40960.0 :seek0 1.0 :seek90 1.0 :seek180 1.0 :fric 1.0 :nonlin-fric-dist 1.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 1.0 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :tiltvf 150.0 :tiltvvf 15.0 ) ) (define *turn-around-mods* (new 'static 'surface :name 'run :tiltv 65536.0 :tiltvv 262144.0 :transv-max 40960.0 :target-speed 40960.0 :fric 0.1 :nonlin-fric-dist 1.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 1.0 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :tiltvf 150.0 :tiltvvf 15.0 ) ) (define *jump-mods* (new 'static 'surface :name 'jump :turnv 131072.0 :turnvv 18204.445 :tiltv 32768.0 :tiltvv 262144.0 :transv-max 40960.0 :target-speed 40960.0 :seek0 0.3 :seek90 0.3 :seek180 0.3 :fric 0.2 :nonlin-fric-dist 1.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 1.0 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :turnvf 30.0 :turnvvf 30.0 :tiltvf 150.0 :tiltvvf 15.0 :mode 'air :flags (surface-flag check-edge air) ) ) (define *double-jump-mods* (new 'static 'surface :name 'jump-double :turnv 131072.0 :turnvv 18204.445 :tiltv 32768.0 :tiltvv 262144.0 :transv-max 32768.0 :target-speed 32768.0 :seek0 0.3 :seek90 0.3 :seek180 0.3 :fric 0.2 :nonlin-fric-dist 1.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 1.0 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :turnvf 30.0 :turnvvf 30.0 :tiltvf 150.0 :tiltvvf 15.0 :mode 'air :flags (surface-flag check-edge air) ) ) (define *smack-jump-mods* (new 'static 'surface :name 'jump :turnv 131072.0 :turnvv 18204.445 :tiltv 32768.0 :tiltvv 262144.0 :transv-max 40960.0 :target-speed 40960.0 :seek0 0.3 :seek90 0.3 :seek180 0.3 :fric 0.05 :nonlin-fric-dist 1.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 1.0 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :turnvf 30.0 :turnvvf 30.0 :tiltvf 150.0 :tiltvvf 15.0 :mode 'air :flags (surface-flag check-edge air gun-inactive) ) ) (define *high-jump-mods* (new 'static 'surface :name 'high-jump :turnv 131072.0 :turnvv 65536.0 :tiltv 32768.0 :tiltvv 262144.0 :transv-max 26624.0 :target-speed 26624.0 :seek0 0.9 :seek90 0.9 :seek180 0.9 :fric 0.3 :nonlin-fric-dist 1.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 1.0 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :turnvf 30.0 :turnvvf 30.0 :tiltvf 150.0 :tiltvvf 15.0 :mode 'air :flags (surface-flag check-edge air) ) ) (define *launch-jump-mods* (new 'static 'surface :name 'launch-jump :turnv 131072.0 :turnvv 65536.0 :tiltv 32768.0 :tiltvv 262144.0 :transv-max 61440.0 :target-speed 61440.0 :seek0 0.9 :seek90 0.9 :seek180 0.9 :fric 0.3 :nonlin-fric-dist 1.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 1.0 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :turnvf 30.0 :turnvvf 30.0 :tiltvf 150.0 :tiltvvf 15.0 :mode 'air :flags (surface-flag no-attack check-edge air) ) ) (define *forward-high-jump-mods* (new 'static 'surface :name 'high-jump :turnv 131072.0 :turnvv 65536.0 :tiltv 32768.0 :tiltvv 262144.0 :transv-max 45056.0 :target-speed 45056.0 :seek0 0.9 :seek90 0.9 :seek180 0.9 :fric 0.3 :nonlin-fric-dist 1.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 1.0 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :turnvf 30.0 :turnvvf 30.0 :tiltvf 150.0 :tiltvvf 15.0 :mode 'air :flags (surface-flag check-edge air) ) ) (define *flip-jump-mods* (new 'static 'surface :name 'high-jump :turnv 131072.0 :turnvv 65536.0 :tiltv 32768.0 :tiltvv 262144.0 :transv-max 80281.6 :target-speed 51200.0 :seek0 0.9 :seek90 0.9 :seek180 0.9 :fric 0.3 :nonlin-fric-dist 1.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 1.0 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :turnvf 30.0 :turnvvf 30.0 :tiltvf 150.0 :tiltvvf 15.0 :mode 'air :flags (surface-flag check-edge air) ) ) (define *forward-jump-mods* (new 'static 'surface :name 'jump :turnv 131072.0 :turnvv 18204.445 :tiltv 32768.0 :tiltvv 262144.0 :transv-max 65536.0 :target-speed 65536.0 :seek0 0.3 :seek90 0.3 :seek180 0.3 :fric 0.05 :nonlin-fric-dist 1.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 1.0 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :turnvf 30.0 :turnvvf 30.0 :tiltvf 150.0 :tiltvvf 15.0 :mode 'air :flags (surface-flag check-edge air) ) ) (define *forward-pole-jump-mods* (new 'static 'surface :name 'jump :turnv 131072.0 :turnvv 18204.445 :tiltv 32768.0 :tiltvv 262144.0 :transv-max 53248.0 :target-speed 53248.0 :seek0 0.3 :seek90 0.3 :seek180 0.3 :fric 0.05 :nonlin-fric-dist 1.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 1.0 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :turnvf 30.0 :turnvvf 30.0 :tiltvf 150.0 :tiltvvf 15.0 :mode 'air :flags (surface-flag check-edge air gun-hide gun-fast-exit) ) ) (let ((v1-20 (copy *jump-mods* 'global))) (set! (-> v1-20 flags) (surface-flag check-edge air super)) (set! (-> v1-20 name) 'high-jump) (set! (-> v1-20 target-speed) 245760.0) (set! (-> v1-20 transv-max) 245760.0) (set! (-> v1-20 seek0) 0.9) (set! *dark-jump-mods* v1-20) ) (define *roll-mods* (new 'static 'surface :name 'roll :turnv 131072.0 :turnvv 5461.3335 :tiltv 32768.0 :tiltvv 262144.0 :transv-max 91750.4 :target-speed 11468.8 :seek0 1.0 :seek90 1.0 :seek180 1.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 0.25 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :turnvf 30.0 :turnvvf 30.0 :tiltvf 150.0 :tiltvvf 15.0 :mode 'attack :flags (surface-flag no-turn-around attack gun-inactive gun-no-twist no-board) ) ) (define *roll-flip-mods* (new 'static 'surface :name 'roll-flip :tiltv 32768.0 :tiltvv 262144.0 :transv-max 91750.4 :target-speed 103219.195 :seek90 0.5 :seek180 0.15 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 0.25 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :tiltvf 150.0 :tiltvvf 15.0 :mode 'attack :flags (surface-flag no-turn-around check-edge air attack gun-inactive gun-no-twist no-board) ) ) (define *flop-mods* (new 'static 'surface :name 'flop :tiltv 32768.0 :tiltvv 262144.0 :transv-max 40960.0 :target-speed 40960.0 :seek0 1.0 :seek90 0.3 :seek180 1.5 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 0.25 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :tiltvf 150.0 :tiltvvf 15.0 :mode 'attack :flags (surface-flag air attack gun-inactive gun-no-twist) ) ) (let ((a0-9 (new 'static 'surface :name 'flop :turnv 9102.223 :turnvv 9102.223 :tiltv 32768.0 :tiltvv 262144.0 :transv-max 40960.0 :target-speed 40960.0 :seek0 0.3 :seek90 0.1 :seek180 0.15 :fric 0.2 :nonlin-fric-dist 1.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 0.25 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :turnvf 30.0 :turnvvf 30.0 :tiltvf 150.0 :tiltvvf 15.0 :mode 'air :flags (surface-flag air gun-inactive gun-no-twist) ) ) ) (set! (-> a0-9 mult-hook) surface-clamp-speed) (set! *flop-land-mods* a0-9) ) (define *wade-mods* (new 'static 'surface :name 'wade :turnv 131072.0 :turnvv 524288.0 :tiltv 65536.0 :tiltvv 262144.0 :transv-max 40960.0 :target-speed 40960.0 :seek0 1.0 :seek90 0.5 :seek180 0.5 :fric 1.0 :nonlin-fric-dist 1.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 1.0 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :turnvf 30.0 :turnvvf 30.0 :tiltvf 150.0 :tiltvvf 15.0 :mode 'wade :flags (surface-flag look-around) ) ) (define *swim-mods* (new 'static 'surface :name 'swim :turnv 49152.0 :turnvv 524288.0 :tiltv 65536.0 :tiltvv 262144.0 :transv-max 28672.0 :target-speed 28672.0 :seek0 0.75 :seek90 0.2 :seek180 0.2 :fric 0.05 :nonlin-fric-dist 1.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 1.0 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :turnvf 30.0 :turnvvf 30.0 :tiltvf 150.0 :tiltvvf 15.0 :mode 'swim :flags (surface-flag gun-off) ) ) (define *dive-mods* (new 'static 'surface :name 'swim :turnv 21845.334 :turnvv 32768.0 :tiltv 65536.0 :tiltvv 262144.0 :transv-max 20480.0 :target-speed 20480.0 :seek0 0.05 :seek90 0.05 :seek180 0.05 :fric 1.0 :nonlin-fric-dist 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :align-speed 1.0 :turnvf 30.0 :turnvvf 30.0 :tiltvf 150.0 :tiltvvf 15.0 :mode 'dive :flags (surface-flag xz-local gun-off gun-fast-exit) ) ) (define *dive-bottom-mods* (new 'static 'surface :name 'swim-bottom :turnv 21845.334 :turnvv 32768.0 :tiltv 65536.0 :tiltvv 262144.0 :transv-max 20480.0 :target-speed 20480.0 :seek0 0.1 :seek90 0.05 :seek180 0.05 :fric 1.0 :nonlin-fric-dist 1.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 1.0 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :turnvf 30.0 :turnvvf 30.0 :tiltvf 150.0 :tiltvvf 15.0 :mode 'dive :flags (surface-flag xz-local gun-off gun-fast-exit) ) ) (let ((v1-30 (copy *walk-mods* 'global))) (set! (-> v1-30 name) 'pole) (set! (-> v1-30 flags) (surface-flag gun-hide gun-fast-exit)) (set! *pole-mods* v1-30) ) (let ((a0-14 (copy *walk-mods* 'global))) (set! (-> a0-14 name) 'grab) (set! (-> a0-14 flags) (surface-flag)) (set! *grab-mods* a0-14) ) (let ((v1-34 (copy *walk-mods* 'global))) (set! (-> v1-34 name) 'edge-grab) (set! (-> v1-34 flags) (surface-flag gun-inactive gun-no-twist)) (set! *edge-grab-mods* v1-34) ) (define *empty-mods* (new 'static 'surface :name 'empty :seek0 1.0 :seek90 1.0 :seek180 1.0 :fric 1.0 :flags (surface-flag gun-off) ) ) (define *neutral-mods* (new 'static 'surface :name 'walk :turnv 131072.0 :turnvv 524288.0 :tiltv 65536.0 :tiltvv 262144.0 :transv-max 40960.0 :target-speed 40960.0 :slip-factor 1.0 :slide-factor 1.0 :slope-up-factor 1.0 :slope-down-factor 1.0 :slope-slip-angle 1.0 :impact-fric 1.0 :bend-factor 1.0 :bend-speed 1.0 :slope-up-traction 1.0 :align-speed 1.0 :turnvf 30.0 :turnvvf 30.0 :tiltvf 150.0 :tiltvvf 15.0 ) ) (let ((v1-37 (new 'static 'surface :name '*stone-surface* :turnv 1.0 :turnvv 1.0 :tiltv 1.0 :tiltvv 1.0 :transv-max 1.0 :target-speed 1.0 :seek0 153600.0 :seek90 153600.0 :seek180 256000.0 :fric 153600.0 :nonlin-fric-dist 5120.0 :slip-factor 1.0 :slope-down-factor 10240.0 :slope-slip-angle 8192.0 :impact-fric 1.0 :bend-factor 0.8 :bend-speed 4.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :slope-change-preserve 1.0 :turnvf 1.0 :turnvvf 1.0 :tiltvf 1.0 :tiltvvf 1.0 :vel-turn 1.0 ) ) ) (set! *stone-surface* v1-37) (set! (-> v1-37 exit-hook) nothing) (set! (-> v1-37 mult-hook) (the-as (function surface surface surface int none) nothing)) (set! (-> v1-37 touch-hook) nothing) (set! (-> v1-37 active-hook) nothing) ) (let ((v1-38 (new 'static 'surface :name '*gravel-surface* :turnv 1.0 :turnvv 1.0 :tiltv 1.0 :tiltvv 1.0 :transv-max 1.0 :target-speed 1.0 :seek0 153600.0 :seek90 153600.0 :seek180 256000.0 :fric 153600.0 :nonlin-fric-dist 5120.0 :slip-factor 1.0 :slide-factor 1.0 :slope-down-factor 32768.0 :slope-slip-angle 8192.0 :impact-fric 1.0 :bend-factor 0.8 :bend-speed 4.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :slope-change-preserve 1.0 :turnvf 1.0 :turnvvf 1.0 :tiltvf 1.0 :tiltvvf 1.0 :vel-turn 1.0 ) ) ) (set! *gravel-surface* v1-38) (set! (-> v1-38 exit-hook) nothing) (set! (-> v1-38 mult-hook) (the-as (function surface surface surface int none) nothing)) (set! (-> v1-38 touch-hook) (lambda () (gravel-surface-touch) (none))) (set! (-> v1-38 active-hook) nothing) ) (let ((v1-39 (new 'static 'surface :name '*edge-surface* :turnv 1.0 :turnvv 1.0 :tiltv 1.0 :tiltvv 1.0 :transv-max 1.0 :target-speed 1.0 :seek0 153600.0 :seek90 153600.0 :seek180 256000.0 :fric 30720.0 :nonlin-fric-dist 5120.0 :slip-factor 1.0 :slope-down-factor 18432.0 :slope-slip-angle 8192.0 :bend-factor 0.8 :bend-speed 4.0 :alignv 1.0 :align-speed 1.0 :turnvf 1.0 :turnvvf 1.0 :tiltvf 1.0 :tiltvvf 1.0 :vel-turn 1.0 ) ) ) (set! *edge-surface* v1-39) (set! (-> v1-39 exit-hook) nothing) (set! (-> v1-39 mult-hook) (the-as (function surface surface surface int none) nothing)) (set! (-> v1-39 touch-hook) nothing) (set! (-> v1-39 active-hook) nothing) ) (let ((v1-40 (new 'static 'surface :name '*wade-surface* :turnv 1.0 :turnvv 1.0 :tiltv 1.0 :tiltvv 1.0 :transv-max 0.7 :target-speed 0.7 :seek0 153600.0 :seek90 153600.0 :seek180 256000.0 :fric 153600.0 :nonlin-fric-dist 5120.0 :slip-factor 1.0 :slope-down-factor 10240.0 :slope-slip-angle 8192.0 :impact-fric 1.0 :bend-factor 0.8 :bend-speed 4.0 :alignv 0.6 :slope-up-traction 1.0 :align-speed 0.6 :turnvf 1.0 :turnvvf 1.0 :tiltvf 1.0 :tiltvvf 1.0 :vel-turn 1.0 ) ) ) (set! *wade-surface* v1-40) (set! (-> v1-40 exit-hook) nothing) (set! (-> v1-40 mult-hook) (the-as (function surface surface surface int none) nothing)) (set! (-> v1-40 touch-hook) nothing) (set! (-> v1-40 active-hook) nothing) ) (let ((v1-41 (new 'static 'surface :name '*quicksand-surface* :turnv 0.25 :turnvv 1.0 :tiltv 1.0 :tiltvv 1.0 :transv-max 0.5 :target-speed 0.5 :seek0 81920.0 :seek90 83968.0 :seek180 165888.0 :fric 329728.0 :nonlin-fric-dist 5120.0 :slip-factor 1.0 :slope-down-factor 10240.0 :slope-slip-angle 8192.0 :impact-fric 1.0 :bend-factor 0.8 :bend-speed 4.0 :alignv 0.5 :slope-up-traction 1.0 :align-speed 0.5 :turnvf 1.0 :turnvvf 1.0 :tiltvf 1.0 :tiltvvf 1.0 :vel-turn 1.0 ) ) ) (set! *quicksand-surface* v1-41) (set! (-> v1-41 exit-hook) nothing) (set! (-> v1-41 mult-hook) (the-as (function surface surface surface int none) nothing)) (set! (-> v1-41 touch-hook) nothing) (set! (-> v1-41 active-hook) nothing) ) (let ((v1-42 (new 'static 'surface :name '*tar-surface* :turnv 0.25 :turnvv 1.0 :tiltv 1.0 :tiltvv 1.0 :transv-max 0.4 :target-speed 0.4 :seek0 81920.0 :seek90 83968.0 :seek180 165888.0 :fric 329728.0 :nonlin-fric-dist 5120.0 :slip-factor 1.0 :slope-down-factor 10240.0 :slope-slip-angle 8192.0 :impact-fric 1.0 :bend-factor 0.8 :bend-speed 4.0 :alignv 0.5 :slope-up-traction 1.0 :align-speed 0.5 :turnvf 1.0 :turnvvf 1.0 :tiltvf 1.0 :tiltvvf 1.0 :vel-turn 1.0 ) ) ) (set! *tar-surface* v1-42) (set! (-> v1-42 exit-hook) nothing) (set! (-> v1-42 mult-hook) (the-as (function surface surface surface int none) nothing)) (set! (-> v1-42 touch-hook) nothing) (set! (-> v1-42 active-hook) nothing) ) (let ((v1-43 (new 'static 'surface :name '*ice-surface* :turnv 0.5 :turnvv 1.0 :tiltv 1.0 :tiltvv 1.0 :transv-max 1.5 :target-speed 1.5 :seek0 24576.0 :seek90 24576.0 :seek180 24576.0 :fric 23756.8 :nonlin-fric-dist 4091904.0 :slip-factor 0.7 :slope-slip-angle 16384.0 :bend-speed 4.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :turnvf 1.0 :turnvvf 1.0 :tiltvf 1.0 :tiltvvf 1.0 :vel-turn 1.0 :flags (surface-flag no-turn-around turn-to-pad) ) ) ) (set! *ice-surface* v1-43) (set! (-> v1-43 exit-hook) nothing) (set! (-> v1-43 mult-hook) (the-as (function surface surface surface int none) nothing)) (set! (-> v1-43 touch-hook) nothing) (set! (-> v1-43 active-hook) nothing) ) (let ((v1-44 (new 'static 'surface :name '*rail-surface* :turnv 1.0 :turnvv 1.0 :tiltv 1.0 :tiltvv 1.0 :transv-max 1.0 :target-speed 1.0 :seek0 153600.0 :seek90 153600.0 :seek180 256000.0 :fric 153600.0 :nonlin-fric-dist 5120.0 :slip-factor 1.0 :slope-down-factor 10240.0 :slope-slip-angle 8192.0 :impact-fric 1.0 :bend-factor 0.8 :bend-speed 4.0 :alignv 1.0 :slope-up-traction 1.0 :align-speed 1.0 :slope-change-preserve 1.0 :turnvf 1.0 :turnvvf 1.0 :tiltvf 1.0 :tiltvvf 1.0 :vel-turn 1.0 :flags (surface-flag no-attack) ) ) ) (set! *rail-surface* v1-44) (set! (-> v1-44 exit-hook) nothing) (set! (-> v1-44 mult-hook) (the-as (function surface surface surface int none) nothing)) (set! (-> v1-44 touch-hook) (lambda () (rail-surface-touch) (none))) (set! (-> v1-44 active-hook) nothing) ) (define *standard-ground-surface* *stone-surface*) (define *swim-surface* *stone-surface*)