Commit graph

382 commits

Author SHA1 Message Date
water111 188373a3f6
decompile some drawable stuff and fix a few small bugs (#859) 2021-09-28 19:24:09 -04:00
water111 f0ceea8b2e
[sparticle] 2d hud particles (#849)
* wip, taking a break to work on asm stuff first

* the goal code for sparticle

* mips2c the first sparticle asm function

* temp

* particle processing no longer crashing

* temp

* working texture cache for vi1 and hud textures

* sprites

* cleanup 1

* temp

* temp

* add zstd library

* temp

* working

* tests

* include fix

* uncomment

* better decomp of sparticle stuff, part 1

* update references
2021-09-26 11:41:58 -04:00
ManDude d8e659df66
[decomp] flying-lurker (#846)
* `flying-lurker`

* why'd this get left behind?

* also `ambient` and add a `banned_objects` config and fix offline tests

* clang

* fix `ambient-type-sound`
2021-09-21 18:40:38 -04:00
water111 f9d8fcd6e4
[decomp] add mips2c converter (#842)
* mips 2 c basic version, not yet tested

* calling works without crashing, but the function doesn't

* it works

* add test

* cleanup and actually add the test

* dont use mips2c by default for font

* clean up formatting
2021-09-11 20:52:35 -04:00
water111 18df68b1f7
fix text rendering bugs (#841) 2021-09-08 22:04:30 -04:00
water111 9fdbc2d974
[goalc] fix static array length (#836)
* fix static array length

* add some more small fixes
2021-09-08 18:49:49 -04:00
Tyler Wilding 4ff2130d55
decomp: decompile almost all the platform related files (#812)
* deocmp: `plat` finished, `baseplat` started

* decomp: finish `baseplat`

* decomp: finish `plat-button`

* decomp: finish `plat-eco`

* decomp: finish `citb-drop-plat-CIT`

* decomp: finish `cit-drop-plat-L1`

* decomp: finish `plat-flip`

* decomp: added a bunch of label defs

* decomp: `plat-button` ref test added

* stash

* decomp: finish `baseplat`

* decomp: finish `plat`

* decomp: finish `plat-button`

* tests: fix offline-test to handle multi-DGO files better

* decomp: finish `citb-drop-plat-CIT`

* decomp: finish `plat-flip`

* decomp: finish `wedge-plats`

* tools: fix memory analyzer, skip invalid type

* decomp: finish `wall-plat`

* fix ordering

* fix some casting issues

* cleanup after conflict resolution

* address reviews
2021-09-06 21:10:19 -04:00
ManDude 89ccb8cbc7
[decomp] progress (#780)
* cleanup `main`

* whitespace

* start `progress` decomp pt1

* fill in more stuff

* Update label_types.jsonc

* run cheats

* clang

* make most of `progress` decompile

* `progress` pt 2

* [decompiler] support dynamic format strings

* Make `progress-draw` decompile and almost all `progress`

* make clang shut up

* fix unhandled format string

* fix `progress-draw`

* Update DecompilerTypeSystem.cpp

* fix?

* fixes

* fix a few functions

* make `language-enum`

* warn on weird floats

* fix minor pad bug

* dump stuff in `progress`

* make `progress-screen` enum

* progress progress

* update refs and fix stupid bug

* trying to get it to work

* it works!?

* disable sound functions

* fixes

* final touches

* tests

* tests

* add process allocations

* use the right register for windows

* another try for windows, counting is hard

* one more try

* use process allocations

Co-authored-by: water <awaterford111445@gmail.com>
2021-09-06 20:35:03 -04:00
Tyler Wilding d1f16b34ff
decomp: another batch of easy files (#823)
* decomp: finish `sharkey`

* decomp: finish `lurkercrab`

* decomp: finish `lurkerpuppy`

* decomp: finish `assistant-citadel`

* decomp: finish `static-screen`

* decomp: finish `robotboss-h`

* decomp: finish `final-door`

* decomp: finish `aphid`

* addressed review
2021-09-06 15:34:31 -04:00
Tyler Wilding 7c25b721f1
decomp: easy batch number 2 (#824)
* decomp: finish `jungle-elevator`

* decomp: finish `bouncer`

* decomp: finish `hopper`

* decomp: finish `junglefish`

* decomp: finish `blocking-plane`

* decomp: finish `sidekick-human`

* decomp: finish `assistant-firecanyon`

* decomp: finish `sage-bluehut`

* decomp: finish `flutflut-bluehut`

* fix arg type
2021-09-06 14:29:06 -04:00
Tyler Wilding 442d5ed570
decomp: projectiles (#777)
* decomp: close to finishing `projectile`

blocked by #754

* decomp: finish `projectiles`

* decompiler: Add support for `sparticle-launch-group` from static data

* fix sparticle-launch-group instances

* decomp: change arg0 to `entity`
2021-09-02 20:00:29 -04:00
Tyler Wilding 4943c125ad
decomp: target-part (#688)
* decomp: finish decompiling `target-part` waiting on label issue

Hitting exception at data_decompile.cppL182

* fixed pointer labels, but blocked by :inline fields from static data

* decomp: finish `target-part`

* address feedback
2021-09-02 19:19:54 -04:00
water111 4616f436f1
fix missing bitfield (#811) 2021-09-01 21:02:16 -04:00
water111 9b0480c50d
[decompiler] process initialization macros (#807)
* implementation and a few working cases

* fix self issue

* fix run-function-in-process

* fix up set-to-run
2021-09-01 16:59:26 -04:00
water111 6d120c1ac8
fix self issue (#808) 2021-09-01 16:42:24 -04:00
Tyler Wilding 42f7a675b2
decomp: a few files that were done except for sp-launch-group (#802)
* decomp: dark-eco-pool blocked by sparticle-launch-group label

* decomp: finalize `dark-eco-pool`

* decomp: mostly finish `beach-rocks` waiting for sparticle label supp

* decomp: almost done `beach-rocks` but potential new handle case

* decomp: finish `beach-rocks`

* decomp: finish `assistant`

* decomp: finish `miners`
2021-09-01 11:20:05 -04:00
water111 ac3092093c
fix really old compiler bug (#799) 2021-08-31 22:12:30 -04:00
Tyler Wilding 1c7c2132eb
decomp: weather-part (#798)
* stash

* decomp: finish what is currently possible in `time-of-day`

* need to know how sp-field-init-spec's functions are called

* solved some issues, but going to be blocked by the sparticle-group-item

* decompiler: Add support for `sparticle-launch-group` from static data

* decomp: finish `weather-part`
2021-08-31 21:36:19 -04:00
water111 c2c6d3ba46
[decompiler] detect res-lump macros (#796)
* support res lump float

* handle data macro

* rest of res macros

* add vi3 to the build system

* missing close paren
2021-08-31 15:01:54 -04:00
water111 41507f1aee
nest floating point addition and multiply operations (#794)
* nest floating point addition and multiply operations

* fix mood
2021-08-31 12:04:46 -04:00
water111 34e8afa0ee
get started on entity (#793) 2021-08-31 11:05:03 -04:00
water111 d9f9e076af
[decompiler] automatically label things when possible (#784)
* improve label system

* clean up menu

* debug menu working, still need to fix tests

* fix tests and clean up
2021-08-29 11:13:06 -04:00
Tyler Wilding 05648e0a96
decomp: finish basebutton (#762)
* decomp: finish `basebutton`

* decomp: finalize `basebutton` and fix `evilbro`

* fix some methods / args
2021-08-22 23:16:55 -04:00
Tyler Wilding 4c61343cb7
decomp: evilbro (#774)
* add script to make adding lambda label casts a bit easier

* decomp: almost finish `evil-bro`

blocked by handle -> process conversion it seems:
`No method or function named .asm.sllv.r0 for type (pointer process-tree)`

* so close! SLLV issue (not a simple handle scenario)

* decomp: finalize `evilbro` blocked by func return type

* decomp: finish `evilbro`
2021-08-22 21:03:47 -04:00
Tyler Wilding 991a438927
decomp: decompile target-util | logic-target (#662)
* add IR syntax highlighting

* set the filterFileRegex properly!

* stash

* decompiler: Add print if conditional fails

* decomp: Mostly finish `target-util`

* decomp: figured out a bit more with `target-util`, a bit stuck now

* decomp: *deep breath* `logic-target` mostly complete

* decompiler: More robust arg_count checking for `format` calls

* decomp: some more work in `target-util`

* fix sllv usage

* decomp: `logic-target` is compiling

* decomp: `target-util` very close - blocked by decomp issue!

* decomp: finish `target-util` except for one issue

#772

* demp: update goal_src

* linting

* add back the one remaining method

* address feedback, update source files
2021-08-22 20:46:37 -04:00
water111 403bb5f4de
[decomp] game-info (#779)
* support more process stuff

* more of game info

* add ref file

* progress on save
2021-08-22 20:12:47 -04:00
water111 11e11d2c04
[decompiler] Several small fixes (#775)
* fix assorted bugs

* stricter return types

* only look for functions in code files
2021-08-19 20:35:12 -04:00
Tyler Wilding 253d7996e8
decomp: almost all of the NPCs! (#748)
* all-types: add all missing `:heap-base`s

* decomp: error encountered when compiling `mayor`

`IR_StoreConstOffset::do_codegen can't handle this` for method `play-anim!`

* decomp: finalize `mayor`

* decomp: finish `bird-lady`

* decomp: finish `bird-lady-beach`

* decomp: finish `sculptor`

* decomp: finish `geologist`

* decomp: finish `oracle`

* decomp: finish `farmer` | `explorer` | almost `assistant`

blocked on sparticle-launch-group

* decomp: finish `sage`

* decomp: finish `gambler`

* decomp: finish `warrior`

* decomp: mostly finish `miners`, blocked by sp-launch-group

* fix issue in `sage`

* fix all the reference tests to use the new state stuff

* fix all of goal_src

* address feedback

* re-gen with `until` fixes
2021-08-18 21:33:31 -04:00
water111 1f0c2e0e71
[decomp] Split condition and body of until after building expressions (#768)
* improve until decomp

* fix tests
2021-08-18 19:36:52 -04:00
water111 97ab6a4e12
add support for non virtual states (#764)
* add support for non virtual states

* typecheck go

* start on virtual states

* more support for virtual states

* offline passes

* fix tests

* use behavior shortcut instead of lambda

* final cleanup of virtual go

* unused var warnings and fix inconsistent enum decompile order on win vs linux

* fix thread safety bug with goal symbol table and vif1 interrupt handler

* fix type mistake
2021-08-17 20:54:03 -04:00
ManDude 56f805f6e6 regex has failed me 2021-08-17 08:15:49 +01:00
ManDude 1f15165b33 rename current-display-frame and make it less confusing 2021-08-17 08:04:33 +01:00
ManDude 63b408773a make pc-pad-input-stop cancel button mapping 2021-08-17 06:32:14 +01:00
ManDude 319bfb0d94 simplify with-dma-buffer-add-bucket 2021-08-17 06:23:08 +01:00
ManDude fd4bd26d88 patch 2021-08-16 15:58:41 +01:00
ManDude a83bae17a5 Merge branch 'master' into d/cpad-test 2021-08-16 15:46:06 +01:00
ManDude 093526721c save key mapping to memory! 2021-08-16 14:57:15 +01:00
ManDude 513b0691cb Update pc-pad-utils.gc 2021-08-16 07:52:41 +01:00
ManDude ada8f19685 Update pc-pad-utils.gc 2021-08-16 07:48:41 +01:00
ManDude ffd4251e71 reword 2021-08-16 07:48:07 +01:00
ManDude efdc598c09 make pc pad remapping process (incomplete) 2021-08-16 07:44:05 +01:00
ManDude 395f97a0c0 Fix dumb mistake... 2021-08-16 04:04:04 +01:00
ManDude ff3174f292 more cpad stuff + make font-flags 2021-08-16 03:50:36 +01:00
water ee81b709a4 add merc 2021-08-14 23:31:17 -04:00
water 78928e4c04 temp 2021-08-14 23:15:10 -04:00
ManDude 4a8295898b Merge branch 'master' into d/cpad-test 2021-08-14 23:24:18 +01:00
water 72340811e5 decomp decomp 2021-08-14 16:49:45 -04:00
ManDude af823cdb82 implement cpad stuff 2021-08-14 21:00:50 +01:00
water 51dd1bdae8 Merge branch 'master' of github.com:water111/jak-project into w/sprite-distort-stub 2021-08-14 13:07:17 -04:00
water 097ae07bb8 clean up font color 2021-08-14 13:06:43 -04:00
Tyler Wilding b3dc755f06
address _almost_ all feedback 2021-08-14 12:45:25 -04:00
Tyler Wilding 9f36419e37
fix goal_src 2021-08-13 22:16:33 -04:00
Tyler Wilding dda8756a35
Merge remote-tracking branch 'water111/master' into decomp/nav-enemy 2021-08-13 22:00:18 -04:00
Tyler Wilding 05f25e60f8
decomp: finalize nav-enemy 2021-08-13 21:57:58 -04:00
water 23748dfeef start on debug graphics 2021-08-13 21:48:56 -04:00
water 5aa15afe29 decompile sprite-distort without vu1 stuff 2021-08-13 18:50:29 -04:00
water d5f05f723e Merge branch 'master' of https://github.com/water111/jak-project into w/dma-for-font 2021-08-12 20:31:51 -04:00
water ee71b52b27 Merge branch 'master' of https://github.com/water111/jak-project into w/dma-for-font 2021-08-12 19:27:51 -04:00
Tyler Wilding 266ce07fd4
Merge remote-tracking branch 'water111/master' into decomp/sunken-elevator 2021-08-12 19:23:19 -04:00
water ebc580822e clean up 2021-08-12 19:03:33 -04:00
Tyler Wilding 59a15bd6a9
decomp: fix goal_src 2021-08-11 22:54:27 -04:00
Tyler Wilding f2e072cff0
fix method name 2021-08-11 22:33:31 -04:00
Tyler Wilding ca1d540849
Merge remote-tracking branch 'water111/master' into decomp/wateranim-rigid-body 2021-08-11 20:57:05 -04:00
Tyler Wilding 409721018b
Merge remote-tracking branch 'water111/master' into decomp/misty-teetertotter 2021-08-11 20:24:55 -04:00
water 71f0a71c4c Merge branch 'master' of https://github.com/water111/jak-project into w/dma-for-font 2021-08-11 20:24:50 -04:00
Tyler Wilding 2f2ad69a0c
remove unneeded casts, switch to :allow-misaligned 2021-08-11 19:54:03 -04:00
water 3bba86ce18 support mt4hh texture for japanese fonts 2021-08-11 19:36:15 -04:00
Tyler Wilding 11efc31e5c
Merge remote-tracking branch 'water111/master' into decomp/twister 2021-08-10 20:44:22 -04:00
Tyler Wilding 38d2b2d02e
fix dynamic element 2021-08-10 20:43:25 -04:00
water 0abc311eb2 actually add the text 2021-08-09 22:11:46 -04:00
water 843c3a899c Merge branch 'master' of https://github.com/water111/jak-project into w/dma-for-font 2021-08-09 22:08:48 -04:00
Tyler Wilding bcae0d0b5f
decomp: finish wobbler (#745)
Co-authored-by: water <awaterford111445@gmail.com>
2021-08-09 22:07:39 -04:00
Tyler Wilding 3cfd50b618
decomp: finish ticky (#744)
Co-authored-by: water <awaterford111445@gmail.com>
2021-08-09 21:55:05 -04:00
water 9495e91259 online tests pass 2021-08-09 21:54:40 -04:00
water 40ecd92272 Merge branch 'master' of https://github.com/water111/jak-project into w/dma-for-font 2021-08-09 21:41:25 -04:00
Tyler Wilding 42e73f64d9
decomp: finish tippy (#742)
Co-authored-by: water <awaterford111445@gmail.com>
2021-08-09 21:09:59 -04:00
ManDude 946284c05d
add goal enum utils to standard libs (#740)
* add goal enum utils to standard libs

* Update .gitattributes
2021-08-09 19:18:53 -04:00
Tyler Wilding 2495066453
Merge remote-tracking branch 'water111/master' into decomp/wateranim-rigid-body 2021-08-09 19:11:46 -04:00
Tyler Wilding f438ba4e84
decomp: shadow (#681)
* decomp: Almost finish `shadow` blocked on static inline-array

* decomp: Add support for `sparticle-launcher` static data

* decomp: finalize `shadow`

* add definitions for sparticle related symbols

* actually fix the crash
2021-08-09 19:07:11 -04:00
water b4846f0491 hook up profiler 2021-08-08 21:50:34 -04:00
water 0dfe6a169d fonts and stuff work 2021-08-08 20:46:14 -04:00
Tyler Wilding 72194ef243
decomp: finish misty-warehouse 2021-08-08 20:15:12 -04:00
Tyler Wilding 8ed6650ec6
decomp: finish sunken-elevator 2021-08-08 19:32:54 -04:00
Tyler Wilding a9816f9d28
decomp: finish misty-teetertotter 2021-08-08 17:00:51 -04:00
Tyler Wilding f29e9cb8ce
decomp: finish mud 2021-08-08 16:07:21 -04:00
water 124003f5f2 store texture in pool 2021-08-08 15:46:34 -04:00
Tyler Wilding 0d0442eeb4
decomp: finish twister 2021-08-08 13:28:47 -04:00
water 54301a36be texture decoding 2021-08-08 13:12:44 -04:00
water 66f95d3c8a text working with no textures 2021-08-07 21:16:44 -04:00
Tyler Wilding 924abfb329
decomp: comment out problematic top-level-lets 2021-08-07 20:05:06 -04:00
Tyler Wilding 4f331b5f79
decomp: finalize rigid-body 2021-08-07 18:29:44 -04:00
Tyler Wilding 20196852f5
decomp: finallize water-anim 2021-08-07 16:15:41 -04:00
water d1674ea9b6 wip 2021-08-06 22:30:02 -04:00
water 21684bd104 misc bug fixes, now draw string generates dma data 2021-08-05 20:29:36 -04:00
water 821c2ab42a display loop runs 2021-08-04 21:30:08 -04:00
water 0c7f9e1850 work on getting font stuff working 2021-08-03 22:40:07 -04:00
ManDude 8946119f19
forgot something in main (#738) 2021-08-03 18:26:00 -04:00
water111 5293f583a8
[decomp] clean up sync info (#735)
* clean up sync info

* clean up trajectory
2021-08-02 21:49:05 -04:00
water111 aa58d146c2
[goalc] register allocator v2 (#731)
* clean up allocator interface to be simpler

* working on functions without spills

* working for all

* fix missing includes for windows

* more windows includes

* initialize regs to zero so printing value unintiailized by game code is repeatable
2021-08-01 17:46:55 -04:00
Tyler Wilding 75f7609baa
decomp: ocean-transition (#616)
* some work on `ocean-transition`

* decomp: finished non-blocked `ocean-transition` functions

* decompiler: Support <0 unsigned comparison

* decompiler/goalc: Support half-word and byte parallel extend ops

* attempt to add support for byte stack spills, assertion errors

`Assertion failed: idx < n_src, file ..\..\..\decompiler\Disasm\Instruction.cpp, line 353`

* decomp: fix byte stack spills, only 1 issue remains in `draw-ocean-transition`

* almost there...

* closer, but unknowns about `dma-buffer` blocking

* dealing with dma-buffer issues

* some more fixes, only an obscure xmm issue remains

* add two problematic functions to blacklists, avoid goal_src additions for now

* fix building/compilation but TypeConsistency hits an assertion error

the `ocean-mid-masks`'s `data` field is none of the types

* decomp: finalize `ocean-transition`

* address feedback - 1 issue remains

* decomp: finalize `ocean-transition`
2021-08-01 17:42:40 -04:00