Commit Graph

10 Commits

Author SHA1 Message Date
Silvris 218cd45844
APProcedurePatch: fix RLE/COPY incorrect sizing ()
* change class variables to instance variables

* Update worlds/Files.py

Co-authored-by: black-sliver <59490463+black-sliver@users.noreply.github.com>

* Update worlds/Files.py

Co-authored-by: black-sliver <59490463+black-sliver@users.noreply.github.com>

* move required_extensions to tuple

* fix missing tuple ellipsis

* fix classvar mixup

* rename tokens to _tokens. use hasattr

* type hint cleanup

* Update Files.py

* check using isinstance instead

* Update Files.py

---------

Co-authored-by: black-sliver <59490463+black-sliver@users.noreply.github.com>
2024-03-22 09:02:38 +01:00
Silvris f4b7c28a33
APProcedurePatch: hotfix changing class variables to instance variables ()
* change class variables to instance variables

* Update worlds/Files.py

Co-authored-by: black-sliver <59490463+black-sliver@users.noreply.github.com>

* Update worlds/Files.py

Co-authored-by: black-sliver <59490463+black-sliver@users.noreply.github.com>

* move required_extensions to tuple

* fix missing tuple ellipsis

* fix classvar mixup

* rename tokens to _tokens. use hasattr

* type hint cleanup

* Update Files.py

* check using isinstance instead

---------

Co-authored-by: black-sliver <59490463+black-sliver@users.noreply.github.com>
2024-03-20 23:45:32 +01:00
Silvris 94650a02de
Core: implement APProcedurePatch and APTokenMixin ()
* initial work on procedure patch

* more flexibility

load default procedure for version 5 patches
add args for procedure
add default extension for tokens and bsdiff
allow specifying additional required extensions for generation

* pushing current changes to go fix tloz bug

* move tokens into a separate inheritable class

* forgot the commit to remove token from ProcedurePatch

* further cleaning from bad commit

* start on docstrings

* further work on docstrings and typing

* improve docstrings

* fix incorrect docstring

* cleanup

* clean defaults and docstring

* define interface that has only the bare minimum required
for `Patch.create_rom_file`

* change to dictionary.get

* remove unnecessary if statement

* update to explicitly check for procedure, restore compatible version and manual override

* Update Files.py

* remove struct uses

* ensure returning bytes, add token type checking

* Apply suggestions from code review

Co-authored-by: Doug Hoskisson <beauxq@users.noreply.github.com>

* pep8

---------

Co-authored-by: beauxq <beauxq@yahoo.com>
Co-authored-by: Doug Hoskisson <beauxq@users.noreply.github.com>
2024-03-19 23:08:29 +01:00
Doug Hoskisson e534abeab0
Core: add layer for patches that don't use `Patch.py` ()
* Core: add layer for patches that don't use `Patch.py`

* bump container version

* APAutoPatchInterface name

* mystic quest change

* OoT and Adventure changes

* missed name in docstring

* container version compatibility
2024-03-14 22:29:29 +01:00
Doug Hoskisson ecec931e9f
Core: fix (typing) mistake in PR ()
I made this variable for more compatible and safer type narrowing, and then I didn't use if for the type narrowing.
2024-03-04 08:26:52 +01:00
Doug Hoskisson 4e31e51d7a
Core: clarify error message when reading an `APContainer` () 2024-03-03 20:09:06 +01:00
Doug Hoskisson 475e803500
Core: APPatch interface ()
define interface that has only the bare minimum required
for `Patch.create_rom_file`
2024-02-15 00:23:05 +01:00
Fabian Dill ef7d8a6b4f
Core: limit parallel APContainer writing ()
Co-authored-by: black-sliver <59490463+black-sliver@users.noreply.github.com>
2023-11-13 06:46:40 +01:00
Alchav 30a4bcbbbe
[Pokemon Red and Blue] Initial implementation () 2022-10-13 07:45:52 +02:00
Fabian Dill 61e39f355d
Core remove legacy patch ()
Co-authored-by: black-sliver <59490463+black-sliver@users.noreply.github.com>
2022-09-30 00:36:30 +02:00