Forums WoW Modding Support Archives TrinityCore Discord Archives [DiscordArchive] in order to execute auto attacks on every X seconds ?

[DiscordArchive] in order to execute auto attacks on every X seconds ?

[DiscordArchive] in order to execute auto attacks on every X seconds ?

rektbyfaith
Administrator
0
08-31-2022, 09:56 PM
#1
Archived author: Armegon • Posted: 2022-08-31T21:56:54.825000+00:00
Original source

in order to execute auto attacks on every X seconds ?
rektbyfaith
08-31-2022, 09:56 PM #1

Archived author: Armegon • Posted: 2022-08-31T21:56:54.825000+00:00
Original source

in order to execute auto attacks on every X seconds ?

rektbyfaith
Administrator
0
09-01-2022, 02:13 AM
#2
Archived author: HelloKitty • Posted: 2022-09-01T02:13:52.476000+00:00
Original source

Afaik in 335 branch autoattack is handled in Player::Update which is called in Map::Update on one of the mapupdate worker pool threads. The timers are just tracked as state on the Unit and checked each update with isAttackReady. You can find it by searching for this in Player::Update: ```
// do attack
AttackerStateUpdate(victim, BASE_ATTACK);
resetAttackTimer(BASE_ATTACK);
```
rektbyfaith
09-01-2022, 02:13 AM #2

Archived author: HelloKitty • Posted: 2022-09-01T02:13:52.476000+00:00
Original source

Afaik in 335 branch autoattack is handled in Player::Update which is called in Map::Update on one of the mapupdate worker pool threads. The timers are just tracked as state on the Unit and checked each update with isAttackReady. You can find it by searching for this in Player::Update: ```
// do attack
AttackerStateUpdate(victim, BASE_ATTACK);
resetAttackTimer(BASE_ATTACK);
```

Recently Browsing
 1 Guest(s)
Recently Browsing
 1 Guest(s)