erich666 / Mineways

Exports models from Minecraft for 3D printing or rendering
http://mineways.com
Other
408 stars 60 forks source link

Mods #3

Closed Moocow9m closed 9 years ago

Moocow9m commented 9 years ago

Is there a way for modded blocks to be added(like computercraft)?

erich666 commented 9 years ago

I'm afraid not - modded blocks will be treated as what they are, or, if unknown, solid stone, as I recall (and could cause crashes - I just fixed a crash caused by one, which will be out in the next version soon).

I've tried to think of ways of making the system more flexible to allow this (as Minutor does for 2D mapping), but there's so much complication with dealing with different block types and how they interact that I gave up. To give you a just a tiny taste, here's the list of attributes that must be understood for each block type. This doesn't include where to get the textures from, nor special connection features such as how glass panes, or fences, or stairs, influence one another. Mineways is mostly meant for 3D printing, so there's a lot that goes on that has to do with that system.

Eric

// fills whole block

define BLF_WHOLE 0x0001

// almost a whole block

define BLF_ALMOST_WHOLE 0x0002

// stairs

define BLF_STAIRS 0x0004

// half block

define BLF_HALF 0x0008

// fair-sized, worth rendering, has geometry

define BLF_MIDDLER 0x0010

// larger billboard object worth rendering

define BLF_BILLBOARD 0x0020

// billboard flat through middle, usually transparent (portal, glass pane)

define BLF_PANE 0x0040

// sits on top of a block below it

define BLF_FLATTOP 0x0080

// flat on a wall: sign, ladder, etc. - normally culled out

define BLF_FLATSIDE 0x0100

// small, not as worth rendering, has geometry - normally culled out

define BLF_SMALL_MIDDLER 0x0200

// small thing: lever, flower - normally culled out

define BLF_SMALL_BILLBOARD 0x0400

// has an alpha for the whole block (vs. glass, which often has a frame that's solid)

define BLF_TRANSPARENT 0x0800

// has cutout parts to its texture, on or off (no semitransparent alpha)

define BLF_CUTOUTS 0x1000

// trunk

define BLF_TRUNK_PART 0x2000

// leaf

define BLF_LEAF_PART 0x4000

// is related to trees - if something is floating and is a tree, delete it for printing

define BLF_TREE_PART (BLF_TRUNK_PART|BLF_LEAF_PART)

// is an entrance of some sort, for sealing off building interiors

define BLF_ENTRANCE 0x8000

// export image texture for this object, as it makes sense - almost everything has this property (i.e. has a texture tile)

define BLF_IMAGE_TEXTURE 0x10000

// this object emits light

define BLF_EMITTER 0x20000

// this object attaches to fences; note that fences do not have this property themselves, so that nether & regular fence won't attach

define BLF_FENCE_NEIGHBOR 0x40000

// this object outputs its true geometry (not just a block) for rendering

define BLF_TRUE_GEOMETRY 0x80000

// this object outputs its special non-full-block geometry for 3D printing, if the printer can glue together the bits. // Slightly different than TRUE_GEOMETRY in that things that are just too thin don't have this bit set.

define BLF_3D_BIT 0x100000

// this object is a 3D bit, and this bit is set if it can actually glue horizontal neighboring blocks together // - not really used. TODO - may want to use this to decide whether objects should be grouped together or whatever.

define BLF_3D_BIT_GLUE 0x200000

// set if the block does not affect fluid height

define BLF_DNE_FLUID 0x400000

// set if the block connects to redstone - do only if there's no orientation to the block, e.g. repeaters attach only on two sides, so don't have this flag

define BLF_CONNECTS_REDSTONE 0x800000

// has no geometry, on purpose

define BLF_NONE 0x1000000

On Mon, May 18, 2015 at 11:06 AM, Moocow9m notifications@github.com wrote:

Is there a way for modded blocks to be added(like computercraft)?

— Reply to this email directly or view it on GitHub https://github.com/erich666/Mineways/issues/3.

Moocow9m commented 9 years ago

hmmmmm well ok then. thanks for replying. Nice coding skills by the way.

ologKirill commented 6 years ago

Now what? Can you add new blocks from the mode? If so please add blocks from (Carpenter's Blocks) is a decorative mod that is great for animations, thank you in advance for your answer. P.S Could you make lessons / instructions how to add blocks from mods.