decomp: add a bunch of enemy files (#2101)

Adds the following files:

- `amphibian`
- `centurion`
- `ginsu`
- `grenadier`
- `hopper`
- `metalmonk`
- `monster-frog`
- `predator-graph`
- `predator-h`
- `predator`
- `rapid-gunner`
- `rhino`
- `rhino-wall`
- `tomb-baby-spider`

Also adds the DGOs for the following levels:

- Mar's Tomb
- Mountain Temple
- Drill Platform
- Sacred Site (Sage Hut)

Manual patches:

- The decompiler emits `(b! #t cfg-17)` in `(trans hostile hopper)`
without putting a `(label cfg-17)` anywhere
- Added cast to `art-joint-anim` in `(code broken rhino-wall)` and
`(code hit rhino-wall)`

Other notes:

- `amphibian` seems to occasionally crash when using its tongue attack.
Haven't investigated this yet
- `ginsu` crashes after being killed somewhere in the `deactivate`
method, possibly because of its `part-spawner`
- Predators aren't spawning in the forest hunt mission, not sure if
`forest-obs` might be needed for that or if it's something else
- The `rhino-wall` STR animation seems to load (albeit a bit broken due
to missing VAG stream playback), but causes the viewport to shrink as
soon as it's played
- I added `pegasus::74` to the `event_handler_hack` bool in
`variable_naming.cpp` because I got a `none` cast after changing the
return value of `enemy::74`
This commit is contained in:
Hat Kid
2023-01-07 23:14:12 +01:00
committed by GitHub
parent 00ac12094e
commit bdee98323d
60 changed files with 37190 additions and 1196 deletions
+2 -1
View File
@@ -735,7 +735,8 @@ void SSA::make_vars(const Function& function, const DecompilerTypeSystem& dts) {
if (function.ir2.env.version == GameVersion::Jak2) {
event_handler_hack = function.guessed_name.is_event_handler() ||
function.guessed_name.to_string() == "target-generic-event-handler" ||
function.guessed_name.to_string() == "target-standard-event-handler";
function.guessed_name.to_string() == "target-standard-event-handler" ||
function.guessed_name.to_string() == "(method 74 pegasus)";
}
for (int block_id = 0; block_id < int(blocks.size()); block_id++) {