0
Commit Graph

322 Commits

Author SHA1 Message Date
Gijs Oortgiese
885fa75f54 Add bee_hive, beenest, honeycom_block and honey_block 2019-12-27 14:17:34 +01:00
Nicolas F
0b74d26c49 Completely change biome code again
Turns out my previous grasp of how Minecraft does this was wrong.

This seems to be the correct way. One side effect is that biome data
now has less resolution. One only really notices this when looking at
water, for which Minecraft does not even use the water colours for
in-game, otherwise I can't really tell a big difference.

Fixes #1698.
2019-12-23 23:50:20 +01:00
Nicolas F
268938a706 Fix biomes for Minecraft 1.15
Fixes #1650.

Mojang changed the biomes code so that it now can have different
biomes for different Y levels. We need to adjust our logic accordingly,
which is done through some small BiomeDispensary class where we shove
a numpy'd Mojang array in and can then read out the biomes for each level.

Biome data is now stored per-section, which needed some changes on the C
side of things. I didn't change anything in the biome overlay code so
I wouldn't be surprised if it's broken now, but for the time being I'd
rather have 1.15 fixed than some obscure overlay.

Tested to work with 1.14 and 1.15 data. No new biomes have been added
to the code yet.
2019-12-10 23:12:16 +01:00
Ian Salmons
9e27e6adc9 add composter 2019-11-01 11:45:00 +01:00
InrcedibleHolg
3c3e958eae add bamboo 2019-11-01 10:50:20 +01:00
InrcedibleHolg
17bb942b94 add missing smooth_red_sandstone_stairs 2019-10-27 11:46:20 +01:00
Florian Graf
935bdb847d feat: added 1.14 scaffolding block 2019-10-27 09:10:55 +01:00
InrcedibleHolg
20fde52236 add new stone walls 2019-10-27 09:07:00 +01:00
Gijs Oortgiese
7342085140 Created seperate sapling blocks and added bamboo_sapling 2019-08-21 09:44:37 +02:00
Nicolas F
3498641d4e Merge rebased sign changes from Gyzie's 1-14-signs (#1627) 2019-08-19 12:36:57 +02:00
Gijs Oortgiese
f73e5d92ff Added sign variants added in 1.14 2019-08-19 12:35:56 +02:00
InrcedibleHolg
cdcb88b0f2 Implement new stairs fix stone stairs and slabs
added code change requests by @CounterPillow
2019-08-17 11:09:03 +02:00
Nicolas F
3b96158fb4 Implement smooth sandstone stairs 2019-08-06 14:26:03 +02:00
Nicolas F
b28073c3a7 Increase overviewer C extension version to 71 2019-08-02 17:12:04 +02:00
InrcedibleHolg
a5d9787071 Lantern implemented
enforcing coding style
2019-07-30 14:43:04 +02:00
Nicolas F
7e2cb56c1b Implement some mossy blocks
This adds:
- mossy stone brick stairs
- mossy cobblestone stairs
- mossy stone brick walls

We also add another block class for walls, and while we're at it,
clean up the stairs texture function to not have a huge sprawling
elif mess for loading textures, but instead to a cheeky dictionary
lookup.

