CGObject_C
struct · objectlayer · 308 bytes
- Vtable
0x803640- Meaning
- Holds an object the server described: its storage, pool handle, type, GUID key, hold count and flags
- Confidence
- verified, proof one
- Finding
- objectlayer/classes#class-sizes-and-pools
Finding: Class sizes and pools in objectlayer: classes
Each type's allocation size is its members, its field array and a second per-field array, in
bytes base + 4·N; N comes from a small function per type. At startup the manager creates one
pool per type 1 to 7 with that size, the class name and a block count. An object comes from its
type's pool, which stores the pool handle at +0x10; the active player instead gets a heap block
of 26648 bytes.
| type | class | base | N | size | block |
|---|---|---|---|---|---|
| 0 | CGObject_C | 0x128 | 3 | 308 (no pool) | |
| 1 | CGItem_C | 0x408 | 35 | 1172 | 512 |
| 2 | CGContainer_C | 0x8c8 | 107 | 2676 | 32 |
| 3 | CGUnit_C | 0x1158 | 170 | 5120 | 64 |
| 4 | CGPlayer_C | 0x2508 | 465 | 11340 | 64 |
| 5 | CGGameObject_C | 0x2f0 | 8 | 784 | 64 |
| 6 | CGDynamicObject_C | 0x1e0 | 3 | 492 | 32 |
| 7 | CGCorpse_C | 0x350 | 6 | 872 | 32 |
The derivation is in the doc.
Fields 35
| offset | size | type | name | meaning | confidence | finding |
|---|---|---|---|---|---|---|
0x0000 | 4 | void * | __vfptr | Holds the type's vtable, stored last by each constructor | verified, proof one | objectlayer/classes#constructors-and-final-vtables |
0x0008 | 4 | uint32_t * | m_fields | Holds the field array, written by 0x613980 | verified, proof one | objectlayer/classes#field-storage |
0x000c | 4 | uint32_t * | m_watchCopy | Holds the copy array of the watched fields, written by 0x613980 | verified, proof one | objectlayer/classes#field-storage |
0x0010 | 4 | uint32_t | m_poolHandle | Holds the handle of the pool block the object came from, written by 0x466e00 | verified, proof one | objectlayer/manager#allocating-and-reusing |
0x0014 | 4 | uint32_t | m_typeId | Holds the type id 0 to 7, written by 0x613880 | verified, proof one | objectlayer/classes#type-id-and-mask |
0x001c | 8 | void *[2] | m_liveBucketLink | Links the object into its bucket of the manager's live table | verified, proof one | objectlayer/objectbase#constructor-and-members |
0x0024 | 8 | void *[2] | m_liveListLink | Links the object into the live table's iteration list | verified, proof one | objectlayer/objectbase#constructor-and-members |
0x0030 | 8 | uint64_t | m_guidKey | Holds the GUID the manager's tables key the object by, written on each table insert | verified, proof one | objectlayer/manager#finding-an-object |
0x0038 | 8 | void *[2] | m_objectListLink | Links the object into the manager's object list or a reuse list | verified, proof one | objectlayer/objectbase#constructor-and-members |
0x0040 | 8 | void *[2] | m_reactivatedLink | Links the object into the manager's reactivated list at +0xb0 | verified, proof one | objectlayer/objectbase#constructor-and-members |
0x0048 | 72 | uint32_t[18] | m_watcherLists | Holds the six field watcher lists of 12 bytes, one per base field | verified, proof one | objectlayer/objectbase#constructor-and-members |
0x0090 | 4 | float | m_scale | Holds the current scale, eased to the scale field over 2000 ms | verified, proof one | objectlayer/objectbase#the-frame-update |
0x0094 | 4 | float | m_scaleFactor | Holds a factor of the node scale, 1.0 | verified, proof one | objectlayer/objectbase#the-node-transform |
0x0098 | 4 | float | m_bodyScaleFactor | Holds the node scale factor used with the body model, 1.0 | verified, proof one | objectlayer/objectbase#the-node-transform |
0x009c | 4 | float | m_overrideScaleFactor | Holds the node scale factor used with the overriding model, 1.0 | verified, proof one | objectlayer/objectbase#the-node-transform |
0x00a0 | 4 | uint32_t | m_scaleEaseStart | Holds the time a scale ease started, 0 when none runs | verified, proof one | objectlayer/objectbase#the-scale-change |
0x00a4 | 4 | float | m_scaleEaseFrom | Holds the scale the ease started from | verified, proof one | objectlayer/objectbase#the-scale-change |
0x00ac | 4 | void * | m_castMissiles | Holds the head of the missiles waiting for release | verified, proof one | objectlayer/objectbase#destruction |
0x00b0 | 4 | void * | m_stuckMissiles | Holds the head of the missiles stuck in the object | verified, proof one | objectlayer/objectbase#the-frame-update |
0x00b4 | 4 | void * | m_effects | Holds the head of the object's spell effects | verified, proof one | objectlayer/objectbase#destruction |
0x00b8 | 4 | uint32_t | m_lightBits | Holds the highlight bits, bit 0 target and bit 1 mouse-over | verified, proof one | objectlayer/objectbase#highlight-light-bits |
0x00bc | 4 | float | m_height | Holds the body model's height, 1.0 before it loads | verified, proof one | objectlayer/objectbase#models-and-the-node |
0x00c0 | 24 | float[6] | m_bounds | Holds the body model's bounding box | verified, proof one | objectlayer/objectbase#models-and-the-node |
0x00d8 | 4 | void * | m_model | Holds the body model | verified, proof one | objectlayer/objectbase#models-and-the-node |
0x00dc | 4 | void * | m_overrideModel | Holds the overriding model, which every user takes first | verified, proof one | objectlayer/objectbase#models-and-the-node |
0x00e0 | 4 | void * | m_node | Holds the world node | verified, proof one | objectlayer/objectbase#models-and-the-node |
0x00e4 | 4 | uint32_t | m_objectFlags | Holds object flags; 0x614f50 sets and clears bit 0x10, release pending | verified, proof one | objectlayer/manager#releasing-an-object |
0x00e8 | 4 | uint32_t | m_holdCount | Holds the count of holds that keep the object from release, stepped by 0x614f10 | verified, proof one | objectlayer/manager#holding-an-object |
0x00ec | 4 | uint32_t | m_fadeStart | Holds the time the alpha fade started | verified, proof one | objectlayer/objectbase#the-alpha-fade |
0x00f0 | 4 | uint32_t | m_fadeMs | Holds the fade's length in milliseconds, 0 when none runs | verified, proof one | objectlayer/objectbase#the-alpha-fade |
0x00f4 | 4 | float | m_fadeAlpha | Holds the current fade alpha | verified, proof one | objectlayer/objectbase#the-alpha-fade |
0x00f8 | 4 | float | m_fadeFrom | Holds the alpha the fade started from | verified, proof one | objectlayer/objectbase#the-alpha-fade |
0x00fc | 4 | float | m_fadeTo | Holds the alpha the fade runs to | verified, proof one | objectlayer/objectbase#the-alpha-fade |
0x0100 | 4 | float | m_alpha | Holds the master alpha the fade is multiplied by, 1.0 | verified, proof one | objectlayer/objectbase#the-alpha-fade |
0x0104 | 12 | float[3] | m_upVector | Holds the smoothed ground normal the model is conformed to | verified, proof one | objectlayer/objectbase#ground-conform |