============================================================================= */ typedef struct { const char *name; int offset; int bits; // 0 = float } netField_t; // using the stringizing operator to save typing... #define NETF(x) #x,offsetof(entityState_t, x) #if 0 // Removed by BTO (VV) const netField_t entityStateFields[] = { { NETF(eType), 8 }, { NETF(eFlags), 32 }, { NETF(pos.trType), 8 }, { NETF(pos.trTime), 32 }, { NETF(pos.trDuration), 32 }, { NETF(pos.trBase[0]), 0 }, { NETF(pos.trBase[1]), 0 }, { NETF(pos.trBase[2]), 0 }, { NETF(pos.trDelta[0]), 0 }, { NETF(pos.trDelta[1]), 0 }, { NETF(pos.trDelta[2]), 0 }, { NETF(apos.trType), 8 }, { NETF(apos.trTime), 32 }, { NETF(apos.trDuration), 32 },
}, #endif // end of list marker {NULL} }; int bg_numItems = ARRAY_LEN( bg_itemlist ) - 1; // entityState_t fields #define NETF(x) (size_t)&((entityState_t*)0)->x, 1 #define NETA(x) (size_t)&((entityState_t*)0)->x, ARRAY_LEN( ((entityState_t*)0)->x ) vmNetField_t bg_entityStateFields[] = { { NETF(pos.trTime), 32 }, { NETF(pos.trBase[0]), 0 }, { NETF(pos.trBase[1]), 0 }, { NETF(pos.trDelta[0]), 0 }, { NETF(pos.trDelta[1]), 0 }, { NETF(pos.trBase[2]), 0 }, { NETF(apos.trBase[1]), 0 }, { NETF(pos.trDelta[2]), 0 }, { NETF(apos.trBase[0]), 0 }, { NETF(event), 10 }, { NETF(angles2[1]), 0 }, { NETF(eType), 8 }, { NETF(torsoAnim), 8 }, { NETF(eventParm), 8 }, { NETF(legsAnim), 8 }, { NETF(groundEntityNum), GENTITYNUM_BITS },