|
@@ -18,12 +18,6 @@
|
18
|
18
|
*
|
19
|
19
|
*-- History ------------------------------------------------
|
20
|
20
|
*
|
21
|
|
- * 2003.05.13:
|
22
|
|
- * Mongoose - New API, maintance cost was becoming so high
|
23
|
|
- * it was needed to sort out methods in groups
|
24
|
|
- * like my newer source code -- of course some
|
25
|
|
- * methods were altered or removed ( clean up )
|
26
|
|
- *
|
27
|
21
|
* 2003.05.19:
|
28
|
22
|
* Mongoose - I'm now using Roy's documented TR5 structures, so
|
29
|
23
|
* I can fill in my blanks and share common structures
|
|
@@ -1388,7 +1382,7 @@ typedef struct tr5_cinematic_frame_s
|
1388
|
1382
|
|
1389
|
1383
|
class TombRaider
|
1390
|
1384
|
{
|
1391
|
|
- public:
|
|
1385
|
+public:
|
1392
|
1386
|
|
1393
|
1387
|
////////////////////////////////////////////////////////////
|
1394
|
1388
|
// Constructors
|
|
@@ -1421,37 +1415,10 @@ class TombRaider
|
1421
|
1415
|
////////////////////////////////////////////////////////////
|
1422
|
1416
|
|
1423
|
1417
|
int NumRooms();
|
1424
|
|
- /*------------------------------------------------------
|
1425
|
|
- * Pre :
|
1426
|
|
- * Post :
|
1427
|
|
- *
|
1428
|
|
- *-- History ------------------------------------------
|
1429
|
|
- *
|
1430
|
|
- * 2000.05.13:
|
1431
|
|
- * Mongoose - Created
|
1432
|
|
- ------------------------------------------------------*/
|
1433
|
1418
|
|
1434
|
1419
|
int NumMoveables();
|
1435
|
|
- /*------------------------------------------------------
|
1436
|
|
- * Pre :
|
1437
|
|
- * Post :
|
1438
|
|
- *
|
1439
|
|
- *-- History ------------------------------------------
|
1440
|
|
- *
|
1441
|
|
- * 2000.05.13:
|
1442
|
|
- * Mongoose - Created
|
1443
|
|
- ------------------------------------------------------*/
|
1444
|
1420
|
|
1445
|
1421
|
int NumTextures();
|
1446
|
|
- /*------------------------------------------------------
|
1447
|
|
- * Pre :
|
1448
|
|
- * Post :
|
1449
|
|
- *
|
1450
|
|
- *-- History ------------------------------------------
|
1451
|
|
- *
|
1452
|
|
- * 2000.05.13:
|
1453
|
|
- * Mongoose - Created
|
1454
|
|
- ------------------------------------------------------*/
|
1455
|
1422
|
|
1456
|
1423
|
int NumSpecialTextures();
|
1457
|
1424
|
/*------------------------------------------------------
|
|
@@ -1465,125 +1432,26 @@ class TombRaider
|
1465
|
1432
|
------------------------------------------------------*/
|
1466
|
1433
|
|
1467
|
1434
|
int NumAnimations();
|
1468
|
|
- /*------------------------------------------------------
|
1469
|
|
- * Pre :
|
1470
|
|
- * Post :
|
1471
|
|
- *
|
1472
|
|
- *-- History ------------------------------------------
|
1473
|
|
- *
|
1474
|
|
- * 2000.05.13:
|
1475
|
|
- * Mongoose - Created
|
1476
|
|
- ------------------------------------------------------*/
|
1477
|
1435
|
|
1478
|
1436
|
unsigned int NumFrames();
|
1479
|
|
- /*------------------------------------------------------
|
1480
|
|
- * Pre :
|
1481
|
|
- * Post :
|
1482
|
|
- *
|
1483
|
|
- *-- History ------------------------------------------
|
1484
|
|
- *
|
1485
|
|
- * 2000.05.13:
|
1486
|
|
- * Mongoose - Created
|
1487
|
|
- ------------------------------------------------------*/
|
1488
|
1437
|
|
1489
|
1438
|
int NumStaticMeshes();
|
1490
|
|
- /*------------------------------------------------------
|
1491
|
|
- * Pre :
|
1492
|
|
- * Post :
|
1493
|
|
- *
|
1494
|
|
- *-- History ------------------------------------------
|
1495
|
|
- *
|
1496
|
|
- * 2000.05.13:
|
1497
|
|
- * Mongoose - Created
|
1498
|
|
- ------------------------------------------------------*/
|
1499
|
1439
|
|
1500
|
1440
|
int NumSprites();
|
1501
|
|
- /*------------------------------------------------------
|
1502
|
|
- * Pre :
|
1503
|
|
- * Post :
|
1504
|
|
- *
|
1505
|
|
- *-- History ------------------------------------------
|
1506
|
|
- *
|
1507
|
|
- * 2000.05.13:
|
1508
|
|
- * Mongoose - Created
|
1509
|
|
- ------------------------------------------------------*/
|
1510
|
1441
|
|
1511
|
1442
|
int NumSpriteSequences();
|
1512
|
|
- /*------------------------------------------------------
|
1513
|
|
- * Pre :
|
1514
|
|
- * Post :
|
1515
|
|
- *
|
1516
|
|
- *-- History ------------------------------------------
|
1517
|
|
- *
|
1518
|
|
- * 2001.06.06:
|
1519
|
|
- * Mongoose - Created
|
1520
|
|
- ------------------------------------------------------*/
|
1521
|
1443
|
|
1522
|
1444
|
int NumItems();
|
1523
|
|
- /*------------------------------------------------------
|
1524
|
|
- * Pre :
|
1525
|
|
- * Post :
|
1526
|
|
- *
|
1527
|
|
- *-- History ------------------------------------------
|
1528
|
|
- *
|
1529
|
|
- * 2001.06.06:
|
1530
|
|
- * Mongoose - Created
|
1531
|
|
- ------------------------------------------------------*/
|
1532
|
1445
|
|
1533
|
1446
|
tr2_version_type Engine();
|
1534
|
|
- /*------------------------------------------------------
|
1535
|
|
- * Pre :
|
1536
|
|
- * Post :
|
1537
|
|
- *
|
1538
|
|
- *-- History ------------------------------------------
|
1539
|
|
- *
|
1540
|
|
- * 2000.05.13:
|
1541
|
|
- * Mongoose - Created
|
1542
|
|
- ------------------------------------------------------*/
|
1543
|
1447
|
|
1544
|
1448
|
unsigned short *Frame();
|
1545
|
|
- /*------------------------------------------------------
|
1546
|
|
- * Pre :
|
1547
|
|
- * Post :
|
1548
|
|
- *
|
1549
|
|
- *-- History ------------------------------------------
|
1550
|
|
- *
|
1551
|
|
- * 2000.05.13:
|
1552
|
|
- * Mongoose - Created
|
1553
|
|
- ------------------------------------------------------*/
|
1554
|
1449
|
|
1555
|
1450
|
tr2_animation_t *Animation();
|
1556
|
|
- /*------------------------------------------------------
|
1557
|
|
- * Pre :
|
1558
|
|
- * Post :
|
1559
|
|
- *
|
1560
|
|
- *-- History ------------------------------------------
|
1561
|
|
- *
|
1562
|
|
- * 2000.05.13:
|
1563
|
|
- * Mongoose - Created
|
1564
|
|
- ------------------------------------------------------*/
|
1565
|
1451
|
|
1566
|
1452
|
tr2_item_t *Item();
|
1567
|
|
- /*------------------------------------------------------
|
1568
|
|
- * Pre :
|
1569
|
|
- * Post :
|
1570
|
|
- *
|
1571
|
|
- *-- History ------------------------------------------
|
1572
|
|
- *
|
1573
|
|
- * 2000.05.13:
|
1574
|
|
- * Mongoose - Created
|
1575
|
|
- ------------------------------------------------------*/
|
1576
|
1453
|
|
1577
|
1454
|
tr2_object_texture_t *ObjectTextures();
|
1578
|
|
- /*------------------------------------------------------
|
1579
|
|
- * Pre :
|
1580
|
|
- * Post :
|
1581
|
|
- *
|
1582
|
|
- *-- History ------------------------------------------
|
1583
|
|
- *
|
1584
|
|
- * 2000.05.13:
|
1585
|
|
- * Mongoose - Created
|
1586
|
|
- ------------------------------------------------------*/
|
1587
|
1455
|
|
1588
|
1456
|
unsigned int getNumBoxes();
|
1589
|
1457
|
/*------------------------------------------------------
|
|
@@ -1597,26 +1465,8 @@ class TombRaider
|
1597
|
1465
|
------------------------------------------------------*/
|
1598
|
1466
|
|
1599
|
1467
|
tr2_box_t *Box();
|
1600
|
|
- /*------------------------------------------------------
|
1601
|
|
- * Pre :
|
1602
|
|
- * Post :
|
1603
|
|
- *
|
1604
|
|
- *-- History ------------------------------------------
|
1605
|
|
- *
|
1606
|
|
- * 2000.05.13:
|
1607
|
|
- * Mongoose - Created
|
1608
|
|
- ------------------------------------------------------*/
|
1609
|
1468
|
|
1610
|
1469
|
tr2_mesh_t *Mesh();
|
1611
|
|
- /*------------------------------------------------------
|
1612
|
|
- * Pre :
|
1613
|
|
- * Post :
|
1614
|
|
- *
|
1615
|
|
- *-- History ------------------------------------------
|
1616
|
|
- *
|
1617
|
|
- * 2000.05.13:
|
1618
|
|
- * Mongoose - Created
|
1619
|
|
- ------------------------------------------------------*/
|
1620
|
1470
|
|
1621
|
1471
|
int getNumAnimsForMoveable(int moveable_index);
|
1622
|
1472
|
/*------------------------------------------------------
|
|
@@ -1633,37 +1483,10 @@ class TombRaider
|
1633
|
1483
|
------------------------------------------------------*/
|
1634
|
1484
|
|
1635
|
1485
|
tr2_staticmesh_t *StaticMesh();
|
1636
|
|
- /*------------------------------------------------------
|
1637
|
|
- * Pre :
|
1638
|
|
- * Post :
|
1639
|
|
- *
|
1640
|
|
- *-- History ------------------------------------------
|
1641
|
|
- *
|
1642
|
|
- * 2000.05.13:
|
1643
|
|
- * Mongoose - Created
|
1644
|
|
- ------------------------------------------------------*/
|
1645
|
1486
|
|
1646
|
1487
|
tr2_moveable_t *Moveable();
|
1647
|
|
- /*------------------------------------------------------
|
1648
|
|
- * Pre :
|
1649
|
|
- * Post :
|
1650
|
|
- *
|
1651
|
|
- *-- History ------------------------------------------
|
1652
|
|
- *
|
1653
|
|
- * 2000.05.13:
|
1654
|
|
- * Mongoose - Created
|
1655
|
|
- ------------------------------------------------------*/
|
1656
|
1488
|
|
1657
|
1489
|
tr2_meshtree_t *MeshTree();
|
1658
|
|
- /*------------------------------------------------------
|
1659
|
|
- * Pre :
|
1660
|
|
- * Post :
|
1661
|
|
- *
|
1662
|
|
- *-- History ------------------------------------------
|
1663
|
|
- *
|
1664
|
|
- * 2000.05.13:
|
1665
|
|
- * Mongoose - Created
|
1666
|
|
- ------------------------------------------------------*/
|
1667
|
1490
|
|
1668
|
1491
|
tr2_sprite_texture_t *Sprite();
|
1669
|
1492
|
/*------------------------------------------------------
|
|
@@ -1677,15 +1500,6 @@ class TombRaider
|
1677
|
1500
|
------------------------------------------------------*/
|
1678
|
1501
|
|
1679
|
1502
|
tr2_sprite_sequence_t *SpriteSequence();
|
1680
|
|
- /*------------------------------------------------------
|
1681
|
|
- * Pre :
|
1682
|
|
- * Post :
|
1683
|
|
- *
|
1684
|
|
- *-- History ------------------------------------------
|
1685
|
|
- *
|
1686
|
|
- * 2001.06.06:
|
1687
|
|
- * Mongoose - Created
|
1688
|
|
- ------------------------------------------------------*/
|
1689
|
1503
|
|
1690
|
1504
|
unsigned char *SpecialTexTile(int texture);
|
1691
|
1505
|
/*------------------------------------------------------
|
|
@@ -1713,37 +1527,10 @@ class TombRaider
|
1713
|
1527
|
------------------------------------------------------*/
|
1714
|
1528
|
|
1715
|
1529
|
unsigned int *Palette16();
|
1716
|
|
- /*------------------------------------------------------
|
1717
|
|
- * Pre :
|
1718
|
|
- * Post :
|
1719
|
|
- *
|
1720
|
|
- *-- History ------------------------------------------
|
1721
|
|
- *
|
1722
|
|
- * 2000.05.13:
|
1723
|
|
- * Mongoose - Created
|
1724
|
|
- ------------------------------------------------------*/
|
1725
|
1530
|
|
1726
|
1531
|
unsigned char *Palette8();
|
1727
|
|
- /*------------------------------------------------------
|
1728
|
|
- * Pre :
|
1729
|
|
- * Post :
|
1730
|
|
- *
|
1731
|
|
- *-- History ------------------------------------------
|
1732
|
|
- *
|
1733
|
|
- * 2000.05.13:
|
1734
|
|
- * Mongoose - Created
|
1735
|
|
- ------------------------------------------------------*/
|
1736
|
1532
|
|
1737
|
1533
|
tr2_room_t *Room();
|
1738
|
|
- /*------------------------------------------------------
|
1739
|
|
- * Pre :
|
1740
|
|
- * Post :
|
1741
|
|
- *
|
1742
|
|
- *-- History ------------------------------------------
|
1743
|
|
- *
|
1744
|
|
- * 2000.05.13:
|
1745
|
|
- * Mongoose - Created
|
1746
|
|
- ------------------------------------------------------*/
|
1747
|
1534
|
|
1748
|
1535
|
int checkMime(char *filename);
|
1749
|
1536
|
/*------------------------------------------------------
|
|
@@ -1836,29 +1623,8 @@ class TombRaider
|
1836
|
1623
|
------------------------------------------------------*/
|
1837
|
1624
|
|
1838
|
1625
|
void getColor(int index, float color[4]);
|
1839
|
|
- /*------------------------------------------------------
|
1840
|
|
- * Pre :
|
1841
|
|
- * Post :
|
1842
|
|
- *
|
1843
|
|
- *-- History ------------------------------------------
|
1844
|
|
- *
|
1845
|
|
- * 2000.05.30:
|
1846
|
|
- * Mongoose - Created
|
1847
|
|
- ------------------------------------------------------*/
|
1848
|
1626
|
|
1849
|
1627
|
tr2_version_type getEngine();
|
1850
|
|
- /*------------------------------------------------------
|
1851
|
|
- * Pre :
|
1852
|
|
- * Post :
|
1853
|
|
- *
|
1854
|
|
- *-- History ------------------------------------------
|
1855
|
|
- *
|
1856
|
|
- * 2003.05.24:
|
1857
|
|
- * Mongoose - Obsoloetes Engine() method, name change
|
1858
|
|
- *
|
1859
|
|
- * 2000.05.13:
|
1860
|
|
- * Mongoose - Created
|
1861
|
|
- ------------------------------------------------------*/
|
1862
|
1628
|
|
1863
|
1629
|
void getMeshCollisionInfo(unsigned int meshIndex,
|
1864
|
1630
|
float center[3], float *radius);
|
|
@@ -2027,15 +1793,6 @@ class TombRaider
|
2027
|
1793
|
void getRoomInfo(unsigned int index,
|
2028
|
1794
|
unsigned int *flags, float pos[3],
|
2029
|
1795
|
float bboxMin[3], float bboxMax[3]);
|
2030
|
|
- /*------------------------------------------------------
|
2031
|
|
- * Pre :
|
2032
|
|
- * Post :
|
2033
|
|
- *
|
2034
|
|
- *-- History ------------------------------------------
|
2035
|
|
- *
|
2036
|
|
- * 2003.05.24:
|
2037
|
|
- * Mongoose - Created
|
2038
|
|
- ------------------------------------------------------*/
|
2039
|
1796
|
|
2040
|
1797
|
int getRoomLight(unsigned int roomIndex, unsigned int index,
|
2041
|
1798
|
float pos[4], float color[4], float dir[3],
|
|
@@ -2165,15 +1922,6 @@ class TombRaider
|
2165
|
1922
|
void getRoomSprite(unsigned int roomIndex, unsigned int index,
|
2166
|
1923
|
float scale, int *texture,
|
2167
|
1924
|
float *pos, float *vertices, float *texcoords);
|
2168
|
|
- /*------------------------------------------------------
|
2169
|
|
- * Pre :
|
2170
|
|
- * Post :
|
2171
|
|
- *
|
2172
|
|
- *-- History ------------------------------------------
|
2173
|
|
- *
|
2174
|
|
- * 2003.05.19:
|
2175
|
|
- * Mongoose - Created
|
2176
|
|
- ------------------------------------------------------*/
|
2177
|
1925
|
|
2178
|
1926
|
unsigned int getRoomSpriteCount(unsigned int roomIndex);
|
2179
|
1927
|
/*------------------------------------------------------
|
|
@@ -2372,29 +2120,8 @@ class TombRaider
|
2372
|
2120
|
------------------------------------------------------*/
|
2373
|
2121
|
|
2374
|
2122
|
void reset();
|
2375
|
|
- /*------------------------------------------------------
|
2376
|
|
- * Pre :
|
2377
|
|
- * Post :
|
2378
|
|
- *
|
2379
|
|
- *-- History ------------------------------------------
|
2380
|
|
- *
|
2381
|
|
- * 2003.05.13:
|
2382
|
|
- * Mongoose - New API, was Clear()
|
2383
|
|
- *
|
2384
|
|
- * 2000.05.13:
|
2385
|
|
- * Mongoose - Created
|
2386
|
|
- ------------------------------------------------------*/
|
2387
|
2123
|
|
2388
|
2124
|
void setDebug(bool toggle);
|
2389
|
|
- /*------------------------------------------------------
|
2390
|
|
- * Pre :
|
2391
|
|
- * Post :
|
2392
|
|
- *
|
2393
|
|
- *-- History ------------------------------------------
|
2394
|
|
- *
|
2395
|
|
- * 2000.05.13:
|
2396
|
|
- * Mongoose - Created
|
2397
|
|
- ------------------------------------------------------*/
|
2398
|
2125
|
|
2399
|
2126
|
void setRoomVertexLightingFactor(float f);
|
2400
|
2127
|
/*------------------------------------------------------
|
|
@@ -2420,7 +2147,7 @@ class TombRaider
|
2420
|
2147
|
------------------------------------------------------*/
|
2421
|
2148
|
|
2422
|
2149
|
|
2423
|
|
- private:
|
|
2150
|
+private:
|
2424
|
2151
|
|
2425
|
2152
|
////////////////////////////////////////////////////////////
|
2426
|
2153
|
// Private Accessors
|
|
@@ -2429,26 +2156,8 @@ class TombRaider
|
2429
|
2156
|
void extractMeshes(unsigned char *mesh_data,
|
2430
|
2157
|
unsigned int num_mesh_pointers,
|
2431
|
2158
|
unsigned int *mesh_pointers);
|
2432
|
|
- /*------------------------------------------------------
|
2433
|
|
- * Pre :
|
2434
|
|
- * Post :
|
2435
|
|
- *
|
2436
|
|
- *-- History ------------------------------------------
|
2437
|
|
- *
|
2438
|
|
- * 2000.05.13:
|
2439
|
|
- * Mongoose - Created
|
2440
|
|
- ------------------------------------------------------*/
|
2441
|
2159
|
|
2442
|
2160
|
int Fread(void *buffer, size_t size, size_t count, FILE *f);
|
2443
|
|
- /*------------------------------------------------------
|
2444
|
|
- * Pre :
|
2445
|
|
- * Post :
|
2446
|
|
- *
|
2447
|
|
- *-- History ------------------------------------------
|
2448
|
|
- *
|
2449
|
|
- * 2000.05.13:
|
2450
|
|
- * Mongoose - Created
|
2451
|
|
- ------------------------------------------------------*/
|
2452
|
2161
|
|
2453
|
2162
|
void getRiffData(unsigned int *bytes, unsigned char **data);
|
2454
|
2163
|
/*------------------------------------------------------
|
|
@@ -2530,32 +2239,8 @@ class TombRaider
|
2530
|
2239
|
------------------------------------------------------*/
|
2531
|
2240
|
|
2532
|
2241
|
void print(const char *methodName, const char *s, ...);
|
2533
|
|
- /*------------------------------------------------------
|
2534
|
|
- * Pre :
|
2535
|
|
- * Post :
|
2536
|
|
- *
|
2537
|
|
- *-- History ------------------------------------------
|
2538
|
|
- *
|
2539
|
|
- * 2003.05.13:
|
2540
|
|
- * Mongoose - New API clean up
|
2541
|
|
- *
|
2542
|
|
- * 2000.05.13:
|
2543
|
|
- * Mongoose - Created
|
2544
|
|
- ------------------------------------------------------*/
|
2545
|
2242
|
|
2546
|
2243
|
void printDebug(const char *methodName, const char *s, ...);
|
2547
|
|
- /*------------------------------------------------------
|
2548
|
|
- * Pre :
|
2549
|
|
- * Post :
|
2550
|
|
- *
|
2551
|
|
- *-- History ------------------------------------------
|
2552
|
|
- *
|
2553
|
|
- * 2003.05.13:
|
2554
|
|
- * Mongoose - New API clean up
|
2555
|
|
- *
|
2556
|
|
- * 2000.05.13:
|
2557
|
|
- * Mongoose - Created
|
2558
|
|
- ------------------------------------------------------*/
|
2559
|
2244
|
|
2560
|
2245
|
|
2561
|
2246
|
////////////////////////////////////////////////////////////
|
|
@@ -2564,80 +2249,44 @@ class TombRaider
|
2564
|
2249
|
|
2565
|
2250
|
|
2566
|
2251
|
bool mReset; /* Guard multiple calls to reset() */
|
2567
|
|
-
|
2568
|
2252
|
bool mDebug; /* Debug output toggle */
|
2569
|
|
-
|
2570
|
2253
|
unsigned int mPakVersion; /* TombRaider pak file header version */
|
2571
|
|
-
|
2572
|
2254
|
tr2_version_type mEngineVersion; /* TombRaider engine version */
|
2573
|
|
-
|
2574
|
2255
|
tr2_colour_t _palette8[256]; /* 8-bit palette */
|
2575
|
|
-
|
2576
|
2256
|
unsigned int _palette16[256]; /* 16-bit palette */
|
2577
|
|
-
|
2578
|
2257
|
unsigned int _num_textiles; /* Total number of texture tiles */
|
2579
|
|
-
|
2580
|
2258
|
unsigned short _num_room_textures; /* Num textures only for room use? */
|
2581
|
|
-
|
2582
|
2259
|
unsigned short _num_misc_textures; /* Num of textures for misc use? */
|
2583
|
|
-
|
2584
|
2260
|
unsigned short _num_bump_map_textures; /* Num of textures that are
|
2585
|
2261
|
bump map, texture pairs */
|
2586
|
|
-
|
2587
|
2262
|
tr2_textile8_t *_textile8; /* 8-bit (palettised) textiles */
|
2588
|
|
-
|
2589
|
2263
|
tr2_textile16_t *_textile16; /* 16-bit (ARGB) textiles */
|
2590
|
|
-
|
2591
|
2264
|
tr2_textile32_t *_textile32; /* 32-bit (BGRA) textiles */
|
2592
|
|
-
|
2593
|
2265
|
unsigned int _num_tex_special; /* Special textures and bump maps count */
|
2594
|
|
-
|
2595
|
2266
|
unsigned char *_tex_special; /* Special textures and bump maps */
|
2596
|
|
-
|
2597
|
2267
|
unsigned int _unknown_t; /* 32-bit unknown
|
2598
|
2268
|
(always 0 in real TR2 levels) */
|
2599
|
|
-
|
2600
|
2269
|
unsigned short _num_rooms; /* Number of rooms in this level */
|
2601
|
|
-
|
2602
|
2270
|
tr2_room_t *_rooms; /* List of rooms (TR1,TR2,TR3,TR4) */
|
2603
|
|
-
|
2604
|
2271
|
tr5_room_t *mRoomsTR5; /* Rooms ( TR5 / TRC ) Only */
|
2605
|
|
-
|
2606
|
2272
|
unsigned int _num_floor_data; /* Num of words of floor data
|
2607
|
2273
|
this level */
|
2608
|
|
-
|
2609
|
2274
|
unsigned short *_floor_data; /* Floor data */
|
2610
|
|
-
|
2611
|
2275
|
int mMeshCount; /* Number of meshes this level */
|
2612
|
|
-
|
2613
|
2276
|
tr2_mesh_t *mMeshes; /* list of meshes */
|
2614
|
|
-
|
2615
|
2277
|
unsigned int _num_animations; /* number of animations this level */
|
2616
|
|
-
|
2617
|
2278
|
tr2_animation_t *_animations; /* list of animations */
|
2618
|
|
-
|
2619
|
2279
|
unsigned int _num_state_changes; /* number of structures(?) this level */
|
2620
|
|
-
|
2621
|
2280
|
tr2_state_change_t *_state_changes; /* list of structures */
|
2622
|
|
-
|
2623
|
2281
|
unsigned int _num_anim_dispatches; /* number of ranges(?) this level */
|
2624
|
|
-
|
2625
|
|
- tr2_anim_dispatch_t *_anim_dispatches; /* list of ranges */
|
2626
|
|
-
|
|
2282
|
+ tr2_anim_dispatch_t *_anim_dispatches; /* list of ranges */
|
2627
|
2283
|
unsigned int _num_anim_commands; /* number of Bone1s this level */
|
2628
|
|
-
|
2629
|
2284
|
tr2_anim_command_t *_anim_commands; /* list of Bone1s */
|
2630
|
|
-
|
2631
|
2285
|
unsigned int _num_mesh_trees; /* number of Bone2s this level */
|
2632
|
|
-
|
2633
|
2286
|
tr2_meshtree_t *_mesh_trees; /* list of Bone2s */
|
2634
|
|
-
|
2635
|
2287
|
unsigned int _num_frames; /* num of words of frame data this level */
|
2636
|
|
-
|
2637
|
2288
|
unsigned short *_frames; /* frame data */
|
2638
|
|
-
|
2639
|
2289
|
unsigned int _num_moveables; /* number of moveables this level */
|
2640
|
|
-
|
2641
|
2290
|
tr2_moveable_t *_moveables; /* list of moveables */
|
2642
|
2291
|
|
2643
|
2292
|
u_int32_t numMoveablesTR5;
|
|
@@ -2656,112 +2305,70 @@ class TombRaider
|
2656
|
2305
|
tr5_flyby_camera_t *flyByCamerasTR5;
|
2657
|
2306
|
|
2658
|
2307
|
unsigned int _num_static_meshes; /* number of static meshes this level */
|
2659
|
|
-
|
2660
|
2308
|
tr2_staticmesh_t *_static_meshes; /* static meshes */
|
2661
|
|
-
|
2662
|
2309
|
unsigned int _num_object_textures; /* number of object textures this level */
|
2663
|
|
-
|
2664
|
2310
|
tr2_object_texture_t *_object_textures; /* list of object textures */
|
2665
|
2311
|
|
2666
|
2312
|
|
2667
|
2313
|
unsigned int _num_sprite_textures; /* num of sprite textures this level */
|
2668
|
|
-
|
2669
|
2314
|
tr2_sprite_texture_t *_sprite_textures; /* list of sprite textures */
|
2670
|
|
-
|
2671
|
2315
|
unsigned int _num_sprite_sequences; /* num of sprite sequences this level */
|
2672
|
|
-
|
2673
|
2316
|
tr2_sprite_sequence_t *_sprite_sequences; /* sprite sequence data */
|
2674
|
|
-
|
2675
|
2317
|
int _num_cameras; /* Number of Cameras */
|
2676
|
|
-
|
2677
|
2318
|
tr2_camera_t *_cameras; /* cameras */
|
2678
|
|
-
|
2679
|
2319
|
int _num_sound_sources; /* Number of Sounds */
|
2680
|
|
-
|
2681
|
2320
|
tr2_sound_source_t *_sound_sources; /* sounds */
|
2682
|
|
-
|
2683
|
2321
|
int _num_boxes; /* Number of Boxes */
|
2684
|
2322
|
|
2685
|
2323
|
|
2686
|
|
- tr2_box_t *_boxes; /* boxes - looks like
|
2687
|
|
- struct { unsigned short value[4]; }
|
2688
|
|
- - value[0..2] might be a vector;
|
2689
|
|
- value[3] seems to be index into
|
2690
|
|
- Overlaps[] */
|
2691
|
|
-
|
|
2324
|
+ tr2_box_t *_boxes; /* boxes - looks like
|
|
2325
|
+ struct { unsigned short value[4]; }
|
|
2326
|
+ - value[0..2] might be a vector;
|
|
2327
|
+ value[3] seems to be index into
|
|
2328
|
+ Overlaps[] */
|
2692
|
2329
|
int _num_overlaps; /* Number of Overlaps */
|
2693
|
|
-
|
2694
|
2330
|
short *_overlaps; /* Overlaps -
|
2695
|
|
- looks like ushort; 0x8000 is flag
|
2696
|
|
- of some sort appears to be an
|
2697
|
|
- offset into Boxes[] and/or
|
2698
|
|
- Boxes2[] */
|
2699
|
|
-
|
|
2331
|
+ looks like ushort; 0x8000 is flag
|
|
2332
|
+ of some sort appears to be an
|
|
2333
|
+ offset into Boxes[] and/or
|
|
2334
|
+ Boxes2[] */
|
2700
|
2335
|
short *_zones; /* Boxes2 */
|
2701
|
|
-
|
2702
|
2336
|
int _num_animated_textures; /* Number of AnimTextures */
|
2703
|
|
-
|
2704
|
2337
|
short *_animated_textures; /* Animtextures */
|
2705
|
|
-
|
2706
|
2338
|
int _num_items; /* Number of Items */
|
2707
|
|
-
|
2708
|
2339
|
tr2_item_t *_items; /* Items */
|
2709
|
|
-
|
2710
|
2340
|
unsigned char *_light_map; /* Colour-light maps */
|
2711
|
|
-
|
2712
|
2341
|
unsigned int _num_cinematic_frames; /* Number of cut-scene frames */
|
2713
|
|
-
|
2714
|
2342
|
tr2_cinematic_frame_t *_cinematic_frames; /* Cut-scene frames */
|
2715
|
|
-
|
2716
|
2343
|
short _num_demo_data; /* Number of Demo Data */
|
2717
|
|
-
|
2718
|
2344
|
unsigned char *_demo_data; /* Demo data */
|
2719
|
|
-
|
2720
|
2345
|
float mRoomVertexLightingFactor;
|
2721
|
|
-
|
2722
|
2346
|
float mTexelScale;
|
2723
|
2347
|
|
2724
|
2348
|
|
2725
|
2349
|
// Sound data
|
2726
|
|
-
|
2727
|
2350
|
short *mSoundMap; /* Sound map */
|
2728
|
|
-
|
2729
|
2351
|
int mNumSoundDetails; /* Number of SampleModifiers */
|
2730
|
|
-
|
2731
|
2352
|
tr2_sound_details_t *mSoundDetails; /* Sample modifiers */
|
2732
|
|
-
|
2733
|
2353
|
int mNumSampleIndices; /* Number of Sample Indices */
|
2734
|
|
-
|
2735
|
2354
|
int *mSampleIndices; /* Sample indices */
|
2736
|
|
-
|
2737
|
2355
|
unsigned int *mSampleIndicesTR5;
|
2738
|
|
-
|
2739
|
2356
|
bool mRiffAlternateLoaded; /* Is a TR2,TR3 SFX loaded? */
|
2740
|
|
-
|
2741
|
2357
|
unsigned int *mRiffAlternateOffsets; /* After parsing this will
|
2742
|
|
- hold byte offsets for TR2,TR3
|
2743
|
|
- RIFFs in the buffered SFX */
|
2744
|
|
-
|
|
2358
|
+ hold byte offsets for TR2,TR3
|
|
2359
|
+ RIFFs in the buffered SFX */
|
2745
|
2360
|
int mRiffDataSz; /* Byte size of a loaded SFX */
|
2746
|
|
-
|
2747
|
2361
|
unsigned char *mRiffData; /* SFX RIFF data in chunks */
|
2748
|
|
-
|
2749
|
2362
|
unsigned int mNumTR4Samples;
|
2750
|
|
-
|
2751
|
2363
|
unsigned char **mTR4Samples;
|
2752
|
|
-
|
2753
|
2364
|
unsigned int *mTR4SamplesSz;
|
2754
|
2365
|
|
2755
|
2366
|
|
2756
|
2367
|
// For packed Fread emu/wrapper
|
2757
|
|
-
|
2758
|
2368
|
unsigned char *mCompressedLevelData; /* Buffer used to emulate fread
|
2759
|
|
- with uncompressed libz data */
|
2760
|
|
-
|
|
2369
|
+ with uncompressed libz data */
|
2761
|
2370
|
unsigned int mCompressedLevelDataOffset; /* Offset into buffer */
|
2762
|
|
-
|
2763
|
2371
|
unsigned int mCompressedLevelSize; /* Size of buffer */
|
2764
|
|
-
|
2765
|
2372
|
tr_fread_mode_t mFreadMode; /* Fread mode file|buffer */
|
2766
|
2373
|
};
|
2767
|
2374
|
|