0
Commit Graph

309 Commits

Author SHA1 Message Date
Nicolas F
6251a6c730 Merge PR #1716 by Auron956 2020-02-11 07:38:43 +01:00
Nicolas F
021e88dd4a Merge pull request #1699 from sjamesr/py3.4-compat
Fix construct requiring >=Python3.5
2020-02-11 06:52:51 +01:00
Auron956
a3960bd419 Fix chest rendering by using 'type' property
Resolves an issue where chests with more than one adjacent chest would
fail to render. Instead of distinguishing double from single chests by
checking for the presence of adjacent chests, use the provided "type"
property of chests to determine if they are single or the left/right
part of a double chest.
2020-02-04 00:16:28 +00:00
Nicolas F
bdca0b9250 textures: clean up chest code
- drop 1.14 compatibility
- code style fixes
2019-12-27 14:42:55 +01:00
Nicolas F
19b5f70fda Merge chest fix of Gyzie into 115 2019-12-27 14:25:38 +01:00
Nicolas F
7538eb42c3 1.15 release preparations
- Update texture error string
- Update docs
- Add missing newline at the end of textures.py
2019-12-27 14:23:01 +01:00
Gijs Oortgiese
885fa75f54 Add bee_hive, beenest, honeycom_block and honey_block 2019-12-27 14:17:34 +01:00
Gijs Oortgiese
050f3dbae4 Updated chests to support 1.15 textures 2019-12-27 00:00:44 +01:00
James Ring
317cce307f Fix construct requiring >=Python3.5 2019-12-24 16:48:09 +00: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
InrcedibleHolg
fa954714ae adapt id for bamboo sapling 2019-10-27 09:36:43 +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
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
e0e33a9acb textures: fix texturepath option not being used
If the first texture loaded was not in the pack, i.e. we fell back
on system textures, then the pack was ignored altogether for the
remainder of the render.

Here we fix this by using an OrderedDict instead of the split jars
and jarpath nonsense, and then always checking the custom textures
first and opening them if they are not already open, and putting
the jar file handle at the start of the OrderedDict.

We also switch around some logic to avoid unnecessary isdir calls
when we're using a resource pack.
2019-07-09 14:20:31 +02:00
Nicolas F
a6bcc0f957 textures: implement proper fallback loading
Sometimes a texture pack is not complete, but system textures are
available to make up the difference. In that case, we should load
those.

Current caveat is that we might not notice texture names changing
with newer minecraft clients because we have old ones installed.

I'll have to think some more about that one.
2019-07-06 23:36:47 +02:00
Nicolas F
5b0430f94b textures: greatly simplify find_file and friends
find_file contained a lot of code for searching textures in ways that
haven't been relevant for years. For example, it had workarounds for
MCPatcher, a tool that hasn't been updated since 2015.

Instead of searching in multiple paths that will never succeed in a
resource pack and Minecraft version that actually work, just look
for the filename that the block functions ask for.

Also, if we already have a manually specified resource pack open,
we shouldn't repeatedly re-open it. Furthermore, it's best if
the very first thing find_file does is try to find the file in
the resource pack or client jar we've already opened previously.

We can now also remove chest.png, ender.png, foliage.png, grass.png
and normal_double.png because Minecraft ships them, so we don't
need to ship them ourselves too. Us shipping them actually hid the
whole find_file garbagefire.

Concerns issue #1604.
2019-07-04 18:24:57 +02:00
Nicolas F
864be71667 textures: cache when a texture couldn't be found
Previously, textures that couldn't be found the first time around
would not have this fact cached, so we'd run through the whole
slow path of find_file with each blockid and data entry.

This is what caused the chests texture generation function to take
almost 12 seconds on my system, as it is looking for "normal.png"
that hasn't existed in Minecraft textures for ages.

Shoving the exception, if one is encountered, into the cache, and
then re-raising it if we load it from the texture cache brings this
number down to about 2 seconds. That's six times as fast!

Concerns issue #1604.
2019-07-04 16:40:11 +02:00
Nicolas F
1e8735328e textures: try more than the most recent Minecraft
We can try each jar in descending order of versions until we actually
find one that works. This fixes #1328.

Future work might move the "if self.jar is not None" higher up in the
function so that we don't keep re-checking the overviewer dir and texture
path for files that we will then not use at all for some reason.
2019-07-04 15:27:58 +02:00
Aaron Griffith
248ea42dd2 Merge branch 'master' into python3-fun-times 2019-06-21 22:08:58 -04:00
Nicolas F
3fc97d131e Add fletching, cartography and smithing tables 2019-04-28 12:55:14 +02:00
InrcedibleHolg
702e4e9e8b added new 1.14 slabs, referencing issue #1560 2019-04-28 10:48:57 +02:00
Nicolas F
e25557d257 textures: fix stone slabs for 1.14 2019-04-26 04:11:20 +02:00
Nicolas F
bd40aeda3d textures: set prismarine slabs to transparent
This fixes upper slabs removing the block below them.
2019-04-07 20:21:45 +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
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
Aaron Griffith
509bce77d6 Merge 'jvaskonen/minecraft113' and 'jvaskonen/pillar' into master 2019-02-21 16:30:34 -05:00
James Miller
72c8a1dbd8 trapdoor orientation
non-oak trapdoors
dried kelp blocks
2018-12-16 05:17:19 -08:00
James Miller
2b2ad76c81 non-oak buttons
buttons on top of blocks
2018-12-16 03:33:38 -08:00
James Miller
ce78ffe008 bone block orientation
smooth stone blocks
coral and dead coral blocks
blue ice
2018-12-16 00:44:09 -08:00
James Miller
9200278f2f Wood and stripped wood 2018-12-15 00:51:27 -08:00
James Miller
be80775bf2 Stripped logs 2018-12-15 00:14:28 -08:00
James Miller
446916540a non-oak pressure plates 2018-12-14 23:40:21 -08:00
James Miller
b282bec2cf Uncarved pumpkin textures 2018-12-14 23:08:33 -08:00
James Miller
43122d5dfa Fixing top textures of non-vertically oriented quartz pillars. 2018-12-11 23:51:56 -08:00
Aaron Griffith
203715d05e do not render internal faces for water
This is closer to the old water rendering method, and better allows
users to see underwater structures.
2018-08-15 17:11:09 -04:00
gmcnew
b7bf62b350 A 1.13-compatible texture pack is required 2018-08-07 04:31:29 +00:00
gmcnew
be5f4c6ed0 Finish updating texture names 2018-08-03 01:11:18 +00:00
gmcnew
3a25138158 Minor texture fixes 2018-08-02 02:31:09 +00:00