[DiscordArchive] Is that the reason?
[DiscordArchive] Is that the reason?
Archived author: Revision • Posted: 2024-02-09T01:05:31.371000+00:00
Original source
can't run getClass on a non-existent object
Archived author: adm • Posted: 2024-02-09T01:07:46.076000+00:00
Original source
how do I do that, like if player == 0 -> something something?
Archived author: Revision • Posted: 2024-02-09T01:08:55.846000+00:00
Original source
You either use `if (!player)` and return or surround your code with a `if (player)` so that if player isn't included it'll still continue like normal
Archived author: adm • Posted: 2024-02-09T01:12:16.489000+00:00
Original source
I will have to meditate on that for awhile
Archived author: adm • Posted: 2024-02-09T01:13:45.931000+00:00
Original source
Thank you!
Archived author: Anchy • Posted: 2024-02-09T01:42:38.801000+00:00
Original source
```cpp
bool IsPlayerPtrNotNull(Player* player)
{
bool isPlayerPtrNotNull = false;
bool areWeSureThatThePlayerPtrIsNotNull = false;
bool sanityCheckThatThePlayerPtrIsNotNull = false;
bool okayMaybeThePlayerPtrIsNotNullAfterAll = false;
for (int i = 0; i < 3; ++i) {
if (i == 0) {
isPlayerPtrNotNull = (player != nullptr);
} else if (i == 1) {
areWeSureThatThePlayerPtrIsNotNull = isPlayerPtrNotNull && (player != nullptr);
} else if (i == 2) {
sanityCheckThatThePlayerPtrIsNotNull = (i % 2 == 0) && areWeSureThatThePlayerPtrIsNotNull && player != nullptr;
}
}
okayMaybeThePlayerPtrIsNotNullAfterAll = (isPlayerPtrNotNull &&
areWeSureThatThePlayerPtrIsNotNull && sanityCheckThatThePlayerPtrIsNotNull);
return okayMaybeThePlayerPtrIsNotNullAfterAll;
}```
Archived author: Anchy • Posted: 2024-02-09T01:42:53.383000+00:00
Original source
```cpp
if(IsPlayerPtrNotNull(player))
{
...
}```
Archived author: Young Toto • Posted: 2024-02-09T02:09:11.893000+00:00
Original source
Where is the logic that handles the dummy effect for Soul Siphon? It isn't in the warlock spell script unless I'm blind
Archived author: Anchy • Posted: 2024-02-09T02:10:36.519000+00:00
Original source
probably in the spell dbc
Archived author: Anchy • Posted: 2024-02-09T02:10:43.421000+00:00
Original source
whats the spellid