Files
jak-project/test/decompiler/reference/jakx/engine/entity/entity-table_REF.gc
T
Tyler Wilding 9c86c86c74 d/jx: More files (#4360)
Breaks the 300 file milestone, also includes the majority of mips2c
functions carried forward. Some functions need some fixes in the c++
code to mips2c properly, and a small handful of the mips2c functions
require manual patching -- all spots were marked with `TODO - fix` that
had to be commented out to get things compiling.
2026-09-04 09:27:06 -04:00

55 lines
2.0 KiB
Common Lisp
Vendored
Generated

;;-*-Lisp-*-
(in-package goal)
;; definition for symbol *entity-info*, type (array entity-info)
(define *entity-info*
(new 'static 'boxed-array :type entity-info
(new 'static 'entity-info
:ptype (type-ref bubbles-path :method-count 56)
:pool '*16k-dead-pool*
:heap-size #x8000
)
(new 'static 'entity-info :ptype 'veger-npc :pool '*16k-dead-pool* :heap-size #x10000)
(new 'static 'entity-info :ptype 'seem-npc :pool '*16k-dead-pool* :heap-size #x20000)
(new 'static 'entity-info :ptype 'kleever-npc :pool '*16k-dead-pool* :heap-size #x18000)
(new 'static 'entity-info :ptype 'damus-npc :pool '*16k-dead-pool* :heap-size #x10000)
(new 'static 'entity-info
:ptype (type-ref nav-graph :method-count 45)
:pool '*16k-dead-pool*
:heap-size #x4000
)
)
)
;; definition for function entity-info-lookup
;; WARN: Return type mismatch basic vs entity-info.
(defun entity-info-lookup ((arg0 type))
(the-as entity-info (cond
((nonzero? (-> arg0 method-table 13))
(-> arg0 method-table 13)
)
(else
(let ((v1-1 *entity-info*))
(dotimes (a1-0 (-> v1-1 length))
(let ((a2-3 (-> v1-1 a1-0 ptype)))
(when (if (logtest? (the-as int a2-3) 1)
(= (-> arg0 symbol) a2-3)
(= arg0 a2-3)
)
(set! (-> arg0 method-table 13) (the-as function (-> v1-1 a1-0)))
(return (the-as entity-info (-> v1-1 a1-0)))
)
)
)
)
(set! (-> arg0 method-table 13) #f)
(the-as basic #f)
)
)
)
)