Giter VIP home page Giter VIP logo

railcraft-api's Introduction

Railcraft-API

An API for interacting with Railcraft.

The latest version can be dowloanded from: https://dl.dropboxusercontent.com/u/38558957/Minecraft/Railcraft/Railcraft_latest-api.zip

The Railcraft API is provided as Open Source with no limitation on use (MIT License - http://choosealicense.com/licenses/mit/).

Package versioning follows the rules laid out by http://semver.org/

When packaging this API with your mod, please include ONLY the classes you need, deleting those you don't. This helps to reduce conflict if the API changes slighty between versions.

Ore Dictionary Tags:

  • blockSteel
  • dustCharcoal
  • dustObsidian
  • dustSaltpeter
  • dustSulfur
  • ingotSteel
  • oreSaltpeter
  • oreSulfur

##InterModComms: ##String:

Message Syntax Description
"ballast" "[modid]:[blockName]@[metadata]" Registers a block as a valid ballast for the Tunnel Bore and Undercutter.
"boiler-fuel-liquid" "[liquidName]@[fuelValuePerBucket]" Specifies a fuel value for a bucket of liquid fuel. The liquid name should be the English display name of the liquid (ie. the tag used to lookup the liquid in the LiquidDictionary).

##NBT: Rock Crusher:

public void addRockCrusherRecipe(ItemStack input, boolean matchMeta, boolean matchNBT, Map<ItemStack, Float> outputs) {
    NBTTagCompound nbt = new NBTTagCompound();

    NBTTagCompound inputNBT = new NBTTagCompound();
    input.writeToNBT(inputNBT);
    nbt.setTag("input", inputNBT);

    nbt.setBoolean("matchMeta", matchMeta);
    nbt.setBoolean("matchNBT", matchNBT);

    int outCount = 0;
    for (Entry<ItemStack, Float> output : outputs.entrySet()) {
        NBTTagCompound outputNBT = new NBTTagCompound();
        output.getKey().writeToNBT(outputNBT);
        outputNBT.setFloat("chance", output.getValue());
        nbt.setTag("output" + outCount++, outputNBT);
    }

    FMLInterModComms.sendMessage("Railcraft", "rock-crusher", nbt);
}

railcraft-api's People

Watchers

 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.