Skip to content
| Marketplace
Sign in
Visual Studio Code>Debuggers>OBB DebuggerNew to Visual Studio Code? Get it now.
OBB Debugger

OBB Debugger

zhangxin786798298

|
15 installs
| (0) | Free
TCP 调试适配器
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

OBB Debugger

OBB Debugger 是一个用于 TCP 调试的 VS Code 扩展,支持OBB脚本调试

主要功能

  • 一键编译(F7)
  • 重新编译(Ctrl+Alt+F7)
  • 挂载调试 OBB服务进程

使用说明

  1. 建议打开工程目录:popion-server\h5game\popionserver(包含.slt解决方案文件的目录)
  2. 配置好 .vscode 文件夹下的相关文件。
  3. 按 F7 进行一键编译,或 Ctrl+Alt+F7 重新编译。
  4. 在 launch.json 中选择对应的调试配置,按 F5 启动调试。

下载插件

C++标准插件
通过VSCode扩展商店安装官方C++插件

配置说明

在.vscode文件夹中包含以下配置文件:

文件名称 作用说明
settings.json 定义全局变量,需根据本地SDK目录路径修改
c_cpp_properties.json C++插件配置文件,用于实现代码跳转和智能提示
tasks.json 编译配置脚本,支持通过.slt整体编译或手动编译单个目录
launch.json 调试主配置文件,包含调试器参数和启动设置

settings.json

{
    "C_Cpp.errorSquiggles": "disabled",
    "SDK_PATH": "E:/sdk",
    "GDB_Path": "F:/MagicX/code/sdk/winexe/bin/PublishU64/ucgdbu64.exe",
    "BUILD_PATH": "F:/MagicX/code/sdk/winexe/bin/PublishU64/ucmakeu64.exe",
    "SERVER_URL": "ws://127.0.0.1:9001"
}

c_cpp_properties.json

{
    "configurations": [
        {
            "name": "Win32",
            "includePath": [
                "${workspaceFolder}/**",
                "${config:SDK_PATH}/include/**"
            ],
            "windowsSdkVersion": "10.0.22621.0",
            "compilerPath": "cl.exe",
            "cStandard": "c17",
            "intelliSenseMode": "windows-msvc-x64",
            "forcedInclude": [
                "${config:SDK_PATH}/include/all.h"
            ]
        }
    ],
    "version": 4
}

tasks.json

{
  "version": "2.0.0",
  "tasks": [
    {
      "label": "build",
      "type": "shell",
      "command": "${config:BUILD_PATH}",
      "args": [
        "popionserver.slt"
      ],
      "options": {
        "env": {
          "Obj": "../../Obj",
          "Obb": "../../Obb"
        }
      },
      "group": {
        "kind": "build",
        "isDefault": true
      }
    },
    {
      "label": "build",
      "type": "shell",
      "command": "${config:BUILD_PATH}",
      "args": [
        "dns:platform_dnsd.obb",
        "gate:platform_gated.obb",
        "smartbandserver:smartbandserverd.obb"
      ],
      "options": {
        "env": {
          "Obj": "../../Obj",
          "Obb": "../../Obb"
        }
      },
      "group": {
        "kind": "build",
        "isDefault": false
      }
    }
  ]
}

launch.json

{
    "version": "0.2.0",
    "configurations": [
        {
            "type": "obb-debugger",         //使用的调试器插件
            "request": "launch",            //默认使用launch 暂不支持其他
            "name": "GameHall_0",           //调试器名称
            "processPath": "${config:GDB_Path}",    //调试器gdb路径
            "processArgs": [
                "${config:SERVER_URL}//GameHall_0"      //连接的服务端地址
            ],
            "port": 19229,          // 与调试器连接的端口,随意找一个本地没有使用的端口即可
            "trace": true,          // 暂时没用,默认使用true
            "sourceFileMap": {
              "/": "${workspaceFolder}"
            }
        },
        {
            "type": "obb-debugger",
            "request": "launch",
            "name": "GameScene_0",
            "processPath": "${config:GDB_Path}",
            "processArgs": [
                "${config:SERVER_URL}//GameScene_0"
            ],
            "port": 19229,
            "trace": true,
            "sourceFileMap": {
              "/": "${workspaceFolder}"
            }
        }
    ]
}
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft