본문으로 건너뛰기
cccskills
무료GitHub에 공개

find-CCSGameRules__sm_mapGcBanInformation

Find and identify the CCSGameRules__sm_mapGcBanInformation global variable in CS2 binary using IDA Pro MCP. Use this skill when reverse engineering CS2 server.dll or libserver.so to locate the GC ban information map structure by decompiling CCSPlayerController_ResourceDataThink's sub-function (Linux) or searching for the "Notification about user penalty" string (Windows).

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

설치 방법 보기

포함된 파일(1)

  • SKILL.md5.3 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

Find CCSGameRules__sm_mapGcBanInformation

Locate CCSGameRules__sm_mapGcBanInformation (global variable) in CS2 server.dll or libserver.so using IDA Pro MCP tools.

Prerequisites

  • CCSPlayerController_ResourceDataThink must be identified first (Linux method depends on it)
  • Use SKILL /get-func-from-yaml to load CCSPlayerController_ResourceDataThink if its YAML already exists

Method

Windows: String-based approach

1. Search for the debug string

mcp__ida-pro-mcp__find_regex pattern="Notification about user penalty: %u/%u"

2. Get cross-references to the string

mcp__ida-pro-mcp__xrefs_to addrs="<string_addr>"

3. Decompile the referencing function

mcp__ida-pro-mcp__decompile addr="<function_addr>"

4. Identify the global variable

Look for the pattern after the DevMsg("Notification about user penalty: %u/%u (%u sec)\n", ...) call:

sub_XXXXXXXX(&unk_YYYYYYYY, &v10, &v12);

Where unk_YYYYYYYY (the second argument, offset by +8 from the base) is CCSGameRules__sm_mapGcBanInformation. The base address is unk_YYYYYYYY - 8.

More specifically, look for:

v12 = &unk_181E4C960;       // unk_181E4C960 is CCSGameRules__sm_mapGcBanInformation - 8
LOBYTE(v13) = 1;
v14 = &v17;
v18 = 0LL;
v19 = 0LL;
sub_XXXXXXXX(&unk_181E4C968, &v10, &v12);  // unk_181E4C968 is CCSGameRules__sm_mapGcBanInformation

The global variable to rename is the one passed as the first argument to the map lookup function (e.g., unk_181E4C968).

Linux: Decompilation-based approach

1. Load CCSPlayerController_ResourceDataThink address

Use SKILL /get-func-from-yaml to get the address, or decompile it directly:

mcp__ida-pro-mcp__decompile addr="<CCSPlayerController_ResourceDataThink_addr>"

2. Decompile the sub-function called inside ResourceDataThink

The wrapper function calls a sub-function as its second operation:

__int64 __fastcall CCSPlayerController_ResourceDataThink(__int64 a1, ...)
{
  ++*(_DWORD *)(a1 + 3084);
  sub_YYYYYY(a1, ...);    // <--- decompile this function
  ...
}
mcp__ida-pro-mcp__decompile addr="<sub_function_addr>"

3. Identify the global variable

In the decompiled sub-function, look for the pattern:

v43 = *((int *)&unk_XXXXXXXX + 6)

or equivalently:

if ( !*v26 || (v42 = sub_A85C10(v7), v43 = *((int *)&unk_XXXXXXXX + 6), (_DWORD)v43 == -1) )

Where unk_XXXXXXXX is CCSGameRules__sm_mapGcBanInformation.

Additional verification — the same variable appears in the tree traversal loop:

if ( (*((_DWORD *)&unk_XXXXXXXX + 3) & 0x7FFFFFFF) != 0 )
{
    v44 = *((_QWORD *)&unk_XXXXXXXX + 2);
    do
    {
      v45 = 56 * v43;
      v46 = (int *)(v44 + v45);
      ...
    }
    while ( (_DWORD)v43 != -1 );
}

Common steps (both platforms)

5. Rename the global variable

mcp__ida-pro-mcp__rename batch={"data": {"old": "<unk_XXXXXXXX>", "new": "CCSGameRules__sm_mapGcBanInformation"}}

6. Generate unique signature

ALWAYS Use SKILL /generate-signature-for-globalvar to generate a robust and unique signature for CCSGameRules__sm_mapGcBanInformation.

7. Write IDA analysis output as YAML

ALWAYS Use SKILL /write-globalvar-as-yaml to write the analysis results.

