9
0
mirror of https://github.com/Kas-tle/java2bedrock.sh.git synced 2025-12-19 14:59:13 +00:00

Fix damage predicates being slightly off

This commit is contained in:
Kas-tle
2022-12-03 15:02:25 -08:00
committed by GitHub
parent c2ae8c20ec
commit 92b2603dea

View File

@@ -196,7 +196,7 @@ if contains(":") then sub("\\:(.+)"; "") else "minecraft" end
;
[.[] | to_entries | map( select((.value.predicate.damage != null) or (.value.predicate.damaged != null) or (.value.predicate.custom_model_data != null)) |
(if .value.predicate.damage then (.value.predicate.damage * maxdur(.key) | round) else null end) as $damage
(if .value.predicate.damage then (.value.predicate.damage * maxdur(.key) | ceil) else null end) as $damage
| (if .value.predicate.damaged == 0 then true else null end) as $unbreakable
| (if .value.predicate.custom_model_data then .value.predicate.custom_model_data else null end) as $custom_model_data |
{