2496
|
1 #pragma once
|
|
2
|
|
3
|
|
4 /* 18 */
|
|
5 #pragma pack(push, 1)
|
|
6 class Sprite //28h
|
|
7 {
|
2524
|
8 public:
|
|
9 inline Sprite()
|
|
10 {
|
|
11 d3d11_srv = nullptr;
|
|
12 }
|
|
13 ~Sprite();
|
|
14
|
2496
|
15 void Release();
|
|
16
|
|
17 const char *pName; //0
|
|
18 int uPaletteID; //4
|
|
19 struct IDirectDrawSurface4 *pTextureSurface; //8
|
|
20 struct IDirect3DTexture2 *pTexture; //ch
|
|
21 int uAreaX; //10h
|
|
22 int uAreaY; //14h
|
|
23 int uBufferWidth; //18h
|
|
24 int uBufferHeight; //1ch
|
|
25 int uAreaWidth; //20h
|
|
26 int uAreaHeight; //24h
|
2524
|
27
|
|
28 struct ID3D11ShaderResourceView *d3d11_srv;
|
2496
|
29 };
|
|
30 #pragma pack(pop)
|
|
31
|
|
32
|
|
33 /* 42 */
|
|
34 #pragma pack(push, 1)
|
|
35 struct SpriteFrame_mm6
|
|
36 {
|
|
37 char pIconName[12];
|
|
38 char pTextureName[12]; //c
|
|
39 __int16 pHwSpriteIDs[8]; //18h
|
|
40 int scale; //28h
|
|
41 int uFlags; //2c
|
|
42 __int16 uGlowRadius; //30
|
|
43 __int16 uPaletteID; //32
|
|
44 __int16 uPaletteIndex;
|
|
45 __int16 uAnimTime;
|
|
46 //__int16 uAnimLength;
|
|
47 //__int16 _pad;
|
|
48 };
|
|
49
|
|
50 class SpriteFrame: public SpriteFrame_mm6
|
|
51 {
|
|
52 public:
|
|
53 __int16 uAnimLength;
|
|
54 __int16 _pad;
|
|
55 };
|
|
56 #pragma pack(pop)
|
|
57
|
|
58 /* 43 */
|
|
59 #pragma pack(push, 1)
|
|
60 struct SpriteFrameTable
|
|
61 {
|
|
62 //----- (0044D4BA) --------------------------------------------------------
|
|
63 inline SpriteFrameTable()
|
|
64 {
|
|
65 uNumSpriteFrames = 0;
|
|
66 pSpriteSFrames = nullptr;
|
|
67 pSpritePFrames = nullptr;
|
|
68 pSpriteEFrames = nullptr;
|
|
69 }
|
|
70 void ToFile();
|
|
71 void FromFile(void *data_mm6, void *data_mm7, void *data_mm8);
|
|
72 bool FromFileTxt(const char *Args);
|
|
73 void ReleaseSFrames();
|
|
74 void ResetSomeSpriteFlags();
|
|
75 void InitializeSprite(signed int uSpriteID);
|
|
76 signed int FastFindSprite(char *pSpriteName);
|
|
77 int BinarySearch(const char *pSpriteName);
|
|
78 SpriteFrame *GetFrame(unsigned int uSpriteID, unsigned int uTime);
|
|
79 SpriteFrame *GetFrameBy_x(unsigned int uSpriteID, signed int a3);
|
|
80
|
|
81 signed int uNumSpriteFrames;
|
|
82 unsigned int uNumEFrames;//field_4;
|
|
83 int unused_field; //field_8
|
|
84 SpriteFrame *pSpriteSFrames; //0c
|
|
85 SpriteFrame **pSpritePFrames; //10h
|
|
86 __int16 *pSpriteEFrames; //14h
|
|
87 };
|
|
88 #pragma pack(pop)
|
|
89
|
|
90
|
|
91
|
|
92
|
|
93 void __fastcall _46E26D_collide_against_sprites(signed int a1, signed int a2);
|
|
94
|
|
95
|
|
96 extern struct SpriteFrameTable *pSpriteFrameTable; |