mirror of
https://github.com/open-goal/jak-project
synced 2026-08-05 09:34:51 -04:00
029983270e
everything up to collide-reaction-target (which is mostly done, but could use a few more names) Fixes issues with gun-part and target-part
424 lines
21 KiB
Common Lisp
424 lines
21 KiB
Common Lisp
;;-*-Lisp-*-
|
|
(in-package goal)
|
|
|
|
;; name: shrub-work.gc
|
|
;; name in dgo: shrub-work
|
|
;; dgos: ENGINE, GAME
|
|
|
|
;; DECOMP BEGINS
|
|
|
|
(define *instance-shrub-work*
|
|
(new 'static 'instance-shrub-work
|
|
:matrix-tmpl (new 'static 'inline-array qword 20
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x10000005 #x0 #x0 #x6c050143))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x20000005 #x0 #x0 #x6c050148))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x20000005 #x0 #x0 #x6c05014d))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x20000005 #x0 #x0 #x6c050152))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x20000005 #x0 #x0 #x6c050157))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x20000005 #x0 #x0 #x6c05015c))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x20000005 #x0 #x0 #x6c050161))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x20000005 #x0 #x0 #x6c050166))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x20000005 #x0 #x0 #x6c05016b))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x10000005 #x0 #x0 #x6c050170))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x10000005 #x0 #x0 #x6c050176))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x20000005 #x0 #x0 #x6c05017b))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x20000005 #x0 #x0 #x6c050180))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x20000005 #x0 #x0 #x6c050185))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x20000005 #x0 #x0 #x6c05018a))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x20000005 #x0 #x0 #x6c05018f))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x20000005 #x0 #x0 #x6c050194))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x20000005 #x0 #x0 #x6c050199))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x20000005 #x0 #x0 #x6c05019e))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x10000005 #x0 #x0 #x6c0501a3))
|
|
)
|
|
:count-tmpl (new 'static 'inline-array vector4w 20
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010175 :w 10)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010142 :w 1)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010142 :w 2)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010142 :w 3)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010142 :w 4)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010142 :w 5)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010142 :w 6)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010142 :w 7)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010142 :w 8)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010142 :w 9)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010142 :w 10)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010175 :w 1)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010175 :w 2)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010175 :w 3)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010175 :w 4)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010175 :w 5)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010175 :w 6)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010175 :w 7)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010175 :w 8)
|
|
(new 'static 'vector4w :x #x20000000 :z #x60010175 :w 9)
|
|
)
|
|
:mscalf-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id next))
|
|
:vif0 (new 'static 'vif-tag :cmd (vif-cmd mscalf) :msk #x1)
|
|
)
|
|
:mscalf-ret-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ret))
|
|
:vif0 (new 'static 'vif-tag :cmd (vif-cmd mscalf) :msk #x1)
|
|
)
|
|
:adgif-tmpl (new 'static 'dma-gif-packet
|
|
:dma-vif (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :qwc #x6 :id (dma-tag-id next))
|
|
:vif1 (new 'static 'vif-tag :imm #x6 :cmd (vif-cmd direct) :msk #x1)
|
|
)
|
|
:gif0 (new 'static 'gif-tag64 :nloop #x5 :eop #x1 :nreg #x1)
|
|
:gif1 (new 'static 'gif-tag-regs :regs0 (gif-reg-id a+d))
|
|
)
|
|
:billboard-tmpl (new 'static 'dma-gif-packet
|
|
:dma-vif (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :qwc #xd :id (dma-tag-id next))
|
|
:vif1 (new 'static 'vif-tag :imm #xd :cmd (vif-cmd direct) :msk #x1)
|
|
)
|
|
:gif0 (new 'static 'gif-tag64
|
|
:nloop #x4
|
|
:eop #x1
|
|
:pre #x1
|
|
:prim (new 'static 'gs-prim :prim (gs-prim-type tri-strip) :iip #x1 :tme #x1 :fge #x1 :abe #x1)
|
|
:nreg #x3
|
|
)
|
|
:gif1 (new 'static 'gif-tag-regs :regs0 (gif-reg-id st) :regs1 (gif-reg-id rgbaq) :regs2 (gif-reg-id xyzf2))
|
|
)
|
|
:shrub-near-packets (new 'static 'inline-array shrub-near-packet 6
|
|
(new 'static 'shrub-near-packet
|
|
:matrix-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :qwc #x6 :id (dma-tag-id cnt))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x345 :num #x6 :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:header-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #x34c :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:stq-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif0 (new 'static 'vif-tag :imm #x103 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x9 :cmd (vif-cmd unpack-v2-16))
|
|
)
|
|
:color-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #x400a :cmd (vif-cmd unpack-v3-8))
|
|
)
|
|
:vertex-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #xb :cmd (vif-cmd unpack-v3-16))
|
|
)
|
|
:mscal-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id next))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #xa :cmd (vif-cmd mscal) :msk #x1)
|
|
)
|
|
:init-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :qwc #x2 :id (dma-tag-id next))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x388 :num #x1 :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:init-data (new 'static 'inline-array qword 2
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x0 #x0 #x345 #x117))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x0 #x0 #x0 #x1500000c))
|
|
)
|
|
)
|
|
(new 'static 'shrub-near-packet
|
|
:matrix-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :qwc #x6 :id (dma-tag-id cnt))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x363 :num #x6 :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:header-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #x36a :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:stq-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif0 (new 'static 'vif-tag :imm #x103 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x120 :cmd (vif-cmd unpack-v2-16))
|
|
)
|
|
:color-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #x4121 :cmd (vif-cmd unpack-v3-8))
|
|
)
|
|
:vertex-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #x122 :cmd (vif-cmd unpack-v3-16))
|
|
)
|
|
:mscal-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id next))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #xa :cmd (vif-cmd mscal) :msk #x1)
|
|
)
|
|
:init-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :qwc #x2 :id (dma-tag-id next))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x388 :num #x1 :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:init-data (new 'static 'inline-array qword 2
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x0 #x0 #x363 #x22e))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x0 #x0 #x0 #x1500000c))
|
|
)
|
|
)
|
|
(new 'static 'shrub-near-packet
|
|
:matrix-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :qwc #x6 :id (dma-tag-id cnt))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x345 :num #x6 :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:header-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #x34c :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:stq-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif0 (new 'static 'vif-tag :imm #x103 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x237 :cmd (vif-cmd unpack-v2-16))
|
|
)
|
|
:color-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #x4238 :cmd (vif-cmd unpack-v3-8))
|
|
)
|
|
:vertex-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #x239 :cmd (vif-cmd unpack-v3-16))
|
|
)
|
|
:mscal-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id next))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #xa :cmd (vif-cmd mscal) :msk #x1)
|
|
)
|
|
:init-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :qwc #x2 :id (dma-tag-id next))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x388 :num #x1 :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:init-data (new 'static 'inline-array qword 2
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x0 #x0 #x345 #x0))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x0 #x0 #x0 #x1500000c))
|
|
)
|
|
)
|
|
(new 'static 'shrub-near-packet
|
|
:matrix-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :qwc #x6 :id (dma-tag-id cnt))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x363 :num #x6 :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:header-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #x36a :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:stq-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif0 (new 'static 'vif-tag :imm #x103 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x9 :cmd (vif-cmd unpack-v2-16))
|
|
)
|
|
:color-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #x400a :cmd (vif-cmd unpack-v3-8))
|
|
)
|
|
:vertex-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #xb :cmd (vif-cmd unpack-v3-16))
|
|
)
|
|
:mscal-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id next))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #xa :cmd (vif-cmd mscal) :msk #x1)
|
|
)
|
|
:init-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :qwc #x2 :id (dma-tag-id next))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x388 :num #x1 :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:init-data (new 'static 'inline-array qword 2
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x0 #x0 #x363 #x117))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x0 #x0 #x0 #x1500000c))
|
|
)
|
|
)
|
|
(new 'static 'shrub-near-packet
|
|
:matrix-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :qwc #x6 :id (dma-tag-id cnt))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x345 :num #x6 :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:header-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #x34c :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:stq-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif0 (new 'static 'vif-tag :imm #x103 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x120 :cmd (vif-cmd unpack-v2-16))
|
|
)
|
|
:color-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #x4121 :cmd (vif-cmd unpack-v3-8))
|
|
)
|
|
:vertex-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #x122 :cmd (vif-cmd unpack-v3-16))
|
|
)
|
|
:mscal-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id next))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #xa :cmd (vif-cmd mscal) :msk #x1)
|
|
)
|
|
:init-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :qwc #x2 :id (dma-tag-id next))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x388 :num #x1 :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:init-data (new 'static 'inline-array qword 2
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x0 #x0 #x345 #x22e))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x0 #x0 #x0 #x1500000c))
|
|
)
|
|
)
|
|
(new 'static 'shrub-near-packet
|
|
:matrix-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :qwc #x6 :id (dma-tag-id cnt))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x363 :num #x6 :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:header-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #x36a :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:stq-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif0 (new 'static 'vif-tag :imm #x103 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x237 :cmd (vif-cmd unpack-v2-16))
|
|
)
|
|
:color-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #x4238 :cmd (vif-cmd unpack-v3-8))
|
|
)
|
|
:vertex-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id ref))
|
|
:vif1 (new 'static 'vif-tag :imm #x239 :cmd (vif-cmd unpack-v3-16))
|
|
)
|
|
:mscal-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :id (dma-tag-id next))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #xa :cmd (vif-cmd mscal) :msk #x1)
|
|
)
|
|
:init-tmpl (new 'static 'dma-packet
|
|
:dma (new 'static 'dma-tag :qwc #x2 :id (dma-tag-id next))
|
|
:vif0 (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl))
|
|
:vif1 (new 'static 'vif-tag :imm #x388 :num #x1 :cmd (vif-cmd unpack-v4-32))
|
|
)
|
|
:init-data (new 'static 'inline-array qword 2
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x0 #x0 #x363 #x0))
|
|
(new 'static 'qword :data (new 'static 'array uint32 4 #x0 #x0 #x0 #x1500000c))
|
|
)
|
|
)
|
|
)
|
|
:dma-ref (new 'static 'dma-packet :dma (new 'static 'dma-tag :id (dma-tag-id ref)))
|
|
:dma-end (new 'static 'dma-packet :dma (new 'static 'dma-tag :id (dma-tag-id end)))
|
|
:wind-const (new 'static 'vector :x 0.5 :y 100.0 :z 0.0166 :w -1.0)
|
|
:constants (new 'static 'vector :x 128.0 :y 1.0)
|
|
:color-constant (new 'static 'vector4w :x #x47000000 :y #x47000000 :z #x47000000)
|
|
:start-bank (new 'static 'array uint8 20 #x0 #x1 #x1 #x1 #x1 #x1 #x1 #x1 #x1 #x1 #x1 #x0 #x0 #x0 #x0 #x0 #x0 #x0 #x0 #x0)
|
|
)
|
|
)
|
|
|
|
(set! (-> *instance-shrub-work* mscalf-tmpl vif0 imm) 103)
|
|
|
|
(set! (-> *instance-shrub-work* mscalf-ret-tmpl vif0 imm) 103)
|
|
|
|
(defun upload-generic-shrub ((arg0 dma-buffer) (arg1 generic-shrub-fragment) (arg2 int) (arg3 int))
|
|
(let* ((v1-0 arg0)
|
|
(t0-0 (the-as object (-> v1-0 base)))
|
|
)
|
|
(set! (-> (the-as dma-packet t0-0) dma) (new 'static 'dma-tag :qwc #x6 :id (dma-tag-id cnt)))
|
|
(set! (-> (the-as dma-packet t0-0) vif0) (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl)))
|
|
(set! (-> (the-as dma-packet t0-0) vif1)
|
|
(new 'static 'vif-tag :num #x6 :cmd (vif-cmd unpack-v4-32) :imm (shr (shl arg2 54) 54))
|
|
)
|
|
(set! (-> v1-0 base) (&+ (the-as pointer t0-0) 16))
|
|
)
|
|
(let* ((v1-1 (the-as matrix (-> arg0 base)))
|
|
(t3-0 (-> *math-camera* camera-temp))
|
|
(t0-3 (-> t3-0 quad 0))
|
|
(t1-4 (-> t3-0 quad 1))
|
|
(t2-4 (-> t3-0 quad 2))
|
|
(t3-1 (-> t3-0 trans quad))
|
|
)
|
|
(set! (-> v1-1 quad 0) t0-3)
|
|
(set! (-> v1-1 quad 1) t1-4)
|
|
(set! (-> v1-1 quad 2) t2-4)
|
|
(set! (-> v1-1 trans quad) t3-1)
|
|
)
|
|
(&+! (-> arg0 base) 64)
|
|
(let* ((v1-4 arg0)
|
|
(t0-4 (the-as object (-> v1-4 base)))
|
|
)
|
|
(set! (-> (the-as vector4w-2 t0-4) vector 0 x) #x3f800000)
|
|
(set! (-> (the-as vector4w-2 t0-4) vector 0 y) #x3f800000)
|
|
(set! (-> (the-as vector4w-2 t0-4) vector 0 z) #x3f800000)
|
|
(set! (-> (the-as vector4w-2 t0-4) vector 0 w) 128)
|
|
(set! (-> (the-as vector4w-2 t0-4) vector 1 x) (the-as int (-> arg1 vtx-cnt)))
|
|
(set! (-> (the-as vector4w-2 t0-4) vector 1 y) 0)
|
|
(set! (-> (the-as vector4w-2 t0-4) vector 1 z) 0)
|
|
(set! (-> (the-as vector4w-2 t0-4) vector 1 w) 0)
|
|
(set! (-> v1-4 base) (&+ (the-as pointer t0-4) 32))
|
|
)
|
|
(let* ((v1-5 arg0)
|
|
(t0-6 (the-as object (-> v1-5 base)))
|
|
)
|
|
(set! (-> (the-as dma-packet t0-6) dma)
|
|
(new 'static 'dma-tag :id (dma-tag-id ref) :addr (the-as int (-> arg1 bsphere x)) :qwc (-> arg1 cnt-qwc))
|
|
)
|
|
(set! (-> (the-as dma-packet t0-6) vif0) (new 'static 'vif-tag))
|
|
(set! (-> (the-as dma-packet t0-6) vif1)
|
|
(new 'static 'vif-tag :cmd (vif-cmd unpack-v4-32) :imm (shr (shl (+ arg2 6) 54) 54) :num (-> arg1 cnt-qwc))
|
|
)
|
|
(set! (-> v1-5 base) (&+ (the-as pointer t0-6) 16))
|
|
)
|
|
(let* ((v1-6 arg0)
|
|
(a2-8 (the-as object (-> v1-6 base)))
|
|
)
|
|
(set! (-> (the-as dma-packet a2-8) dma)
|
|
(new 'static 'dma-tag :id (dma-tag-id ref) :addr (the-as int (-> arg1 bsphere w)) :qwc (-> arg1 stq-qwc))
|
|
)
|
|
(set! (-> (the-as dma-packet a2-8) vif0) (new 'static 'vif-tag :imm #x103 :cmd (vif-cmd stcycl)))
|
|
(set! (-> (the-as dma-packet a2-8) vif1)
|
|
(new 'static 'vif-tag :cmd (vif-cmd unpack-v2-16) :imm (shr (shl arg3 54) 54) :num (-> arg1 vtx-cnt))
|
|
)
|
|
(set! (-> v1-6 base) (&+ (the-as pointer a2-8) 16))
|
|
)
|
|
(let* ((v1-7 arg0)
|
|
(a2-10 (the-as object (-> v1-7 base)))
|
|
)
|
|
(set! (-> (the-as dma-packet a2-10) dma)
|
|
(new 'static 'dma-tag :id (dma-tag-id ref) :addr (the-as int (-> arg1 bsphere z)) :qwc (-> arg1 col-qwc))
|
|
)
|
|
(set! (-> (the-as dma-packet a2-10) vif0) (new 'static 'vif-tag))
|
|
(set! (-> (the-as dma-packet a2-10) vif1)
|
|
(new 'static 'vif-tag :cmd (vif-cmd unpack-v3-8) :imm (shr (shl (+ arg3 1) 54) 54) :num (-> arg1 vtx-cnt))
|
|
)
|
|
(set! (-> v1-7 base) (&+ (the-as pointer a2-10) 16))
|
|
)
|
|
(let* ((v1-8 arg0)
|
|
(a2-12 (the-as object (-> v1-8 base)))
|
|
)
|
|
(set! (-> (the-as dma-packet a2-12) dma)
|
|
(new 'static 'dma-tag :id (dma-tag-id ref) :addr (the-as int (-> arg1 bsphere y)) :qwc (-> arg1 vtx-qwc))
|
|
)
|
|
(set! (-> (the-as dma-packet a2-12) vif0) (new 'static 'vif-tag))
|
|
(set! (-> (the-as dma-packet a2-12) vif1)
|
|
(new 'static 'vif-tag :cmd (vif-cmd unpack-v3-16) :imm (shr (shl (+ arg3 2) 54) 54) :num (-> arg1 vtx-cnt))
|
|
)
|
|
(set! (-> v1-8 base) (&+ (the-as pointer a2-12) 16))
|
|
)
|
|
(let* ((v1-9 arg0)
|
|
(a1-7 (the-as object (-> v1-9 base)))
|
|
)
|
|
(set! (-> (the-as dma-packet a1-7) dma) (new 'static 'dma-tag :id (dma-tag-id cnt)))
|
|
(set! (-> (the-as dma-packet a1-7) vif0) (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl)))
|
|
(set! (-> (the-as dma-packet a1-7) vif1) (new 'static 'vif-tag :imm #xa :cmd (vif-cmd mscal) :msk #x1))
|
|
(set! (-> v1-9 base) (&+ (the-as pointer a1-7) 16))
|
|
)
|
|
arg0
|
|
)
|