jak-project/game
Hat Kid c64eea6337
[buildactor] support generating collide-meshes for custom models (#3540)
This adds support for generating collide meshes when importing custom
models. A couple of things to keep in mind:

- A single `collide-mesh` may only have up to 255 vertices.
- When exporting a GLTF file in Blender, a `collide-mesh` will be
generated for every mesh object that has collision properties applied
(ideally, you would set all visual meshes to `ignore` and your collision
meshes to `invisible` in the OpenGOAL plugin's custom properties).
- Ensure that your actor using the model properly allocates enough
`collide-shape-prim-mesh`es for each `collide-mesh` ([example from the
original game that uses multiple
meshes](f6688659f2/goal_src/jak1/levels/finalboss/robotboss.gc (L2628-L2806))).

~One annoying problem that I haven't fully figured out yet (unrelated to
the actual functionality):
`collide-mesh`es are stored in art groups as an `(array collide-mesh)`
in the `art-joint-geo`'s `extra`, so I had to add a new `Res` type to
support this. The way that `array`s are stored in `res-lump`s is a bit
of a hack right now. The lump only stores a pointer to the array, so the
size of that is 4 bytes, but because we have to generate all the actual
array data too, the current `ResLump` code in C++ doesn't handle this
case well and would assert, so I decided to omit the asserts if an
`array` tag is present and "fake" the size so the object file is
generated more closely to how the game expects it until we figure out
something better.~
This was fixed by generating the array data beforehand and creating a
`ResRef` class that takes the pointer to the array data and adds it to
the lump.
2024-05-29 06:09:20 +02:00
..
assets CI: Periodic Controller Database Update (#3528) 2024-05-25 10:51:09 -04:00
common jak2/3: re-implement screenshot system through goal (#3482) 2024-04-25 01:46:18 +01:00
external jak3: add discord rpc and fix some decomp (#3500) 2024-05-01 13:49:26 +02:00
graphics [buildactor] support generating collide-meshes for custom models (#3540) 2024-05-29 06:09:20 +02:00
kernel decomp3: decompile remaining mission code (#3515) 2024-05-16 16:21:44 +02:00
mips2c jak 3 shadows (#3530) 2024-05-23 18:29:42 +01:00
overlord jak3: fix hud sprite crash + add entity debugger (#3516) 2024-05-13 04:09:25 +01:00
sce decomp3: spawn target, add merc and particle buckets and some temporary hacks (#3445) 2024-04-05 00:07:39 -04:00
settings game: allow overriding the config directory location (#3477) 2024-04-28 15:29:20 -04:00
sound deps: update fmt to latest version (#3403) 2024-03-05 22:11:52 -05:00
system fix c++ compiler warnings, extract_merc assert (#3488) 2024-05-03 17:29:18 +01:00
tools deps: update fmt to latest version (#3403) 2024-03-05 22:11:52 -05:00
CMakeLists.txt jak 3 shadows (#3530) 2024-05-23 18:29:42 +01:00
main.cpp game: fix the path the--portable flag determines (#3537) 2024-05-26 00:40:33 -04:00
runtime.cpp [jak3] Decomp for gkernel, gkernel-h, gstate, gstring (#3326) 2024-01-21 18:08:05 -05:00
runtime.h g/j2: Integrate highscores with Speedrun.com/JakSpeedruns.com when speedrunner mode is enabled (#3037) 2023-10-11 20:43:55 -04:00