| 213 | } |
| 214 | |
| 215 | void InitializeObjects() |
| 216 | { |
| 217 | TENLog("Initializing objects...", LogLevel::Info); |
| 218 | |
| 219 | AllocTR4Objects(); |
| 220 | AllocTR5Objects(); |
| 221 | |
| 222 | ObjectInfo* obj; |
| 223 | |
| 224 | for (int i = 0; i < ID_NUMBER_OBJECTS; i++) |
| 225 | { |
| 226 | obj = &Objects[i]; |
| 227 | obj->Initialize = nullptr; |
| 228 | obj->collision = nullptr; |
| 229 | obj->control = nullptr; |
| 230 | obj->HitRoutine = DefaultItemHit; |
| 231 | obj->pivotLength = 0; |
| 232 | obj->radius = DEFAULT_RADIUS; |
| 233 | obj->shadowType = ShadowMode::None; |
| 234 | obj->HitPoints = NOT_TARGETABLE; |
| 235 | obj->hitEffect = HitEffect::None; |
| 236 | obj->explodableMeshbits = 0; |
| 237 | obj->intelligent = false; |
| 238 | obj->AlwaysActive = false; |
| 239 | obj->nonLot = false; |
| 240 | obj->Hidden = false; |
| 241 | obj->damageType = DamageMode::Any; |
| 242 | obj->LotType = LotType::Basic; |
| 243 | obj->meshSwapSlot = NO_VALUE; |
| 244 | obj->isPickup = false; |
| 245 | obj->isPuzzleHole = false; |
| 246 | } |
| 247 | |
| 248 | InitializeEffectsObjects(); |
| 249 | InitializeGenericObjects(); // Generic objects |
| 250 | InitializeTR5Objects(); // Standard TR5 objects (NOTE: lara need to be loaded first, so entity like doppelganger can use this animIndex !) |
| 251 | InitializeTR1Objects(); // Standard TR1 objects |
| 252 | InitializeTR2Objects(); // Standard TR2 objects |
| 253 | InitializeTR3Objects(); // Standard TR3 objects |
| 254 | InitializeTR4Objects(); // Standard TR4 objects |
| 255 | |
| 256 | // User defined objects |
| 257 | CustomObjects(); |
| 258 | |
| 259 | CurrentSequence = 0; |
| 260 | SequenceResults[0][1][2] = 0; |
| 261 | SequenceResults[0][2][1] = 1; |
| 262 | SequenceResults[1][0][2] = 2; |
| 263 | SequenceResults[1][2][0] = 3; |
| 264 | SequenceResults[2][0][1] = 4; |
| 265 | SequenceResults[2][1][0] = 5; |
| 266 | SequenceUsed[0] = 0; |
| 267 | SequenceUsed[1] = 0; |
| 268 | SequenceUsed[2] = 0; |
| 269 | SequenceUsed[3] = 0; |
| 270 | SequenceUsed[4] = 0; |
| 271 | SequenceUsed[5] = 0; |
| 272 | } |
no test coverage detected