Skip to content

Commit ba7acb4

Browse files
authored
Merge pull request #48 from Tschipcraft/dev
v1.11.1
2 parents d883f5e + 4a86604 commit ba7acb4

File tree

31 files changed

+127
-148
lines changed

31 files changed

+127
-148
lines changed

.github/workflows/cd.yml

Lines changed: 1 addition & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -331,35 +331,7 @@ jobs:
331331
files: |
332332
./${{ github.event.repository.name }}-v${{ github.event.inputs.tag }}-mc${{ env.MC_HUMAN_VERSION_RANGE }}-datapack.zip
333333
334-
- name: Upload Forge mod version to CurseForge # Same reason as above
335-
id: upload_forge_curseforge_mod
336-
uses: Kir-Antipov/mc-publish@v3.3
337-
if: steps.check_mod_folder.outputs.files_exists == 'true' && github.event.inputs.dry_run == 'false'
338-
with:
339-
curseforge-id: 1223719
340-
curseforge-token: ${{ secrets.CURSEFORGE_TOKEN }}
341-
game-versions: |
342-
>=1.17 <=1.21.5
343-
game-version-filter: any
344-
fail-mode: skip
345-
346-
name: "Release v${{ github.event.inputs.tag }}"
347-
version: ${{ github.event.inputs.tag }}+mod
348-
changelog-file: CHANGES.md
349-
350-
dependencies: |
351-
catalogue(optional){curseforge:459701}
352-
midnightlib(optional){curseforge:488090}
353-
pehkui(optional){curseforge:319596}
354-
java: |
355-
Java 21
356-
Java 17
357-
loaders: |
358-
forge
359-
files: |
360-
./${{ github.event.repository.name }}-v${{ github.event.inputs.tag }}-mc${{ env.MC_HUMAN_VERSION_RANGE }}-mod.jar
361-
362-
- name: Upload mod version to CurseForge
334+
- name: Upload mod version to CurseForge # Duplicate uploads sadly don't work on CurseForge
363335
id: upload_curseforge_mod
364336
uses: Kir-Antipov/mc-publish@v3.3
365337
if: steps.check_mod_folder.outputs.files_exists == 'true' && github.event.inputs.dry_run == 'false'

.spyglassrc.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"env": {
3-
"gameVersion": "1.21.5",
3+
"gameVersion": "1.21.9",
44
"exclude": []
55
}
66
}

CHANGES.md

