Game Map Asset: Difference between revisions
Created page with "__NOTOC__ Category:Assets Category:CoD4 Category:MW2 Category:MW3 Category:Ghosts Category:WaW Category:BO1 Category:BO2 The game map (or game ..." |
|||
| (2 intermediate revisions by the same user not shown) | |||
| Line 3: | Line 3: | ||
[[Category:CoD4]] | [[Category:CoD4]] | ||
[[Category:MW2]] | [[Category:MW2]] | ||
[[Category:WaW]] | [[Category:WaW]] | ||
[[Category:BO1]] | [[Category:BO1]] | ||
| Line 153: | Line 151: | ||
NODE_COVER_RIGHT = 0x6, | NODE_COVER_RIGHT = 0x6, | ||
NODE_COVER_LEFT = 0x7, | NODE_COVER_LEFT = 0x7, | ||
NODE_COVER_PILLAR = 0x8, | |||
NODE_AMBUSH = 0x9, | |||
NODE_CONCEALMENT_STAND = | NODE_EXPOSED = 0xA, | ||
NODE_CONCEALMENT_CROUCH = | NODE_CONCEALMENT_STAND = 0xB, | ||
NODE_CONCEALMENT_PRONE = | NODE_CONCEALMENT_CROUCH = 0xC, | ||
NODE_REACQUIRE = | NODE_CONCEALMENT_PRONE = 0xD, | ||
NODE_BALCONY = | NODE_REACQUIRE = 0xE, | ||
NODE_SCRIPTED = | NODE_BALCONY = 0xF, | ||
NODE_NEGOTIATION_BEGIN = | NODE_SCRIPTED = 0x10, | ||
NODE_NEGOTIATION_END = | NODE_NEGOTIATION_BEGIN = 0x11, | ||
NODE_TURRET = | NODE_NEGOTIATION_END = 0x12, | ||
NODE_GUARD = | NODE_TURRET = 0x13, | ||
NODE_NUMTYPES = | NODE_GUARD = 0x14, | ||
NODE_NUMTYPES = 0x15, | |||
NODE_DONTLINK = 0x15, | |||
}; | }; | ||
struct pathlink_s | struct pathlink_s | ||
{ | { | ||
char | float fDist; | ||
unsigned __int16 nodeNum; | |||
char disconnectCount; | |||
char negotiationLink; | |||
char flags; | |||
char ubBadPlaceCount[5]; | |||
}; | }; | ||
| Line 176: | Line 181: | ||
{ | { | ||
nodeType type; | nodeType type; | ||
int spawnflags; | |||
ScriptString targetname; | ScriptString targetname; | ||
ScriptString script_linkName; | ScriptString script_linkName; | ||
| Line 183: | Line 188: | ||
ScriptString animscript; | ScriptString animscript; | ||
int animscriptfunc; | int animscriptfunc; | ||
vec3_t vOrigin; | |||
float fAngle; | float fAngle; | ||
vec2_t forward; | |||
float fRadius; | float fRadius; | ||
float minUseDistSq; | float minUseDistSq; | ||
__int16 wOverlapNode[2]; | __int16 wOverlapNode[2]; | ||
unsigned __int16 totalLinkCount; | unsigned __int16 totalLinkCount; | ||
pathlink_s *Links; | pathlink_s *Links; | ||
}; | }; | ||
struct | struct SentientHandle | ||
{ | |||
unsigned __int16 number; | |||
unsigned __int16 infoIndex; | |||
}; | |||
struct pathnode_dynamic_t | |||
{ | |||
SentientHandle pOwner; | |||
int iFreeTime; | |||
int iValidTime[3]; | |||
int dangerousNodeTime[3]; | |||
int inPlayerLOSTime; | |||
__int16 wLinkCount; | |||
__int16 wOverlapCount; | |||
__int16 turretEntNumber; | |||
__int16 userCount; | |||
bool hasBadPlaceLink; | |||
}; | |||
struct pathnode_transient_t | |||
{ | { | ||
int iSearchFrame; | |||
pathnode_t *pNextOpen; | |||
pathnode_t *pPrevOpen; | |||
pathnode_t *pParent; | |||
float fCost; | |||
float fHeuristic; | |||
union | |||
{ | |||
float nodeCost; | |||
float linkIndex; | |||
}; | |||
}; | }; | ||
struct | struct pathnode_t | ||
{ | { | ||
pathnode_constant_t constant; | |||
pathnode_dynamic_t dynamic; | |||
pathnode_transient_t transient; | |||
}; | }; | ||
| Line 212: | Line 243: | ||
{ | { | ||
int nodeCount; | int nodeCount; | ||
unsigned | unsigned __int16 *nodes; | ||
}; | }; | ||
| Line 221: | Line 252: | ||
}; | }; | ||
struct pathnode_tree_t | |||
{ | |||
int axis; | |||
float dist; | |||
pathnode_tree_info_t u; | |||
}; | |||
struct pathbasenode_t | |||
{ | |||
vec3_t vOrigin; | |||
unsigned int type; | |||
}; | |||
struct PathData | struct PathData | ||
{ | { | ||
unsigned int nodeCount; | unsigned int nodeCount; | ||
unsigned int originalNodeCount; | |||
pathnode_t *nodes; | pathnode_t *nodes; | ||
pathbasenode_t *nodeBases; | pathbasenode_t *nodeBases; | ||
int visBytes; | int visBytes; | ||
char *pathVis; | char *pathVis; | ||
int smoothBytes; | |||
char *smoothCache; | |||
int nodeTreeCount; | int nodeTreeCount; | ||
pathnode_tree_t *nodeTree; | pathnode_tree_t *nodeTree; | ||
| Line 238: | Line 280: | ||
struct GameWorldSp | struct GameWorldSp | ||
{ | |||
const char *name; | |||
PathData path; | |||
}; | |||
struct GameWorldMp | |||
{ | { | ||
const char *name; | const char *name; | ||
| Line 243: | Line 291: | ||
}; | }; | ||
</syntaxhighlight> | </syntaxhighlight> | ||
== Call of Duty 4 Multiplayer == | == Call of Duty 4 Multiplayer == | ||
The multiplayer Call of Duty 4 game world is pretty much unneeded. | The multiplayer Call of Duty 4 game world is pretty much unneeded. | ||
| Line 406: | Line 455: | ||
=== Multiplayer === | === Multiplayer === | ||
<syntaxhighlight lang="cpp"> | <syntaxhighlight lang="cpp"> | ||
struct | struct GameWorldMp | ||
{ | { | ||
const char *name; | const char *name; | ||
Latest revision as of 06:14, 21 December 2014
The game map (or game world) is part of the D3DBSP system produced by Radiant, and is on every Call of Duty game except for Modern Warfare 3 and Ghosts. This contains scripting information for the map, such as AI pathing information.
Call of Duty 4 Single Player & World at War & Black Ops 1
For World at War and Black Ops 1, the MP and SP assets are identical.
enum nodeType
{
NODE_BADNODE = 0x0,
NODE_PATHNODE = 0x1,
NODE_COVER_STAND = 0x2,
NODE_COVER_CROUCH = 0x3,
NODE_COVER_CROUCH_WINDOW = 0x4,
NODE_COVER_PRONE = 0x5,
NODE_COVER_RIGHT = 0x6,
NODE_COVER_LEFT = 0x7,
NODE_COVER_WIDE_RIGHT = 0x8,
NODE_COVER_WIDE_LEFT = 0x9,
NODE_CONCEALMENT_STAND = 0xA,
NODE_CONCEALMENT_CROUCH = 0xB,
NODE_CONCEALMENT_PRONE = 0xC,
NODE_REACQUIRE = 0xD,
NODE_BALCONY = 0xE,
NODE_SCRIPTED = 0xF,
NODE_NEGOTIATION_BEGIN = 0x10,
NODE_NEGOTIATION_END = 0x11,
NODE_TURRET = 0x12,
NODE_GUARD = 0x13,
NODE_NUMTYPES = 0x14,
};
struct pathlink_s
{
float fDist;
unsigned __int16 nodeNum;
char disconnectCount;
char negotiationLink;
char ubBadPlaceCount[4];
};
struct pathnode_constant_t
{
nodeType type;
unsigned __int16 spawnflags;
ScriptString targetname;
ScriptString script_linkName;
ScriptString script_noteworthy;
ScriptString target;
ScriptString animscript;
int animscriptfunc;
float vOrigin[3];
float fAngle;
float forward[2];
float fRadius;
float minUseDistSq;
__int16 wOverlapNode[2];
__int16 wChainId;
__int16 wChainDepth;
__int16 wChainParent;
unsigned __int16 totalLinkCount;
pathlink_s *Links;
};
struct pathnode_dynamic_t
{
struct sentient_s *pOwner;
int iFreeTime;
int iValidTime[3];
int inPlayerLOSTime;
__int16 wLinkCount;
__int16 wOverlapCount;
__int16 turretEntNumber;
__int16 userCount;
};
struct pathnode_t
{
pathnode_constant_t constant;
pathnode_dynamic_t dynamic;
pathnode_transient_t transient;
};
struct pathnode_transient_t
{
int iSearchFrame;
pathnode_t *pNextOpen;
pathnode_t *pPrevOpen;
pathnode_t *pParent;
float fCost;
float fHeuristic;
float costFactor;
};
struct pathnode_tree_t
{
int axis;
float dist;
pathnode_tree_info_t u;
};
struct pathnode_tree_nodes_t
{
int nodeCount;
unsigned short **nodes;
};
union pathnode_tree_info_t
{
pathnode_tree_t *child[2];
pathnode_tree_nodes_t s;
};
typdef char pathbasenode_t[0x10];
struct PathData
{
unsigned int nodeCount;
pathnode_t *nodes;
pathbasenode_t *nodeBases;
unsigned int chainNodeCount;
unsigned __int16 *chainNodeForNode;
unsigned __int16 *nodeForChainNode;
int visBytes;
char *pathVis;
int nodeTreeCount;
pathnode_tree_t *nodeTree;
};
struct GameWorldSp
{
const char *name;
PathData path;
};Black Ops 2
The Black Ops 2 game maps (which are loaded exactly the same) are slightly different from its predecessors.
enum nodeType
{
NODE_BADNODE = 0x0,
NODE_PATHNODE = 0x1,
NODE_COVER_STAND = 0x2,
NODE_COVER_CROUCH = 0x3,
NODE_COVER_CROUCH_WINDOW = 0x4,
NODE_COVER_PRONE = 0x5,
NODE_COVER_RIGHT = 0x6,
NODE_COVER_LEFT = 0x7,
NODE_COVER_PILLAR = 0x8,
NODE_AMBUSH = 0x9,
NODE_EXPOSED = 0xA,
NODE_CONCEALMENT_STAND = 0xB,
NODE_CONCEALMENT_CROUCH = 0xC,
NODE_CONCEALMENT_PRONE = 0xD,
NODE_REACQUIRE = 0xE,
NODE_BALCONY = 0xF,
NODE_SCRIPTED = 0x10,
NODE_NEGOTIATION_BEGIN = 0x11,
NODE_NEGOTIATION_END = 0x12,
NODE_TURRET = 0x13,
NODE_GUARD = 0x14,
NODE_NUMTYPES = 0x15,
NODE_DONTLINK = 0x15,
};
struct pathlink_s
{
float fDist;
unsigned __int16 nodeNum;
char disconnectCount;
char negotiationLink;
char flags;
char ubBadPlaceCount[5];
};
struct pathnode_constant_t
{
nodeType type;
int spawnflags;
ScriptString targetname;
ScriptString script_linkName;
ScriptString script_noteworthy;
ScriptString target;
ScriptString animscript;
int animscriptfunc;
vec3_t vOrigin;
float fAngle;
vec2_t forward;
float fRadius;
float minUseDistSq;
__int16 wOverlapNode[2];
unsigned __int16 totalLinkCount;
pathlink_s *Links;
};
struct SentientHandle
{
unsigned __int16 number;
unsigned __int16 infoIndex;
};
struct pathnode_dynamic_t
{
SentientHandle pOwner;
int iFreeTime;
int iValidTime[3];
int dangerousNodeTime[3];
int inPlayerLOSTime;
__int16 wLinkCount;
__int16 wOverlapCount;
__int16 turretEntNumber;
__int16 userCount;
bool hasBadPlaceLink;
};
struct pathnode_transient_t
{
int iSearchFrame;
pathnode_t *pNextOpen;
pathnode_t *pPrevOpen;
pathnode_t *pParent;
float fCost;
float fHeuristic;
union
{
float nodeCost;
float linkIndex;
};
};
struct pathnode_t
{
pathnode_constant_t constant;
pathnode_dynamic_t dynamic;
pathnode_transient_t transient;
};
struct pathnode_tree_nodes_t
{
int nodeCount;
unsigned __int16 *nodes;
};
union pathnode_tree_info_t
{
pathnode_tree_t *child[2];
pathnode_tree_nodes_t s;
};
struct pathnode_tree_t
{
int axis;
float dist;
pathnode_tree_info_t u;
};
struct pathbasenode_t
{
vec3_t vOrigin;
unsigned int type;
};
struct PathData
{
unsigned int nodeCount;
unsigned int originalNodeCount;
pathnode_t *nodes;
pathbasenode_t *nodeBases;
int visBytes;
char *pathVis;
int smoothBytes;
char *smoothCache;
int nodeTreeCount;
pathnode_tree_t *nodeTree;
};
struct GameWorldSp
{
const char *name;
PathData path;
};
struct GameWorldMp
{
const char *name;
PathData path;
};Call of Duty 4 Multiplayer
The multiplayer Call of Duty 4 game world is pretty much unneeded.
struct GameWorldMp
{
const char *name;
};Modern Warfare 2
Single Player
enum nodeType
{
NODE_BADNODE = 0x0,
NODE_PATHNODE = 0x1,
NODE_COVER_STAND = 0x2,
NODE_COVER_CROUCH = 0x3,
NODE_COVER_CROUCH_WINDOW = 0x4,
NODE_COVER_PRONE = 0x5,
NODE_COVER_RIGHT = 0x6,
NODE_COVER_LEFT = 0x7,
NODE_COVER_WIDE_RIGHT = 0x8,
NODE_COVER_WIDE_LEFT = 0x9,
NODE_CONCEALMENT_STAND = 0xA,
NODE_CONCEALMENT_CROUCH = 0xB,
NODE_CONCEALMENT_PRONE = 0xC,
NODE_REACQUIRE = 0xD,
NODE_BALCONY = 0xE,
NODE_SCRIPTED = 0xF,
NODE_NEGOTIATION_BEGIN = 0x10,
NODE_NEGOTIATION_END = 0x11,
NODE_TURRET = 0x12,
NODE_GUARD = 0x13,
NODE_NUMTYPES = 0x14,
};
struct pathlink_s
{
float fDist;
unsigned __int16 nodeNum;
char disconnectCount;
char negotiationLink;
char ubBadPlaceCount[4];
};
struct pathnode_constant_t
{
nodeType type;
unsigned __int16 spawnflags;
ScriptString targetname;
ScriptString script_linkName;
ScriptString script_noteworthy;
ScriptString target;
ScriptString animscript;
int animscriptfunc;
float vOrigin[3];
float fAngle;
float forward[2];
float fRadius;
float minUseDistSq;
__int16 wOverlapNode[2];
unsigned __int16 totalLinkCount;
pathlink_s *Links;
};
struct pathnode_t
{
pathnode_constant_t constant;
char unknown[0x48];
};
struct pathnode_tree_t
{
int axis;
float dist;
pathnode_tree_info_t u;
};
struct pathnode_tree_nodes_t
{
int nodeCount;
unsigned short **nodes;
};
union pathnode_tree_info_t
{
pathnode_tree_t *child[2];
pathnode_tree_nodes_t s;
};
typdef char pathbasenode_t[0x10];
struct PathData
{
unsigned int nodeCount;
pathnode_t *nodes;
pathbasenode_t *nodeBases;
unsigned int chainNodeCount;
unsigned __int16 *chainNodeForNode;
unsigned __int16 *nodeForChainNode;
int visBytes;
char *pathVis;
int nodeTreeCount;
pathnode_tree_t *nodeTree;
};
struct unknownGameWorldSpStruct1Internal1Internal1
{
char unknown1[0x34];
unsigned int unknownCount;
char * unknown2; //Size = ((unknownCount << 1) + unknownCount) << 2
};
struct unknownGameWorldSpStruct1Internal1Internal2
{
unknownGameWorldSpStruct1Internal1Internal1 * unknownStruct;
};
struct unknownGameWorldSpStruct1Internal1
{
const char * unknownString;
unsigned int unknownCount1;
unknownGameWorldSpStruct1Internal1Internal1 * unknownStructs1;
unsigned int unknownCount2;
unknownGameWorldSpStruct1Internal1Internal2 * unknownStructs2;
unsigned int unknownCount3;
unknownGameWorldSpStruct1Internal1Internal2 * unknownStructs3;
char unknown[0x10];
};
struct unknownGameWorldSpStruct1
{
unsigned int unknownCount;
unknownGameWorldSpStruct1Internal1 * unknownStructs;
};
struct unknownGameWorldStruct2Internal1
{
char * unknownString;
short unknown1;
short unknownCount1;
unsigned short * unknown2; //Count = unknownCount1
};
struct unknownGameWorldStruct2
{
unsigned int unknownCount1;
char * unknown1; //Size = ((unknownCount1 << 1) + unknownCount1) << 2
unsigned int unknownCount2;
unknownGameWorldStruct2Internal1 * unknownStructs;
char unknown2[0x6C];
};
struct GameWorldSp
{
const char *name;
PathData path;
unknownGameWorldSpStruct1 unknownStruct1;
unknownGameWorldStruct2 * unknownStruct2;
};Multiplayer
struct GameWorldMp
{
const char *name;
unknownGameWorldStruct2 * unknownStruct; //Refer to this from the singleplayer section
};