查找CCSGameRulesGoToIntermission

tools-only2026-10-27查看 394复制 1980

使用 IDA Pro MCP 在 CS2 二进制文件中查找并识别 CCSGameRules_GoToIntermission 函数。在逆向工程 CS2 server.dll 或 server.so 时使用此技能,通过搜索 "Going to intermission..." 字符串引用来定位 GoToIntermission 函数。

Download (.md)

📘如何使用这个技能

  1. 1
    复制技能内容·点击上方「Copy SKILL.md」复制全部内容,或 Download 下载到本地
  2. 2
    打开你的 AI 客户端·支持 Claude Code、Trae、Cursor、ChatGPT、DeepSeek、Kimi 等任意 AI 助手
  3. 3
    粘贴为系统提示/知识文件·Claude Code:放入 .claude/skills/ 目录;普通对话:作为首条消息发送并说「请严格按这份技能文档执行」
  4. 4
    直接提出你的需求·AI 会按技能定义的工作流、格式和约束来处理,无需再解释背景

💡 提示:技能生效后,每次对话只需一句需求,AI 会按 SKILL.md 的流程执行。

SKILL.md3009 chars
---
name: find-CCSGameRules_GoToIntermission
description: Find and identify the CCSGameRules_GoToIntermission function in CS2 binary using IDA Pro MCP. Use this skill when reverse engineering CS2 server.dll or server.so to locate the GoToIntermission function by searching for the "Going to intermission..." string reference.
---

# Find CCSGameRules_GoToIntermission

Locate `CCSGameRules_GoToIntermission` in CS2 server.dll or server.so using IDA Pro MCP tools.

## Method

### 1. Search for Reference String

Search for the string `"Going to intermission..."`:

```
mcp__ida-pro-mcp__find_regex pattern="Going to intermission"
```

Note the string address.

### 2. Find Cross-Reference and Containing Function

Get xrefs to the string address:

```
mcp__ida-pro-mcp__xrefs_to addrs="<string_address>"
```

This will lead to `CCSGameRules_GoToIntermission`. Rename it:

```
mcp__ida-pro-mcp__rename batch={"func": [{"addr": "<function_addr>", "name": "CCSGameRules_GoToIntermission"}]}
```

### 3. Get VTable Index

**ALWAYS** Use SKILL `/get-vtable-index` to get vtable offset and index for the function `CCSGameRules_GoToIntermission`.

VTable class name: `CCSGameRules`

### 4. Generate Signature

**ALWAYS** Use SKILL `/generate-signature-for-function` to generate a robust and unique signature for `CCSGameRules_GoToIntermission`.

### 5. Write Analysis Results as YAML

**ALWAYS** Use SKILL `/write-vfunc-as-yaml` to write the analysis results for `CCSGameRules_GoToIntermission`.

Required parameters:
- `func_name`: `CCSGameRules_GoToIntermission`
- `func_addr`: The function address from step 2
- `func_sig`: The signature from step 4

VTable parameters:
- `vtable_name`: `CCSGameRules`
- `vfunc_index`: The vtable index from step 3
- `vfunc_offset`: The vtable offset from step 3

## VTable Information

- **VTable Name**: `CCSGameRules::`vftable'`
- **VTable Mangled Name (Windows)**: `??_7CCSGameRules@@6B@`
- **VTable Mangled Name (Linux)**: `_ZTV12CCSGameRules`
- **VTable Index**: 128 - This can change when game updates.
- **VTable Offset**: 0x400 (128 * 8 = 1024) - This can change when game updates.

* Note that for `server.so`, the first 16 bytes of "vftable" are for RTTI. The real vftable = `_ZTV12CCSGameRules` + `0x10`.

## Output YAML Format

The output YAML filename depends on the platform:
- `server.dll` → `CCSGameRules_GoToIntermission.windows.yaml`
- `server.so` → `CCSGameRules_GoToIntermission.linux.yaml`

```yaml
func_name: CCSGameRules_GoToIntermission
func_va: 0x18087eba0
func_rva: 0x87eba0
func_size: 0xe61
func_sig: 48 89 5C 24 ?? 55 56 57 41 54 41 55 41 56 41 57 48 8D AC 24 ?? ?? ?? ?? 48 81 EC ?? ?? ?? ?? 4C 8B E1
vtable_name: CCSGameRules
vfunc_offset: 0x400
vfunc_index: 128
```

## Notes

- This function is called when a match ends and the game transitions to intermission.
- It sends `CCSUsrMsg_EndOfMatchAllPlayersData` and `CCSUsrMsg_ServerRankRevealAll` user messages.
- It fires the `cs_intermission` game event.
- It is a large function (~0xE61 bytes).
来源:skillsdirectory

评论0

登录后参与评论

还没有评论,来抢沙发吧