Commit graph

297 commits

Author SHA1 Message Date
Tyler Wilding 44d59e6b33
d/jak2: finish mood-funcs | mood-funcs2 | almost all of mood and airlock (#1842) 2022-09-06 20:35:00 -04:00
Tyler Wilding 80d0137dba
d/jak2: finish the majority of sparticle and sparticle-launcher (#1840)
* sparticle-launcher

* d/jak2: large amount of `sparticle-launcher` done

* d/jak2: finish the majority of `sparticle`

* decomp: improve format code ignoring

* d/jak2: make bits unique in `sp-cpuinfo-flag`

* d/jak1: revert config change
2022-09-05 18:03:46 -04:00
ManDude f1f18e7e05
[decomp2] joint-mod, chain-physics, loader (#1816)
* prep

* Update repo-settings-mark.bat

* Update repo-settings-unmark.bat

* decomp `joint-mod`

* add `joint-mod-ik-callback` to ref exceptions

* `chain-physics`

* Update jak2_ntsc_v1.jsonc

* update bat scripts

* `loader`

* pretty

* refs

* support `process->handle` (and `ppointer->handle`?)

* refs

* source and fixes

* fix `ja` detect

* `ja` macro implement

* fix a method

* update source

* merge fixes

* annoying fixes

* format

* arg

* hack

* fix test
2022-09-02 18:13:38 -04:00
Hat Kid 52bb1c4915
decomp: board-h, board-util, gun-util, darkjak-h (#1817)
* decomp: `board-util`, `gun-util`, `darkjak-h`

* address changes and decompile `board-h`

* fix `board-util`

* remove `_type_` from `projectile` method

* fix `gun-h.gc`

* Update gun-h.gc
2022-09-01 18:25:42 -04:00
Tyler Wilding d264779173
d/jak2: finish glist | glist-h | camera | cam-interface | cam-states-dbg | cam-combiner | cam-debug | cam-start (#1829)
* d/jak2: finish `glist` and `glist-h` partially done `time-of-day`

* d/jak2: finish `camera` and `cam-interface`

* d/jak2: partially finish `cam-master` `cam-states`, and `cam-update` finish `cam-states-dbg` `cam-combiner` `cam-debug` and `cam-start`

* tests: update ref tests

* scripts: add scripts to automatically update gsrc files

* d/jak2: update gsrc
2022-08-31 19:22:47 -04:00
Ethan Lafrenais e7b1a2d292
[decomp] jak2: sprite, sprite-distort, some of sprite-glow (#1814)
* Decompile sprite-distort

* Revert matrix, sprite-vec-data-2d changes

* Sprite distort ref test

* Sprite distort docs

* Better sprite-distort docs

* Jak2 sprite distort VU

* sprite decomp

* Some of sprite-glow

* Clean up
2022-08-29 19:04:54 -04:00
Tyler Wilding d176b294b9
d/jak2: finish entity-table | sky-data | relocate | and the majority of default-menu (#1812)
* d/jak2: finish `entity-table`

* d/jak2: finish `sky-data`

* d/jak2: finish `relocate`

* d/jak2: halfway through `default-menu`

* d/jak2: 75% done `default-menu`....

* d/jak2: add `default-menu` to ref tests (partially)

* d/jak2: finish updating related code

* scripts: add tooling to automatically keep code from `all-types` up to date

* d/jak2: fixed vector types
2022-08-29 18:49:57 -04:00
water111 2bead6db97
[decompile] Joint (#1813)
* temp

* decompile joints

* fix merge
2022-08-28 16:38:58 -04:00
Tyler Wilding 799e10a0ae
d/jak2: finish cylinder | mech-h | font-data most of text and history and chip away at a bunch of other files (#1802)
* d/jak2: finish `cylinder`

* d/jak2: mostly finish `history`

* d/jak2: finish a bit of `ripple` and `sync-info`

* d/jak2: finish `font-data` and chip away at some other files

* d/jak2: most of `text` done, a bit of `script` - symbol arr issue in `level-info`

* d/jak2: finish `mech-h`

* lint: format

* tests: fix typeconsistency

* d/jak2: address feedback
2022-08-28 10:45:07 -04:00
water111 7443520e88
[decomp] load-dgo, ramdisk, gsound, transformq (#1798)
* temp

* cleanup after merge

* transformq too
2022-08-24 21:57:13 -04:00
water111 06ef52cd25
[decompiler] support for jak 2 (#1781)
* [decompiler] suppport jak 2

* cleanpu

* remove brief from gtest options

* fix test
2022-08-22 18:53:51 -04:00
water111 da4ec008c3
Add a gltf level exporter (#1719)
* Add a gltf level exporter

* more fixes

* disable by default

* compile fixes for windows

* improve collide packer

* bug fix

* clang format

* fix texture bug
2022-08-05 12:25:35 -04:00
Tyler Wilding 7c8ac12b55
decomp: fix calls to read_config_file (#1717) 2022-07-31 19:25:18 -04:00
Tyler Wilding d1ad6c3817
utf8: fix locale mis-handling on linux (#1698)
* utf8: fix locale mis-handling on linux

* lint: formatting
2022-07-23 10:30:23 -04:00
water111 dc652d10c5
[jak2] decomp gkernel, setup offline tests (#1638)
* add comments

* oops

* format'

* spelling is hard
2022-07-12 18:50:18 -04:00
Tyler Wilding 1b67d1dc77
Fix UTF-8 handling when running the game, env-vars, and setting the project path (#1632)
* fix utf-8 handling around env-vars

* fix file opening errors related to unicode

* add uncaught exception handler in `gk` to ensure something is logged

* gracefully fail if window icon cant be loaded and work with unicode

* linux fix and add changes to vendor file
2022-07-10 19:03:24 -04:00
water111 28a2ecdfd3
[jak2] goalc supports multiple projects (#1619)
* [jak2] goalc supports multiple projects

* disable deci2 server if not debugging
2022-07-06 21:18:08 -04:00
Tyler Wilding 8a18072d97
tests/jak2: Better prepare offline tests for multiple games (#1591)
* git: ignore vs build dir

* cmake: ditch `clang-cl` on windows in favor of actual `clang`

* build: suppress a significant number of warnings

* build: adjust workflows and vendor nasm

* docs: update docs to remove `clang-cl` mentions

* tests: move jak1 reference tests into their own folder

* tests: update offline tests to support multiple games

* tests: some additional fixes and multi-game handling

* tests: update reference tests
2022-07-06 18:10:38 -04:00
Tyler Wilding 6446389263
extractor: cleanup, support unicode properly, and add multi-game support (#1609)
* extractor: refactor and cleanup for multi-game support

* deps: switch to `ghc::filesystem` as it is utf-8 everywhere by default

* extractor: finally working with unicode

* unicode: fix unicode cli args on windows in all `main` functions
2022-07-05 20:38:13 -04:00
water111 1e33dcda4b
Remove assets folder, use more std::filesystem (#1575)
* Remove assets folder, use more std::filesystem

* windows fix

* another one for windows

* another one

* better system for different folders

* rm debugging stuff

* let extractor override everything

* dont revert jak1 change
2022-06-29 23:32:46 -04:00
Tyler Wilding 36dc015d62
jak2: Create goal_src skeleton (#1576) 2022-06-29 22:20:09 -04:00
Tyler Wilding 2d595c1ac0
lint: add include sorting config to clang-format (#1517) 2022-06-22 23:37:46 -04:00
ManDude 7d5045ab3f
PAL & NTSC-J support + updates (#1490)
* PAL dumps files

* alrighty then

* make PAL warning slightly more specific

* PAL patches for `title-obs`

* Update all-types.gc

* PAL patch `beach-obs`

* `process-taskable` PAL patch

* `ambient` PAL patch

* `yakow` PAL patch

* `village-obs` PAL patch

* `sparticle-launcher` patch

* `swamp-obs` PAL patch

* `sequence-a-village1` PAL patch

* typo

* errors

* `powerups` PAL patch

* `ogreboss` PAL patch

* jak 1 v2 encoding

* `load-boundary` PAL patch

* `flying-lurker` PAL patch

* `mayor` PAL patch

* update game encoding to PAL (v2) encoding

* `cam-debug` and `cam-update` PAL patch

* `fisher` PAL patch

* `target` PAL patch

* `target2` PAL patch and fix text compiling

* `target-death` PAL patch

* `target-racer-h` PAL patch

* `logic-target` PAL patch

* `main` PAL patch

* `snow-flutflut-obs` PAL patch

* `rolling-obs` PAL patch

* `gsound` PAL patch

* update refs

* `progress` and `progress-draw` PAL patches

* clang

* wrong.

* complain

* clang

* fix test

* fix blurry jp text

* fix weird interrupt lag from setting window size

* patch more text lines, special handling for credits

* Update FontUtils.cpp

* Add xdelta3 and file patching interface

* add window lock toggle and update settings ver

* better particle hacks

* add PAL support to extractor

* Fix credits

* also NTSC-J support

* make xdelta3 a separate library

* address feedback

Co-authored-by: water <awaterford111445@gmail.com>
2022-06-22 05:16:34 +01:00
water111 ecb2781a89
[decompiler] cleanup to get atomic ops working on jak2 inputs (#1426)
* [decompiler] cleanup to get atomic ops working on jak2 inputs

* clang format
2022-06-08 18:34:52 -04:00
ManDude 0212aa10c9
[decomp] better handling of animation code and art files (#1352)
* update refs

* [decompiler] read and process art groups

* finish decompiler art group selection & detect in `ja-group?`

* make art stuff work on offline tests!

* [decompiler] detect `ja-group!` (primitive)

* corrections.

* more

* use new feature on skel groups!

* find `loop!` as well

* fully fledged `ja` macro & decomp + `loop` detect

* fancy fixed point printing!

* update source

* `:num! max` (i knew i should've done this)

* Update jak1_ntsc_black_label.jsonc

* hi imports

* make compiling the game work

* fix `defskelgroup`

* clang

* update refs

* fix chan

* fix seek and finalboss

* fix tests

* delete unused function

* track let rewrite stats

* reorder `rewrite_let`

* Update .gitattributes

* fix bug with `:num! max`

* Update robotboss-part.gc

* Update goal-lib.gc

* document `ja`

* get rid of pc fixes thing

* use std::abs
2022-05-20 02:30:14 +01:00
ManDude 4d634cf50d
[decomp] add a bunch of flag enums (#1350)
* update refs

* first pass

* update refs 2

* update

* update

* update

* stuff and things

* accidentally wiped this

* fancy decomp for static sound specs

* clang

* 5 more refs
2022-05-02 18:35:17 -04:00
water111 97dc0e14df
[decompiler] performance improvements in extraction (#1309)
* small speedups to extractor

* faster extraction
2022-04-15 20:40:10 -04:00
Tyler Wilding ab063bf7b0
extractor: split up extraction process and allow overriding data dir path (#1302)
* extractor: split up extraction process and allow overriding `data` dir path

* lint: formatting

* deps: add CLI11 dependency

* extractor: refactor CLI arg handling
2022-04-15 18:01:47 -04:00
water111 b263e33e94
[goalc] fix mod bug and add div tests (#1296)
* fix mod bug and add div tests

* update changelog
2022-04-11 20:53:24 -04:00
water111 f341be65e9
remove old ir1 code (#1287) 2022-04-09 11:46:56 -04:00
water111 5bd0b735a5
Add extractor tool (#1276)
* first attempt

* fix

* zip to tar

* windows

* try again, std::filesystem sucks

* std::filesystem is still garbage

* std::filesystem is terrible

* std::filesystem continues to waste my time

* again

* neadsflaldksal;df
2022-04-03 19:17:03 -04:00
water111 9c00b0c135
[graphics] generic merc (#1192)
* begin generic merc

* more generic stuff

* generic dma generation not crashing, at least until high-speed-reject

* c

* unpacker for generic

* starting to work

* small fixes

* more fixes

* more progress

* cleanup

* fix tests

* no custom imgui assert on windows
2022-02-24 22:33:10 -05:00
water111 a1480b5b6e
fix the slide (#1188) 2022-02-20 13:30:08 -05:00
Tyler Wilding ffb04ddd10
Documentation cleanup and some feature improvements (#1155)
* ci: switch to codacy for coverage

* docs: update badges

* decomp: allow overriding config flags via CLI

* cleanup: top level file cleanup

* docs: big README overhaul

Attempt to close #1128 and #1086

* decomp: attempt to detect if `iso_data` is missing or wrongly extracted

* game: switch to `fpng` for screenshots, allow for compression

closes #1035

* game: switch vsync control to a checkbox

* lint: format cpp files

* lint: format json files

* docs/scripts: organize taskfile
2022-02-12 17:48:50 -05:00
ManDude 24578b64b9
proper support for hardcoded "time" types (#1141)
* hardcode `time-frame`things

* Update cam-states_REF.gc

* Update level-info_REF.gc

* update refs 1

* update refs 2

* update refs 3

* update refs 4

* update refs 5

* update detection and casting

* Update FormExpressionAnalysis.cpp

* update refs 6

* update mood decomp

* update refs 7

* update refs 8

* remove temp entity birth code

* update time-frame casts

* fix compiler

* hardcode stuff and fix some types

* fix some bitfield detection being wrong

* bug fixes

* detect seconds on adds with immediate

* update refs 9

* fix casts and rand-vu-int-range bugs (update refs 10)

* update refs 11

* update 12

* update 13

* update 14

* Update game-info_REF.gc

* improve cpad macros detection

* remove unused code

* update refs

* clang

* update source code

* Update cam-states.gc

* `lavatube-energy` finish

* update refs

* fix actor bank stuff

* Update navigate.gc

* reduce entity default stack size

* Update transformq-h.gc

* oops forgot these

* fix code and tests

* fix mood sound stuff

* Update load-dgo.gc

* Update README.md
2022-02-12 12:26:19 -05:00
Tyler Wilding ad2278713c
Do a pass through the remaining files that had issues - add them to ref tests (#1145)
* tests: add `ropebridge`

* tests: add `snow-bunny` to tests

* tests: add `ice-cube`

* tests: can't add `village3-obs` as we dont handle per-file state skipping well

* tests: add `collide-mesh`

* scripts: cleanup Taskfile somemore
2022-02-08 20:23:06 -05:00
water111 78cde74d5a
update readme and fix always playing str (#1139)
* update readme deps

* replace assert

* bump timeout

* fix memory corruption in kernel

* use unknown if level name is invalid
2022-02-08 19:02:47 -05:00
ManDude 5b44aece75
random fixes + support clang-cl on visual studio (#1129)
* delete unused shaders

* hide some options in debug menu

* change fullscreen logic a bit

* add "all actors" toggle

* borderless fix and fix alpha in direct renderer untextured (do we need a separate shader for that?)

* fix fuel cell orbit icons in widescreen

* fix `curve` types

* refs

* fix levitator task...

* fix some task stuff

* update font code a bit (temp)

* cmake, third-party and visual studio overhaul

* Update .gitmodules

* update modules

* clone repos

* fix encoding in zydis

* where did these come from

* try again

* add submodule

* Update 11zip

* Update 11zip

* Update 11zip

* delete

* try again

* clang

* update compiler flags

* delete 11zip. go away.

* Create memory-dump-p2s.py

* properly

* fix minimum architecture c++ compiler flags

* fix zydis

* oops

* Update all-types.gc

* fix clang-cl tests

* make "all actors" work better, entity debug qol

* update game-text conversion code to be more modularized

* Create vendor.txt

* fix typos and minor things

* update refs

* clang

* Attempt to add clang-cl support to vs2019 and CI

* vs2022 + clang-cl

* srsly? fix clang build

* Update launch.vs.json

* extend windows CI timer
2022-02-07 19:15:37 -05:00
water111 bcbd1159dd
Continue cleanup of source files (#1138)
* more cleanup

* tests
2022-02-06 18:53:43 -05:00
Tyler Wilding 142961a747
decomp: the majority of navigate and rolling-lightning-mole (#741)
* decomp: Add texture-upload to ref tests

* maybe 50% done?

* 5 functions to go!

* decomp: stuck in `navigate`

* work-around fp issue

* some cleanup and label casts

* working on supporting asm instructions -- this is currently WRONG

* support ASM operations

* fixes for asm op support

* decomp: finish the vast majority of `navigate`

* format

* update test though i think this suggests a regression!

* decomp: cleanup some more of navigate

* decomp: finish `rolling-lightning-mole`

* revert `r0` handling for `pcpyud` and `pextuw`

* update ref tests

* lint

* fix a failing test

* help

* navigate mostly works now, with some potential bugs

* remove my debugging logs

* update ref tests

* review feedback cleanup

* these are all likely fine

* can't get the crab to chase me anymore

* the crab is back
2022-01-18 01:14:47 -05:00
water111 dc663d8a1f
[game] edge grab, small fixes, add zoomer (#1083)
* fix a few small things

* fix tests

* another fix

* fix tests
2022-01-17 14:36:29 -05:00
Tyler Wilding e65c61f3e2
tests: add a bunch of missing ref tests (#1082)
* scripts: add a script to point out missing ref test files

* tests: add a bunch of files to ref tests we were missing
2022-01-17 11:51:26 -05:00
water111 54c6ddbab9
pass filename through (#1080) 2022-01-15 23:31:07 -05:00
Tyler Wilding b95be06fef
decomp: mostly finish ogreboss (#1024)
* decomp: partially done `ogreboss`

* decomp: finish `ogreboss`

* update

* fix `ogreboss` and `viewer`

* update ref tests

* update ogreboss
2022-01-15 20:33:11 -05:00
Tyler Wilding 50197c0695
cleanup: cleanup all-types and all state definitions (#1062)
* cleanup: cleanup all-types and all state definitions

* these are fine

* these are fine

* these are fine

* everything is fine

* gsrc updated

* remove define-externs in gsrc
2022-01-08 18:23:30 -05:00
Tyler Wilding 004ecd4fe3
decomp: finish target-racer | target-tube (#1042)
* decomp: finish `target-racer`

target-racing-turn-anim was the `cond` issue here

* decomp: finish `target-tube`

target-tube-turn-anim was the issue here
2022-01-04 23:16:29 -05:00
Tyler Wilding a75ecf176e
decomp: finish orbit-plat and sage-finalboss (#1039)
* decomp: finish `orbit-plat` and waiting on `sage-finalboss` inconsistency for gsrc

* decomp: finish `sage-finalboss` except the relocate method

* decomp: add fix to finish `sage-finalboss`

* update formatting in unrelated files
2022-01-04 23:10:53 -05:00
Tyler Wilding da0e9a3930
decomp: finish rolling-obs | hud | title-obs | maincave-obs | lavatube-energy (#1023)
* decomp: `(code caveelevator-one-way-idle-end)` problematic

* decomp: finish `rolling-obs`

* decomp: `snow-obs` finished, but needs s6-1 fix

* stuck: `(code target-title)`

* decomp: finish `hud`

* re-decompile

* decomp: finish `title-obs`

* decomp: finish `maincave-obs`

* decomp: finish `lavatube-energy`

* fixes
2021-12-30 21:27:35 -05:00
Tyler Wilding c6f0c5cd29
decomp: merge all s6-* remappings and finish training-obs | villagep-obs | lavatube-obs | rolling-robber | snow-obs (#1018)
* decompiler: merge all `s6-*` usages

* decomp: finish `training-obs`

* decomp: finish `rolling-robber`

* decomp: finish `villagep-obs`

* decomp: finish `lavatube-obs`

* skip function in `lavatube-obs` over #1029

* closes #1029

* kick nasm

* merge s6 and sp in variable naming pass

* revert my fix

* fix mistakes and a bad method signature

Co-authored-by: water111 <awaterford111445@gmail.com>
2021-12-28 23:16:42 -05:00
Tyler Wilding 99db6bb371
decomp: finish sunken-pipegame | sun-exit-chamber | beach-obs (#1021)
* decomp: finish `sunken-pipegame`

* decomp: finish `sun-exit-chamber`

* decomp: finish `beach-obs`

* fix mistakes

* make `collide-func` work in offline tests
2021-12-28 18:52:52 -05:00
water111 a8342aef31
[graphics] TIE extractor (#1026)
* temp

* temp

* wip

* more progress on the instance asm

* first half of tie extraction, up to dma lists

* more tie extraction

* first part figured out maybe

* bp1 loop seems to work, bp2 loop does not

* bp1 and bp2 appear working. sadly ip is needed

* ip1 outline, not working ip2

* just kidding, ip2 seems to work

* extraction seems to work

* basic rendering working

* tie fixes

* performance optimization of tie renderer

* hook up tie to engine

* fix more bugs

* cleanup and perf improvements

* fix tests

* ref tests

* mm256i for gcc

* CLANG

* windows

* more compile fixes

* fix fast time of day

* small fixes

* fix after merge

* clang
2021-12-26 12:33:51 -05:00
Tyler Wilding 373e9059eb
decomp: add powerups to ref-tests and finish target-flut | target-death (#1017)
* decomp: add `powerups` to ref-tests

* decomp: finish `target-flut`

* decomp: finish `target-death`
2021-12-18 19:13:40 -05:00
Tyler Wilding e6d17eb78f
decomp: finish plant-boss and crates (#1012)
* stuck: `crates` has issues setting bitfield with `r0`

* decomp: finish `plant-boss` except for 1 function

* decomp: finish `crates`

* address feedback
2021-12-18 01:31:14 -05:00
Tyler Wilding f605b0ee38
decomp: generic-obs (#894)
* stash

* more

* and more

* like 80% done

* trying to update things

* refreshed work on generic-obs

* blocked: down to only decompiler issues!

* decomp: finish `generic-obs` skip over the failing functions for now

* `pair` -> `object`s and fix 2/4 of the functions i had skipped

* address feedback
2021-11-13 23:31:29 -05:00
Tyler Wilding 5f1ed7ab60
decomp: decompile *-obs files (#856)
* decomp: mostly finish `cam-master`

* decomp/scripts: lots of work in cam-states

* stash

* Merge remote-tracking branch 'water111/master' into decomp/camera-master

Updated submodule third-party/googletest

* decompiler: Add support for non power of 2 offsets for inline arr access

* decomp: mostly finish `cam-states` need to fix a macro issue

* blocked: `cam-master` decompiler crash when adding casts

* decomp: finish `cam-states-dbg`

* decomp: mostly finish `pov-camera` with the exception of joint-related code

* decomp: `cam-debug` finished decompiling, no way does this compile yet though

* decomp: considerable work done in `cam-layout`

* decomp: `cam-layout` almost done!

* decomp: `pov-camera` finished, TC tests will fail for now

* decomp: working on resolving issues

* decomp: cam-layout decompiling

* fixing more issues in cam-master...one event handler remains

* skip problematic function in `cam-master` for now

* gsrc: update res macros

* decomp: finish `cam-states`

* decomp: giving up on `cam-debug`

* tests: allow skipping state handlers in ref tests

* decomp: working through cam-layout bugs

* decomp: allow for shifting non-integers

* decomp: finalize `cam-layout` and `cam-master`

* decomp: finalize `cam-states`

* cleanup: bi-annual formatting of the casting files

* formatting

* decomp: start working on beach-obs

* blocked: `beach-obs` mostly finished, but handle cast issues and unknown `prebind` func signature

* blocked: `villagep-obs` done, `s6` not being referred to as `self`

* decomp: finish `citadel-obs`

* decomp: finish `darkcave-obs`

* blocked: need to allow `hud-h` to decompile properly (#f as static pointer)

* decomp: finish `jungle-obs`

* decomp: finish `village-obs`

* blocked: `misty-obs` handle cast issues

* decomp: finish `village2-obs`

* decomp: 1 function left in `swamp-obs`, particle related -- maybe we know now?

* decomp: finish `swamp-obs`

* blocked: `maincave-obs` handle casts

* decomp: finish `sunken-obs`

* blocked: `rolling-obs` handle casts and hud-parts

* decomp: finish `firecanyon-obs`

* decomp: finish `ogre-obs`

* blocked: `village3-obs` gives up type analysis!

* blocked: `snow-obs` has hud-parts and handle casts code

* decomp: finish `snow-flutflut-obs`

* blocked: `lavatube-obs` has s6-1 issue

* blocked: `title-obs` handle cast issues

* fixed post merge problems

* decomp: finish `jungleb-obs`

* blocked: `training-obs` has `s6-1` issue

* fix type consistency

* scripts: Extend update script to handle the game-text-id enum as well

* git: Update git attributes to effectively halve PR burden

* fixed `sound-play-by-name` signature

* fix particle definitions in firecanyon-obs

* fix func signature in racer-states

* update ref tests

* tests: update current ref tests

* tests: add `joint` to ref-tests

* tests: add `process-drawable` to ref-tests

* updated gsrc

* add back manual fix

* address most feedback, update source files

* get rid of forward declarations in `darkcave-obs`

Co-authored-by: ManDude <7569514+ManDude@users.noreply.github.com>
2021-11-05 21:29:32 -04:00
water111 8b25a19e92
add ref test for text (#947) 2021-10-26 21:35:23 -04:00
Tyler Wilding 5f040792e9
decomp: finish merc-death and some progress on ocean / powerups (#940)
* blocked: `powerups` finicky handle casts

* stuck: decompiled `ocean-texture` but `ocean-verts` is a mystery to me

* decomp: finish `merc-death`

* fix some issues, add a way to remind us for files we've manually touched

* tests: add `ambient` to ref tests, uncover compiler error

* tests: add `main` and `font` to ref tests
2021-10-26 19:16:16 -04:00
Tyler Wilding 236f298138
decomp: add default-menu to ref tests, cleanup irrelevant gsrc forward decls (#941)
* decomp: add `default-menu` to ref tests, cleanup gsrc

* re-disable function

* decomp: add `drawable-group` to ref-tests
2021-10-25 19:22:52 -04:00
water111 d6f631383e
decomp more level stuff (#932)
* more level stuff

* vi1 to jun load working, with multiple skies

* small fixes

* add level ref test

* clang
2021-10-23 16:00:49 -04:00
water111 49e3fa2963
fix decomp bugs and add ref tests (#930) 2021-10-23 10:41:11 -04:00
Tyler Wilding 45318be063
decomp: finish _almost all of_ the remaining camera code (#845)
* decomp: mostly finish `cam-master`

* decomp/scripts: lots of work in cam-states

* stash

* Merge remote-tracking branch 'water111/master' into decomp/camera-master

Updated submodule third-party/googletest

* decompiler: Add support for non power of 2 offsets for inline arr access

* decomp: mostly finish `cam-states` need to fix a macro issue

* blocked: `cam-master` decompiler crash when adding casts

* decomp: finish `cam-states-dbg`

* decomp: mostly finish `pov-camera` with the exception of joint-related code

* decomp: `cam-debug` finished decompiling, no way does this compile yet though

* decomp: considerable work done in `cam-layout`

* decomp: `cam-layout` almost done!

* decomp: `pov-camera` finished, TC tests will fail for now

* decomp: working on resolving issues

* decomp: cam-layout decompiling

* fixing more issues in cam-master...one event handler remains

* skip problematic function in `cam-master` for now

* gsrc: update res macros

* decomp: finish `cam-states`

* decomp: giving up on `cam-debug`

* tests: allow skipping state handlers in ref tests

* decomp: working through cam-layout bugs

* decomp: allow for shifting non-integers

* decomp: finalize `cam-layout` and `cam-master`

* decomp: finalize `cam-states`

* cleanup: bi-annual formatting of the casting files

* formatting

* address feedback - leave the float labels alone for now

* address feedback

* linting/formatting

* update gsrc and ref tests

Co-authored-by: ManDude <7569514+ManDude@users.noreply.github.com>
2021-10-16 21:01:23 -04:00
ManDude caac740aff
[decomp] fisher and FIN.DGO (finalboss) level (#899)
* decomp `fisher`, `robotboss`, `light-eco`, `green-eco-lurker`, `sage-finalboss`, `robotboss-weapon`, `robotboss-misc`

* fixes

* add files

* add `:states` list to `deftype` and fix files

* test state forward decl's on a few more types

* also the refs

* add light-eco

* whatever
2021-10-16 14:06:33 -04:00
water111 f87646e8ce
Small state fixes (#901)
* small fixes

* catch uncaught exception
2021-10-15 21:31:22 -04:00
water111 3a1c9eaf75
[decompiler] clean up offline test program, reorganize decomp order (#895)
* make a new offline test

* finish up offline test and fix crash bugs
2021-10-12 20:33:26 -04:00
water111 b2052016e2
[decomp] sky/time of day (#883)
* time of day

* goal code seems to work

* stars at wrong spot

* stars and sun work

* debugging clouds

* fix texture correction

* sky works

* cleanup, add profiler

* clean up

* final clean up

* offline tests

* missing include
2021-10-10 20:07:03 -04:00
Tyler Wilding 2cb00f4a02
decomp: anim-tester and a bunch of progress on files that are blocked (#884)
* blocked: `puffer` has state decomp issues

* blocked: decomp crash when adding process-drawble cast in `helix-water`

* blocked: `green-eco-lurker` no nice way to cast value out of EMB

* decomp: started on `citadel-sages`

* decomp: `seagull` blocked state decomp

* blocked: `sunken-pipegame` runs into handle related issues

* blocked: `snow-ram` and `snow-ram-boss` state decomp

* decomp: `rolling-race-ring` blocked, handle casts

* blocked: state decomp in `part-tester`

* decomp: started `joint-exploder`

* blocked: `anim-tester` has rare cmove-#f-zero usage

* decomp: I lied! `anim-tester` finished

* config: update banned list
2021-10-10 19:53:19 -04:00
Tyler Wilding fbcc1542f3
decomp: decompile remaining particle files (#865)
* decomp: finish `beach-part`

* decomp: finish `citadel-part`

* decomp: finish `robotboss-part`

* decomp: finish `sage-finalboss-part`

* decomp: finish `jungle-part`

* decomp: finish `flut-part`

* decomp: finish `firecanyon-part`

* decomp: finish `village2-part2`

* decomp: finish `swamp-part`

* decomp: finish `maincave-part`

* decomp: finish `sunken-part0-5`

* decomp: finish `ogre-part`

* decomp: finish `robocave-part` and `snow-part`

* decomp: finish `collectables-part`

* decomp: finish `village1-part`

* decomp: finish `village1-part2

* decomp: finish `training-part`

* decomp: finish `misty-part`

* decomp: finish `village2-part`

* decomp: finish `village3-part`

* decomp: finish `lavatube-part`

* decomp: finish `hud-h`, `target-racer-h`, `racer-part`

* address feedback
2021-09-29 20:33:40 -04:00
water111 7ebbe812b1
Cleanup sparticle, add ref tests, name a few methods (#863)
* temp

* add reference tests
2021-09-28 21:17:38 -04:00
Tyler Wilding dd959d0d0d
decomp: Continuing full pass of gameplay code (#839)
* decomp: finish `babak` - :code is called in `(code nav-enemy-patrol babak)`

* decomp: almost finish `process-taskable`

* blocked: mistycannon / pelican

* decomp: finish `babak-with-cannon` write a script to fix gsrc

* decomp: finish `process-taskable`

* decomp: finish `flutflut` and `yakow`

* decomp: finish `fishermans-boat`

* blocked: state decomp `training-obs`

* decomp: finish `muse`

* decomp: finish `bonelurker`

* blocked: state decomp in `quicksandlurker`| `balloonlurker`

* decomp: finish `assistant-village2`

* scripts: script to help updating goal_src

* starting to update goal_src

* tests: update ref tests

* src: more src updating

* src: waiting on `process-taskable` and `muse`

* blocked: `citb-plat` state decomp

* decomp: finish `square-platform`

* blocked: `orbit-plat` due to overlays + static data

* decomp: finish `qbert-plat`

* blocked: almost finish `misty-conveyor`, sparticle-callback

* blocked: jungle-mirrors

* blocked: state decomp in `swamp-blimp`

* decomp: finish `swamp-bat`

* decomp: finish `swamp-rat`

* decomp: finish `swamp-rat-nest`

* blocked: state decomp `kermit`

* decomp: finish `cavecrystal-light`

* decomp: finish `spiderwebs`

* blocked: state decomp `dark-crystal`

* decomp: finish `baby-spider`

* decomp: finish `mother-spider-h`

* decomp: finish `mother-spider-proj`

* blocked: state decomp in `gnawer`

* blocked: state decomp in `driller-lurker`

* blocked: `sun-exit-chamber` breaks when adding handle cast

* decomp: finish `sunken-water`

* blocked: `target-tube` ShortCircuitElement::push_to_stack

* decomp: finish `sunken-fish`

* blocked: `minecart` decomp crash when adding stack cast

* decomp: finish `assistant-village3`

* decomp: finish `sage-village3`

* blocked: `cave-trap` done but ran into `go` issue

* blocked: `spider-egg` state decomp

* decomp: finish `target-snowball`

* blocked/stuck: `target-ice` decomp issue around cpad

* pausing: ice-cube has some weird collide-shape-prim handling

* blocked: `snow-ball` state decomp

* blocked: `snow-bumper` state decomp

* decomp: finish `snow-ram-h`

* decomp: finish `yeti`

* decomp: finish `assistant-lavatube`

* re-enable the float cast log

* decomp: updating to new sparticle definitions

* decomp: address feedback up to `swamp-rat-nest`

* address remaining feedback

* all-types: move the `pointer` def

* add back temporary `hud-hidden?`
2021-09-28 20:42:00 -04:00
water111 188373a3f6
decompile some drawable stuff and fix a few small bugs (#859) 2021-09-28 19:24:09 -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 5683f04046
[decomp] handle handle->process inside an and (#851)
* fix the loader example

* improve compiler error message

* fix missing cast issue
2021-09-21 00:12:37 -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
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
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 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 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 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
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 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
water 5aa15afe29 decompile sprite-distort without vu1 stuff 2021-08-13 18:50:29 -04:00
Tyler Wilding a9816f9d28
decomp: finish misty-teetertotter 2021-08-08 17:00:51 -04:00
Tyler Wilding d400ec3b2d
decomp: mood (#672)
* decomp: Almost finished `mood`, but confused over the `mood-context` type!

* only function that remains involves vftoi / ppach instructions

* stash

* decomp: fix inline array access issue

* decomp: finalize `mood`

* linting
2021-08-01 16:11:22 -04:00
Tyler Wilding d37e6c548e
decomp: camera | cam-combiner | cam-start | cam-update (#621)
* started process on `camera`

* the bulk of `camera` is finished, with the exception of a few

* decomp: Confirmed function ret value

* decomp: `cam-combiner` dead code issue

* stash

* decomp: finish `cam-combiner`

* decomp: finish `cam-start`

* decomp: mostly finish `cam-update`, just needs polish now

* `cam-standard-event-handler` still causing issues

* `cam-combiner` issues with top-level `s6` usage

* decomp: update reference tests

* decomp: finalize `cam-start`

* decomp: `cam-update` cleaned up everything except the array of planes issue

* label correction

* still blocked in cam-combiner over casting issues

* decomp:  resolve issues in `cam-start`

* decomp: finalize `cam-update`

* stash

* decomp: finalize `cam-combiner`

* decomp: finalize `camera`

* decomp: address feedback
2021-07-30 22:18:35 -04:00
water111 bd9f550d82
add ref test for sprite and support nested bitfields in static data (#723) 2021-07-26 20:02:16 -04:00
water111 2b6684aa5c
[decompiler] Working toward bsp (#717)
* clean up

* before int to float stuff

* before trying to eliminate the separate read and write maps

* partial fix for register issues

* add missing include
2021-07-25 15:30:37 -04:00
ManDude 1e11a588f5
[decomp] loader prelim work + some cleanup (#697)
* [decomp] `loader` prelim work + some cleanup

* more things

* more

* even more

* yet even more

* minor fixes

* decompiler fix + use behaviors for two funcs

* last functions

* Create loader_REF.gc

* more work

* change vag tool config format + unrelated farmer and yakow stuff

* update some things

* fix some decomp

* cleanup things i came across + make dgo compileable

* fix consistency test

* update refs

* offline test: skip buggy `external-art-buffer` method

* fix test
2021-07-23 18:30:49 -04:00
water111 c76b51d805
clean up to gsound! (#709) 2021-07-19 20:49:33 -04:00
water111 656489e942
[decomp] Clean up - part 2 (#687)
* temp

* temp2

* basic case support

* working for or without else

* support more cases

* clean up to drawable headers

* ocean

* format json
2021-07-11 16:35:25 -04:00
Tyler Wilding 1b5c5239b1
decomp: mostly finish aligner (#686)
* decomp: mostly finish `aligner`

Issues in aligner/aligner-h that require hand-editing after decompilation

* linting
2021-07-11 16:19:03 -04:00
water111 1898c7c52a
[decomp] texture (#684)
* temp

* more cleanup

* fix merge issue

* handle no texture correctly
2021-07-09 22:20:37 -04:00
water111 551a9c4955
[decompiler] ASM Branching Support (#677)
* basic example working in geometry

* before updating offline'

* clean up

* temp

* progress
2021-07-05 16:07:07 -04:00
Tyler Wilding 17aedd894d
decomp: hint-control | menu | default-menu (as much as possible) (#632)
* decomp: mostly done `hint-control`

* decomp: Started and decent chunk of `menu` done

* temp stash

* decomp: escape from `menu` hell

* decomp: starting on `default-menu`

* decomp: As much as i can do in `default-menu` at this time

* decomp: clean up `hint-control`

* decomp: fix reference tests

* temp stash

* decomp: finalize `menu`

* decomp: add `menu` to goal_src

* decomp: finalize `hint-control`

* decomp: Resolve TypeConsistency issues

* and fix reference tests

* address feedback

* format and lint

* fix tests
2021-07-04 18:25:08 -04:00
water111 784cd5debb
[decomp] get started on game info (#674)
* temp

* menu text

* wip

* recognize handle to process

* more
2021-07-03 16:18:41 -04:00
Tyler Wilding bc41241234
decomp: task-control (#654)
* stash

* decompiler: support symbols in arrays

* decomp: a ton of lambda casts

* finish task control?

* add lambda label casts

* decomp: resolve some issues, add enums

* decomp: One last decompiler issue remains

* decomp: finalize `task-control`

* linting

* revert change to test change, didn't mean to commit

* decomp: comment out function call for now
2021-07-02 15:11:28 -04:00
water111 bfc1173ed5
Clean up files in kernel (#625)
* clean up gcommon

* cleanup kernel
2021-06-25 17:55:50 -04:00
water111 06ae38d464
[decomp] clean up type def formatting and remove all-forward-definitions.gc (#608)
* clean up

* fix test
2021-06-19 15:50:52 -04:00
water111 0aa474f12b
[decomp] finish actor-link-h and a few more (#592)
* finish actor-link-h

* decompile files

* fix pp issue
2021-06-14 20:46:54 -04:00
Tyler Wilding 506b5d8ceb
Decompile: prototype | video | vol-h | air-h | nav-enemy-h | rigid-body-h (#575)
* decomp: `prototype` done

* tests/ref: Update all reference tests

* decomp: `video` done

* decomp: Add `video` to src

* decomp: `vol-h` done

* tests/ref: Update reference tests again

* decomp: Add `vol-h` to ref tests, leave `entity` in process as a `basic` for now!

* decomp: `air-h` done, compiler issue though

* decomp: `nav-enemy-h` done, compiler issue though

* decomp: `rigid-body-h` done, compiler issue though

* Address feedback and fix the failing to compile files

* linting

* finish `video` off
2021-06-12 21:52:55 -04:00
water111 92afd62e2c
[decompiler] fix missing casts issue (#573)
* fix casts issue

* fix bug

* one last small fix
2021-06-09 21:35:13 -04:00
water111 fef7fad65a
[decompiler] process-drawable-h (#561)
* decomile process-drawable-h

* one more
2021-06-05 23:55:36 -04:00
water111 54f72e9b10
[decomp] joint-mod-h (#560)
* decompile joint-mod-h

* format'

* missing include

* fix test
2021-06-05 20:22:03 -04:00
water111 3d8013633a
[decompiler] Fix rlet in top level and detect matrix and stack inline construction (#547)
* top level in rlet

* detect matrix and vector inline 0

* pretty print the symbol map
2021-05-31 18:14:18 -04:00
water111 b1a76b2291
[decomp] Small fixes (#541)
* fix a few bugs

* fix local vars missing in top level

* more small fixes

* support missing inline array access case

* one more fix
2021-05-30 19:57:11 -04:00
Tyler Wilding fb939726e8
decomp: Decompile ripple (#512)
* decomp: Decompile `ripple`

* decomp: Finish decompiling `ripple`

* update necessary src files
2021-05-26 19:40:12 -04:00
water111 3fbdd662dc
[decompiler] Support accessing 128-bit bitfields (#514)
* support some 128-bit bitfield stuff

* fix bug

* support type stuff correctly
2021-05-21 20:36:04 -04:00
Tyler Wilding 174a079dbd
decomp: Decompile stats-h (#504)
* decomp: Decompile `stats-h`

* linting
2021-05-20 13:53:19 -04:00
water111 ec412c7777
[decomp] ramdisk, load-dgo and rpc-h (#496)
* decompile ramdisk load-dgo and rpc-h

* add a bunch of offline tests

* clang-format
2021-05-16 21:07:22 -04:00
water111 79d10979da
[decomp] math-camera (#491)
* decompile math camera

* missing line
2021-05-15 20:08:08 -04:00
water111 613efbd768
[decomp] transformq-h, clean up trig, and offline test for trig (#485)
* clean up

* fix store vf fallback errors
2021-05-15 10:38:14 -04:00
water111 129ab54fd4
[decompiler] clean up if/when/cond and recognize define-perm (#472)
* clean up if and when and cond decisions

* recognize define perm
2021-05-12 19:46:17 -04:00
water111 223adeeb0c
Automatically get float label type in most cases (#463)
* automatically get float type in most cases

* try harder to print json errors

* fix test
2021-05-11 21:57:05 -04:00
water111 0599d144f8
[decompiler] Clean up config more (#458)
* remove global config

* fix dir
2021-05-11 20:49:54 -04:00
water111 433993074a
Clean up some errors/crashes in decompiler (#452)
* fix offline tests, clean up some warnings

* clean up warnings during decomp

* fix remaining crash issues
2021-05-11 16:43:13 -04:00
Tyler Wilding 2a315419de
tests: Automate the offline reference tests better (#427)
* tests: Move all files to new directories

* scripts: Update decomp scripts

* tests: Remove hard-coded list for offline tests

* linting
2021-05-09 17:03:58 -04:00
Tyler Wilding 971e0e3e24
decomp: pov-camera-h and hud-h (#425)
* decomp: `pov-camera-h`

* decomp: decompile `hud-h` and update offline tests

* linting
2021-05-07 22:56:37 -04:00
Tyler Wilding 73a4f2c83e
decomp: lights.gc (#420)
* scripts: Hack script to quickly identify the next goal_src file that hasn't been decomp'd yet

* config: Delete old type_hints file

* decomp: Decompile lights.gc

* decomp-tests: Add offline tests and temporary forward defs

* vs: Rename / add new offline test run config

* decomp: Add formatted lights.gc source

* decomp: Temporary define stub in geometry,gc

* decomp: Cleanup `lights-group` handling
2021-05-07 20:54:20 -04:00
water111 21fefa0aaa
[decompiler] small fixes for methods and more reference tests (#419)
* clean up method stuff, fix a few small bugs, and add references for easy -h files

* more small fixes and reference tests
2021-05-06 00:42:49 -04:00
water111 0a6602e320
[Decompile] connect, text-h, settings-h, capture, memory-usage-h (#410)
* decompile stuff

* temp

* temp2

* fix

* temp

* preparing for merge

* working

* fix stupid format

* fix codacy
2021-05-05 17:38:16 -04:00
ManDude 8d99bee88c
[decompile] decomp time-of-day-h, fix mood-h, update sky-h, make art-h almost work (#415)
* [decompiler] make certain floats decompile to constants

* update various types in `mood-h`, `time-of-day-h` and `art-h`

* fix `time-of-day-context`

* add some offline tests

* make `new-dynamic-structure` decompile at least

* formatting

* Update all-types.gc

* Update all-types.gc
2021-05-04 21:36:22 -04:00
ManDude 2beaa7a340
[decomp] cleanup drawable and ocean stuff (#414)
* use `kmalloc-flags` for goal `kmalloc`

* cleanup some drawable stuff, add offline tests

* cleanup generic-h a bit

* make decompiler work on 16-bit static data

* cleanup ocean stuff

* fix `ocean-spheres`

* oops forgot this

* I forgot to actually make `ocean-tables`
2021-05-03 08:54:49 -04:00
ManDude 7cb04c6cd5
[decomp] font-h, fix a vector type, minor decompiler fixes (#411)
* Make `:do-not-decompile` work on field lookup as well

* decompile `font-h` and update a vector type + minor fixes

* fix some types

* fix font-h

* fix font-h (again)

* update a script

* fixes

* Fix segfault

* Fix `PROT_NONE` page protection on windows
2021-05-01 21:09:48 -04:00
water111 7018827a50
decompile display (#408) 2021-05-01 15:51:53 -04:00
water111 70d93354eb
[Decompile] file-io, loader-h, texture-h, level-h, math-camera-h (#397)
* file-io and loader-h

* add test for level-h

* math camera-h
2021-04-28 20:51:17 -04:00
water111 14028b90bc
[Decompile] vector.gc (finally) (#394)
* support psubw

* do half of vector

* rest of vector

* add test

* format
2021-04-28 17:14:54 -04:00
water111 53a70d8e43
clean up display-h (#392) 2021-04-27 19:40:14 -04:00
water111 3d2ca71fe3
[Decompile] pad and gs (#389)
* update stuff

* gs reference added

* update config
2021-04-26 21:40:08 -04:00
water111 2002db359a
[Decompiler] WIP: Stack Spills (#382)
* set up types

* cleaned up type analysis and got things working through atomic ops

* expression working, need types

* improved types and names

* getting close

* finish up dma-disasm

* fix
2021-04-25 14:48:54 -04:00
water111 7737817ac7
[Decomp] Fix bitfields in dma-bucket (#367)
* fix bitfields in dma-bucket

* fix dma-bucket
2021-04-18 12:08:08 -04:00
water111 9867155e7c
[Decompiler] More support for bitfields (#363)
* temp

* initial support for dynamic bitfields

* some more progress on display

* dma-buffer good

* small fixes
2021-04-17 18:35:50 -04:00
water111 e5f0fecf17
[Decompiler] bitfield support and clean up of DMA (#350)
* get to vif

* support basic bitfield access

* make bitfields in dma work

* clean up dma

* fix merge conflict
2021-04-11 16:07:01 -04:00
ManDude 64ae2d6d39
[decomp] sync-info 1 (#351)
* move commonly used scripts to specific folders

* fixes

* Update test.sh

* Update test.sh

* Fix file permission

* move commonly used scripts to specific folders

* fixes

* Update test.sh

* Update test.sh

* Fix file permission

* [dynamics-h] clean-up

* make things neat

* update surface-h

* [sync-info] decomp 1

* move commonly used scripts to specific folders

* fixes

* Update test.sh

* Update test.sh

* Fix file permission

* move commonly used scripts to specific folders

* fixes

* Update test.sh

* Update test.sh

* Fix file permission

* [sync-info] update decomp

* Update gravity-h.gc

* [windows] separate scripts for runtime w/ or w/o display

* Update dynamics-h.gc

* Add offline test for sync-info

* clang
2021-04-10 21:17:36 -04:00
water111 9969445cf7
[Decomp] Math library: transform and quaternion (#344)
* decompile transform

* types for quaternion

* part of quaternion

* finish quaternion

* fix offline test reference

* wip fix to let issue

* fix
2021-04-02 11:35:14 -04:00
water111 0a76e6e157
[Decompiler] Make matrix decompile (#341)
* small fixes

* update

* add instructions

* finish matrix

* add matrix test cases
2021-03-28 20:26:30 -04:00
water111 64c35ca453
[Decompiler] Stack Variables (#338)
* clean up type analysis

* get everything set up

* basic stack variables working

* partial load fix

* most of matrix

* add offline tests
2021-03-27 15:18:59 -04:00
water111 7fac11ddf5
Support 128-bit variables (#336)
* wip 128 bit support

* add a few more files to offline test
2021-03-25 16:02:48 -04:00
water111 99683c0dac
[decompiler] Add tests and fixes for vector-h and math (#333)
* before messing with ssa stuff

* fix ash

* bounding box
2021-03-24 19:16:31 -04:00
water111 9ffc6014e1
fix printing and add gstate (#330) 2021-03-22 20:04:00 -04:00
water111 4262145c99
fix set! missing typecast (#324) 2021-03-17 19:26:35 -04:00
water111 d60d9b639a
support anonymous functions (#323) 2021-03-14 19:06:51 -04:00
water111 e93d97dd07
[decompiler] gkernel offline test (#321)
* working on pointer math

* bug fixes

* gkernel passing with no anon functions

* update tests
2021-03-14 16:11:42 -04:00
water111 814480f9e5
[Decompiler] Replace type hint system and improve variable types. (#320)
* get gkernel and gkernel-h at least somewhat working in the offline tests

* strip comments from json

* switch hints to casts. online tests passing, offline passing up to gkernel

* variable retyping is added

* fix up casts in lets

* update
2021-03-13 16:10:39 -05:00
water111 9074a35b9b
[Decompiler] Fix printing of lets (#314)
* fix let prints and windows warnings

* missing include for windows

* windows again
2021-03-07 12:01:59 -05:00
water111 d8a82eeca1
[Decompiler] Fix up pretty printing and other small changes (#311)
* fix up pretty printing

* wip

* fix pointer cast signed vs unsigned issue
2021-03-06 20:16:48 -05:00
water111 65ffe83468
[Decompiler] Decompile let (#309)
* test

* fix bug

* fix tests for let

* missing formatting fix
2021-03-05 18:48:01 -05:00
water111 d9aa535dd0
[Decompiler] Fix issues in gcommon (#305)
* fix several issues

* small fixes
2021-03-03 20:52:25 -05:00
water111 413c1f5c74
[Decompiler] Add offline tests (#303)
* add offline test for gcommon as an example.

* fix test

* unused var
2021-03-03 15:42:55 -05:00