Skip to content

Conversation

@lonevox
Copy link
Contributor

@lonevox lonevox commented Oct 27, 2025

Entity already has a method called attack, which is used when the entity attacks something. hurt is used to damage the entity it is called on, so they have different usages, which makes it confusing that they have the same name in kjs.

`Entity` already has a method called `attack`, which is used when the entity attacks something. `hurt` is used to damage the entity it is called on, so they have different usages, which makes it confusing that they have the same name in kjs.
@KonSola5
Copy link

KonSola5 commented Jan 26, 2026

From what I see in a clean NeoForge 1.21.1 devenv, attack is only a method of Player.
LivingEntity nor Entity do not have the attack method, neither by themselves nor in any interface those classes implement.

But attack method on Player is not remapped - will it shadow the attack method on Entity?

@KonSola5
Copy link

I'd suggest remapping the method on Entity to damage instead.

@LatvianModder LatvianModder changed the base branch from main to 2101 January 29, 2026 10:27
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

Successfully merging this pull request may close these issues.

2 participants