Compare commits

...

4 commits

Author SHA1 Message Date
f1ac960376 Use indicators from contenttweaker script in ore veins 2022-11-13 18:04:42 +01:00
dfc65320a5 Merge branch 'main' 2022-11-13 17:34:50 +01:00
ccbd0259c3 fixup ore_veins.json file
it contained wrong metadata values, also changed some names,
also updated boron entry

Co-authored-by: SwitchyJuice <konluk2005@gmail.com>
2022-11-13 17:31:09 +01:00
2d1a2f14e5 Add ore indicators as items placed on the ground
Item placing on the ground is added by Draconic Evolution,
I used a janky way to setblock generated indicator to that tile.
That tile needs nbt so I had to set a block using execute as setblock command,
which is bad, because it spams logs and operators chat
2022-11-13 07:54:48 +01:00
5 changed files with 187 additions and 126 deletions

View file

@ -5,6 +5,12 @@
"block": "ic2:resource", "block": "ic2:resource",
"meta": 1 "meta": 1
}, },
"indicator": {
"blocks": "contenttweaker:juice/internal/indicator/copper",
"ignore_vegatation": false,
"ignore_liquids": false,
"rarity": 24
},
"stone": "minecraft:stone", "stone": "minecraft:stone",
"rarity": 160, "rarity": 160,
"min_y": -30, "min_y": -30,
@ -21,6 +27,12 @@
"block": "forestry:resources", "block": "forestry:resources",
"meta": 0 "meta": 0
}, },
"indicator": {
"blocks": "contenttweaker:juice/internal/indicator/apatite",
"ignore_vegatation": false,
"ignore_liquids": false,
"rarity": 24
},
"stone": "minecraft:stone", "stone": "minecraft:stone",
"rarity": "100", "rarity": "100",
"min_y": -10, "min_y": -10,
@ -36,9 +48,9 @@
"ore": "minecraft:gold_ore", "ore": "minecraft:gold_ore",
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": "minecraft:gold_ore", "blocks": "contenttweaker:juice/internal/indicator/gold",
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 200, "rarity": 200,
@ -57,12 +69,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/silver",
"block": "thermalfoundation:ore",
"meta": 2
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 240, "rarity": 240,
@ -81,12 +90,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/platinium",
"block": "thermalfoundation:ore",
"meta": 6
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 300, "rarity": 300,
@ -105,12 +111,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/tin",
"block": "mekanism:oreblock",
"meta": 2
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 180, "rarity": 180,
@ -130,12 +133,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/aluminium",
"block": "thermalfoundation:ore",
"meta": 4
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 190, "rarity": 190,
@ -154,12 +154,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/nickel",
"block": "thermalfoundation:ore",
"meta": 5
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 210, "rarity": 210,
@ -178,12 +175,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/redstone",
"block": "minecraft:redstone_ore",
"meta": 0
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 170, "rarity": 170,
@ -201,9 +195,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": "mekanism:oreblock", "blocks": "contenttweaker:juice/internal/indicator/osmium",
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 190, "rarity": 190,
@ -222,12 +216,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/magnesium",
"block": "nuclearcraft:ore",
"meta": 7
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 255, "rarity": 255,
@ -242,24 +233,21 @@
"type": "cluster", "type": "cluster",
"ore": { "ore": {
"block": "nuclearcraft:ore", "block": "nuclearcraft:ore",
"meta": 7 "meta": 5
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/boron",
"block": "nuclearcraft:ore",
"meta": 7
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 255, "rarity": 280,
"min_y": 5, "min_y": 5,
"max_y": 45, "max_y": 25,
"density": 65, "density": 55,
"vertical_size": 12, "vertical_size": 11,
"horizontal_size": 9 "horizontal_size": 7
}, },
"lithium_ore": { "lithium_ore": {
@ -270,10 +258,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": "nuclearcraft:ore", "blocks": "contenttweaker:juice/internal/indicator/lithium",
"meta": 6,
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 255, "rarity": 255,
@ -292,12 +279,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/uranium",
"block": "nuclearcraft:ore",
"meta": 4
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 260, "rarity": 260,
@ -315,9 +299,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": "minecraft:coal_ore", "blocks": "contenttweaker:juice/internal/indicator/coal",
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 90, "rarity": 90,
@ -336,9 +320,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": "minecraft:iron_ore", "blocks": "contenttweaker:juice/internal/indicator/iron",
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 160, "rarity": 160,
@ -356,9 +340,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": "minecraft:diamond_ore", "blocks": "contenttweaker:juice/internal/indicator/diamond",
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 300, "rarity": 300,
@ -369,16 +353,16 @@
"horizontal_size": 6 "horizontal_size": 6
}, },
"lapislazuli_ore": { "lapis_ore": {
"type": "cluster", "type": "cluster",
"ore": { "ore": {
"block": "minecraft:lapis_ore" "block": "minecraft:lapis_ore"
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": "minecraft:lapis_ore", "blocks": "contenttweaker:juice/internal/indicator/lapis",
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 150, "rarity": 150,
@ -397,12 +381,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/silicon",
"block": "galacticraftcore:basic_block_core",
"meta": 8
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 210, "rarity": 210,
@ -420,12 +401,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/lead",
"block": "thermalfoundation:ore",
"meta": 3
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 185, "rarity": 185,
@ -443,12 +421,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/iridium",
"block": "thermalfoundation:ore",
"meta": 7
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 360, "rarity": 360,
@ -467,12 +442,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/blackquartz",
"block": "actuallyadditions:block_misc",
"meta": 3
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 265, "rarity": 265,
@ -491,12 +463,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/ruby",
"block": "biomesoplenty:gem_ore",
"meta": 1
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 310, "rarity": 310,
@ -510,16 +479,13 @@
"type": "cluster", "type": "cluster",
"ore": { "ore": {
"block": "biomesoplenty:gem_ore", "block": "biomesoplenty:gem_ore",
"meta": 2 "meta": 7
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/amber",
"block": "biomesoplenty:gem_ore",
"meta": 2
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 275, "rarity": 275,
@ -537,12 +503,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/sapphire",
"block": "biomesoplenty:gem_ore",
"meta": 6
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 310, "rarity": 310,
@ -560,12 +523,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/peridot",
"block": "biomesoplenty:gem_ore",
"meta": 3
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 300, "rarity": 300,
@ -583,12 +543,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/malachite",
"block": "biomesoplenty:gem_ore",
"meta": 5
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 270, "rarity": 270,
@ -606,12 +563,9 @@
}, },
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/tanzite",
"block": "biomesoplenty:gem_ore",
"meta": 3
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 295, "rarity": 295,
@ -622,7 +576,7 @@
"horizontal_size": 4 "horizontal_size": 4
}, },
"Certuz_quarz_ore": { "certus_quartz_ore": {
"type": "cluster", "type": "cluster",
"ore": [{ "ore": [{
"block": "appliedenergistics2:quartz_ore", "block": "appliedenergistics2:quartz_ore",
@ -635,12 +589,9 @@
], ],
"stone": "minecraft:stone", "stone": "minecraft:stone",
"indicator": { "indicator": {
"blocks": { "blocks": "contenttweaker:juice/internal/indicator/certus_quartz",
"block": "biomesoplenty:gem_ore",
"meta": 3
},
"ignore_vegatation": false, "ignore_vegatation": false,
"ignore_liquids": true, "ignore_liquids": false,
"rarity": 24 "rarity": 24
}, },
"rarity": 330, "rarity": 330,

10
index.toml generated
View file

@ -1146,7 +1146,7 @@ hash = "5046cde3673ccd62ba2209aaab9a917b3e1b0da7f521477e89f68bdba1648187"
[[files]] [[files]]
file = "config/oreveins/ore_veins.json" file = "config/oreveins/ore_veins.json"
hash = "902bbc0437f614c8251a280a9960e4d6d52b7fad0f155bafaf838dcacbb2eb72" hash = "e1b2b9e15458917be388f68454e78dec70d299e82525f35233d817ea9e2b03cf"
[[files]] [[files]]
file = "config/sereneseasons/biome_info.json" file = "config/sereneseasons/biome_info.json"
@ -2393,3 +2393,11 @@ hash = "b4aea7892748ecfa5cf775fb0a18f0909795c0b025666ecaea88bb3a923b4194"
[[files]] [[files]]
file = "scripts/nc_script_addons/MoarRealisticRadiation/rad_qmd.zs" file = "scripts/nc_script_addons/MoarRealisticRadiation/rad_qmd.zs"
hash = "a07879875ad20ae8e285c3cb39beeee648bd080ec12985b76583ad707a3de3ee" hash = "a07879875ad20ae8e285c3cb39beeee648bd080ec12985b76583ad707a3de3ee"
[[files]]
file = "scripts/ore_veins/indicators.1.zs"
hash = "e1c7d1f08c0c54de9b6f9be8c29b3fe4c6f35bc3c8e917d06aaf7bf4fd182a2a"
[[files]]
file = "scripts/ore_veins/indicators.2.zs"
hash = "08d456f730c1a797aab31811ba5a24e319ce35d000c4af80348a964a6c471898"

View file

@ -6,7 +6,7 @@ pack-format = "packwiz:1.1.0"
[index] [index]
file = "index.toml" file = "index.toml"
hash-format = "sha256" hash-format = "sha256"
hash = "e87241e8996c4ec0f34c2bf0ab46d0b994a591af4592c2106b98b5886a26be5d" hash = "d16c25fabb4e0584e25d5d3196037dcfd66ecf74bb6b569e9e8a4bec59e90d11"
[versions] [versions]
forge = "14.23.5.2860" forge = "14.23.5.2860"

View file

@ -0,0 +1,97 @@
#loader contenttweaker
import mods.contenttweaker.Block;
import mods.contenttweaker.DropHandler;
import mods.contenttweaker.ResourceLocation;
import mods.contenttweaker.VanillaFactory;
var nugget_table as string[][] = [
# [name, id, meta]
["copper", "ic2:resource", "1"],
["apatite", "forestry:resources", "0"],
["gold", "minecraft:gold_ore", "0"],
["silver", "thermalfoundation:ore", "2"],
["platinium", "thermalfoundation:ore", "6"],
["tin", "mekanism:oreblock", "2"],
["aliminium", "thermalfoundation:ore", "4"],
["nickel", "thermalfoundation:ore", "5"],
["redstone", "minecraft:redstone_ore", "0"],
["osmium", "mekanism:oreblock", "0"],
["magnesium", "nuclearcraft:ore", "7"],
["boron", "nuclearcraft:ore", "5"],
["lithium", "nuclearcraft:ore", "6"],
["uranium", "nuclearcraft:ore", "4"],
["coal", "minecarft:coal_ore", "0"],
["iron", "minecraft:iron_ore", "0"],
["diamond", "minecraft:diamond_ore", "0"],
["lapis", "minecraft:lapis_ore", "0"],
["silicon", "galacticraftcore:basic_block_core", "8"],
["lead", "thermalfoundation:ore", "3"],
["iridium", "thermalfoundation:ore", "7"],
["blackquartz", "actuallyadditions:block_misc", "3"],
["ruby", "biomesofplenty:gem_ore", "1"],
["amber", "biomesofplenty:gem_ore", "7"],
["sapphire", "biomesofplenty:gem_ore", "6"],
["peridot", "biomesofplenty:gem_ore", "2"],
["malachite", "biomesofplenty:gem_ore", "5"],
["tanzite", "biomesofplenty:gem_ore", "4"],
["certus_quartz", "appliedenegistics2:material", "0"]
];
function replaceCommand(blockName as string, item as string, meta as string, blockPos as mods.contenttweaker.BlockPos) as string {
return "execute @a " +
blockPos.getX() as string + " " +
blockPos.getY() as string + " " +
blockPos.getZ() as string + " " +
"detect " +
blockPos.getX() as string + " " +
blockPos.getY() as string + " " +
blockPos.getZ() as string + " " +
"contenttweaker:" + blockName + " * " +
"setblock " +
blockPos.getX() as string + " " +
blockPos.getY() as string + " " +
blockPos.getZ() as string + " " +
"draconicevolution:placed_item " +
"0 " +
"replace " +
"{InventoryStacks: [{ id: \"" + item + "\", Count: 1, Damage: " + meta as string + " }]}";
}
for i in nugget_table {
var blockName as string = "juice/internal/indicator/" + i[0];
var item as string = i[1];
var meta as string = i[2];
print("Adding internal ore indicator block: " + i[0]);
var block = VanillaFactory.createBlock(blockName, <blockmaterial:air>);
block.setTextureLocation(ResourceLocation.create("contenttweaker:blocks/ore_nugget"));
block.setToolLevel(0);
# block.setAxisAlignedBB(mods.contenttweaker.AxisAlignedBB.create(0.375f, 0.0f, 0.375f, 0.625f, 0.125f, 0.625f));
block.setEnumBlockRenderType("MODEL");
block.setBlockHardness(0.1);
block.setBlockLayer("CUTOUT");
block.setBlockResistance(0);
block.setDropHandler(function(drops, world, position, state, fortune) { drops.clear(); });
block.setFullBlock(false);
block.setLightOpacity(0);
block.setPassable(true);
block.setReplaceable(true);
# janky hack, mate
block.setOnBlockPlace(function(world, blockPos, blockState) {
var command as string = replaceCommand(blockName, item, meta, blockPos);
server.commandManager.executeCommand(server, command);
});
block.setOnRandomTick(function(world, blockPos, blockState) {
var command as string = replaceCommand(blockName, item, meta, blockPos);
server.commandManager.executeCommand(server, command);
});
block.setOnUpdateTick(function(world, blockPos, blockState) {
var command as string = replaceCommand(blockName, item, meta, blockPos);
server.commandManager.executeCommand(server, command);
});
block.register();
}

View file

@ -0,0 +1,5 @@
for i in loadedMods["contenttweaker"].items {
if (i.definition.name.contains("internal")) {
mods.jei.JEI.hide(i);
}
}