In case you're wondering, yes I am just as disgusted by this code as
you are.
2019-07-15 17:23:25 +02:00
Nicolas F
634e13c92c Merge branch 'workstations' of https://github.com/IncredibleHolg/Minecraft-Overviewer 2019-07-13 17:37:58 +02:00
InrcedibleHolg
419889c1f1 add workstations: blastfurnace, smoker, lectern, loom, stonecutter and grindstone 2019-07-12 21:16:22 +02:00
Nicolas F
aeeaadd5bb Bump C extension version to 68 2019-07-12 15:27:42 +02:00
Wunkolo
4298aea569 Fix GCC signed-unsigned and pointer-warnings (#1608)
* Fix GCC signed-unsigned and pointer-warnings

A lot of the signed/unsigned issues are related to the fact that I converted
a lot of indexing values to use unsigned types, little did I know that a lot of
other values used when indexing actually come from the python-end. Python does
not have built-in unsigned types so all integers coming from Python are signed
implicitly so a lot of things like image-size and x, y coordiantes are specially
handling negative-integer cases.

Guess we'll just take our `int32_t i = 0; i < blah; ++i` and like it.

Code now compiles with no warnings or nagging.
2019-07-12 15:26:45 +02:00
Nicolas F
221b2c6805 Bump C extension version to 67 2019-07-10 18:37:38 +02:00
Nicolas F
4f3c7368ba Merge branch 'posix-types' of Wunkolo (#1598) 2019-07-10 18:36:32 +02:00
Nicolas F
6b0ccc1513 src/primitives/base: don't try to free nullpointer
If loading the grass and foliage biome colour fails, Overviewer doesn't
necessarily crash, it just renders everything gray, apart from one small
issue: in trying to call base_finish, it'd crash trying to decrease the
reference of a null pointer.
2019-07-06 23:15:55 +02:00
Wunkolo
22840d5a97 Implement straggler standard integer types 2019-06-26 10:29:10 -07:00
Wunkolo
5b212dc585 Implement standard C boolean type 2019-06-25 14:19:12 -07:00
Wunkolo
d738c21852 Propagate block, bool, standard integer types across codebase
Posix type integer pass

Propagate block, bool, integer types across codebase

Add standard integer types to prototypes
2019-06-25 11:56:11 -07:00
Wunkolo
8162f3f877 Add .clang_format
Also applies clang-format to the current code base, using command:
`find . -regex '.*\.\(c\|h\)' -exec clang-format -style=file -i {} \;`
2019-06-23 18:43:32 -07:00
Aaron Griffith
676bf32af9 another version bump, to test out new builder 2019-06-23 14:35:37 -04:00
Aaron Griffith
ec13bc03cf bump extension version 2019-06-23 13:54:26 -04:00
Aaron Griffith
9a52a02f13 Bumped extension version. 2019-06-21 22:10:01 -04:00
Aaron Griffith
248ea42dd2 Merge branch 'master' into python3-fun-times 2019-06-21 22:08:58 -04:00
InrcedibleHolg
702e4e9e8b added new 1.14 slabs, referencing issue #1560 2019-04-28 10:48:57 +02:00
Nicolas F
134d6063bf primitives: misc char -> short fixes 2019-04-07 20:25:53 +02:00
InrcedibleHolg
5df95be17a added: prismarine_brick_stairs, prismarine_slab, dark_prismarine_slab, prismarine_brick_slab 2019-04-06 21:56:30 +02:00
Nicolas F
1ab66dddea fix prismarine stairs
Sorry for the noise in mc_id.h, but somebody decided they want DOS
line endings and I couldn't allow that to happen. When not doing that
put the whole thing into diff, I decided to just fix the indentation
too while I was at it.

Needed bugfixing of some overlooked unsigned char usages for block IDs,
as otherwise the lighting would be scuffed.

Concerns issue #1486.
2019-03-31 19:20:10 +02:00
Wunkolo
4b0b50f215 Implement style fixes 2019-03-18 14:04:36 -07:00
Wunkolo
62dcfab7a0 Fix block_class_is_subset linkage 2019-03-17 20:21:03 -07:00
Wunkolo
121b0d96ab Increment extension version 2019-03-17 18:48:06 -07:00
Wunkolo
26bd4d120a Fix implicit declaration 2019-03-17 18:46:45 -07:00
Wunkolo
1271772aa1 Collapse special case logic to block_class_is_subset
Thanks demorgan's law
2019-03-17 18:02:44 -07:00
Wunkolo
5ff6a6400e Convert case switch to block_class_is_subset 2019-03-17 17:57:18 -07:00
Wunkolo
ee9a3411ba block_class_is_subset implementation pass 2019-03-17 17:33:30 -07:00
Wunkolo
2c3d54ea5d Implement block_class header 2019-03-17 15:09:33 -07:00
Wunkolo
eb9d6a98e5 Increment overviewer extension version 2019-03-17 12:05:32 -07:00
Nicolas F
e348a548b6 Initial Python 3 port
Many things work, some don't. Notably, genPOI doesn't work, and
there's some signedness comparison stuff going on in the C extension.

This also completely drops support for Python 2, as maintaining a C
extension for both Python 2 and 3 is a pain and not worth it for the
9 months that Python 2 is still going to be supported upstream.

The documentation needs to be adjusted as well.

All of the few tests we have pass, and rendering a map works, both
with a configuration file and without. We can also use optimizeimages.

Concerns #1528.
2019-03-17 17:57:07 +01:00
Wunkolo
50f12827f5 Block ID enum pass 2019-03-16 22:42:08 -07:00
Wunkolo
4d4df31ece Block ID to mc_id replacement pass 2019-03-16 21:15:08 -07:00
Wunkolo
7e97544f4d First pass mc_id enum implementation 2019-03-16 20:21:44 -07:00
Nicolas F
b70f1a012f Fix C extension build warnings the painful way
Some bad distributions (Debian) apparently are not good enough to
have a Pillow version from this decade packaged.

Therefore, we need to do it the painful way of prefixing our
symbols and refactoring everything to use them.

A new header file called "utils.h" has been added for this purpose,
and it is included in "overviewer.h".

The following macros have been prefixed with "OV_":
- MIN
- MAX
- CLAMP
- BLEND
- MULDIV255

Additionally, the C extension version was bumped to 56 because 55
was reverted back to 54.
2019-02-22 12:53:47 +01:00
Aaron Griffith
fc4a8ec38d Revert "Fix C extension build warnings"
This reverts commit 03a8697866.

Turns out there was a good reason for this: it makes Overviewer work on
Debian. Why? Who knows. It's a mystery.
2019-02-21 17:08:39 -05:00