gpt4 book ai didi

C++ 错误 : Expected an identifier

转载 作者:行者123 更新时间:2023-11-28 00:42:22 25 4
gpt4 key购买 nike

我正在尝试制作标题,但它给了我错误:

#ifndef __OFFSETS__H_
#define __OFFSETS__H_

typedef unsigned long MAIN = 0x22EA120;//0x022BF0C0 ;
typedef unsigned long RECOILVT = 0x020A3ACC;//0x020FA644;
typedef unsigned long DEVIATIONVT = 0x020A3AC8;//0x020FA640;

#define BF3_X
#define BF3_X_BASE
#define BF3_X_SIZE
#define OFFSET_CLIENTGAMECONTEXT
#define OFFSET_BORDERINPUTNODE
#define OFFSET_DXRENDERER
#define OFFSET_GAMERENDERER
#define pbcl_BASE
#define OFFSET_PBSS_BUFFER
#define OFFSET_PBSS_TAKESS
#define OFFSET_GIVEDAMAGE Address
#define OFFSET_COMPUTEAAB 0x010C95F0 // Function - BF3_X_BASE = IDA
#define OFFSET_AABWORLDTRANSFORM 0x010C6610 // Function - BF3_X_BASE = IDA Address
#define OFFSET_DBGRENDERER2 0x00000000 // Function - BF3_X_BASE = IDA
#define OFFSET_DBGRENDRAWTEXT 0x004B7610 // Function - BF3_X_BASE = IDA
#define OFFSET_DBGRENDRAW2DLINE 0x004B9980 // Function - BF3_X_BASE = IDA
#define OFFSET_DBGRENDRAWRECTLINE 0x004A11E0 // Function - BF3_X_BASE = IDA Address
#define OFFSET_DBGRENDRAWRECT
#define OFFSET_DBGRENDRAWSPHERE 0x004B7610 // Function - BF3_X_BASE = IDA
#define OFFSET_UPDATEMATRICES 0x006C3A90 // Function - BF3_X_BASE = IDA
#define OFFSET_W2S 0x00EF1590 // Function - BF3_X_BASE
#define OFFSET_RS_BEGINDRAW 0x006800A1 // Function - BF3_X_BASE = IDA
#define OFFSET_CLIENTPLAYER_ENTRY 0x00A99A20 // Function - BF3_X_BASE = IDA Address
#define OFFSET_CSW_GETWEAPON 0x01049B60 // Function - BF3_X_BASE = IDA
#define OFFSET_CSW_GETHEAT 0x00000000 // Function - BF3_X_BASE = IDA
#endif

错误是

error C2513: 'unsigned long' : no variable declared before '='

我不知道为什么?任何想法 ?

最佳答案

这些行不正确

typedef unsigned long MAIN = 0x22EA120;//0x022BF0C0 ;
typedef unsigned long RECOILVT = 0x020A3ACC;//0x020FA644;
typedef unsigned long DEVIATIONVT = 0x020A3AC8;//0x020FA640;

您正在定义一个类型。你不能给一个类型一个值。

做一个或另一个!

编辑

要么

一)

typedef unsigned long MAIN;
typedef unsigned long RECOILVT;
typedef unsigned long DEVIATIONVT;

二)

#define MAIN 0x22EA120
#define RECOILVT 0x020A3ACC
#define DEVIATIONVT 0x020A3AC8

c)

const int MAIN = 0x22EA120;//0x022BF0C0 ;
const int RECOILVT = 0x020A3ACC;//0x020FA644;
const int DEVIATIONVT = 0x020A3AC8;//0x020FA640;

你的选择

关于C++ 错误 : Expected an identifier,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18169547/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com