overcasting now runs on a percentage schema
This commit is contained in:
parent
6af1993725
commit
0d97d47937
16 changed files with 29 additions and 37 deletions
|
@ -321,19 +321,19 @@ f043370d6762b976e33dd6e9562d5e1659d32bbf assets/hexcasting/models/item/wand_old.
|
|||
05e86742a71afd740f47639be62f93bc9898fcde data/forge/tags/items/gems.json
|
||||
b6593ea802a692c29b5032292df31beb84878ad8 data/hexcasting/advancements/aaa_wasteful_cast.json
|
||||
4f4c94021adfb296e3ef3dce1acc46f724f38f92 data/hexcasting/advancements/aab_big_cast.json
|
||||
a165e3959b7d0c37bea586d0e94609b483255569 data/hexcasting/advancements/enlightenment.json
|
||||
2fe3543a209fca031b1eace7ea217c76142609cc data/hexcasting/advancements/enlightenment.json
|
||||
eb6393ffc79966e4b5983a68157742b78cd12414 data/hexcasting/advancements/opened_eyes.json
|
||||
d0b09e984b9270fe20b6c8d6f17e7690caaea409 data/hexcasting/advancements/recipes/brainsweep/brainsweep/akashic_record.json
|
||||
7e93886be31c3762a5b70e56a7214d19f64d58a8 data/hexcasting/advancements/recipes/brainsweep/brainsweep/budding_amethyst.json
|
||||
12d9101d43c907f08b0f94747240678d53e4c1fb data/hexcasting/advancements/recipes/brainsweep/brainsweep/directrix_redstone.json
|
||||
ed6ce219b2ee65d69ea45a43fb9a71b1f5da88bb data/hexcasting/advancements/recipes/brainsweep/brainsweep/impetus_look.json
|
||||
d225f90cc1e3b8200014106cd2d3bede9c783817 data/hexcasting/advancements/recipes/brainsweep/brainsweep/impetus_rightclick.json
|
||||
c966b7ab46808f86bdb7bbd07049146f0dfb24ec data/hexcasting/advancements/recipes/brainsweep/brainsweep/impetus_storedplayer.json
|
||||
cf0ad981bebbb79414d955fb40fbf537fe88b89d data/hexcasting/advancements/recipes/brainsweep/brainsweep/akashic_record.json
|
||||
c2a362b8c19cb288187d8ff340f82198edc54378 data/hexcasting/advancements/recipes/brainsweep/brainsweep/budding_amethyst.json
|
||||
c11dc4388c18dadff5d93126eb0f7ae848d627b9 data/hexcasting/advancements/recipes/brainsweep/brainsweep/directrix_redstone.json
|
||||
86424d21e1bf91c128d3b0d528b813629ad962e9 data/hexcasting/advancements/recipes/brainsweep/brainsweep/impetus_look.json
|
||||
5f9f0962f407062e7b6dd0e8c5f8c55ce13962a5 data/hexcasting/advancements/recipes/brainsweep/brainsweep/impetus_rightclick.json
|
||||
5d4811f78feefbef0a305555143f488b3dac7ac6 data/hexcasting/advancements/recipes/brainsweep/brainsweep/impetus_storedplayer.json
|
||||
3fe1fcf17e1e25aebede47c537f92888330ccf9f data/hexcasting/advancements/recipes/hexcasting/abacus.json
|
||||
5a17fa9a1496f5fbedd0362f94a5231e0e5ebbfc data/hexcasting/advancements/recipes/hexcasting/ageing_scroll_paper_lantern.json
|
||||
c498998fcffe3d1a0b6dfd6459db64e9389f5c15 data/hexcasting/advancements/recipes/hexcasting/akashic_bookshelf.json
|
||||
66e51300dc72c27ed8024ddf852ac9a6208a66b1 data/hexcasting/advancements/recipes/hexcasting/akashic_bookshelf.json
|
||||
31f9b7d8141f67981deedf7a46894e454006bb28 data/hexcasting/advancements/recipes/hexcasting/akashic_button.json
|
||||
d9f9fc153bf8e8861f79f982b185d2e4c7048067 data/hexcasting/advancements/recipes/hexcasting/akashic_connector.json
|
||||
168749d413b20bb9c05a8e7191758e0e596a319b data/hexcasting/advancements/recipes/hexcasting/akashic_connector.json
|
||||
1266b263056dd15c862bff27b05a119c4bbc89ee data/hexcasting/advancements/recipes/hexcasting/akashic_door.json
|
||||
149179e18b1b8db5dc3fb96e6faa6cb6ffaecb75 data/hexcasting/advancements/recipes/hexcasting/akashic_panel.json
|
||||
4f852507d843f82dce1512f55abfb205b9829ed4 data/hexcasting/advancements/recipes/hexcasting/akashic_planks.json
|
||||
|
@ -368,8 +368,8 @@ d6dfd0c6e995270868cb90de818d24b8a667fd01 data/hexcasting/advancements/recipes/he
|
|||
b0b1c5fff194b92ff8c5d6468e177271fd910abd data/hexcasting/advancements/recipes/hexcasting/dye_colorizer_red.json
|
||||
ccc33b4f1a43c8ecd3352ad36ae2dd2191317b5b data/hexcasting/advancements/recipes/hexcasting/dye_colorizer_white.json
|
||||
9c857c4aeda8a1b3d7a1b5d341871a9434b5816f data/hexcasting/advancements/recipes/hexcasting/dye_colorizer_yellow.json
|
||||
d978ce120b6af69899ff556f06997fcea522948b data/hexcasting/advancements/recipes/hexcasting/empty_directrix.json
|
||||
e40a09b7fdf5125be645a323ea5e1922a7e963f0 data/hexcasting/advancements/recipes/hexcasting/empty_impetus.json
|
||||
7351200c8e3eb24772852c578286384c8aab61bd data/hexcasting/advancements/recipes/hexcasting/empty_directrix.json
|
||||
023c32e8834eb313c4fa94a84a8f6390ee951ef0 data/hexcasting/advancements/recipes/hexcasting/empty_impetus.json
|
||||
f089ab17470c5fa0065438c5533d5fafb3ee8eaf data/hexcasting/advancements/recipes/hexcasting/focus.json
|
||||
fc57d15e9f9f11347a2170dd06053954345368d2 data/hexcasting/advancements/recipes/hexcasting/lens.json
|
||||
82be04125e60a28701de5bb6bc7855bb46fa9d0f data/hexcasting/advancements/recipes/hexcasting/pride_colorizer_0.json
|
||||
|
@ -406,7 +406,7 @@ f32ccb2d36d773215d91dee46bec70a20af501c3 data/hexcasting/advancements/recipes/he
|
|||
30950c6dd31102cf145f8f7d2979df0736a7ba1e data/hexcasting/advancements/recipes/hexcasting/wand_oak.json
|
||||
f8d2872c4e692153049b6ae4879755a079954763 data/hexcasting/advancements/recipes/hexcasting/wand_spruce.json
|
||||
3b2bcffe70bb1f732f06c2560cef66de6c273d62 data/hexcasting/advancements/recipes/hexcasting/wand_warped.json
|
||||
d31956749bebbcb3f0d3c37f89b569642ac8c2fb data/hexcasting/advancements/root.json
|
||||
ed0e62cb81783d8eb6323dd70609067219f163ec data/hexcasting/advancements/root.json
|
||||
739cbdf7f204132f2acfab4df8d21c6197aa1456 data/hexcasting/advancements/y_u_no_cast_angy.json
|
||||
70a8f77d38affa642afbfceebe129358737b09ac data/hexcasting/loot_modifiers/amethyst_cluster_charged.json
|
||||
f746acc6b3e798d3b95f4ceb463c648b1f3ae8c3 data/hexcasting/loot_modifiers/amethyst_cluster_dust.json
|
||||
|
|
|
@ -20,7 +20,7 @@
|
|||
"trigger": "hexcasting:overcast",
|
||||
"conditions": {
|
||||
"health_used": {
|
||||
"min": 17.95
|
||||
"min": 0.8
|
||||
},
|
||||
"mojang_i_am_begging_and_crying_please_add_an_entity_health_criterion": {
|
||||
"min": 0.1,
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
"trigger": "hexcasting:overcast",
|
||||
"conditions": {
|
||||
"health_used": {
|
||||
"min": 17.95
|
||||
"min": 0.8
|
||||
},
|
||||
"mojang_i_am_begging_and_crying_please_add_an_entity_health_criterion": {
|
||||
"min": 0.1,
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
"trigger": "hexcasting:overcast",
|
||||
"conditions": {
|
||||
"health_used": {
|
||||
"min": 17.95
|
||||
"min": 0.8
|
||||
},
|
||||
"mojang_i_am_begging_and_crying_please_add_an_entity_health_criterion": {
|
||||
"min": 0.1,
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
"trigger": "hexcasting:overcast",
|
||||
"conditions": {
|
||||
"health_used": {
|
||||
"min": 17.95
|
||||
"min": 0.8
|
||||
},
|
||||
"mojang_i_am_begging_and_crying_please_add_an_entity_health_criterion": {
|
||||
"min": 0.1,
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
"trigger": "hexcasting:overcast",
|
||||
"conditions": {
|
||||
"health_used": {
|
||||
"min": 17.95
|
||||
"min": 0.8
|
||||
},
|
||||
"mojang_i_am_begging_and_crying_please_add_an_entity_health_criterion": {
|
||||
"min": 0.1,
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
"trigger": "hexcasting:overcast",
|
||||
"conditions": {
|
||||
"health_used": {
|
||||
"min": 17.95
|
||||
"min": 0.8
|
||||
},
|
||||
"mojang_i_am_begging_and_crying_please_add_an_entity_health_criterion": {
|
||||
"min": 0.1,
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
"trigger": "hexcasting:overcast",
|
||||
"conditions": {
|
||||
"health_used": {
|
||||
"min": 17.95
|
||||
"min": 0.8
|
||||
},
|
||||
"mojang_i_am_begging_and_crying_please_add_an_entity_health_criterion": {
|
||||
"min": 0.1,
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
"trigger": "hexcasting:overcast",
|
||||
"conditions": {
|
||||
"health_used": {
|
||||
"min": 17.95
|
||||
"min": 0.8
|
||||
},
|
||||
"mojang_i_am_begging_and_crying_please_add_an_entity_health_criterion": {
|
||||
"min": 0.1,
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
"trigger": "hexcasting:overcast",
|
||||
"conditions": {
|
||||
"health_used": {
|
||||
"min": 17.95
|
||||
"min": 0.8
|
||||
},
|
||||
"mojang_i_am_begging_and_crying_please_add_an_entity_health_criterion": {
|
||||
"min": 0.1,
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
"trigger": "hexcasting:overcast",
|
||||
"conditions": {
|
||||
"health_used": {
|
||||
"min": 17.95
|
||||
"min": 0.8
|
||||
},
|
||||
"mojang_i_am_begging_and_crying_please_add_an_entity_health_criterion": {
|
||||
"min": 0.1,
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
"trigger": "hexcasting:overcast",
|
||||
"conditions": {
|
||||
"health_used": {
|
||||
"min": 17.95
|
||||
"min": 0.8
|
||||
},
|
||||
"mojang_i_am_begging_and_crying_please_add_an_entity_health_criterion": {
|
||||
"min": 0.1,
|
||||
|
|
|
@ -34,4 +34,4 @@
|
|||
"has_charged_amethyst"
|
||||
]
|
||||
]
|
||||
}
|
||||
}
|
|
@ -35,7 +35,7 @@ public class OvercastTrigger extends SimpleCriterionTrigger<OvercastTrigger.Inst
|
|||
super.trigger(player, inst -> {
|
||||
var manaToHealth = HexConfig.manaToHealthRate.get();
|
||||
var healthUsed = manaGenerated / manaToHealth;
|
||||
return inst.test(manaGenerated, healthUsed, player.getHealth() - (float) healthUsed);
|
||||
return inst.test(manaGenerated, healthUsed / player.getMaxHealth(), player.getHealth() - (float) healthUsed);
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
@ -17,7 +17,6 @@ import net.minecraft.resources.ResourceLocation;
|
|||
import net.minecraft.world.item.ItemStack;
|
||||
import net.minecraft.world.item.Items;
|
||||
import net.minecraft.world.level.ItemLike;
|
||||
import net.minecraft.world.level.block.Blocks;
|
||||
import net.minecraftforge.common.data.ExistingFileHelper;
|
||||
|
||||
import java.util.function.Consumer;
|
||||
|
@ -38,14 +37,7 @@ public class HexAdvancements extends AdvancementProvider {
|
|||
new ResourceLocation("minecraft", "textures/block/calcite.png"),
|
||||
FrameType.TASK, true, true, true))
|
||||
// the only thing making this vaguely tolerable is the knowledge the json files are worse somehow
|
||||
.addCriterion("on_thingy", new TickTrigger.TriggerInstance(EntityPredicate.Composite.wrap(
|
||||
EntityPredicate.Builder.entity()
|
||||
.steppingOn(LocationPredicate.Builder.location()
|
||||
.setBlock(BlockPredicate.Builder.block()
|
||||
.of(Blocks.AMETHYST_BLOCK, Blocks.CALCITE)
|
||||
.build())
|
||||
.setY(MinMaxBounds.Doubles.between(-64.0, 30.0)).build())
|
||||
.build())))
|
||||
.addCriterion("has_charged_amethyst", InventoryChangeTrigger.TriggerInstance.hasItems(HexItems.CHARGED_AMETHYST::get))
|
||||
.save(consumer, prefix("root")); // how the hell does one even read this
|
||||
|
||||
// weird names so we have alphabetical parity
|
||||
|
@ -54,7 +46,7 @@ public class HexAdvancements extends AdvancementProvider {
|
|||
.parent(root)
|
||||
.addCriterion("waste_amt", new SpendManaTrigger.Instance(EntityPredicate.Composite.ANY,
|
||||
MinMaxBounds.Ints.ANY,
|
||||
MinMaxBounds.Ints.atLeast(89 * ManaConstants.DUST_UNIT)))
|
||||
MinMaxBounds.Ints.atLeast(89 * ManaConstants.DUST_UNIT / 10)))
|
||||
.save(consumer, prefix("aaa_wasteful_cast"));
|
||||
Advancement.Builder.advancement()
|
||||
.display(simple(HexItems.CHARGED_AMETHYST.get(), "big_cast", FrameType.TASK))
|
||||
|
@ -93,7 +85,7 @@ public class HexAdvancements extends AdvancementProvider {
|
|||
new OvercastTrigger.Instance(EntityPredicate.Composite.ANY,
|
||||
MinMaxBounds.Ints.ANY,
|
||||
// add a little bit of slop here
|
||||
MinMaxBounds.Doubles.atLeast(17.95),
|
||||
MinMaxBounds.Doubles.atLeast(0.8),
|
||||
MinMaxBounds.Doubles.between(0.1, 2.05)))
|
||||
.save(consumer, prefix("enlightenment"));
|
||||
|
||||
|
|
|
@ -258,7 +258,7 @@ public class HexRecipes extends PaucalRecipeProvider {
|
|||
var enlightenment = new OvercastTrigger.Instance(EntityPredicate.Composite.ANY,
|
||||
MinMaxBounds.Ints.ANY,
|
||||
// add a little bit of slop here
|
||||
MinMaxBounds.Doubles.atLeast(17.95),
|
||||
MinMaxBounds.Doubles.atLeast(0.8),
|
||||
MinMaxBounds.Doubles.between(0.1, 2.05));
|
||||
|
||||
ShapedRecipeBuilder.shaped(HexBlocks.EMPTY_IMPETUS.get())
|
||||
|
|
Loading…
Reference in a new issue