4c9fa02bf2
Now using ref-cast for casting between repr(transparent) references instead of a From hack.
2020-10-06 08:24:50 +01:00
47303aa8e9
Revised generate_enum_property_option to be closer to an eventual derive.
2020-09-20 02:48:32 +01:00
2a39f8b438
Moved Bytes interface to dcb-bytes crate.
...
Instead of implementing `Bytes for Option<T>`, a proxy is now used, as `dcb-bytes` is in a separate crate.
2020-09-20 02:34:39 +01:00
152c8250ff
Made dcb a workspace and moved the current implementation to the main crate dcb.
2020-09-20 00:45:38 +01:00
a4eba109bf
Moved Digimon's errors to their own module.
2020-09-20 00:34:08 +01:00
aa7edaf92b
Fixed bounds on Bytes's associated types.
2020-09-19 23:38:08 +01:00
1b276918d3
Fixed issue with formatter.
2020-09-18 17:30:31 +01:00
e18612b8c7
Added forgotten invariant on AsciiStrArr.
2020-09-18 17:25:15 +01:00
333fab38b4
Extended interface of AsciiStrArr.
...
`AsciiStrArr` now stores it's chracters as `MaybeUninit`.
Added unit tests to `AsciiStrArr`.
Fixed documentaton with `address::real::ToDataError`.
2020-09-18 17:24:08 +01:00
fac333c0ed
Improved AsciiStrArr.
2020-09-18 04:42:26 +01:00
d66b855ab3
Improved slicing and indexing into AsciiStrArr.
...
Added `TryFrom<&str> for AsciiStrArr<N>`.
2020-09-18 03:56:14 +01:00
cdaf7047f4
Added AsciiStrArr and modified all modules to use it.
2020-09-18 01:45:58 +01:00
65deb1fe84
Added global allow for new clippy lint, clippy::unwrap_in_result.
...
Fixed bug with `Read` and `Write` implementations of `GameFile`.
`Data` and `Real` addresses, now print `0x` before their number to indicate they're hexadecimal.
Added unit tests for `Read` and `Write` implementations of `GameFile`.
2020-09-17 15:48:52 +01:00
32c2de695d
Revised some unit tests for Move.
2020-09-11 14:09:20 +01:00
e85527fdbf
move warning and errors now implement std::error::Error.
...
`From` / `Into` implementations for `Data` and `u64` are now done using `derive_more`.
2020-09-11 13:28:49 +01:00
2ec0a90e58
Simplified Read, Write and Seek implementations of GameFile.
...
Added some unit tests for `game_file`.
Added `Data::remaining_bytes`.
Fixed bug in `Real::try_to_data`.
Renamed `Real::data_section_end` to `cur_sector_data_section_end`.
Added `Real::next_sector_data_section_start`.
2020-09-11 13:25:22 +01:00
68916aa93d
Added try_to_data and to_real methods to the addresses.
...
Started using the new address methods instead of `From` / `TryFrom`.
Moved definition of `TryFrom` and `From` for addresses into their respective modules.
Revised implementation of `Seek` for `GameFile`.
2020-09-10 14:35:07 +01:00
3786c89f18
Added restrictions to Bytes::ByteArray.
2020-09-09 12:38:02 +01:00
46470cdae7
Now using min_const_generics.
2020-09-09 12:35:28 +01:00
faa6beacfa
util::impl_bytes::generate_enum_property_option is now exported in util.
2020-09-09 12:24:41 +01:00
ae8402634a
Turned various functions in util and io const.
...
Added missing `Sub` and `SubAssign` implementations to `io::address::Real`.
Added `from_u64` and `as_u64` to both address types in `io`.
2020-09-09 12:12:08 +01:00
ffd06d4f28
Updated lints to reflect new clippy versions.
...
Moved `clippy::unsafe_derive_deserialize` allow to where it is explicitly allowed, instead of allowing it crate-wide.
2020-09-09 11:56:59 +01:00
7873c5eed3
Moved helper macros to implement Bytes to util.
...
Discovered more fields of `Deck`.
Fixed `DeckTable` having the wrong address for the table.
2020-07-21 18:18:46 +01:00
1e171b7071
Replaced occurencies of 0x{:x} in format strings with the equivalent {:#x}
2020-07-18 22:04:35 +01:00
820b1e3225
Improved card table.
...
Added some features to deck table, such as reading & writing the header.
2020-07-18 22:03:47 +01:00
e89efc849d
Fixed wrong usage of char in documentation.
...
Added some derives to `CardTable`.
Added documentation for `Deck`.
2020-07-14 23:10:09 +01:00
9885563e32
Moved CardTable's errors to it's own module.
...
Changed all `log::debug!` to `log::trace!`.
2020-07-14 22:24:52 +01:00
e62a374d48
Removed unused nightly features.
2020-07-14 22:15:30 +01:00
422a09fcc2
Fixed doc test on lib.rs to use new exports.
2020-07-14 22:13:25 +01:00
09c716a804
Moved util from game module to crate level to add functions more global, outside of game.
...
Removed all `as` conversions lints and fixed code using them.
2020-07-14 22:11:14 +01:00
b08c6431cf
Improved validation interface.
...
Implemented new validation interface for `Move`.
Added more tests to `Move`.
2020-07-14 19:41:23 +01:00
36c429372e
Reworked util module.
...
Changed all functions that read/write ascii strings to a trait.
2020-07-14 18:48:22 +01:00
f5ebcd1cf5
Changed imports style.
2020-07-14 17:58:32 +01:00
b33ba8f2d3
Revised validation interface.
2020-07-14 17:53:34 +01:00
9e1318576a
Removed valicdation interface as-is.
...
Fixed missing documentation accross the whole project.
2020-07-14 17:38:56 +01:00
a561090b76
Removed nightly feature const_if_match, as it's stable as of rust 1.45.0.
2020-07-14 17:25:18 +01:00
Zenithsiz
13c8a2116b
Updated README.md
2020-07-14 12:48:25 +01:00
33ffb13555
Fixed formatting errors from thiserror migration.
2020-07-11 22:03:35 +01:00
d876673326
Changed from err-impl to thiserror for deriving errors.
...
Added `PartialEq`, `Eq`, `Clone` and `Copy` bounds for as many errors as possible.
2020-07-11 21:52:19 +01:00
aa24a5cad9
Added unit tests for Move.
2020-07-11 21:30:05 +01:00
f65ad458fa
Fixed documentation reference being malformed in validation.rs.
2020-05-29 23:54:30 +01:00
0966bc3416
Moved Move card property documentation to it's own file.
2020-05-29 23:32:32 +01:00
615b48f212
Added validation to Move card property.
2020-05-29 23:09:45 +01:00
355da1476e
Added some getters and setters to the Validation interface.
2020-05-23 05:23:30 +01:00
c03f3237bf
Added [Bytes::validate] interface to validate structures before writing them to bytes.
...
Currently all implementations return an empty validation, but they will be developed over time.
2020-05-13 15:58:27 +01:00
a836133e55
Added ability to deserialize a EffectConditionOperation from 0xFF for Aquilamon. Fixes #1 .
...
Added the ability to deserialize extra fields in card properties with the `generate_enum_property_mod` macro.
2020-05-13 15:11:11 +01:00
95d2ea261d
Now using nightly compiler for workflows.
2020-05-13 04:25:57 +01:00
a89ce37da1
Added nightly to github workflow, as well as a rustfmt step to verify formatting.
2020-05-13 04:23:20 +01:00
2940a737e0
Made the err-impl repository public. Workflow builds should now succeed.
2020-05-13 04:15:13 +01:00
8a87ab2bcc
Changed dependency err-impl to be a git dependency.
...
Re-enabled workflow for `clippy` and testing.
2020-05-13 04:03:04 +01:00