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

[SAI] SMART_EVENT_LINK "61" Doesn't Seem to be Working #20927

Open
LannyE opened this issue Dec 16, 2024 · 11 comments
Open

[SAI] SMART_EVENT_LINK "61" Doesn't Seem to be Working #20927

LannyE opened this issue Dec 16, 2024 · 11 comments

Comments

@LannyE
Copy link
Contributor

LannyE commented Dec 16, 2024

Current Behaviour

When I try to use SAI and create an Event 61 link the event doesn't work. I thought it was just me not understanding how things worked but over time I just am not seeing things working that use SAI and have Event 61 linking events together. I tested my theory with a Bloodfury Warder (Entry 18853) who is supposed to say something as they enrage between 0-30% health. Unfortunately, they enrage but say nothing.
image
image
I also tried an another random person Katherine Lee (Entry 28705). She is supposed to set Orientation on WP 5 reached as per her SAI Linked event.
image
It should set her Orientation to 0.837758 while linked to a Waypoint pause but instead it just pauses and no Orientation change.
.GPS info on her when she reaches that waypoint.
image

Can anyone confirm this is happening? Am I just having some weird issues with only my installation?

Expected Blizzlike Behaviour

SAI Linked entries should execute together.

Source

No response

Steps to reproduce the problem

  1. .go creature 67305
  2. attack him and bring his health down to under 30%
  3. Watch him enrage and not say anything. It should say something as far as the SAI is scripted.
  4. or find any creature that uses event 61 and see if it executes with the linked event.

Extra Notes

No response

AC rev. hash/commit

AzerothCore rev. a0fee21+ 2024-12-13 19:55:52 -0700 (master branch) (Win64, RelWithDebInfo, Static) (My Fork)
& AzerothCore rev. 35f316b 2024-12-15 18:50:58 +0000 (master branch) (Win64, RelWithDebInfo, Static) (worldserver-daemon) (Clean Test Server)

Operating system

Windows

Custom changes or Modules

mod-ah-bot
mod-gain-honor-guard
mod-individual-xp
mod-pvp-titles
mod-solo-lfg
mod-transmog
mod-weekend-xp

@sudlud

This comment has been minimized.

@sudlud
Copy link
Member

sudlud commented Dec 16, 2024

nvm I misread the example 😅

@sudlud
Copy link
Member

sudlud commented Dec 16, 2024

Also please test this on a clean AC Installation without custom changes and not the playerbot fork / modules etc.

@Rorschach91
Copy link
Member

A similar thing happened to me when trying to solve the problem of the havenshire horse jumping the fence in the dk start area.
When the horse reaches the end of its waypoint, it should change orientation and use the special mount animation, but it stays in place when the waypoint ends.

@fangshun2004
Copy link
Contributor

When he's angry, there will be words
image

@LannyE
Copy link
Contributor Author

LannyE commented Dec 16, 2024

@sudlud My apologies, I am getting old apparently, I gave you the wrong AC Rev from my PROD server which uses that fork and not my test server which has the NPCbot and my custom changes stripped from it. Yes, this happens on a clean build. I tested it on all my servers and like an idiot I copied the rev from my PROD server log. I removed any modules on my test AZ build and rebuilt the databases from scratch and tested it again. The problem persists and is very apparent.

Rev for my test server:
AzerothCore rev. 35f316b 2024-12-15 18:50:58 +0000 (master branch) (Win64, RelWithDebInfo, Static) (worldserver-daemon)

Please don't let this stop developers from looking at the issue as it appears from what others have confirmed this could be a very critical issue as so many bosses, game objects, NPCs, events and such use Event Linking in their SAI scripts. I noticed something off probably about a few months ago when developing a fix for something and brushed it off as me not doing something right. Can you please take a look at this and see if you can confirm what I am seeing? Thank you.

@sudlud
Copy link
Member

sudlud commented Dec 16, 2024

thanks for the update :)

@sudlud
Copy link
Member

sudlud commented Dec 18, 2024

#16739 was a recent change to SAI handling

@LannyE
Copy link
Contributor Author

LannyE commented Dec 20, 2024

I have been testing this all week going through many scripts, and it appears event links work fine except for when dealing with waypoints. The problem is the waypoint pause code appears to not be predictive and is only reactionary. So, if the SAI says to pause at a specific waypoint ID and then links an orientation smart action the code only fires right as it hits that waypoint ID but depending on the speed of the creature the pause may happen slightly after it passes the waypoint ID and slingshots back to the waypoint it was supposed to pause at. During that slingshot it actually fires off the orientation action, but the slingshot movement changes the creature back to the direction of the waypoint.

Anyway, it looks like it is just me being stupid. @sudlud thanks for being patient with me, you can close this issue if you want. Although the real issue is using SAI to pause at any points in a waypoint that is the not the end point (without repeat) of the waypoint path doesn't pause right at the specific point and slingshots back which removes some of the smart actions effects that are linked to it (like set orientation). The fix is either to make the waypoint pause code predictive, add a way to delay linked smart actions to help account for the slingshot action, or convert the pause and linked actions to a small event script.

Thanks for your time.

@sudlud
Copy link
Member

sudlud commented Dec 20, 2024

Thanks for the research :)

@fangshun2004
Copy link
Contributor

fangshun2004 commented Dec 20, 2024

I have been testing this all week going through many scripts, and it appears event links work fine except for when dealing with waypoints. The problem is the waypoint pause code appears to not be predictive and is only reactionary. So, if the SAI says to pause at a specific waypoint ID and then links an orientation smart action the code only fires right as it hits that waypoint ID but depending on the speed of the creature the pause may happen slightly after it passes the waypoint ID and slingshots back to the waypoint it was supposed to pause at. During that slingshot it actually fires off the orientation action, but the slingshot movement changes the creature back to the direction of the waypoint.

Anyway, it looks like it is just me being stupid. @sudlud thanks for being patient with me, you can close this issue if you want. Although the real issue is using SAI to pause at any points in a waypoint that is the not the end point (without repeat) of the waypoint path doesn't pause right at the specific point and slingshots back which removes some of the smart actions effects that are linked to it (like set orientation). The fix is either to make the waypoint pause code predictive, add a way to delay linked smart actions to help account for the slingshot action, or convert the pause and linked actions to a small event script.

Thanks for your time.

Do you use SMART_ACTION_WP_START (53) to move as a creature? It's a bit similar to #18938. Use 53 as a move command to pause and stop unstable. @Gultask recommends SMART_ACTION_WAYPOINT_DATA_START(232)SMART_ACTION_MOVEMENT_STOP(234)
SMART_ACTION_MOVEMENT_PAUSE (235) alternative, you can give it a try.

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

4 participants