Giter Site home page Giter Site logo

better-foliage's Introduction

Better Foliage

Summary

Better Foliage is a mod that will make your Minecraft worlds more impressive, mainly by improving how vegetation looks.

This is port for Minecraft Bedrock Edition, working under Inner Core for Horizon. At the current moment this is alpha version, that contains only core features of the original mod.

Adding Custom Leaves

To integrate better foliage with your mod, you need 2 things: generate leaves textures and setup render for leaves block.

To make preloader generate leaves textures, create file with extension .rescfg in your resources and add all leaves textures:

{
    "better-foliage": {
        "leaves": [
            {"texture": "terrain-atlas/texture1.png"},
            ...
        ]
    }
}

Next, use follwing code to register render for leaves block:

ModAPI.addAPICallback("BetterFoliageLeaves", function(BetterFoliage) {
	BetterFoliage.setupLeavesModel(block id, data or -1, ["block texture name", block texture index]);
});

If your leaves use vanilla leaves color source, you may pass additional parameter, that specifies vanilla leaves type to get color from:

ModAPI.addAPICallback("BetterFoliageLeaves", function(BetterFoliage) {
	// vanilla leaves data:
	// 0 - oak
	// 1 - spruce 
	// 2 - birch
	// 3 - jungle
	BetterFoliage.setupLeavesModel(block id, data or -1, ["block texture name", block texture index], vanilla leaves data);
});

better-foliage's People

Contributors

zheka2304 avatar hunabis avatar toxesfoxes avatar

Stargazers

 avatar TriHydera avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.