Gdpc

Latest version: v7.3.0

Safety actively analyzes 642283 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 2 of 3

6.0.3

Compatible with GDMC-HTTP **>=1.0.0, <2.0.0**.

**Fixes:**
- Fixed a bug when constructing a `Model` without blocks. (Thanks [Phobos97](https://github.com/Phobos97)!)
- Fixed off-by-one in `Rect`/`Box` `.corners`.

6.0.2

Compatible with GDMC-HTTP **>=1.0.0, <2.0.0**.

**Fixes:**
- Added missing "not"s to some WorldSlice docstrings.
- Fixed some broken `Box` functions. (Thanks [MTTVDN](https://github.com/MTTVDN)!)

6.0.1

Compatible with GDMC-HTTP **>=1.0.0, <2.0.0**.

**Fixes:**
- Set `scikit-image` minimum version to `0.19.0`.

6.0.0

Starting from this version, GDPC will use
[semantic versioning](https://semver.org/).

Compatible with GDMC-HTTP **>=1.0.0, <2.0.0**.\
Note that the GDMC-HTTP repository has changed! It can now be found at
https://github.com/Niels-NTG/gdmc_http_interface


Changes

This version is a complete overhaul of the entire library. It brings **many,
many** new features, improvements and bugfixes, but it also breaks compatibility
almost everywhere.

Due to the sheer amount of breaking changes, this entry won't list them
exhaustively. You can assume that nothing is compatible. It is recommended to
re-learn the API using the examples and tutorials mentioned in the README.
The good news is that the significant architectural improvements in this version
will reduce the need for substantial breaking changes in the future.

Now, on to the changes - mostly in prose. This listing may be incomplete, but
should mention everything major.

5.0.0

an Interface instance with x, y and z offsets. That is, GDPC 5.0.0 supported
*translations*. This version, however, enhances this with 90-degree rotations
around the Y-axis and flipping/mirroring operations.

At the core of the transformation system lies the `Transform` class, which
essentially acts as a transformation matrix. It stores a translation (a 3D
vector), a rotation around the Y-axis (0, 1, 2 or 3) and a boolean flip vector.
Transforms can be multiplied like matrices, and they can be applied to vectors.

The `Block` class contains functionality that ensures that even *individual
blocks* which have an orientation (such as stairs) are rotated and flipped
correctly.

The `Editor` class now has a `.transform` attribute that defines that editor's
"point of view". It is applied to all block placement and retrieval positions.
You can modify this transform to change the editor's local coordinate system.

See the transformation tutorial for more details about the transformation
system.


Other changes

**Additions:**

- GDPC is now fully type hinted!

- Some important objects are now re-exported from `__init__.py`. That means
you can now use\
`from gdpc import Editor, Block, Transform, Rect, Box`.

- Mostly thanks to a change in GDMC-HTTP, you can now interact with different
dimensions! Simply modify `Editor.dimension`
(e.g. `Editor.dimension = "the_nether"`).

- Mostly thanks to a change in GDMC-HTTP, you can now directly retrieve biomes
using `Editor.getBiome()`.

- `Editor.placeBlock()` can now place multiple of the same block at once, with
improved performance.

- `Editor.runCommand()` can now run the command with a specific execution
position.

- `Editor.runCommand()` can now optionally defer the command until after the
next block buffer flush.

- `Editor` now has a new optional performance feature: it can automatically
multithread buffer flushes. Note however that this feature only rarely
improves performance and may come with some significant downsides. See the
editor performance tutorial for more information.

- You can now change the GDMC HTTP interface host from the default
`"http://localhost:9000"` - simply modify `Editor.host`.

- Block palettes now support "no placement" entries - simply use `Block(None)`.
Contrary to `Block("air")`, these "empty" blocks don't overwrite existing
blocks on placement.

- For most functions in `geometry`, there is now a corresponding function in
`vector_tools` that will yield all points of the shape directly, without
placing any blocks.

- `bookData()` (previously called `writeBook()`) now properly escapes the passed
text, title, author and description strings. You can now freely use characters
like `'` and `\`.

- `lookup.py` has been updated with all Minecraft 1.18 blocks, and most 1.19
blocks.


**Changes:**

- GDPC no longer prints anything directly. Most prints have been removed or
replaced with exceptions, and for those where this was not possible, GDPC now
uses the `logging` module. You can now disable all GDPC console output using
`logging.getLogger("gdpc").setLevel(logging.CRITICAL + 1)`.

- Exception messages are no longer colored.

- GDPC no longer checks the build area - it no longer prints warnings when
placing blocks outside of it. Build area warnings/enforcement may be added
to GDMC-HTTP in a future version.

- Various custom exception types have been added for specific GDPC errors.

- Exception messages for GDMC HTTP interface-related errors are now more
descriptive.

- Various functions that previously silently returned a default value on error
now throw an exception instead.

- All requests to the GDMC HTTP interface now perform some retries before
throwing an exception. The amount of retries is configurable.

- GDPC no longer sends any requests on import, so it will no longer crash on
import when Minecraft is not running.

- Thanks to a change in GDMC-HTTP, you now only need to place one block of a
multi-block object such as a door or a bed to place the entire thing.

- The block buffer of an `Editor` now also acts as a cache, ensuring that the
buffering mode is fully transparent.

- The integration of `Editor` and `WorldSlice` has been improved. See the
editor performance tutorial for more details.

- Some functions have been removed from `geometry`, and various new ones have
been added.

- `bookData()` no longer adds hardcoded pages to the created book.

- Metadata dunders like `__version__` are now only available from `__init__.py`,
but there are now more of them.


**Fixes:**

- Lots of bugs have been fixed, though no doubt many new ones have been
introduced as well. ;)


Older versions

For older versions, see
https://github.com/nikigawlik/gdmc_http_client_python/releases

1.19.2

Mostly thanks to work in the GDMC-HTTP mod, GDPC is now compatible with
Minecraft 1.19.2! On the technical side, that means it now supports negative
Y-coordinates and cubic biomes.

Unfortunately, the GDMC-HTTP mod is not backwards compatible with Minecraft

Page 2 of 3

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.