rodecomp/Source/Contents/Effects/EffectVisibility.cpp
ragnarok-clanker a47d20f8be Reconstruct readable C++ and organize cohesive source subsystems
Administrative source import: native x86 compilation passed for 423 authored units. Source placement and submission states are migrated separately; this commit does not imply peer acceptance.

Previous head: 35d2a8cb36
Payload SHA256: 592f016d2730c5593bb653aa054c1e5f76a6df72c8f5a09e66f74876e2e33dee
2026-10-25 07:42:41 +00:00

42 lines
1,023 B
C++

#include "Contents/Effects/EffectActor.h"
#include "Contents/Effects/EffectVisibility.h"
#include "Contents/Effects/RagEffectState.h"
#include "Contents/Configuration/ServiceOptions.h"
// OFFSET: 0x00C734B0
// FUNCTION: fn_20327
bool PartyEffectVisible(const RagEffectState& effect, const EffectVisibilityContext& context) {
if (context.options.Get(8) == 0 && effect.forceRender == 0) {
return false;
}
const EffectActor* actor = effect.parent;
if (!actor) {
return false;
}
if (actor->render.unknown_00A8 == 0) {
return true;
}
if (effect.unknown_11CA0 == 0) {
if (actor->render.accountId == context.localAccountId) {
return true;
}
if (context.partyVisible) {
for (const MessengerMember& member : context.party) {
if (member.accountId == actor->render.accountId) {
if (member.offline == 0) {
return true;
}
break;
}
}
}
}
return actor->render.visible != 0 && actor->render.enabled != 0;
}