annotate IconFrameTable.cpp @ 1429:c7489dd19f88

BuildingType_Tavern and CastSpellInfo_PushCastSpellInfo fix
author Ritor1
date Thu, 01 Aug 2013 17:51:16 +0600
parents c423f946dc99
children 7ef4b64f6329
rev   line source
1295
86a83e12d795 moving files
Ritor1
parents:
diff changeset
1 #include "IconFrameTable.h"
86a83e12d795 moving files
Ritor1
parents:
diff changeset
2 #include "LOD.h"
86a83e12d795 moving files
Ritor1
parents:
diff changeset
3 #include "mm7_data.h"
86a83e12d795 moving files
Ritor1
parents:
diff changeset
4 #include "Allocator.h"
86a83e12d795 moving files
Ritor1
parents:
diff changeset
5 #include "FrameTableInc.h"
86a83e12d795 moving files
Ritor1
parents:
diff changeset
6
86a83e12d795 moving files
Ritor1
parents:
diff changeset
7 //----- (00494F3A) --------------------------------------------------------
86a83e12d795 moving files
Ritor1
parents:
diff changeset
8 unsigned int IconFrameTable::FindIcon(const char *pIconName)
86a83e12d795 moving files
Ritor1
parents:
diff changeset
9 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
10 IconFrameTable *v2; // esi@1
86a83e12d795 moving files
Ritor1
parents:
diff changeset
11 int v3; // ebx@1
86a83e12d795 moving files
Ritor1
parents:
diff changeset
12 unsigned int uID; // edi@1
86a83e12d795 moving files
Ritor1
parents:
diff changeset
13 unsigned int result; // eax@4
86a83e12d795 moving files
Ritor1
parents:
diff changeset
14
86a83e12d795 moving files
Ritor1
parents:
diff changeset
15 v2 = this;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
16 v3 = 0;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
17 uID = 0;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
18 if ( (signed int)this->uNumIcons <= 0 )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
19 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
20 LABEL_4:
86a83e12d795 moving files
Ritor1
parents:
diff changeset
21 result = 0;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
22 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
23 else
86a83e12d795 moving files
Ritor1
parents:
diff changeset
24 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
25 while ( _stricmp(pIconName, v2->pIcons[v3].pAnimationName) )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
26 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
27 ++uID;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
28 ++v3;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
29 if ( (signed int)uID >= (signed int)v2->uNumIcons )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
30 goto LABEL_4;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
31 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
32 result = uID;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
33 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
34 return result;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
35 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
36
86a83e12d795 moving files
Ritor1
parents:
diff changeset
37 //----- (00494F70) --------------------------------------------------------
86a83e12d795 moving files
Ritor1
parents:
diff changeset
38 IconFrame *IconFrameTable::GetFrame(unsigned int uIconID, unsigned int uFrameID)
86a83e12d795 moving files
Ritor1
parents:
diff changeset
39 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
40 IconFrame *v3; // edi@1
86a83e12d795 moving files
Ritor1
parents:
diff changeset
41 IconFrame *v4; // ecx@1
86a83e12d795 moving files
Ritor1
parents:
diff changeset
42 __int16 v5; // dx@2
86a83e12d795 moving files
Ritor1
parents:
diff changeset
43 int v6; // edx@3
86a83e12d795 moving files
Ritor1
parents:
diff changeset
44 unsigned int v7; // eax@3
86a83e12d795 moving files
Ritor1
parents:
diff changeset
45 char *i; // ecx@3
86a83e12d795 moving files
Ritor1
parents:
diff changeset
46 int v9; // esi@5
86a83e12d795 moving files
Ritor1
parents:
diff changeset
47 IconFrame *result; // eax@6
86a83e12d795 moving files
Ritor1
parents:
diff changeset
48
86a83e12d795 moving files
Ritor1
parents:
diff changeset
49 v3 = this->pIcons;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
50 v4 = &v3[uIconID];
86a83e12d795 moving files
Ritor1
parents:
diff changeset
51 if ( v4->uFlags & 1 && (v5 = v4->uAnimLength) != 0 )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
52 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
53 v6 = ((signed int)uFrameID >> 3) % (unsigned __int16)v5;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
54 v7 = uIconID;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
55 for ( i = (char *)&v4->uAnimTime; ; i += 32 )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
56 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
57 v9 = *(short *)i;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
58 if ( v6 <= v9 )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
59 break;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
60 v6 -= v9;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
61 ++v7;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
62 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
63 result = &v3[v7];
86a83e12d795 moving files
Ritor1
parents:
diff changeset
64 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
65 else
86a83e12d795 moving files
Ritor1
parents:
diff changeset
66 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
67 result = &v3[uIconID];
86a83e12d795 moving files
Ritor1
parents:
diff changeset
68 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
69 return result;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
70 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
71
86a83e12d795 moving files
Ritor1
parents:
diff changeset
72 //----- (00494FBF) --------------------------------------------------------
86a83e12d795 moving files
Ritor1
parents:
diff changeset
73 void IconFrameTable::InitializeAnimation(unsigned int uIconID)
86a83e12d795 moving files
Ritor1
parents:
diff changeset
74 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
75 IconFrameTable *v2; // esi@1
86a83e12d795 moving files
Ritor1
parents:
diff changeset
76 unsigned int v3; // edi@3
86a83e12d795 moving files
Ritor1
parents:
diff changeset
77 const char *i; // eax@3
86a83e12d795 moving files
Ritor1
parents:
diff changeset
78 IconFrame *v5; // eax@5
86a83e12d795 moving files
Ritor1
parents:
diff changeset
79
86a83e12d795 moving files
Ritor1
parents:
diff changeset
80 v2 = this;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
81 if ( (signed int)uIconID <= (signed int)this->uNumIcons && (uIconID & 0x80000000u) == 0 )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
82 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
83 v3 = uIconID;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
84 for ( i = this->pIcons[uIconID].pTextureName; ; i = v5[v3].pTextureName )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
85 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
86 v2->pIcons[v3].uTextureID = pIcons_LOD->LoadTexture(i, TEXTURE_16BIT_PALETTE);
86a83e12d795 moving files
Ritor1
parents:
diff changeset
87 v5 = v2->pIcons;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
88 if ( !(v5[v3].uFlags & 1) )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
89 break;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
90 ++v3;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
91 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
92 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
93 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
94
86a83e12d795 moving files
Ritor1
parents:
diff changeset
95 //----- (0049500A) --------------------------------------------------------
86a83e12d795 moving files
Ritor1
parents:
diff changeset
96 void IconFrameTable::ToFile()
86a83e12d795 moving files
Ritor1
parents:
diff changeset
97 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
98 IconFrameTable *v1; // esi@1
86a83e12d795 moving files
Ritor1
parents:
diff changeset
99 FILE *v2; // eax@1
86a83e12d795 moving files
Ritor1
parents:
diff changeset
100 FILE *v3; // edi@1
86a83e12d795 moving files
Ritor1
parents:
diff changeset
101
86a83e12d795 moving files
Ritor1
parents:
diff changeset
102 auto Str = this;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
103
86a83e12d795 moving files
Ritor1
parents:
diff changeset
104 v1 = Str;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
105 v2 = fopen("data\\dift.bin", "wb");
86a83e12d795 moving files
Ritor1
parents:
diff changeset
106 v3 = v2;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
107 if ( !v2 )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
108 Abortf("Unable to save dift.bin!");
86a83e12d795 moving files
Ritor1
parents:
diff changeset
109 fwrite(v1, 4u, 1u, v2);
86a83e12d795 moving files
Ritor1
parents:
diff changeset
110 fwrite(v1->pIcons, 0x20u, v1->uNumIcons, v3);
86a83e12d795 moving files
Ritor1
parents:
diff changeset
111 fclose(v3);
86a83e12d795 moving files
Ritor1
parents:
diff changeset
112 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
113
86a83e12d795 moving files
Ritor1
parents:
diff changeset
114 //----- (00495056) --------------------------------------------------------
86a83e12d795 moving files
Ritor1
parents:
diff changeset
115 void IconFrameTable::FromFile(void *pSerialized)
86a83e12d795 moving files
Ritor1
parents:
diff changeset
116 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
117 uNumIcons = *(int *)pSerialized;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
118 pIcons = (IconFrame *)pAllocator->AllocNamedChunk(pIcons, 32 * uNumIcons, "I Frames");
86a83e12d795 moving files
Ritor1
parents:
diff changeset
119 memcpy(pIcons, (char *)pSerialized + 4, 32 * uNumIcons);
86a83e12d795 moving files
Ritor1
parents:
diff changeset
120 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
121
86a83e12d795 moving files
Ritor1
parents:
diff changeset
122 //----- (0049509D) --------------------------------------------------------
86a83e12d795 moving files
Ritor1
parents:
diff changeset
123 int IconFrameTable::FromFileTxt(const char *Args)
86a83e12d795 moving files
Ritor1
parents:
diff changeset
124 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
125 IconFrameTable *v2; // ebx@1
86a83e12d795 moving files
Ritor1
parents:
diff changeset
126 FILE *v3; // eax@1
86a83e12d795 moving files
Ritor1
parents:
diff changeset
127 int v4; // esi@3
86a83e12d795 moving files
Ritor1
parents:
diff changeset
128 void *v5; // eax@10
86a83e12d795 moving files
Ritor1
parents:
diff changeset
129 FILE *v6; // ST0C_4@12
86a83e12d795 moving files
Ritor1
parents:
diff changeset
130 char *i; // eax@12
86a83e12d795 moving files
Ritor1
parents:
diff changeset
131 const char *v8; // ST00_4@15
86a83e12d795 moving files
Ritor1
parents:
diff changeset
132 int v9; // eax@16
86a83e12d795 moving files
Ritor1
parents:
diff changeset
133 int v10; // edx@20
86a83e12d795 moving files
Ritor1
parents:
diff changeset
134 int v11; // ecx@21
86a83e12d795 moving files
Ritor1
parents:
diff changeset
135 int v12; // eax@22
86a83e12d795 moving files
Ritor1
parents:
diff changeset
136 signed int j; // edx@25
86a83e12d795 moving files
Ritor1
parents:
diff changeset
137 IconFrame *v14; // ecx@26
86a83e12d795 moving files
Ritor1
parents:
diff changeset
138 int v15; // esi@26
86a83e12d795 moving files
Ritor1
parents:
diff changeset
139 int k; // eax@27
86a83e12d795 moving files
Ritor1
parents:
diff changeset
140 signed int result; // eax@11
86a83e12d795 moving files
Ritor1
parents:
diff changeset
141 char Buf; // [sp+Ch] [bp-2F8h]@3
86a83e12d795 moving files
Ritor1
parents:
diff changeset
142 FrameTableTxtLine v19; // [sp+200h] [bp-104h]@4
86a83e12d795 moving files
Ritor1
parents:
diff changeset
143 FrameTableTxtLine v20; // [sp+27Ch] [bp-88h]@4
86a83e12d795 moving files
Ritor1
parents:
diff changeset
144 int v21; // [sp+2F8h] [bp-Ch]@3
86a83e12d795 moving files
Ritor1
parents:
diff changeset
145 int v22; // [sp+2FCh] [bp-8h]@3
86a83e12d795 moving files
Ritor1
parents:
diff changeset
146 FILE *File; // [sp+300h] [bp-4h]@1
86a83e12d795 moving files
Ritor1
parents:
diff changeset
147 int Argsa; // [sp+30Ch] [bp+8h]@26
86a83e12d795 moving files
Ritor1
parents:
diff changeset
148
86a83e12d795 moving files
Ritor1
parents:
diff changeset
149 v2 = this;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
150 //TileTable::dtor((TileTable *)this);
86a83e12d795 moving files
Ritor1
parents:
diff changeset
151 v3 = fopen(Args, "r");
86a83e12d795 moving files
Ritor1
parents:
diff changeset
152 File = v3;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
153 if ( !v3 )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
154 Abortf("IconFrameTable::load - Unable to open file: %s.", Args);
86a83e12d795 moving files
Ritor1
parents:
diff changeset
155 v4 = 0;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
156 v21 = 0;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
157 v22 = 1;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
158 if ( fgets(&Buf, 490, v3) )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
159 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
160 do
86a83e12d795 moving files
Ritor1
parents:
diff changeset
161 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
162 *strchr(&Buf, 10) = 0;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
163 memcpy(&v20, frame_table_txt_parser(&Buf, &v19), sizeof(v20));
86a83e12d795 moving files
Ritor1
parents:
diff changeset
164 if ( v20.uPropCount && *v20.pProperties[0] != 47 )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
165 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
166 if ( v20.uPropCount < 3 )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
167 Abortf("IconFrameTable::loadText, too few arguments, %s line %i.", Args, v22);
86a83e12d795 moving files
Ritor1
parents:
diff changeset
168 ++v21;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
169 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
170 ++v22;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
171 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
172 while ( fgets(&Buf, 490, File) );
86a83e12d795 moving files
Ritor1
parents:
diff changeset
173 v4 = v21;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
174 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
175 v2->uNumIcons = v4;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
176 v5 = pAllocator->AllocNamedChunk(v2->pIcons, 32 * v4, "I Frames");
86a83e12d795 moving files
Ritor1
parents:
diff changeset
177 v2->pIcons = (IconFrame *)v5;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
178 if ( v5 )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
179 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
180 v6 = File;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
181 v2->uNumIcons = 0;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
182 fseek(v6, 0, 0);
86a83e12d795 moving files
Ritor1
parents:
diff changeset
183 for ( i = fgets(&Buf, 490, File); i; i = fgets(&Buf, 490, File) )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
184 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
185 *strchr(&Buf, 10) = 0;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
186 memcpy(&v20, frame_table_txt_parser(&Buf, &v19), sizeof(v20));
86a83e12d795 moving files
Ritor1
parents:
diff changeset
187 if ( v20.uPropCount && *v20.pProperties[0] != 47 )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
188 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
189 strcpy(v2->pIcons[v2->uNumIcons].pAnimationName, v20.pProperties[0]);
86a83e12d795 moving files
Ritor1
parents:
diff changeset
190 strcpy(v2->pIcons[v2->uNumIcons].pTextureName, v20.pProperties[1]);
86a83e12d795 moving files
Ritor1
parents:
diff changeset
191 v8 = v20.pProperties[2];
86a83e12d795 moving files
Ritor1
parents:
diff changeset
192 v2->pIcons[v2->uNumIcons].uFlags = 0;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
193 if ( !_stricmp(v8, "new") )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
194 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
195 v9 = (int)&v2->pIcons[v2->uNumIcons].uFlags;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
196 *(char *)v9 |= 4u;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
197 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
198 v2->pIcons[v2->uNumIcons].uAnimTime = atoi(v20.pProperties[3]);
86a83e12d795 moving files
Ritor1
parents:
diff changeset
199 v2->pIcons[v2->uNumIcons].uAnimLength = 0;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
200 v2->pIcons[v2->uNumIcons++].uTextureID = 0;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
201 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
202 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
203 fclose(File);
86a83e12d795 moving files
Ritor1
parents:
diff changeset
204 v10 = 0;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
205 if ( (signed int)(v2->uNumIcons - 1) > 0 )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
206 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
207 v11 = 0;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
208 do
86a83e12d795 moving files
Ritor1
parents:
diff changeset
209 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
210 v12 = (int)&v2->pIcons[v11];
86a83e12d795 moving files
Ritor1
parents:
diff changeset
211 if ( !(*(char *)(v12 + 60) & 4) )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
212 *(char *)(v12 + 28) |= 1u;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
213 ++v10;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
214 ++v11;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
215 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
216 while ( v10 < (signed int)(v2->uNumIcons - 1) );
86a83e12d795 moving files
Ritor1
parents:
diff changeset
217 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
218 for ( j = 0; j < (signed int)v2->uNumIcons; *(short *)(Argsa + 26) = v15 )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
219 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
220 v14 = v2->pIcons;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
221 Argsa = (int)&v14[j];
86a83e12d795 moving files
Ritor1
parents:
diff changeset
222 v15 = *(short *)(Argsa + 24);
86a83e12d795 moving files
Ritor1
parents:
diff changeset
223 if ( *(char *)(Argsa + 28) & 1 )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
224 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
225 ++j;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
226 for ( k = (int)&v14[j]; *(char *)(k + 28) & 1; k += 32 )
86a83e12d795 moving files
Ritor1
parents:
diff changeset
227 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
228 v15 += *(short *)(k + 24);
86a83e12d795 moving files
Ritor1
parents:
diff changeset
229 ++j;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
230 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
231 LOWORD(v15) = v14[j].uAnimTime + v15;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
232 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
233 ++j;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
234 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
235 result = 1;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
236 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
237 else
86a83e12d795 moving files
Ritor1
parents:
diff changeset
238 {
86a83e12d795 moving files
Ritor1
parents:
diff changeset
239 fclose(File);
86a83e12d795 moving files
Ritor1
parents:
diff changeset
240 result = 0;
86a83e12d795 moving files
Ritor1
parents:
diff changeset
241 }
86a83e12d795 moving files
Ritor1
parents:
diff changeset
242 return result;
1296
c423f946dc99 moving files continue
Ritor1
parents: 1295
diff changeset
243 }
c423f946dc99 moving files continue
Ritor1
parents: 1295
diff changeset
244 //----- (0042EB78) --------------------------------------------------------
c423f946dc99 moving files continue
Ritor1
parents: 1295
diff changeset
245 int IconFrameTable::GetIconAnimLength(unsigned int uIconID)
c423f946dc99 moving files continue
Ritor1
parents: 1295
diff changeset
246 {
c423f946dc99 moving files continue
Ritor1
parents: 1295
diff changeset
247 return 8 * this->pIcons[uIconID].uAnimLength;
1295
86a83e12d795 moving files
Ritor1
parents:
diff changeset
248 }