Forums WoW Modding Support Archives Azerothcore Discord Archives [DiscordArchive] do i remove [nodiscard]? i take it, too?

[DiscordArchive] do i remove [nodiscard]? i take it, too?

[DiscordArchive] do i remove [nodiscard]? i take it, too?

rektbyfaith
Administrator
0
08-18-2023, 11:40 AM
#1
Archived author: Barnes • Posted: 2023-08-18T11:40:20.745000+00:00
Original source

do i remove [nodiscard]? i take it, too?
rektbyfaith
08-18-2023, 11:40 AM #1

Archived author: Barnes • Posted: 2023-08-18T11:40:20.745000+00:00
Original source

do i remove [nodiscard]? i take it, too?

rektbyfaith
Administrator
0
08-18-2023, 12:16 PM
#2
Archived author: Foe • Posted: 2023-08-18T12:16:51.755000+00:00
Original source

Nope, keep that as is
rektbyfaith
08-18-2023, 12:16 PM #2

Archived author: Foe • Posted: 2023-08-18T12:16:51.755000+00:00
Original source

Nope, keep that as is

rektbyfaith
Administrator
0
08-18-2023, 12:16 PM
#3
Archived author: Foe • Posted: 2023-08-18T12:16:56.274000+00:00
Original source

That's an ac thing
rektbyfaith
08-18-2023, 12:16 PM #3

Archived author: Foe • Posted: 2023-08-18T12:16:56.274000+00:00
Original source

That's an ac thing

rektbyfaith
Administrator
0
08-18-2023, 12:52 PM
#4
Archived author: Barnes • Posted: 2023-08-18T12:52:16.845000+00:00
Original source

Ok and insert the following after line 436? Im guessing the virtual member functions that are defining classes (im guessing?) that are declared before and after can be ignored.
```c++
------ Proceeding code
bool InsamePhase(uint32 otherMask) const
{
uint32 myMask = GetPhaseMask();
// If either object is in phase >= 64 then use the new behaviour.
if (my Mask >= 64 || otherMask >= 64)
{
// If the target phase is 1 then allow to see
// otherwise phases must match
return
// If i am in the same phase as them.
myMask == otherMask ||
// If i am in phase -1 (all).
myMask == uint32(-1) ||
// If target is in phase -1 (all).
otherMask == uint32(-1) ||
// If target is in phase 1 and I can see phase 1.
(otherMask == 1 && CanSeePhaseOne()) ||
// If I am in phase 1, I am must be a creature and I can see unique phases.
(myMask == 1 && (ToCreature() && CanSeeUniquePhase()));
}
return (myMask & otherMask) != 0;
}
----- Rest of code
```
rektbyfaith
08-18-2023, 12:52 PM #4

Archived author: Barnes • Posted: 2023-08-18T12:52:16.845000+00:00
Original source

Ok and insert the following after line 436? Im guessing the virtual member functions that are defining classes (im guessing?) that are declared before and after can be ignored.
```c++
------ Proceeding code
bool InsamePhase(uint32 otherMask) const
{
uint32 myMask = GetPhaseMask();
// If either object is in phase >= 64 then use the new behaviour.
if (my Mask >= 64 || otherMask >= 64)
{
// If the target phase is 1 then allow to see
// otherwise phases must match
return
// If i am in the same phase as them.
myMask == otherMask ||
// If i am in phase -1 (all).
myMask == uint32(-1) ||
// If target is in phase -1 (all).
otherMask == uint32(-1) ||
// If target is in phase 1 and I can see phase 1.
(otherMask == 1 && CanSeePhaseOne()) ||
// If I am in phase 1, I am must be a creature and I can see unique phases.
(myMask == 1 && (ToCreature() && CanSeeUniquePhase()));
}
return (myMask & otherMask) != 0;
}
----- Rest of code
```

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