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

MC_NPC_GET_PLAYER_TARGET #44

Open
jerbmega opened this issue Feb 28, 2023 · 1 comment
Open

MC_NPC_GET_PLAYER_TARGET #44

jerbmega opened this issue Feb 28, 2023 · 1 comment
Labels
callback request enhancement New feature or request

Comments

@jerbmega
Copy link
Collaborator

passes npc and player, return false to invalidate a player as a valid target

@jerbmega jerbmega added enhancement New feature or request callback request labels Feb 28, 2023
@ConnorForan
Copy link
Collaborator

ConnorForan commented Jan 2, 2024

Probably relevant note, there is the MC_NPC_PICK_TARGET callback that runs after the whole target selection is completed, provides the npc and the target that the game chose, and allows returning a different entity to change the target.

It can't do the "invalidate a player as a valid target" thing (apart from just returning a different target yourself), which would probably require patching into the spot where the game decides whether or not a given player is a valid target, so that it could go on to choose a different target? Though there's also stuff like familiars or other enemies being selected as the target to take into account.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
callback request enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants