jak-project/test/goalc/source_templates/with_game/test-function128.gc
2021-07-26 21:39:05 -04:00

28 lines
728 B
Common Lisp

(let ((tv (new 'static 'vec4s :x 1.0 :y 2.0 :z 3.0 :w 4.0)))
(let ((temp (print tv)))
(format #t "~%")
(set! (-> temp x) 10.0)
(set! (-> tv y) 20.0)
(print tv)
(format #t "~%")
(print temp)
(format #t "~%")
)
)
(defun test-print-sound-name-chars ((arg0 int) (name sound-name) (arg2 int))
(let ((mem (new 'stack-no-clear 'array 'uint8 16)))
(set! (-> (the (pointer sound-name) mem)) name)
(let ((i 0))
(while (and (< i 16) (nonzero? (-> mem i)))
(format #t " ~c" (-> mem i))
(+! i 1)
)
)
(format #t "~%")
(format #t "arg0: ~d arg2: ~d~%" arg0 arg2)
)
)
(test-print-sound-name-chars 1 (string->sound-name "0123456789abcdefghij") 2)