Brutal Bosses - Custom Bosses[Forge/Fabric]

Brutal Bosses - Custom Bosses[Forge/Fabric]

15M Downloads

[Bug]: Passangers nbt tag not working

BartlomiejPiotrowski opened this issue ยท 2 comments

commented

Describe the bug you're experiencing

I tried adding a passanger to a boss, but boss entity spawns without the rider ,
the passanger nbt is absent from spawned entity .

I checked multiple seemingly valid combinations using whole nbt of entity and just passengers tag but nothing seems to work.

Some files i tried:

{
"entity": "minecraft:polar_bear",
"name": "Bob",
"visualscale": 1,
"experience": 1000,
"entitynbt": "{DeathTime: 0s, LeftHanded: 0b, OnGround: 1b, AbsorptionAmount: 0.0f, Attributes: [{Name: "porting_lib:entity_gravity", Base: 0.08d}, {Name: "porting_lib:step_height_addition", Base: 0.0d}, {Name: "minecraft:generic.movement_speed", Base: 0.25d}, {Name: "minecraft:generic.follow_range", Modifiers: [{Amount: 0.07216729370302254d, UUID: [I; -2038865140, 2023837626, -2026259813, 423191578], Name: "Random spawn bonus", Operation: 1}], Base: 20.0d}], Invulnerable: 0b, Brain: {memories: {}}, Age: 0, za_data: {}, "puzzleslib:spawn_type": "SPAWN_EGG", HandDropChances: [0.085f, 0.085f], ArmorDropChances: [0.085f, 0.085f, 0.085f, 0.085f], Rotation: [91.212555f, 0.0f], HurtByTimestamp: 0, ForcedAge: 0, Passengers: [{Patrolling: 0b, DeathTime: 0s, CanJoinRaid: 1b, LeftHanded: 0b, OnGround: 0b, AbsorptionAmount: 0.0f, Attributes: [{Name: "porting_lib:step_height_addition", Base: 0.0d}, {Name: "porting_lib:entity_gravity", Base: 0.08d}, {Name: "minecraft:generic.follow_range", Modifiers: [{Amount: -0.09028421006922842d, UUID: [I; -1776484215, -1093907858, -2043244302, 1943552331], Name: "Random spawn bonus", Operation: 1}], Base: 32.0d}, {Name: "minecraft:generic.movement_speed", Base: 0.3499999940395355d}, {Name: "ranged_weapon:damage", Base: 0.0d}], PatrolLeader: 0b, Invulnerable: 0b, Brain: {memories: {}}, za_data: {}, "puzzleslib:spawn_type": "SPAWN_EGG", HandDropChances: [0.085f, 0.085f], ArmorDropChances: [0.085f, 0.085f, 0.085f, 0.085f], Rotation: [183.75504f, -40.0f], HurtByTimestamp: 0, ArmorItems: [{}, {}, {}, {}], "faux-custom-entity-data:custom": {}, Tags: ["collective.checked"], HandItems: [{id: "minecraft:crossbow", tag: {Damage: 0}, Count: 1b}, {}], Air: 300s, UUID: [I; 469154660, -402896455, -1376767183, -1306811946], Inventory: [], FireType: "minecraft:", Wave: 0, PersistenceRequired: 0b, FallDistance: 0.0f, id: "minecraft:pillager", Motion: [0.0d, -0.0784000015258789d, 0.0d], Pos: [3553.9767668079703d, 64.5999999821186d, 1553.0293317315482d], AABB: [3553.6767667960494d, 64.5999999821186d, 1552.7293317196272d, 3554.2767668198912d, 66.55000002980232d, 1553.329331743469d], CanPickUpLoot: 0b, Health: 24.0f, HurtTime: 0s, FallFlying: 0b, Fire: -1s, PortalCooldown: 0}], AngerTime: 0, ArmorItems: [{}, {}, {}, {}], "faux-custom-entity-data:custom": {}, Tags: ["collective.checked"], HandItems: [{}, {}], Air: 300s, UUID: [I; 1853945001, -1896460969, -1156258368, 452823895], FireType: "minecraft:", InLove: 0, FallDistance: 0.0f, Fire: -1s, Motion: [0.0d, -0.0784000015258789d, 0.0d], Pos: [3553.9767668079703d, 64.0d, 1553.0293317315482d], AABB: [3553.2767668198912d, 64.0d, 1552.329331743469d, 3554.6767667960494d, 65.39999997615814d, 1553.7293317196272d], CanPickUpLoot: 0b, Health: 30.0f, HurtTime: 0s, FallFlying: 0b, PersistenceRequired: 0b, PortalCooldown: 0}",
"namevisible": false,
"effects": {
},
"attributes": {
},
"customattributes": {
"dropgear": 0
},
"gear": {
},
"ai-goals": {
},
"spawnatchest": {
"minecraft:chests/igloo_chest": 3
}
}

{
"entity": "minecraft:polar_bear",
"name": "Bob",
"visualscale": 1,
"experience": 1000,
"entitynbt": "{Passengers:[{id:"minecraft:Pillager"}]}",
"namevisible": false,
"effects": {
},
"attributes": {
},
"customattributes": {
"dropgear": 0
},
"gear": {
},
"ai-goals": {
},
"spawnatchest": {
"minecraft:chests/igloo_chest": 3
}
}

Reproducability

Add nbt containing a passenger, and spawn boss

Mod up to date

  • Before submitting this issue I updated to the newest version and reproduced it

Minecraft version

1.20.1

Modloader version

Fabric

Logs and Datapacks

https://gist.github.com/BartlomiejPiotrowski/0315132fbc43a8c60087ae1b2ce87136

commented

"entitynbt": "" Allows you to add extra entity NBT data to the boss entity. You can get the nbt data by using the /data get entity @e[limit=1,sort=nearest,type=!minecraft:player] command. Copy the output of it from the latest.log file and replace all " with \"

Your nbt data is missing the \ before all internal quottation marks, only the outer two "" do not need it any other should be \ "

commented

The backslashes are there, i didnt notice that github markdown eats them and just copy pasted.

Here is how the file i tested is supposed to look:
{
"entity": "minecraft:polar_bear",
"name": "Bob",
"visualscale": 1,
"experience": 1000,
"entitynbt": "{Passengers:[{id:\"minecraft:Pillager\"}]}",
"namevisible": false,
"effects": {
},
"attributes": {
},
"customattributes": {
"dropgear": 0
},
"gear": {
},
"ai-goals": {
},
"spawnatchest": {
"minecraft:chests/igloo_chest": 3
}
}

without the backslashes the spawnboss command does not work, with them boss spawns missing the passenger part of the nbt