custom binding function config
This commit is contained in:
parent
6bd3f54842
commit
63315c35c4
8 changed files with 97 additions and 15 deletions
|
|
@ -6,7 +6,7 @@ export const config = {
|
|||
packinfo: {
|
||||
name: "AsaJS",
|
||||
description: "Create your Minecraft JSON-UI resource packs using JavaScript.",
|
||||
version: [4, 0, 1],
|
||||
version: [1, 0, 0],
|
||||
},
|
||||
compiler: {
|
||||
enabled: true,
|
||||
|
|
@ -14,4 +14,19 @@ export const config = {
|
|||
autoEnable: true,
|
||||
importToPreview: false,
|
||||
},
|
||||
binding_functions: {
|
||||
custom_abs: function (number) {
|
||||
const randomAbs = RandomBindingString(16)
|
||||
|
||||
return {
|
||||
generate_bindings: [
|
||||
{
|
||||
source_property_name: `[ abs(${number}) ]`,
|
||||
target_property_name: randomAbs,
|
||||
},
|
||||
],
|
||||
return_value: randomAbs,
|
||||
}
|
||||
},
|
||||
},
|
||||
}
|
||||
|
|
|
|||
Reference in a new issue