Required parameters:

  • gv_name: CCSGameRules__sm_mapGcBanInformation
  • gv_addr: The global variable address from step 3/4
  • gv_sig: The validated signature from step 6
  • gv_sig_va: The virtual address that signature matches
  • gv_inst_offset: Offset from signature start to GV-accessing instruction
  • gv_inst_length: Length of the GV-accessing instruction
  • gv_inst_disp: Displacement offset within the instruction

Global Variable Characteristics

  • Type: Map/tree structure (CUtlMap or similar)
  • Purpose: Stores GC (Game Coordinator) ban information per player, used during resource data updates
  • Usage: Queried during CCSPlayerController_ResourceDataThink to check player penalty status
  • Structure fields accessed:
    • +0x0C (+3 as DWORD): Node count / flags (masked with 0x7FFFFFFF)
    • +0x10 (+2 as QWORD): Pointer to tree node array
    • +0x18 (+6 as int): Root node index (or -1 if empty)
    • Each node is 56 bytes with key at offset +16 and data at offset +48

Output YAML Format

The output YAML filename depends on the platform:

  • server.dll → CCSGameRules__sm_mapGcBanInformation.windows.yaml
  • libserver.so / libserver.so → CCSGameRules__sm_mapGcBanInformation.linux.yaml

Notes

  • This is a global variable, NOT a function — use /write-globalvar-as-yaml, not /write-func-as-yaml
  • The variable name uses double underscore (__) to represent the :: scope separator
  • On Windows, the string "Notification about user penalty" provides a direct path to the variable
  • On Linux, the variable must be found through decompilation of the ResourceDataThink sub-function

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Clean up the local workspace after a dev branch has been merged into main. Verifies the current dev branch is fully merged into origin/main, then switches to main, pulls the latest, deletes the local dev branch, and deletes the remote dev branch if it still exists. STOPS and warns the user if the current branch is not yet merged. Triggers: cleanup workspace, cleanup branch, delete merged branch, finish dev branch, post-merge cleanup

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

mrc4tt/CS2_VibeSignatures32026년 10월 23일 업데이트

Convert an existing find-XXXX SKILL.md into a preprocessor Python script, updating configs/<GAMEVER>.yaml and removing the old SKILL.md. Covers xref-string-based and LLM_DECOMPILE-based discovery patterns.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

mrc4tt/CS2_VibeSignatures32026년 10월 23일 업데이트

Create an Agent SKILL.md fallback for an existing find-XXXX finder that relies on a fragile discovery foundation — above all LLM_DECOMPILE (patterns C/D/E), which matches the decompiled shape of a predecessor function against a stored reference and breaks when a symbol is inlined or de-inlined in a way the reference does not cover. The generated fallback coexists with the preprocessor and runs only when it returns failure, recovering every target robustly by decompiling the predecessor and following the inline/de-inline boundary with semantic anchors. Use when a finder broke on a game update, or you want to durably backstop one before it does. The recipe generalizes to any finder foundation. Triggers: create agent skill fallback, add SKILL.md fallback, robust fallback for finder, backstop LLM_DECOMPILE finder, final guarantee skill

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

mrc4tt/CS2_VibeSignatures32026년 10월 23일 업데이트

Create a new cpp_tests entry for validating a C++ interface vtable layout against binary reference YAMLs. Creates the .cpp test file in cpp_tests/ and appends a configs/<GAMEVER>.yaml entry under cpp_tests:. Use when a user asks to add vtable layout validation for a new hl2sdk_cs2 interface class.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

mrc4tt/CS2_VibeSignatures32026년 10월 23일 업데이트

create-pr

무료

Create a GitHub pull request from staged task changes or an already-committed current branch. Deliver source/config/ reference changes together with their computed source-owned `bin_artifacts` closure. PR validation routing is owned by the default-branch trusted workflow; snapshots, gamedata, and manifests are Release-derived only.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

mrc4tt/CS2_VibeSignatures32026년 10월 23일 업데이트

Create a new find-XXXX preprocessor Python script from scratch (no existing SKILL.md), add configs/<GAMEVER>.yaml skill and symbol entries. Covers xref-string-based and LLM_DECOMPILE-based discovery patterns. Use when a GitHub issue or user instruction specifies a new function to find.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

mrc4tt/CS2_VibeSignatures32026년 10월 23일 업데이트

mrc4tt의 스킬 모두 보기

이 스킬의 문제 신고