Lines changed: 7 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,7 @@
1-
- **Entities with emissive layers are now properly hidden** 👻 (Endermen, Spiders, and Cave Spiders) (closes [#25](https://github.com/Tschipcraft/spawnanimations/issues/25))
2-
- For this feature to work in Minecraft 1.20.4 and below, [Pehkui](https://modrinth.com/project/t5W7Jfwy) must be installed. Pehkui can still be installed in newer versions for smoother poof animations
3-
- Added config options to enable/disable the poof animation ([#40](https://github.com/Tschipcraft/spawnanimations/issues/40)), animation sounds (closes [#39](https://github.com/Tschipcraft/spawnanimations/issues/39)), reducing the number of particles emitted by hidden Endermen, and hiding emissive mob layers ([#25](https://github.com/Tschipcraft/spawnanimations/issues/25))
4-
- Improved performance by refactoring entity activation distance calculations to bundle and cache position data retrieval calls and by updating batch activation logic. The whole project is now up to 45% faster per tick!
5-
- Modified the attack predicate of the secondary dig-up requirements so that it disregards the Y-distance. This allows mobs to, for example, appear at the bottom of pillars if a player decides to build up during the night
6-
- Added an activation distance recommendation message when using the Vanilla activation mode
7-
- Removed the Hoglin from the dig up animation
8-
- Fixed most compatibility issues with [Hostile Mobs Improve Over Time](https://modrinth.com/project/ku4JD9TH) by adding missing tag recovery logic when preparing an entity for hiding. This should generally improve compatibility with other packs that override entity tags (closes [#26](https://github.com/Tschipcraft/spawnanimations/issues/26))
9-
- Fixed poof animation playing multiple times when "Play Animation on Unsupported Blocks" is off
10-
- Fixed possibility of hidden falling mobs losing their fall distance NBT when appearing
11-
- Fixed v0 save format not correctly upgrading to v1 in 1.20.5 and 1.20.6 (precisely from 24w11a to 24w20a)
12-
- Changed exclude tag from `exclude` to `ts.sa.exclude`
1+
- **Added support for Minecraft 1.21.9** 🥉
2+
- Updated to work with the new pack.mcmeta syntax
3+
- Raised entity processing limits to resolve mob farm complications (Thanks @Fyoncle)
4+
- Fixed Vanilla activation mode behaving the same way as Classic for activation distances below 25 (closes [#46](https://github.com/Tschipcraft/spawnanimations/issues/46))
5+
- Added native support for snow blocks when playing the dig up animation
6+
- Removed native support for some container blocks
7+
- Expanded and reorganized tag lists to include convention tags for improved mod compatibility

META-INF/mods.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ version="${version}+mod"
1111
displayName="Spawn Animations"
1212
description='''Hostile mobs dig out of the ground or poof into existence when they spawn!
1313
14-
§lWorks with:§r Zombies, Husks, Drowned, Skeletons, Strays, Bogged, Spiders, Cave Spiders, Creepers, Slimes, Magma Cubes, Wither Skeletons, Hoglins, Zombified Piglins, Striders, Enderman and Giants.
14+
§lWorks with:§r Zombies, Husks, Drowned, Skeletons, Strays, Bogged, Wither Skeletons, Spiders, Cave Spiders, Creepers, Endermen, Slimes, Magma Cubes, Zombified Piglins, Striders and Giants.
1515
1616
This data pack is designed to be as unintrusive as possible. Hidden entities including their worn armor and tools will only be invisible and silent.
1717

META-INF/neoforge.mods.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ version="${version}+mod"
1111
displayName="Spawn Animations"
1212
description='''Hostile mobs dig out of the ground or poof into existence when they spawn!
1313
14-
§lWorks with:§r Zombies, Husks, Drowned, Skeletons, Strays, Bogged, Spiders, Cave Spiders, Creepers, Slimes, Magma Cubes, Wither Skeletons, Hoglins, Zombified Piglins, Striders, Enderman and Giants.
14+
§lWorks with:§r Zombies, Husks, Drowned, Skeletons, Strays, Bogged, Wither Skeletons, Spiders, Cave Spiders, Creepers, Endermen, Slimes, Magma Cubes, Zombified Piglins, Striders and Giants.
1515
1616
This data pack is designed to be as unintrusive as possible. Hidden entities including their worn armor and tools will only be invisible and silent.
1717

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
Hostile mobs dig out of the ground or poof into existence when they spawn.
1717

1818
**Works with:**
19-
Zombies, Husks, Drowned, Skeletons, Strays, Bogged, Spiders, Cave Spiders, Creepers, Slimes, Magma Cubes, Wither Skeletons, Hoglins, Zombified Piglins, Striders, Enderman and Giants.
19+
Zombies, Husks, Drowned, Skeletons, Strays, Bogged, Wither Skeletons, Spiders, Cave Spiders, Creepers, Endermen, Slimes, Magma Cubes, Zombified Piglins, Striders and Giants.
2020

2121
This data pack/mod is designed to be as unintrusive as possible. Hidden entities including their worn armor and tools will only be invisible and silent.
2222

assets/spawnanimations/lang/en_us.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"modmenu.summaryTranslation.spawnanimations": "Hostile mobs dig out of the ground or poof into existence when they spawn!",
3-
"modmenu.descriptionTranslation.spawnanimations": "Hostile mobs dig out of the ground or poof into existence when they spawn!\n§lWorks with:§r Zombies, Husks, Drowned, Skeletons, Strays, Bogged, Spiders, Cave Spiders, Creepers, Slimes, Magma Cubes, Wither Skeletons, Hoglins, Zombified Piglins, Striders, Enderman and Giants.\nThis data pack is designed to be as unintrusive as possible. Hidden entities including their worn armor and tools will only be invisible and silent.\nExecute the command §o/function §ospawnanimations:settings§r for a world-specific settings menu and/or install MidnightLib for global settings across all worlds.",
4-
"fml.menu.mods.info.description.spawnanimations": "Hostile mobs dig out of the ground or poof into existence when they spawn!\n\n§lWorks with:§r Zombies, Husks, Drowned, Skeletons, Strays, Bogged, Spiders, Cave Spiders, Creepers, Slimes, Magma Cubes, Wither Skeletons, Hoglins, Zombified Piglins, Striders, Enderman and Giants.\n\nThis data pack is designed to be as unintrusive as possible. Hidden entities including their worn armor and tools will only be invisible and silent.\n\nExecute the command §o/function §ospawnanimations:settings§r for a world-specific settings menu and/or install MidnightLib for global settings across all worlds.",
3+
"modmenu.descriptionTranslation.spawnanimations": "Hostile mobs dig out of the ground or poof into existence when they spawn!\n§lWorks with:§r Zombies, Husks, Drowned, Skeletons, Strays, Bogged, Wither Skeletons, Spiders, Cave Spiders, Creepers, Endermen, Slimes, Magma Cubes, Zombified Piglins, Striders and Giants.\nThis data pack is designed to be as unintrusive as possible. Hidden entities including their worn armor and tools will only be invisible and silent.\nExecute the command §o/function §ospawnanimations:settings§r for a world-specific settings menu and/or install MidnightLib for global settings across all worlds.",
4+
"fml.menu.mods.info.description.spawnanimations": "Hostile mobs dig out of the ground or poof into existence when they spawn!\n\n§lWorks with:§r Zombies, Husks, Drowned, Skeletons, Strays, Bogged, Wither Skeletons, Spiders, Cave Spiders, Creepers, Endermen, Slimes, Magma Cubes, Zombified Piglins, Striders and Giants.\n\nThis data pack is designed to be as unintrusive as possible. Hidden entities including their worn armor and tools will only be invisible and silent.\n\nExecute the command §o/function §ospawnanimations:settings§r for a world-specific settings menu and/or install MidnightLib for global settings across all worlds.",
55

66
"spawnanimations.midnightconfig.title": "Spawn Animations Configuration",
77
"spawnanimations.midnightconfig.empty": "",
@@ -17,7 +17,7 @@
1717
"spawnanimations.midnightconfig.activation_distance": "Activation Distance",
1818
"spawnanimations.midnightconfig.activation_distance.tooltip": "Default: §a20 blocks§f\nMobs closer to a player than this value will play the animation.\nSetting this to 0 will use the world-specific value.",
1919
"spawnanimations.midnightconfig.activation_mode": "Activation Mode",
20-
"spawnanimations.midnightconfig.activation_mode.tooltip": "Default: §aClassic§f\n§nClassic§r: Mobs outside the activation range remain hidden until a player is in range.\n§nVanilla§r: Mobs outside the activation range spawn normally.\n§9ℹ Info:§f When set to Vanilla, it is recommended to set the activation distance to at least 25 blocks to see the animation.",
20+
"spawnanimations.midnightconfig.activation_mode.tooltip": "Default: §aClassic§f\n§nClassic§r: Mobs outside the activation range remain hidden until a player is in range.\n§nVanilla§r: Mobs outside the activation range spawn normally.\n§9ℹ Info:§f When set to Vanilla, it is recommended to set the activation distance to at least 25 blocks to see the animation for naturally spawned mobs.",
2121
"spawnanimations.midnightconfig.enable_poof_animation": "Enable Poof Animation",
2222
"spawnanimations.midnightconfig.enable_poof_animation.tooltip": "Default: §aYes§f\nIf enabled, some mobs, or mobs without a block to dig up from, will play the poof animation instead.",
2323
"spawnanimations.midnightconfig.play_animation_sounds": "Play Animation Sounds",

data/spawnanimations/function/internal/animation/dig_up/particles/particles.mcfunction

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,13 @@ execute if block ~ ~ ~ minecraft:cobblestone run particle block{block_state:"min
2020
execute if block ~ ~ ~ minecraft:hay_block run particle block{block_state:"minecraft:hay_block"} ~ ~0.2 ~ 0.1 0 0.1 1 9 normal
2121
execute if block ~ ~ ~ minecraft:gravel run particle block{block_state:"minecraft:gravel"} ~ ~0.2 ~ 0.1 0 0.1 1 9 normal
2222
execute if block ~ ~0.3 ~ minecraft:snow run particle block{block_state:"minecraft:snow"} ~ ~0.4 ~ 0.1 0 0.1 1 9 normal
23+
execute if block ~ ~ ~ minecraft:snow_block unless block ~ ~0.3 ~ minecraft:snow run particle block{block_state:"minecraft:snow_block"} ~ ~0.2 ~ 0.1 0 0.1 1 9 normal
2324
execute if block ~ ~ ~ #minecraft:ice run particle block{block_state:"minecraft:ice"} ~ ~0.2 ~ 0.1 0 0.1 1 9 normal
2425
execute if block ~ ~ ~ minecraft:obsidian run particle block{block_state:"minecraft:obsidian"} ~ ~0.2 ~ 0.1 0 0.1 1 9 normal
2526
execute if block ~ ~ ~ minecraft:slime_block run particle block{block_state:"minecraft:slime_block"} ~ ~0.2 ~ 0.1 0 0.1 1 9 normal
2627

2728
# End
2829
execute if block ~ ~ ~ minecraft:end_stone run particle block{block_state:"minecraft:end_stone"} ~ ~0.2 ~ 0.1 0 0.1 1 9 normal
29-
# Chorus
3030

3131
# Nether
3232
execute if block ~ ~ ~ #minecraft:base_stone_nether run particle block{block_state:"minecraft:netherrack"} ~ ~0.2 ~ 0.1 0 0.1 1 9 normal
@@ -35,13 +35,6 @@ execute if block ~ ~ ~ minecraft:nether_bricks run particle block{block_state:"m
3535
execute if block ~ ~ ~ #minecraft:soul_fire_base_blocks run particle block{block_state:"minecraft:soul_sand"} ~ ~0.2 ~ 0.1 0 0.1 1 9 normal
3636
execute if block ~ ~ ~ #minecraft:soul_fire_base_blocks run particle minecraft:soul ~ ~0.2 ~ 0.1 0.1 0.1 0.01 1 normal
3737

38-
# Containers
39-
execute if block ~ ~ ~ minecraft:chest run particle block{block_state:"minecraft:chest"} ~ ~0.2 ~ 0.1 0 0.1 1 3 normal
40-
execute if block ~ ~ ~ minecraft:trapped_chest run particle block{block_state:"minecraft:trapped_chest"} ~ ~0.2 ~ 0.1 0 0.1 1 3 normal
41-
execute if block ~ ~ ~ minecraft:ender_chest run particle block{block_state:"minecraft:ender_chest"} ~ ~0.2 ~ 0.1 0 0.1 1 1 normal
42-
execute if block ~ ~ ~ minecraft:hopper run particle block{block_state:"minecraft:hopper"} ~ ~0.2 ~ 0.1 0 0.1 1 3 normal
43-
execute if block ~ ~ ~ minecraft:beacon run particle block{block_state:"minecraft:glass"} ~ ~0.2 ~ 0.1 0 0.1 1 3 normal
44-
4538
# Extra mob-specific particles
4639
execute positioned ~ ~ ~ if entity @s[type=#spawnanimations:particles/nether_mob] run particle lava ~ ~0.4 ~ 0.1 0 0.1 0.01 1 normal
4740
execute positioned ~ ~ ~ if entity @s[type=#spawnanimations:particles/end_mob] run particle dragon_breath ~ ~0.2 ~ 0.1 0 0.1 0.01 5 normal

data/spawnanimations/function/internal/animation/dig_up/prepare.mcfunction

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,16 @@ execute as @s[scores={ts.sa.timer=-300..99}] run function spawnanimations:intern
66
execute as @s[scores={ts.sa.e.nbt.Sil=0},tag=!ts.sa.verify] run function spawnanimations:internal/animation/dig_up/recover_tags/hidden
77
tag @s[scores={ts.sa.timer=100}] add ts.sa.verified
88

9+
# Exclude out of range entities in Vanilla activation mode
10+
execute if score $activation_mode ts.sa.settings matches -1..0 if score $activation_dist ts.sa.settings matches 1..24 as @s[tag=!ts.sa.verified,tag=!ts.sa.verify,tag=!ts.sa.to_verify] unless entity @a[gamemode=!spectator,distance=..25] run tag @s add ts.sa.verified
11+
execute if score $activation_mode ts.sa.settings matches -1..0 if score $activation_dist ts.sa.settings matches 25.. as @s[tag=!ts.sa.verified,tag=!ts.sa.verify,tag=!ts.sa.to_verify] unless entity @a[gamemode=!spectator,distance=..100] run tag @s add ts.sa.verified
12+
913
# Exclude entities that have the glowing, levitation or invisibility potion effect, are riding another entity, or are burning
10-
execute as @s[tag=!ts.sa.verify,tag=!ts.sa.to_verify,predicate=!spawnanimations:exclude] run tag @s add ts.sa.verified
14+
tag @s[tag=!ts.sa.verified,tag=!ts.sa.verify,tag=!ts.sa.to_verify,predicate=!spawnanimations:exclude] add ts.sa.verified
1115

1216
# Exclude silent or no AI mobs
13-
execute as @s[tag=!ts.sa.verified,tag=!ts.sa.verify,tag=!ts.sa.to_verify,nbt={Silent:1b}] run tag @s add ts.sa.verified
14-
execute as @s[tag=!ts.sa.verified,tag=!ts.sa.verify,tag=!ts.sa.to_verify,nbt={NoAI:1b}] run tag @s add ts.sa.verified
17+
tag @s[tag=!ts.sa.verified,tag=!ts.sa.verify,tag=!ts.sa.to_verify,nbt={Silent:1b}] add ts.sa.verified
18+
tag @s[tag=!ts.sa.verified,tag=!ts.sa.verify,tag=!ts.sa.to_verify,nbt={NoAI:1b}] add ts.sa.verified
1519

1620
# Hide the entity
1721
execute as @s[tag=!ts.sa.verified,tag=!ts.sa.verify,tag=!ts.sa.to_verify] run function spawnanimations:internal/entity/hide

data/spawnanimations/function/internal/animation/dig_up/sound/play_sound.mcfunction

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@ execute if block ~ ~ ~ minecraft:cobblestone run playsound minecraft:block.stone
1717
# Other
1818
execute if block ~ ~ ~ minecraft:hay_block run playsound minecraft:block.grass.break hostile @a ~ ~ ~ 0.85 0.6
1919
execute if block ~ ~ ~ #minecraft:wool run playsound minecraft:block.wool.break hostile @a ~ ~ ~ 0.85 0.6
20-
execute if block ~ ~0.2 ~ minecraft:snow run playsound minecraft:block.snow.break hostile @a ~ ~ ~ 0.85 0.6
20+
execute if block ~ ~0.3 ~ minecraft:snow run playsound minecraft:block.snow.break hostile @a ~ ~ ~ 0.85 0.6
21+
execute if block ~ ~ ~ minecraft:snow_block unless block ~ ~0.3 ~ minecraft:snow run playsound minecraft:block.snow.break hostile @a ~ ~ ~ 0.85 0.5
2122
execute if block ~ ~ ~ #minecraft:ice run playsound minecraft:block.glass.break hostile @a ~ ~ ~ 0.85 0.7
2223
execute if block ~ ~ ~ minecraft:obsidian run playsound minecraft:block.stone.break hostile @a ~ ~ ~ 0.85 0.4
2324
execute if block ~ ~ ~ minecraft:slime_block run playsound minecraft:block.slime_block.break hostile @a ~ ~ ~ 0.85 0.4
@@ -31,12 +32,4 @@ execute if block ~ ~ ~ #minecraft:nylium run playsound minecraft:block.wart_bloc
3132
execute if block ~ ~ ~ minecraft:nether_bricks run playsound minecraft:block.nether_bricks.break hostile @a ~ ~ ~ 0.85 0.6
3233
execute if block ~ ~ ~ #minecraft:soul_fire_base_blocks run playsound minecraft:block.soul_sand.break hostile @a ~ ~ ~ 0.85 0.6
3334

34-
# Containers
35-
execute if block ~ ~ ~ minecraft:chest run playsound minecraft:block.wood.break hostile @a ~ ~ ~ 0.85 0.6
36-
execute if block ~ ~ ~ minecraft:trapped_chest run playsound minecraft:block.wood.break hostile @a ~ ~ ~ 0.85 0.6
37-
execute if block ~ ~ ~ minecraft:ender_chest run playsound minecraft:block.ender_chest.open hostile @a ~ ~ ~ 0.85 0.4
38-
execute if block ~ ~ ~ minecraft:hopper run playsound minecraft:block.metal.break hostile @a ~ ~ ~ 0.85 0.6
39-
execute if block ~ ~ ~ minecraft:beacon run playsound minecraft:block.glass.break hostile @a ~ ~ ~ 0.85 0.4
40-
41-
4235
execute if block ~ ~ ~ minecraft:lava run playsound minecraft:block.lava.pop hostile @a ~ ~ ~ 0.85 0.6

0 commit comments

Comments
 (0)