Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[1.20.1-1.3.0.1] Horses can't be called while holding a Domestication Innovation Collar Tag, and causes the Collar Tag to be deleted #30

Open
TBlazeWarriorT opened this issue Dec 18, 2023 · 2 comments

Comments

@TBlazeWarriorT
Copy link

TBlazeWarriorT commented Dec 18, 2023

Version:
callablehorses-1.20.1-1.3.0.1.jar

The bug:
When I call my horse using the Callable Horses mod while holding a Collar Tag, the tag deletes itself. Very frustrating, has caused me to delete a bunch of tags by accident and lose progress.

Reproducing:
Using DomesticationInnovation (domesticationinnovation-1.7.1-1.20.1.jar + citadel-2.4.9-1.20.1.jar) and Callable Horses:

  • Hold a Collar Tag in any game mode except Creative, even in spectator mode
  • Call your horse
  • One Tag will be bugged out and deleted on each press :(

Video demonstration:

dom.inno.bug.compressed.mp4

MC Logs:
https://api.paste.ee/p/jFVZE

What I know so far:
This has to do with isAreaProtected() from Callable Horses, fakeHorse from Callable Horses, and something stinky I can't figure out with Collar Tags from this domestication. The collar is likely being applied to the fake horse entity and being deleted, if not deleted entirely for no reason. What I can't figure out why, is why holding a tag triggers Callable Horses' area protection, and why calling a horse would even attempt to apply that tag to the fake horse, if that's even what's happening. My brian hurts and my tags are missing

Corresponding issue on Dom Inn.:
AlexModGuy/DomesticationInnovation#177

@TBlazeWarriorT TBlazeWarriorT changed the title Horses can't be called while holding a Domestication Innovation Collar Tag, and causes the Collar Tag to be deleted [1.20.1-1.3.0.1] Horses can't be called while holding a Domestication Innovation Collar Tag, and causes the Collar Tag to be deleted Dec 18, 2023
@TBlazeWarriorT
Copy link
Author

After a lot of head scratching, I think I understand it.
If my theory is correct:
Callable Horses uses unsafe methods to check if an area is protected. It forces an interaction with a fake horse with the main hand, which can apply items to the horse, such as the Collar Tag, that gets consumed then deleted. The Collar Tag probably partially realizes it is a fake horse, and despite still being consumed, probably cancels the event partially and doesn't even let the real horse be called when it should, triggering issues on both sides. It's weird that it doesn't happen with vanilla items like name tags or food, but I'm no expert so that's my best guess still.

@TBlazeWarriorT
Copy link
Author

I've recompiled the mod and confirmed that removing isAreaProtected() check stops the collar from being deleted. I'll be using the mod without the area protection for now, whatever it was for, as it can delete items.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant