Jump to content

How to interact with entities when player is in combat


Slick

Recommended Posts

The interact() API is not very reliable when player is under attack. It is not moving the mouse and returning false from the method. I have tested executing InteractionEvent and getting similar results 

I have also tried ClickMouseEvent with EntityDestination as well as simply getMouse().move and click but they still do fail to click an object quite often

What is the preferred way to interact with other entities when player is in combat?

Link to comment
Share on other sites

6 hours ago, Slick said:

The interact() API is not very reliable when player is under attack. It is not moving the mouse and returning false from the method. I have tested executing InteractionEvent and getting similar results 

I have also tried ClickMouseEvent with EntityDestination as well as simply getMouse().move and click but they still do fail to click an object quite often

What is the preferred way to interact with other entities when player is in combat?

It's probably something with your code, because interaction code does not care about being in combat or not...
Share some code and let's see what's wrong :)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...