«    September 2024    »
MonTueWedThuFriSatSun
 1
2345678
9101112131415
16171819202122
23242526272829
30 
September 2024 (45)
August 2024 (37)
July 2024 (6)
June 2024 (23)
May 2024 (6)
April 2024 (30)
 
For-Minecraft.com » Mods for Minecraft Pocket Edition » ToolLib API - Creating Your Own Tools for IC Mods
1

ToolLib API - Creating Your Own Tools for IC Mods




At the moment when you have played enough industrial mods and want to create something of your own, ToolLib will help you with this. This library allows you to create your own unique tools working in the Inner Core environment. If you have an interesting idea and you need to add a customized set of tools, here is a small script where there are variables.

By: abdulla000n

ToolLib API - Creating Your Own Tools for IC Mods

Import:
importLib("ToolLib", "*");

Lesson: How to create a tool?:

ToolLIB.register({
params: {
uid: "tool ID",
name: "tool name",
textures: {
name: "texture"
meta: the index number, if 0 is not necessary.
}
},
localize: {
ru: "name (for Russian localization"
},
funcs: {
prototype: {
damage:tool damage,
blockTypes: ["material ID"]
},
material: "tool material",
isTool: holding in hand,
enchantType: enchant.
}
});

The prototype has other methods: destroyBlock, useItem, modifilyEnchant etc.

[spoiler:Example:]

ToolLIB.register({
params: {
uid: "darkSteelPickaxe",
name: "Dark Steel Pickaxe",
textures: {
name: "darkSteel_pickaxe"
}
},
localize: {
ru: "darkSteel_pickaxe"
},
funcs: {
prototype: {
damage: 2,
blockTypes: ["stone", "dirt"]
},
material: "darkSteel",
isTool: true,
enchantType: Native.EnchantType.pickaxe
}
});


If you make an addon to some IC mod that already has the library, then it is enough to import it. You can see the example above or Ender IO PE tools.

How to install the ToolLib API?


1. For stable operation, you need to download and install Inner Core.
2. After installation, move "ToolLib.js" from the archive to games/com.mojang/mods/mod_name/lib/.


Download ToolLib API - Creating Your Own Tools for IC Mods


Recommend:

Nhutan (13 December 2017 17:23)
Group: Guest
hay day


Name:*
E-Mail:
Captcha: *
Up © 2024 For-Minecraft.com