1
Fork 0
mirror of https://github.com/redstrate/Physis.git synced 2025-07-20 07:47:45 +00:00
Commit graph

32 commits

Author SHA1 Message Date
209e62e5b5 Fix tests due to API changes 2025-06-30 21:43:33 -04:00
862b16b681 Fix reading subrow ids again, add helpers to get subrow 2025-06-30 21:29:23 -04:00
6ebb7acfcd Add support for reading subrows and their ids 2025-06-30 19:59:25 -04:00
1d3192de23 Fix various Cargo and Clippy warnings 2025-06-02 17:32:31 -04:00
8a3e8dad64 Move EXD parsing functions into their own module
It was getting hard to work in here, so I moved all of the
private-API-parsing-things into their own file.
2025-05-10 23:51:22 -04:00
8d94c630ab Improve EXD documentation 2025-05-10 23:41:21 -04:00
0313f75abb Fix how we read/write packed booleans in EXD, add another write test
Apparently we were reading packed booleans wrong the whole time
(whoops!) They are packed into *bytes*, oops... That is fixed now, and I
also expanded write support for packed booleans. It makes the assumption
that the byte is always at the end of the row, but I think that's OK for
now.

I also added a good test-case for this, the PhysicsGroup EXD. It has a
lot of rows, and some packed booleans thrown in. The columns also have
out-of-order column definitions (as in, their offsets don't increase in
order.)
2025-05-10 23:31:53 -04:00
dae35ecfb8 Extend EXD writing to support strings, add new test cases
Now we can re-create OpeningSystemDefine, and is added as a new test
case to test reading/writing string columns. This was actually quite
fun, it turns out that they like aligning the data sections to a 4-byte
boundary for some reason.
2025-05-10 22:55:00 -04:00
36304a2e57 Finish basic EXD write support, add tests for GCShop
Expanding upon the EXH tests of this same data, we can successfully
write it back (hence why it's testdata now!) A lot of the writing logic
is specific for this EXD, but it's a start.
2025-05-10 21:38:47 -04:00
c5613cd431 Add support for writing EXH files
This is an easy format to add write support for, and we can recreate the
"GCShop" EXH which is super simple as it's just one page and one
language.
2025-05-10 19:06:06 -04:00
347631e395 Add helper methods to ColumnData to help convert it to underlying data
It's slightly awkward to get data out of this type, because you have to
match it usually. I have added to_x() members instead to make it much
easier.
2025-05-09 17:58:56 -04:00
5efa3c9663 Add EXD::get_row function 2025-04-28 23:36:51 -04:00
e29e1bfde9 Revert some of the EXD reading changes to fix Item sheet parsing 2025-04-28 21:59:07 -04:00
61a24971c2 Move model stuff to it's own module 2025-04-28 16:57:02 -04:00
26c4041b68 Refactor EXD parsing, begin adding write support 2025-04-28 16:42:32 -04:00
2db0717141 Fix EXD test 2025-03-23 18:40:44 -04:00
d3918c1382 Actually use row ids in EXD files
I'm an idiot, these row ids are here for a reason and are important for actually
reading Excel sheets. The API has changed to a read_row() function that takes a
row id, and I'll improve it before release.
2025-03-15 21:40:34 -04:00
bb7c74fec8 Redesign how IndexFile parsing works, again
Now it reads much more of the index file format, and tries to handle
index1/index2 differences more opaquely. I'm not yet happy with the API, it
needs a bit more work.
2025-03-06 18:52:26 -05:00
d5b3b8a468 Run cargo fmt 2024-04-20 13:18:03 -04:00
d9bf25cb0e Add invalid data test for EXD 2024-04-16 21:52:14 -04:00
90bd2d334d Reorganize some functions in EXD 2024-04-14 13:28:43 -04:00
7a75c170cc Make a semantic difference between owned and non-owned byte data 2023-10-13 16:16:04 -04:00
2000b978b3 Ensure compliance with REUSE, add to CI 2023-08-06 08:25:04 -04:00
69c3ca3bf9 Upgrade dependencies, including moving to binrw 0.11 which breaks stuff
The one exception is bitflags, because 2.0 has breaking changes I can't
work around...
2023-03-31 17:30:30 -04:00
177523831b Switch a lot more parsers from binread -> binrw
This doesn't necessarily mean that these formats support writing (yet)
but just to solve the initial compilation errors.
2022-10-13 17:11:03 -04:00
9819f87fcc Suppress some warnings 2022-09-15 16:26:31 -04:00
d9e79e563a Reformat code 2022-08-16 11:52:07 -04:00
c7184cb36f Fix Clippy warnings and errors 2022-08-16 11:50:18 -04:00
be9c850fc1 Remove some warnings 2022-07-27 21:21:50 -04:00
7486c558ce Remove repr(C) from ColumnData 2022-07-21 21:01:48 -04:00
036a37c839 Make ColumnData repr(C), make EXH members public outside of crate 2022-07-21 20:25:37 -04:00
ca4962c876 Add EXH and EXD parsers 2022-07-21 19:58:58 -04:00