L L4D2node

CRecipientFilter::UsePredictionRules

0x00805bc0 · 231 bytes · __thiscall

_ZN16CRecipientFilter18UsePredictionRulesEv

Decompiled

undefined (1 param)

/* CRecipientFilter::UsePredictionRules() */

void __thiscall CRecipientFilter::UsePredictionRules(CRecipientFilter *this)

{
  uint uVar1;
  undefined4 this_00;
  char cVar2;
  int iVar3;
  int *piVar4;
  CBasePlayer *pCVar5;
  undefined *puVar6;
  
  if (this[0x1c] == (CRecipientFilter)0x0) {
    this[0x1c] = (CRecipientFilter)0x1;
    iVar3 = (**(code **)(*(int *)this + 0x10))(this);
    this_00 = g_RecipientFilterPredictionSystem._12_4_;
    if (((iVar3 != 0) && ((int)g_RecipientFilterPredictionSystem._16_4_ < 1)) &&
       (g_RecipientFilterPredictionSystem._12_4_ != 0)) {
      cVar2 = (**(code **)(*(int *)g_RecipientFilterPredictionSystem._12_4_ + 0x16c))
                        (g_RecipientFilterPredictionSystem._12_4_);
      if (cVar2 != '\0') {
        RemoveRecipient(this,(CBasePlayer *)this_00);
        cVar2 = CBasePlayer::IsSplitScreenPlayer((CBasePlayer *)this_00);
        if (cVar2 == '\0') {
          piVar4 = (int *)CBasePlayer::GetSplitScreenPlayers((CBasePlayer *)this_00);
          if (0 < piVar4[3]) {
            iVar3 = 0;
            do {
              pCVar5 = (CBasePlayer *)0x0;
              uVar1 = *(uint *)(*piVar4 + iVar3 * 4);
              if (((uVar1 != 0xffffffff) &&
                  (puVar6 = g_pEntityList + (uVar1 & 0xfff) * 0x10,
                  puVar6 != (undefined *)0xfffffffc)) && (*(uint *)(puVar6 + 8) == uVar1 >> 0xc)) {
                pCVar5 = *(CBasePlayer **)(puVar6 + 4);
              }
              iVar3 = iVar3 + 1;
              RemoveRecipient(this,pCVar5);
            } while (iVar3 < piVar4[3]);
          }
        }
        else {
          pCVar5 = (CBasePlayer *)CBasePlayer::GetSplitScreenPlayerOwner((CBasePlayer *)this_00);
          RemoveRecipient(this,pCVar5);
        }
      }
    }
  }
  return;
}

SourceMod gamedata

paste into addons/sourcemod/gamedata/<your_plugin>.txt
used as the SourceMod key — change to fit your plugin's convention
SourceMod library name (server / engine / matchmaking)

Just a Signatures{} block, ready to drop into a gamedata file. Wire it up in your plugin however you like - SDKCall, DHooks, raw memory ops, or anything else.



        

        

          

Type inference is best-effort from the C signature - sanity-check the DHooks types before shipping.

Return-type handling cheatsheet (DHookReturn)