annotate stru6.cpp @ 71:8453114181af

intermediate
author Nomad
date Sat, 27 Oct 2012 21:44:29 +0200
parents fdacbc653945
children 3b5267621a5b
rev   line source
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1 #include "stru6.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
2 #include "LayingItem.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
3 #include "IndoorCameraD3D.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
4 #include "ParticleEngine.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
5 #include "Game.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
6 #include "LOD.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
7 #include "Sprites.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
8 #include "DecalBuilder.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
9 #include "ObjectList.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
10 #include "Actor.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
11 #include "Random.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
12 #include "Spells.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
13 #include "IconFrameTable.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
14 #include "Time.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
15 #include "Viewport.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
16 #include "PaletteManager.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
17 #include "Overlays.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
18 #include "stru160.h"
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
19
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
20
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
21
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
22
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
23
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
24
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
25 //----- (00478211) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
26 void stru6_stru1_indoor_sw_billboard::Initialize(int a2)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
27 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
28 uNumVec4sInArray1 = 66;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
29 pArray1 = new stru16x[66];
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
30
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
31 uNumVec3sInArray2 = 128;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
32 pArray2 = new stru160[128];
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
33
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
34 for (uint i = 0; i < uNumVec4sInArray1; ++i)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
35 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
36 pArray1[i].field_0 = array_4EB8B8[i].field_0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
37 pArray1[i].field_4 = array_4EB8B8[i].field_4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
38 pArray1[i].field_8 = array_4EB8B8[i].field_8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
39 pArray1[i].field_C = a2;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
40 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
41 memcpy(pArray2, array_4EBBD0_x/*array_4EBBD0*/, uNumVec3sInArray2 * sizeof(stru160));
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
42 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
43
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
44 //----- (0047829F) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
45 void stru6_stru1_indoor_sw_billboard::_47829F_fireball_collision(float arg0, float a3, float a4, float a5, int a2)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
46 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
47 stru6_stru1_indoor_sw_billboard *v6; // esi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
48 int v7; // edi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
49 char *v8; // eax@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
50 signed int v9; // ecx@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
51 int v10; // edx@3
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
52 signed int i; // [sp+8h] [bp-4h]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
53
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
54 auto a1 = this;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
55
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
56 v6 = a1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
57 v7 = 0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
58 for ( i = 0; i < (signed int)v6->uNumVec3sInArray2; ++i )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
59 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
60 v8 = (char *)&v6->field_14[1];
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
61 v9 = 3;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
62 do
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
63 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
64 *((float *)v8 - 1) = a5 * *(&v6->pArray1->field_0 + 4 * *(int *)((char *)&v6->pArray2->field_0 + v7)) + arg0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
65 *(float *)v8 = a5 * *(&v6->pArray1->field_4 + 4 * *(int *)((char *)&v6->pArray2->field_0 + v7)) + a3;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
66 v8 += 16;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
67 *((float *)v8 - 3) = a5 * *(&v6->pArray1->field_8 + 4 * *(int *)((char *)&v6->pArray2->field_0 + v7)) + a4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
68 v10 = *(int *)((char *)&v6->pArray2->field_0 + v7);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
69 v7 += 4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
70 --v9;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
71 *((int *)v8 - 2) = *((int *)&v6->pArray1[1].field_0 + 4 * v10);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
72 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
73 while ( v9 );
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
74 v6->field_10 = 3;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
75 if ( v6->sub_477C61() && v6->sub_477F63() )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
76 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
77 if ( v6->sub_47802A() )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
78 pRenderer->_4A4CC9(v6, a2);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
79 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
80 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
81 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
82
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
83
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
84
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
85
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
86 //----- (004A71FE) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
87 void stru6::DoAddProjectile(float srcX, float srcY, float srcZ, float dstX, float dstY, float dstZ, unsigned int uTextureID)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
88 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
89 int v8; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
90
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
91 v8 = uNumProjectiles;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
92 if ( v8 != 32 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
93 {
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
94 pProjectiles[v8].srcX = srcX;
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
95 *((float *)&this->array_0[0].uSpellAnimLength + 7 * (uNumProjectiles + 21)) = srcY;
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
96 pProjectiles[uNumProjectiles].srcZ = srcZ;
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
97 pProjectiles[uNumProjectiles].dstX = dstX;
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
98 pProjectiles[uNumProjectiles].dstY = dstY;
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
99 pProjectiles[uNumProjectiles].dstZ = dstZ;
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
100 pProjectiles[uNumProjectiles++].uTextureID = uTextureID;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
101 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
102 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
103
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
104 //----- (004A7298) --------------------------------------------------------
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
105 void stru6::DrawProjectiles()
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
106 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
107 float v10; // ST1C_4@8
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
108 float v11; // ST0C_4@8
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
109 IDirect3DTexture2 *v12; // [sp+20h] [bp-78h]@6
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
110 RenderVertexSoft v[2]; // [sp+30h] [bp-68h]@1
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
111
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
112 for (uint i = 0; i < uNumProjectiles; ++i)
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
113 {
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
114 auto p = pProjectiles + i;
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
115
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
116 v[0].vWorldPosition.x = p->srcX;
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
117 v[0].vWorldPosition.y = p->srcY;
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
118 v[0].vWorldPosition.z = p->srcZ;
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
119 v[1].vWorldPosition.x = p->dstX;
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
120 v[1].vWorldPosition.y = p->dstY;
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
121 v[1].vWorldPosition.z = p->dstZ;
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
122 pGame->pIndoorCameraD3D->ViewTransform(v, 2);
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
123
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
124 sr_42620A(v);
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
125
59
5159d2e6f559 BLV render
Nomad
parents: 45
diff changeset
126 pGame->pIndoorCameraD3D->Project(v, 2, 0);
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
127
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
128 if (p->uTextureID != -1)
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
129 v12 = pBitmaps_LOD->pHardwareTextures[p->uTextureID];
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
130 else
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
131 v12 = 0;
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
132
59
5159d2e6f559 BLV render
Nomad
parents: 45
diff changeset
133 v10 = pGame->pIndoorCameraD3D->fov_x / v[1].vWorldViewPosition.x * 20.0;
5159d2e6f559 BLV render
Nomad
parents: 45
diff changeset
134 v11 = pGame->pIndoorCameraD3D->fov_x / v[0].vWorldViewPosition.x * 20.0;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
135 pRenderer->DrawProjectile(
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
136 v[0].vWorldViewProjX,
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
137 v[0].vWorldViewProjY,
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
138 v[0].vWorldViewPosition.x,
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
139 v11,
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
140 v[1].vWorldViewProjX,
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
141 v[1].vWorldViewProjY,
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
142 v[1].vWorldViewPosition.x,
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
143 v10,
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
144 v12);
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
145 }
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
146 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
147
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
148 //----- (004A73AA) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
149 void stru6::_4A73AA_hanging_trace_particles___like_fire_strike_ice_blast_etc(LayingItem *a2, unsigned int uDiffuse, unsigned int uTextureID)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
150 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
151 stru6 *v4; // edi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
152 LayingItem *v5; // esi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
153 int v6; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
154 stru6_stru2 *v7; // eax@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
155 double v8; // st7@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
156 double v9; // st6@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
157 double v10; // st7@3
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
158 Particle_ local_0; // [sp+8h] [bp-68h]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
159 float x; // [sp+78h] [bp+8h]@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
160
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
161 v4 = this;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
162 memset(&local_0, 0, 0x68u);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
163 v5 = a2;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
164 v6 = a2->field_54;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
165 if ( v6 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
166 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
167 v7 = &v4->array_0[v6 & 0x1F];
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
168 x = ((double)a2->vPosition.x - v7->flt_4) * 0.5 + v7->flt_4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
169 v8 = ((double)v5->vPosition.y - v7->flt_8) * 0.5 + v7->flt_8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
170 v9 = ((double)v5->vPosition.z - v7->flt_C) * 0.5 + v7->flt_C;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
171 local_0.bFree = 1036;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
172 local_0.uDiffuse = uDiffuse;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
173 local_0.x = x + 4.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
174 local_0.y = v8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
175 local_0.z = v9;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
176 local_0.flt_10 = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
177 local_0.flt_14 = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
178 local_0.flt_18 = 0.0;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
179 local_0.timeToLive = (rand() & 0x40) + 96;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
180 local_0.uTextureID = uTextureID;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
181 local_0.flt_28 = 1.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
182 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
183 local_0.x = x - 4.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
184 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
185 local_0.x = (double)v5->vPosition.x + 4.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
186 local_0.y = (double)v5->vPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
187 local_0.z = (double)v5->vPosition.z;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
188 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
189 local_0.x = (double)v5->vPosition.x - 4.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
190 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
191 v4->array_0[v5->field_54 & 0x1F].flt_4 = (double)v5->vPosition.x;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
192 v4->array_0[v5->field_54 & 0x1F].flt_8 = (double)v5->vPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
193 v4->array_0[v5->field_54 & 0x1F].flt_C = (double)v5->vPosition.z;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
194 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
195 else
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
196 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
197 a2->field_54 = v4->array_0[0].uSpellAnimLength++;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
198 v4->array_0[a2->field_54 & 0x1F].flt_4 = (double)a2->vPosition.x;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
199 v4->array_0[a2->field_54 & 0x1F].flt_8 = (double)a2->vPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
200 v4->array_0[a2->field_54 & 0x1F].flt_C = (double)a2->vPosition.z;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
201 v10 = (double)a2->vPosition.x;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
202 local_0.bFree = 1036;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
203 local_0.uDiffuse = uDiffuse;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
204 local_0.x = v10 + 4.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
205 local_0.y = (double)a2->vPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
206 local_0.z = (double)a2->vPosition.z;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
207 local_0.flt_10 = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
208 local_0.flt_14 = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
209 local_0.flt_18 = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
210 local_0.flt_28 = 1.0;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
211 local_0.timeToLive = (rand() & 0x7F) + 128;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
212 local_0.uTextureID = uTextureID;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
213 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
214 local_0.x = (double)a2->vPosition.x - 4.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
215 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
216 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
217 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
218
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
219 //----- (004A75CC) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
220 void stru6::_4A75CC_single_spell_collision_particle(LayingItem *a1, unsigned int uDiffuse, unsigned int uTextureID)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
221 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
222 double v4; // st7@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
223 signed int v5; // edi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
224 Particle_ local_0; // [sp+8h] [bp-68h]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
225
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
226 memset(&local_0, 0, 0x68u);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
227 local_0.bFree = 1029;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
228 local_0.x = (double)a1->vPosition.x;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
229 local_0.y = (double)a1->vPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
230 v4 = (double)a1->vPosition.z;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
231 local_0.uDiffuse = uDiffuse;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
232 local_0.z = v4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
233 v5 = 10;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
234 local_0.timeToLive = (rand() & 0x7F) + 128;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
235 local_0.uTextureID = uTextureID;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
236 local_0.flt_28 = 1.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
237 do
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
238 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
239 local_0.flt_10 = (double)(rand() & 0x1FF) - 255.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
240 local_0.flt_14 = (double)(rand() & 0x1FF) - 255.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
241 local_0.flt_18 = (double)(rand() & 0x1FF) - 255.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
242 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
243 --v5;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
244 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
245 while ( v5 );
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
246 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
247
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
248 //----- (004A7688) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
249 void stru6::_4A7688_fireball_collision_particle(LayingItem *a2)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
250 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
251 LayingItem *v2; // esi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
252 double v3; // st7@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
253 double v4; // st7@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
254 double v5; // st7@4
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
255 int v6; // eax@6
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
256 float v7; // ST0C_4@6
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
257 float v8; // ST08_4@6
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
258 float v9; // ST04_4@6
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
259 float v10; // ST00_4@6
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
260 Particle_ local_0; // [sp+1Ch] [bp-7Ch]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
261 stru6 *v12; // [sp+84h] [bp-14h]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
262 float v13; // [sp+88h] [bp-10h]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
263 double v14; // [sp+8Ch] [bp-Ch]@5
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
264 float v15; // [sp+94h] [bp-4h]@4
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
265 signed int i; // [sp+A0h] [bp+8h]@4
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
266 signed int a2b; // [sp+A0h] [bp+8h]@6
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
267
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
268 v12 = this;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
269 memset(&local_0, 0, 0x68u);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
270 v2 = a2;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
271 v3 = (double)a2->uSpriteFrameID / (double)pObjectList->pObjects[a2->uObjectDescID].uLifetime;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
272 v13 = 512.0 * v3;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
273 if ( v3 >= 0.75 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
274 v4 = (1.0 - v3) * 4.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
275 else
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
276 v4 = v3 * 1.333333333333333;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
277 v15 = v4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
278 v5 = (double)a2->vPosition.x;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
279 local_0.bFree = 1029;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
280 local_0.uDiffuse = 0xFF3C1Eu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
281 local_0.x = v5;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
282 local_0.y = (double)a2->vPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
283 local_0.z = (double)a2->vPosition.z;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
284 local_0.timeToLive = (rand() & 0x7F) + 128;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
285 local_0.uTextureID = pBitmaps_LOD->LoadTexture("effpar01", TEXTURE_DEFAULT);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
286 i = 10;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
287 local_0.flt_28 = 1.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
288 do
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
289 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
290 HIDWORD(v14) = rand() & 0x1FF;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
291 local_0.flt_10 = (double)SHIDWORD(v14) - 255.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
292 HIDWORD(v14) = rand() & 0x1FF;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
293 local_0.flt_14 = (double)SHIDWORD(v14) - 255.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
294 WORD2(v14) = rand() & 0x1FF;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
295 HIDWORD(v14) = WORD2(v14);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
296 local_0.flt_18 = (double)WORD2(v14) - 255.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
297 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
298 --i;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
299 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
300 while ( i );
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
301 v14 = v13 + 6.7553994e15;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
302 a2b = LODWORD(v14);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
303 v6 = sub_4A7063(0xFF3C1Eu, v15);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
304 v7 = (double)a2b;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
305 v8 = (double)v2->vPosition.z;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
306 v9 = (double)v2->vPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
307 v10 = (double)v2->vPosition.x;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
308 v12->pStru1->_47829F_fireball_collision(v10, v9, v8, v7, v6);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
309 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
310
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
311 //----- (004A77FD) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
312 void stru6::_4A77FD_some_stuff_d3d(LayingItem *a1)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
313 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
314 LayingItem *v2; // esi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
315 stru6 *v3; // edi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
316 double v4; // st7@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
317 double v5; // st7@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
318 double v6; // ST1C_8@4
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
319 int v7; // eax@4
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
320 float v8; // ST0C_4@4
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
321 float v9; // ST08_4@4
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
322 float v10; // ST04_4@4
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
323 float v11; // ST00_4@4
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
324 float v12; // [sp+28h] [bp-4h]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
325 float a1a; // [sp+34h] [bp+8h]@4
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
326
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
327 v2 = a1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
328 v3 = this;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
329 v4 = (double)a1->uSpriteFrameID / (double)pObjectList->pObjects[a1->uObjectDescID].uLifetime;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
330 v12 = 512.0 - v4 * 512.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
331 if ( v4 >= 0.75 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
332 v5 = v4 * 4.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
333 else
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
334 v5 = v4 * 1.333333333333333;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
335 a1a = v5;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
336 v6 = v12 + 6.7553994e15;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
337 v7 = sub_4A7063(0x7E7E7Eu, a1a);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
338 v8 = (double)SLODWORD(v6);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
339 v9 = (double)v2->vPosition.z;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
340 v10 = (double)v2->vPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
341 v11 = (double)v2->vPosition.x;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
342 v3->pStru1->_47829F_fireball_collision(v11, v10, v9, v8, v7);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
343 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
344
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
345 //----- (004A78AE) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
346 void stru6::_4A78AE_sparks_spell(LayingItem *a1)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
347 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
348 ObjectDesc *v2; // esi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
349 unsigned int v3; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
350 double v4; // st7@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
351 Particle_ local_0; // [sp+8h] [bp-68h]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
352
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
353 v2 = &pObjectList->pObjects[a1->uObjectDescID];
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
354 memset(&local_0, 0, 0x68u);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
355 v3 = a1->uSpriteFrameID;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
356 local_0.x = (double)a1->vPosition.x;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
357 v4 = (double)a1->vPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
358 local_0.bFree = 2048;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
359 local_0.uDiffuse = 0x7F7F7Fu;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
360 local_0.timeToLive = 1;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
361 local_0.y = v4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
362 local_0.z = (double)a1->vPosition.z;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
363 local_0.flt_10 = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
364 local_0.flt_14 = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
365 local_0.flt_18 = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
366 local_0.uTextureID = pSpriteFrameTable->GetFrame(v2->uSpriteID, v3)->pHwSpriteIDs[0];
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
367 LODWORD(local_0.flt_28) = 0x40000000u;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
368 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
369 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
370
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
371 //----- (004A7948) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
372 void stru6::_4A7948_mind_blast_after_effect(LayingItem *a1)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
373 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
374 ObjectDesc *v2; // esi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
375 unsigned int v3; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
376 double v4; // st7@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
377 char v5; // al@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
378 signed int v6; // edi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
379 Particle_ Dst; // [sp+8h] [bp-68h]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
380
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
381 v2 = &pObjectList->pObjects[a1->uObjectDescID];
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
382 memset(&Dst, 0, 0x68u);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
383 v3 = a1->uSpriteFrameID;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
384 Dst.x = (double)a1->vPosition.x;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
385 v4 = (double)a1->vPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
386 Dst.bFree = 2053;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
387 Dst.uDiffuse = 0x7F7F7Fu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
388 Dst.y = v4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
389 Dst.z = (double)a1->vPosition.z;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
390 Dst.uTextureID = pSpriteFrameTable->GetFrame(v2->uSpriteID, v3)->pHwSpriteIDs[0];
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
391 v5 = rand();
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
392 v6 = 10;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
393 Dst.flt_28 = 1.0;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
394 Dst.timeToLive = (v5 & 0x7F) + 128;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
395 do
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
396 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
397 Dst.flt_10 = (double)(rand() & 0x1FF) - 255.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
398 Dst.flt_14 = (double)(rand() & 0x1FF) - 255.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
399 Dst.flt_18 = (double)(rand() & 0x1FF) - 255.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
400 pGame->pParticleEngine->AddParticle(&Dst);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
401 --v6;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
402 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
403 while ( v6 );
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
404 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
405
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
406 //----- (004A7A27) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
407 bool stru6::AddMobileLight(LayingItem *a1, unsigned int uDiffuse, int uRadius)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
408 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
409 return pMobileLightsStack->AddLight(
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
410 a1->vPosition.x,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
411 a1->vPosition.y,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
412 a1->vPosition.z,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
413 a1->uSectorID,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
414 uRadius,
59
5159d2e6f559 BLV render
Nomad
parents: 45
diff changeset
415 (uDiffuse & 0x00FF0000) >> 16,
5159d2e6f559 BLV render
Nomad
parents: 45
diff changeset
416 (uDiffuse & 0x0000FF00) >> 8,
5159d2e6f559 BLV render
Nomad
parents: 45
diff changeset
417 uDiffuse & 0x000000FF,
5159d2e6f559 BLV render
Nomad
parents: 45
diff changeset
418 byte_4E94D3);
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
419 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
420 // 4E94D3: using guessed type char byte_4E94D3;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
421
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
422 //----- (004A7A66) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
423 void stru6::_4A7A66_miltiple_spell_collision_partifles___like_after_sparks_or_lightning(LayingItem *a1, unsigned int uDiffuse, unsigned int uTextureID, float a4)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
424 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
425 int v5; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
426 char v6; // al@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
427 double v7; // st6@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
428 double v8; // st6@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
429 double v9; // st7@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
430 double v10; // st6@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
431 Particle_ local_0; // [sp+0h] [bp-6Ch]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
432 float v12; // [sp+68h] [bp-4h]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
433 float a1a; // [sp+74h] [bp+8h]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
434 float uDiffusea; // [sp+78h] [bp+Ch]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
435 float uTextureIDa; // [sp+7Ch] [bp+10h]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
436
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
437 memset(&local_0, 0, 0x68u);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
438 local_0.bFree = 1029;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
439 local_0.x = (double)a1->vPosition.x;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
440 v5 = a1->vPosition.z;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
441 local_0.y = (double)a1->vPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
442 local_0.uDiffuse = uDiffuse;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
443 local_0.z = (double)(v5 + 32);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
444 v6 = rand();
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
445 local_0.flt_28 = 1.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
446 v7 = 0.0 * a4;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
447 local_0.timeToLive = (v6 & 0x7F) + 128;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
448 local_0.uTextureID = uTextureID;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
449 a1a = v7;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
450 local_0.flt_10 = v7;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
451 local_0.flt_14 = a4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
452 local_0.flt_18 = a4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
453 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
454 v8 = 0.70710677 * a4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
455 uDiffusea = v8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
456 local_0.flt_10 = v8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
457 local_0.flt_14 = v8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
458 local_0.flt_18 = a4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
459 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
460 local_0.flt_14 = a1a;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
461 local_0.flt_10 = a4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
462 local_0.flt_18 = a4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
463 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
464 local_0.flt_10 = uDiffusea;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
465 local_0.flt_18 = a4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
466 v9 = -uDiffusea;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
467 uTextureIDa = v9;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
468 local_0.flt_14 = v9;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
469 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
470 v10 = -1.0 * a4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
471 local_0.flt_10 = a1a;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
472 v12 = v10;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
473 local_0.flt_14 = v10;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
474 local_0.flt_18 = a4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
475 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
476 local_0.flt_18 = a4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
477 local_0.flt_10 = uTextureIDa;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
478 local_0.flt_14 = uTextureIDa;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
479 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
480 local_0.flt_10 = v12;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
481 local_0.flt_14 = a1a;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
482 local_0.flt_18 = a4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
483 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
484 local_0.flt_10 = uTextureIDa;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
485 local_0.flt_14 = uDiffusea;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
486 local_0.flt_18 = a4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
487 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
488 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
489
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
490 //----- (004A7C07) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
491 void stru6::_4A7C07(LayingItem *a2)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
492 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
493 stru6 *v2; // edi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
494 LayingItem *v3; // esi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
495 int v4; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
496 ObjectDesc *v5; // ebx@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
497 stru6_stru2 *v6; // eax@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
498 double v7; // st6@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
499 double v8; // st5@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
500 double v9; // st4@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
501 char v10; // al@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
502 double v11; // st7@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
503 double v12; // st7@3
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
504 Particle_ local_0; // [sp+Ch] [bp-68h]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
505 float a2a; // [sp+7Ch] [bp+8h]@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
506
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
507 v2 = this;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
508 memset(&local_0, 0, 0x68u);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
509 v3 = a2;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
510 v4 = a2->field_54;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
511 v5 = &pObjectList->pObjects[a2->uObjectDescID];
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
512 if ( v4 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
513 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
514 v6 = &v2->array_0[v4 & 0x1F];
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
515 v7 = ((double)a2->vPosition.x - v6->flt_4) * 0.5 + v6->flt_4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
516 v8 = ((double)a2->vPosition.y - v6->flt_8) * 0.5 + v6->flt_8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
517 v9 = ((double)a2->vPosition.z - v6->flt_C) * 0.5 + v6->flt_C;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
518 local_0.bFree = 2048;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
519 local_0.uDiffuse = 0xFFFFFFu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
520 a2a = v9;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
521 local_0.x = v7;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
522 local_0.z = a2a;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
523 local_0.y = v8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
524 local_0.flt_10 = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
525 local_0.flt_14 = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
526 local_0.flt_18 = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
527 v10 = rand();
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
528 LODWORD(local_0.flt_28) = 0x40400000u;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
529 local_0.timeToLive = (v10 & 0x3F) + 64;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
530 local_0.uTextureID = pSpriteFrameTable->GetFrame(v5->uSpriteID, v3->uSpriteFrameID)->pHwSpriteIDs[0];
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
531 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
532 v11 = (double)v3->vPosition.x;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
533 LODWORD(local_0.flt_28) = 0x40800000u;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
534 local_0.x = v11;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
535 local_0.y = (double)v3->vPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
536 local_0.z = (double)v3->vPosition.z;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
537 local_0.timeToLive = (rand() & 0x3F) + 64;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
538 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
539 v2->array_0[v3->field_54 & 0x1F].flt_4 = (double)v3->vPosition.x;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
540 v2->array_0[v3->field_54 & 0x1F].flt_8 = (double)v3->vPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
541 v2->array_0[v3->field_54 & 0x1F].flt_C = (double)v3->vPosition.z;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
542 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
543 else
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
544 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
545 a2->field_54 = v2->array_0[0].uSpellAnimLength++;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
546 v2->array_0[a2->field_54 & 0x1F].flt_4 = (double)a2->vPosition.x;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
547 v2->array_0[a2->field_54 & 0x1F].flt_8 = (double)a2->vPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
548 v2->array_0[a2->field_54 & 0x1F].flt_C = (double)a2->vPosition.z;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
549 v12 = (double)a2->vPosition.x;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
550 local_0.bFree = 2048;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
551 local_0.uDiffuse = 0xFFFFFFu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
552 LODWORD(local_0.flt_28) = 0x40000000u;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
553 local_0.x = v12;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
554 local_0.y = (double)a2->vPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
555 local_0.z = (double)a2->vPosition.z;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
556 local_0.flt_10 = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
557 local_0.flt_14 = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
558 local_0.flt_18 = 0.0;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
559 local_0.timeToLive = (rand() & 0x3F) + 64;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
560 local_0.uTextureID = pSpriteFrameTable->GetFrame(v5->uSpriteID, a2->uSpriteFrameID)->pHwSpriteIDs[0];
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
561 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
562 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
563 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
564
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
565 //----- (004A7E05) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
566 void stru6::AddProjectile(LayingItem *a2, int a3, unsigned int uTextureID)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
567 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
568 int v4; // edx@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
569 float v5; // ST14_4@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
570 float v6; // ST10_4@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
571 float v7; // ST0C_4@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
572
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
573 v4 = a2->field_54;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
574 if ( v4 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
575 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
576 v5 = (double)a2->vPosition.z;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
577 v6 = (double)a2->vPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
578 v7 = (double)a2->vPosition.x;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
579 DoAddProjectile(
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
580 this->array_0[v4 & 0x1F].flt_4,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
581 this->array_0[v4 & 0x1F].flt_8,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
582 this->array_0[v4 & 0x1F].flt_C,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
583 v7,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
584 v6,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
585 v5,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
586 uTextureID);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
587 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
588 else
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
589 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
590 a2->field_54 = this->array_0[0].uSpellAnimLength++;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
591 this->array_0[a2->field_54 & 0x1F].flt_4 = (double)a2->vPosition.x;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
592 this->array_0[a2->field_54 & 0x1F].flt_8 = (double)a2->vPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
593 this->array_0[a2->field_54 & 0x1F].flt_C = (double)a2->vPosition.z;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
594 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
595 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
596
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
597 //----- (004A7E89) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
598 int stru6::_4A7E89_sparkles_on_actor_after_it_casts_buff(Actor *pActor, unsigned int uDiffuse)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
599 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
600 Actor *v3; // edi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
601 int v4; // ebx@3
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
602 int result; // eax@5
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
603 Particle_ Dst; // [sp+Ch] [bp-6Ch]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
604 int v7; // [sp+74h] [bp-4h]@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
605 signed int pActora; // [sp+80h] [bp+8h]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
606
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
607 memset(&Dst, 0, 0x68u);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
608 Dst.bFree = 1036;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
609 Dst.timeToLive = (rand() & 0x7F) + 128;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
610 v3 = pActor;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
611 Dst.uTextureID = pBitmaps_LOD->LoadTexture("effpar02", TEXTURE_DEFAULT);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
612 pActora = 50;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
613 Dst.flt_28 = 1.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
614 do
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
615 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
616 v7 = (unsigned __int8)rand() + v3->vPosition.x - 127;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
617 Dst.x = (double)v7;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
618 v7 = (unsigned __int8)rand() + v3->vPosition.y - 127;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
619 Dst.y = (double)v7;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
620 v7 = v3->vPosition.z + (unsigned __int8)rand();
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
621 Dst.z = (double)v7;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
622 if ( uDiffuse )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
623 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
624 Dst.uDiffuse = uDiffuse;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
625 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
626 else
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
627 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
628 v4 = rand() << 16;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
629 Dst.uDiffuse = rand() | v4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
630 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
631 pGame->pParticleEngine->AddParticle(&Dst);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
632 --pActora;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
633 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
634 while ( pActora );
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
635 return result;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
636 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
637
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
638 //----- (004A7F74) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
639 void stru6::_4A7F74(int x, int y, int z)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
640 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
641 stru6 *v4; // esi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
642 char v5; // al@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
643 signed int v6; // edi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
644 unsigned int v7; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
645 double v8; // st7@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
646 double v9; // st7@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
647 Particle_ local_0; // [sp+8h] [bp-78h]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
648 double v11; // [sp+70h] [bp-10h]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
649 double v12; // [sp+78h] [bp-8h]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
650 float z1; // [sp+88h] [bp+8h]@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
651
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
652 v4 = this;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
653 memset(&local_0, 0, 0x68u);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
654 local_0.bFree = 1029;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
655 local_0.uDiffuse = 0x7E7E7Eu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
656 v5 = rand();
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
657 local_0.flt_28 = 1.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
658 v6 = 8;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
659 local_0.timeToLive = (v5 & 0x7F) + 128;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
660 v7 = v4->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
661 v12 = (double)x;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
662 local_0.uTextureID = v7;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
663 v11 = (double)y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
664 do
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
665 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
666 v8 = pRnd->GetRandom();
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
667 local_0.x = v8 * 40.0 - 20.0 + v12;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
668 v9 = pRnd->GetRandom();
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
669 z1 = (double)z;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
670 local_0.z = z1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
671 local_0.y = v9 * 40.0 - 20.0 + v11;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
672 local_0.flt_10 = pRnd->GetRandom() * 400.0 - 200.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
673 local_0.flt_14 = pRnd->GetRandom() * 400.0 - 200.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
674 local_0.flt_18 = pRnd->GetRandom() * 150.0 + 50.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
675 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
676 --v6;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
677 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
678 while ( v6 );
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
679 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
680
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
681 //----- (004A806F) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
682 int stru6::_4A806F(Actor *pActor)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
683 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
684 int v2; // ecx@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
685 unsigned int v3; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
686 double v4; // st7@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
687 float v5; // ST00_4@6
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
688
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
689 v2 = (int)pActor;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
690 v3 = LODWORD(pActor->pActorBuffs[10].uExpireTime) - pMiscTimer->uTotalGameTimeElapsed;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
691 if ( (signed int)v3 <= 64 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
692 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
693 if ( (v3 & 0x80000000u) != 0 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
694 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
695 pActor->pActorBuffs[10].uExpireTime = 0i64;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
696 v4 = 1.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
697 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
698 else
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
699 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
700 v2 = v3 * v3;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
701 v4 = 1.0 - (double)(signed int)(v3 * v3) * 0.0001953125;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
702 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
703 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
704 else
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
705 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
706 v2 = (v3 - 64) * (v3 - 64);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
707 v4 = (double)v2 * 0.0001953125 + 0.2;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
708 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
709 v5 = v4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
710 return _48B561_mess_with_scaling_along_z(/*v2, */v5);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
711 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
712
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
713 //----- (004A80DC) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
714 void stru6::_4A80DC_some_stuff_sw(LayingItem *a2)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
715 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
716 stru6 *v2; // esi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
717 signed int v3; // ebx@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
718 Particle_ local_0; // [sp+Ch] [bp-68h]@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
719
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
720 v2 = this;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
721 memset(&local_0, 0, 0x68u);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
722 local_0.bFree = 1029;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
723 local_0.uDiffuse = 0x7E7E7Eu;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
724 local_0.timeToLive = (rand() & 0x7F) + 128;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
725 local_0.uTextureID = v2->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
726 v3 = 8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
727 local_0.flt_28 = 1.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
728 do
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
729 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
730 local_0.x = pRnd->GetRandom() * 40.0 + (double)a2->vPosition.x - 20.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
731 local_0.y = pRnd->GetRandom() * 40.0 + (double)a2->vPosition.y - 20.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
732 local_0.z = (double)a2->vPosition.z;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
733 local_0.flt_10 = pRnd->GetRandom() * 800.0 - 400.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
734 local_0.flt_14 = pRnd->GetRandom() * 800.0 - 400.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
735 local_0.flt_18 = pRnd->GetRandom() * 350.0 + 50.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
736 pGame->pParticleEngine->AddParticle(&local_0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
737 --v3;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
738 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
739 while ( v3 );
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
740 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
741
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
742 //----- (004A81CA) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
743 bool stru6::_4A81CA(LayingItem *a2)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
744 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
745 stru6 *v2; // ebx@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
746 int result; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
747 int v4; // eax@27
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
748 unsigned int diffuse; // esi@41
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
749 int v6; // ecx@49
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
750 int v7; // eax@54
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
751 int v8; // eax@55
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
752 char v9; // zf@56
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
753 int v10; // eax@59
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
754 int v11; // eax@61
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
755 int v12; // eax@85
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
756 int v13; // eax@86
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
757 int v14; // eax@96
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
758 int v15; // eax@111
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
759 int v16; // eax@118
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
760 int v17; // eax@139
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
761 int v18; // eax@140
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
762 int v19; // eax@141
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
763 int v20; // eax@151
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
764 unsigned int v21; // [sp-8h] [bp-20h]@66
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
765 LayingItem *v22; // [sp-8h] [bp-20h]@81
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
766 unsigned int v23; // [sp-4h] [bp-1Ch]@4
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
767 unsigned int v24; // [sp-4h] [bp-1Ch]@5
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
768 unsigned int v25; // [sp-4h] [bp-1Ch]@30
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
769 unsigned int v26; // [sp-4h] [bp-1Ch]@57
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
770 unsigned int v27; // [sp-4h] [bp-1Ch]@66
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
771 int v28; // [sp-4h] [bp-1Ch]@81
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
772 unsigned int v29; // [sp+0h] [bp-18h]@4
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
773 unsigned int v30; // [sp+0h] [bp-18h]@5
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
774 int v31; // [sp+0h] [bp-18h]@30
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
775 unsigned int v32; // [sp+0h] [bp-18h]@45
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
776 float v33; // [sp+0h] [bp-18h]@57
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
777 float v34; // [sp+0h] [bp-18h]@66
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
778 signed int v35; // [sp+0h] [bp-18h]@81
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
779 char pContainer[7]; // [sp+10h] [bp-8h]@81
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
780
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
781 v2 = this;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
782 result = a2->uItemType;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
783 if ( result <= 545 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
784 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
785 if ( result != 545 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
786 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
787 result -= 500;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
788 switch ( result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
789 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
790 case 0:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
791 case 30:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
792 v29 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
793 v23 = 0xAAAFFu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
794 goto LABEL_8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
795 case 1:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
796 case 31:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
797 v30 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
798 v24 = 0xAAAFFu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
799 goto LABEL_32;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
800 case 5:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
801 v29 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
802 v23 = 0x5C310Eu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
803 goto LABEL_8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
804 case 10:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
805 v29 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
806 v23 = 0xFF3C1Eu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
807 goto LABEL_8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
808 case 15:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
809 v29 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
810 v23 = 0x62D0u;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
811 goto LABEL_8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
812 case 16:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
813 v30 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
814 v24 = 0x62D0u;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
815 goto LABEL_32;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
816 case 20:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
817 v29 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
818 v23 = 0xAB450u;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
819 goto LABEL_8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
820 case 21:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
821 v30 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
822 v24 = 0xAB450u;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
823 goto LABEL_32;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
824 case 25:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
825 v29 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
826 v23 = 0xC8C805u;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
827 goto LABEL_8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
828 case 26:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
829 v30 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
830 v24 = 0xC8C805u;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
831 goto LABEL_32;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
832 case 35:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
833 v29 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
834 v23 = 0xFFFFFFu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
835 goto LABEL_8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
836 case 36:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
837 v30 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
838 goto LABEL_154;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
839 case 40:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
840 goto LABEL_17;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
841 case 11:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
842 goto LABEL_31;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
843 case 6:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
844 goto LABEL_115;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
845 case 41:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
846 goto LABEL_164;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
847 default:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
848 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
849 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
850 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
851 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
852 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
853 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
854 if ( result <= 4051 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
855 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
856 if ( result != 4051 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
857 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
858 if ( result <= 2031 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
859 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
860 if ( result != 2031 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
861 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
862 if ( result <= 1051 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
863 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
864 if ( result == 1051 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
865 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
866 result = AddMobileLight(a2, 0xFF3C1Eu, 256);// fireball hit
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
867 if ( pRenderer->pRenderD3D )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
868 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
869 result = a2->field_58 & 7;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
870 if ( result != 3 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
871 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
872 if ( result != 2 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
873 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
874 result = (bool)&v2->field_204;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
875 v6 = v2->field_204;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
876 if ( v6 != 4 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
877 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
878 *(int *)result = v6 + 1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
879 _4A7688_fireball_collision_particle(a2);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
880 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
881 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
882 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
883 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
884 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
885 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
886 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
887 if ( result <= 600 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
888 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
889 if ( result == 600 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
890 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
891 result = AddMobileLight(a2, 0xFF3C1Eu, 256);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
892 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
893 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
894 result -= 550;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
895 if ( !result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
896 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
897 LABEL_34:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
898 LOBYTE(result) = 1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
899 return result;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
900 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
901 v4 = result - 1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
902 if ( v4 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
903 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
904 result = v4 - 4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
905 if ( !result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
906 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
907 --result;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
908 if ( !result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
909 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
910 v31 = 256;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
911 v25 = 0xFF0000u;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
912 LABEL_144:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
913 result = AddMobileLight(a2, v25, v31);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
914 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
915 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
916 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
917 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
918 goto LABEL_31;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
919 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
920 if ( result < 811 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
921 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
922 if ( result <= 814 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
923 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
924 if ( result == 1010 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
925 goto LABEL_41; // fire strike
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
926 if ( result != 1011 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
927 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
928 if ( result != 1050 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
929 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
930 LABEL_41:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
931 diffuse = 0xFF3C1Eu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
932 LABEL_42:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
933 _4A73AA_hanging_trace_particles___like_fire_strike_ice_blast_etc(
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
934 a2,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
935 diffuse,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
936 this->uTextureID_effpar1);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
937 LABEL_43:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
938 v31 = 256;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
939 LABEL_44:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
940 v25 = diffuse;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
941 goto LABEL_144;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
942 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
943 v32 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
944 diffuse = 0xFF3C1Eu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
945 LABEL_146:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
946 _4A75CC_single_spell_collision_particle(a2, diffuse, v32);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
947 goto LABEL_43;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
948 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
949 if ( result <= 1081 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
950 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
951 if ( result == 1081 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
952 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
953 diffuse = 0xFF3C1Eu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
954 _4A7A66_miltiple_spell_collision_partifles___like_after_sparks_or_lightning(
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
955 a2,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
956 0xFF3C1Eu,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
957 this->uTextureID_effpar1,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
958 300.0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
959 _4A7A66_miltiple_spell_collision_partifles___like_after_sparks_or_lightning(
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
960 a2,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
961 0xFF3C1Eu,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
962 v2->uTextureID_effpar1,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
963 250.0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
964 v33 = 200.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
965 v26 = v2->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
966 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
967 else
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
968 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
969 result -= 1060;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
970 if ( !result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
971 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
972 v7 = result - 1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
973 if ( v7 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
974 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
975 v8 = v7 - 9;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
976 if ( !v8 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
977 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
978 LABEL_31:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
979 v30 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
980 v24 = 0xFF3C1Eu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
981 goto LABEL_32;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
982 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
983 result = v8 - 10;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
984 v9 = result == 0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
985 LABEL_129:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
986 if ( v9 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
987 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
988 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
989 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
990 diffuse = 0xFF3C1Eu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
991 v33 = 250.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
992 v26 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
993 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
994 LABEL_84:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
995 _4A7A66_miltiple_spell_collision_partifles___like_after_sparks_or_lightning(a2, diffuse, v26, v33);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
996 goto LABEL_43;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
997 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
998 v10 = result - 1090;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
999 if ( v10 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1000 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1001 result = v10 - 10;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1002 if ( !result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1003 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1004 v11 = result - 1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1005 if ( !v11 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1006 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1007 diffuse = 0xFF3C1Eu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1008 _4A75CC_single_spell_collision_particle(a2, 0xFF3C1Eu, this->uTextureID_effpar1);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1009 v32 = v2->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1010 goto LABEL_146;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1011 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1012 result = v11 - 929;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1013 if ( result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1014 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1015 LABEL_63:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1016 if ( !pRenderer->pRenderD3D )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1017 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1018 _4A78AE_sparks_spell(a2);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1019 v31 = 128;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1020 v25 = 0x64640Fu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1021 goto LABEL_144;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1022 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1023 v34 = 250.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1024 v27 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1025 v21 = 0xFF3C1Eu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1026 LABEL_117:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1027 _4A7A66_miltiple_spell_collision_partifles___like_after_sparks_or_lightning(a2, v21, v27, v34);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1028 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1029 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1030 goto LABEL_67;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1031 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1032 if ( result <= 3060 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1033 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1034 if ( result == 3060 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1035 goto LABEL_171; // acid burst
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1036 if ( result <= 2101 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1037 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1038 if ( result == 2101 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1039 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1040 v33 = 200.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1041 v26 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1042 goto LABEL_83;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1043 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1044 if ( result != 2060 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1045 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1046 if ( result != 2061 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1047 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1048 if ( result <= 2079 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1049 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1050 if ( result <= 2081 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1051 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1052 if ( pRenderer->pRenderD3D )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1053 _4A77FD_some_stuff_d3d(a2);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1054 else
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1055 _4A80DC_some_stuff_sw(a2);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1056 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1057 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1058 v9 = result == 2100;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1059 goto LABEL_129;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1060 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1061 LABEL_67:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1062 v33 = 200.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1063 v26 = this->uTextureID_effpar2;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1064 LABEL_83:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1065 diffuse = (unsigned int)&pDecalBuilder->std__vector_pDecals[557].pVertices[57].vWorldViewPosition.y;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1066 goto LABEL_84;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1067 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1068 if ( !pRenderer->pRenderD3D )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1069 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1070 *(int *)pContainer = *(int *)"sp18h1";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1071 *(short *)&pContainer[4] = *(short *)"h1";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1072 pContainer[6] = aSp18h1[6];
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1073 pRnd->SetRange(1, 6);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1074 pContainer[5] = pRnd->GetInRange() + '0';
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1075 v35 = pBitmaps_LOD->LoadTexture(pContainer, TEXTURE_DEFAULT);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1076 v28 = 100;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1077 v22 = a2;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1078 LABEL_157:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1079 AddProjectile(v22, v28, v35);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1080 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1081 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1082 v12 = result - 3010;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1083 if ( !v12 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1084 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1085 LABEL_171:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1086 diffuse = 0xAB450u;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1087 goto LABEL_42;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1088 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1089 v13 = v12 - 1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1090 if ( !v13 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1091 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1092 v32 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1093 diffuse = 0xAB450u;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1094 goto LABEL_146;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1095 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1096 result = v13 - 19;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1097 if ( !result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1098 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1099 --result;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1100 if ( result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1101 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1102 LABEL_89:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1103 v32 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1104 diffuse = 0x9EB9F1u;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1105 goto LABEL_146;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1106 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1107 if ( result > 4000 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1108 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1109 result -= 4030;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1110 if ( !result || (--result, !result) )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1111 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1112 result -= 19;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1113 v9 = result == 0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1114 goto LABEL_129;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1115 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1116 if ( result == 4000 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1117 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1118 if ( !pRenderer->pRenderD3D )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1119 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1120 _4A7C07(a2);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1121 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1122 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1123 result -= 3061;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1124 if ( !result || (result -= 29) == 0 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1125 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1126 v14 = result - 1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1127 if ( !v14 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1128 goto LABEL_89;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1129 result = v14 - 1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1130 if ( result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1131 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1132 v29 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1133 v23 = 0x9EB9F1u;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1134 LABEL_8:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1135 _4A73AA_hanging_trace_particles___like_fire_strike_ice_blast_etc(a2, v23, v29);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1136 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1137 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1138 goto LABEL_122;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1139 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1140 if ( result <= 7090 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1141 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1142 if ( result == 7090 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1143 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1144 if ( result > 6030 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1145 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1146 if ( result > 6091 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1147 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1148 result -= 6100;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1149 if ( !result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1150 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1151 result -= 930;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1152 if ( result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1153 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1154 --result;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1155 if ( result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1156 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1157 v30 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1158 v24 = 0xF00000u;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1159 goto LABEL_32;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1160 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1161 goto LABEL_63;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1162 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1163 if ( result != 6091 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1164 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1165 result -= 6040;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1166 if ( !result || (result -= 20) == 0 || (result -= 10) == 0 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1167 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1168 result -= 20;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1169 v9 = result == 0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1170 goto LABEL_129;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1171 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1172 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1173 else
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1174 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1175 if ( result == 6030 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1176 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1177 if ( result <= 4091 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1178 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1179 if ( result != 4091 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1180 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1181 result -= 4070;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1182 if ( !result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1183 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1184 v15 = result - 1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1185 if ( v15 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1186 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1187 result = v15 - 9;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1188 if ( !result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1189 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1190 result -= 10;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1191 if ( !result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1192 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1193 _4A73AA_hanging_trace_particles___like_fire_strike_ice_blast_etc(
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1194 a2,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1195 0x7E7E7Eu,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1196 this->uTextureID_effpar1);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1197 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1198 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1199 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1200 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1201 LABEL_115:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1202 v30 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1203 v24 = 0x5C310Eu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1204 LABEL_32:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1205 _4A75CC_single_spell_collision_particle(a2, v24, v30);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1206 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1207 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1208 v34 = 200.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1209 v27 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1210 v21 = 0x7E7E7Eu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1211 goto LABEL_117;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1212 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1213 v16 = result - 4092;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1214 if ( !v16 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1215 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1216 LABEL_17:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1217 v29 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1218 v23 = 0x7E7E7Eu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1219 goto LABEL_8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1220 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1221 result = v16 - 8;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1222 if ( !result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1223 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1224 result -= 1910;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1225 if ( !result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1226 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1227 --result;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1228 if ( result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1229 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1230 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1231 LABEL_122:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1232 _4A7948_mind_blast_after_effect(a2);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1233 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1234 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1235 if ( result <= 9000 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1236 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1237 if ( result == 9000 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1238 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1239 if ( result <= 8030 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1240 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1241 if ( result == 8030 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1242 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1243 v17 = result - 7091;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1244 if ( v17 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1245 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1246 v18 = v17 - 909;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1247 if ( !v18 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1248 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1249 diffuse = 0xFFFFFFu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1250 _4A73AA_hanging_trace_particles___like_fire_strike_ice_blast_etc(
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1251 a2,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1252 0xFFFFFFu,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1253 this->uTextureID_effpar3);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1254 v31 = 128;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1255 goto LABEL_44;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1256 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1257 v19 = v18 - 1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1258 if ( v19 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1259 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1260 result = v19 - 9;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1261 if ( !result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1262 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1263 v31 = 64;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1264 v25 = 0xFFFFFFu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1265 goto LABEL_144;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1266 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1267 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1268 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1269 v32 = this->uTextureID_effpar2;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1270 diffuse = 0xFFFFFFu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1271 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1272 else
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1273 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1274 v32 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1275 diffuse = 0xF00000u;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1276 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1277 goto LABEL_146;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1278 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1279 result -= 8040;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1280 if ( !result || (result -= 20) == 0 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1281 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1282 v20 = result - 30;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1283 if ( v20 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1284 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1285 result = v20 - 1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1286 if ( result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1287 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1288 v30 = this->uTextureID_effpar3;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1289 LABEL_154:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1290 v24 = 16777215;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1291 goto LABEL_32;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1292 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1293 result = AddMobileLight(a2, 0xFFFFFFu, 128);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1294 if ( !pRenderer->pRenderD3D )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1295 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1296 v35 = -1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1297 v28 = 100;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1298 v22 = a2;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1299 goto LABEL_157;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1300 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1301 if ( result > 9050 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1302 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1303 result -= 9070;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1304 if ( !result || (result -= 10) == 0 || (--result, !result) )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1305 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1306 goto LABEL_168;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1307 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1308 if ( result == 9050 || (result -= 9010) == 0 || (result -= 20) == 0 || (result -= 10) == 0 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1309 goto LABEL_34;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1310 --result;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1311 if ( !result )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1312 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1313 LABEL_164:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1314 v30 = this->uTextureID_effpar1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1315 v24 = 0x7E7E7Eu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1316 goto LABEL_32;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1317 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1318 LABEL_168:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1319 LOBYTE(result) = 0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1320 return result;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1321 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1322
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1323 //----- (004A89BD) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1324 int stru6::SetPlayerBuffAnim(unsigned __int16 uSpellID, unsigned __int16 uPlayerID)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1325 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1326 stru6 *v3; // edi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1327 PlayerBuffAnim *v4; // esi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1328 int result; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1329 const char *v6; // [sp-4h] [bp-10h]@2
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1330
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1331 v3 = this;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1332 v4 = (PlayerBuffAnim *)((char *)this + 16 * (signed __int16)uPlayerID);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1333 v4[32].uSpellIconID_ = 0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1334 v4[32].uSpellID = uSpellID;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1335 result = (signed __int16)uSpellID - 3;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1336 switch ( uSpellID )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1337 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1338 case (SPELL_WATER_PROTECTION_FROM_WATER|0x80):
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1339 v6 = "zapp";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1340 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1341 case SPELL_AIR_FEATHER_FALL:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1342 case SPELL_SPIRIT_DETECT_LIFE:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1343 case SPELL_SPIRIT_DOOM:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1344 case 0x96u:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1345 v6 = "spboost1";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1346 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1347 case SPELL_AIR_SHIELD|0x2:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1348 case SPELL_WATER_WATER_WALK:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1349 case SPELL_SPIRIT_PRESERVE:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1350 case 0x97u:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1351 v6 = "spboost2";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1352 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1353 case SPELL_BODY_CURE_WEAKNESS|0x10:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1354 case SPELL_BODY_FIRST_AID|SPELL_AIR_SHIELD:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1355 case 0x56u:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1356 case SPELL_BODY_CURE_POISON|0x10:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1357 case 0x98u:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1358 v6 = "spboost3";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1359 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1360 case (SPELL_AIR_SHIELD|0x20):
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1361 case SPELL_MIND_REMOVE_FEAR:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1362 case SPELL_BODY_CURE_WEAKNESS:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1363 v6 = "spheal1";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1364 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1365 case SPELL_SPIRIT_PRESERVE|0x4:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1366 case SPELL_MIND_CURE_PARALYSIS:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1367 case 0x40u:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1368 case SPELL_BODY_FIRST_AID:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1369 case SPELL_BODY_CURE_POISON:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1370 case SPELL_BODY_CURE_DISEASE:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1371 case 0x60u:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1372 v6 = "spheal2";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1373 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1374 case SPELL_BODY_HAMMERHANDS|0x4:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1375 case SPELL_BODY_CURE_WEAKNESS|0x20:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1376 v6 = "spheal3";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1377 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1378 case SPELL_FIRE_PROTECTION_FROM_FIRE:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1379 case SPELL_FIRE_FIRE_RING:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1380 v6 = "spell03";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1381 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1382 case SPELL_FIRE_HASTE:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1383 v6 = "spell05";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1384 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1385 case SPELL_AIR_PROTECTION_FROM_AIR:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1386 v6 = "spell14";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1387 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1388 case SPELL_AIR_SHIELD:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1389 v6 = "spell17";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1390 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1391 case SPELL_WATER_PROTECTION_FROM_WATER:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1392 v6 = "spell25";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1393 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1394 case SPELL_EARTH_PROTECTION_FROM_EARTH:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1395 v6 = "spell36";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1396 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1397 case SPELL_EARTH_STONESKIN:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1398 v6 = "spell38";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1399 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1400 case SPELL_SPIRIT_BLESS:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1401 v6 = "spell46";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1402 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1403 case SPELL_SPIRIT_HEROISM:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1404 v6 = "spell51";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1405 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1406 case SPELL_SPIRIT_HEROISM|0x4:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1407 v6 = "spell55";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1408 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1409 case SPELL_MIND_PROTECTION_FROM_MIND:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1410 v6 = "spell58";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1411 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1412 case SPELL_BODY_FIRST_AID|0x1:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1413 v6 = "spell69";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1414 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1415 case SPELL_BODY_FIRST_AID|SPELL_FIRE_PROTECTION_FROM_FIRE:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1416 v6 = "spell71";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1417 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1418 case SPELL_BODY_HAMMERHANDS:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1419 v6 = "spell73";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1420 goto LABEL_24;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1421 case SPELL_BODY_PROTECTION_FROM_MAGIC:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1422 v6 = "spell75";
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1423 LABEL_24:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1424 result = pIconsFrameTable->FindIcon(v6);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1425 v4[33].uSpellIconID = result;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1426 break;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1427 default:
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1428 v4[32].uSpellID = 0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1429 break;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1430 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1431 if ( v4[32].uSpellID )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1432 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1433 result = 8 * pIconsFrameTable->pIcons[v4[33].uSpellIconID].uAnimLength;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1434 v3->array_0[(signed __int16)uPlayerID + 33].uSpellAnimLength = result;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1435 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1436 return result;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1437 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1438
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1439 //----- (004A8BDF) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1440 void stru6::FadeScreen__like_Turn_Undead_and_mb_Armageddon(unsigned int uDiffuseColor, unsigned int uFadeTime)
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1441 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1442 this->uFadeTime = uFadeTime;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1443 this->uFadeTime2 = uFadeTime;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1444 this->uFadeColor = uDiffuseColor;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1445 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1446
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1447 //----- (004A8BFC) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1448 int stru6::_4A8BFC()
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1449 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1450 stru6 *v1; // esi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1451 int result; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1452
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1453 v1 = this;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1454 result = 8
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1455 * pSpriteFrameTable->pSpriteSFrames[pSpriteFrameTable->FastFindSprite("spell84")].uAnimLength;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1456 v1->uAnimLength = result;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1457 return result;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1458 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1459
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1460 //----- (004A8C27) --------------------------------------------------------
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1461 void stru6::RenderSpecialEffects()
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1462 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1463 double v4; // st7@4
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1464 double v5; // st6@4
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1465 double v6; // st7@4
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1466 float v7; // ST14_4@6
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1467 unsigned int v8; // ST14_4@8
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1468 unsigned int v9; // eax@8
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1469 SpriteFrame *v10; // eax@8
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1470 int v11; // edi@8
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1471 double v12; // st7@9
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1472 double v13; // st7@9
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1473 double v14; // st7@9
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1474 double v15; // st6@9
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1475 HRESULT v16; // eax@9
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1476 HRESULT v17; // eax@9
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1477 signed __int64 v18; // qtt@10
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1478 const char *v19; // [sp+4h] [bp-E8h]@0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1479 int v20; // [sp+8h] [bp-E4h]@0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1480 unsigned int v21; // [sp+Ch] [bp-E0h]@0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1481 RenderBillboardTransform_local0 vsr; // [sp+10h] [bp-DCh]@10
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1482 RenderVertexD3D3 vd3d[4]; // [sp+60h] [bp-8Ch]@9
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1483 int v24; // [sp+E0h] [bp-Ch]@10
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1484 SpriteFrame *v70; // [sp+E4h] [bp-8h]@8
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1485 unsigned int v26; // [sp+E8h] [bp-4h]@3
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1486
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1487 if (uNumProjectiles)
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1488 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1489 DrawProjectiles();
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1490 uNumProjectiles = 0;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1491 }
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1492
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1493 field_204 = 0;
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1494 v26 = uFadeTime;
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1495 if ( v26 > 0 )
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1496 {
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1497 v4 = (double)(signed int)v26 / (double)uFadeTime2;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1498 v5 = 1.0 - v4 * v4;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1499 v6 = v5;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1500 if ( v5 > 0.9 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1501 v6 = 1.0 - (v5 - 0.9) * 10.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1502 v7 = v6;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1503 pRenderer->_4A52F1(uFadeColor, v7);
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1504 uFadeTime -= pEventTimer->uTimeElapsed;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1505 }
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1506
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1507 if (uAnimLength > 0)
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1508 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1509 v8 = 8
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1510 * pSpriteFrameTable->pSpriteSFrames[pSpriteFrameTable->FastFindSprite("spell84")].uAnimLength
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1511 - uAnimLength;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1512 v9 = pSpriteFrameTable->FastFindSprite("spell84");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1513 v10 = pSpriteFrameTable->GetFrame(v9, v8);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1514 v11 = v10->pHwSpriteIDs[0];
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1515 v70 = v10;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1516 uAnimLength -= pEventTimer->uTimeElapsed;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1517 if ( pRenderer->pRenderD3D )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1518 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1519 v12 = (double)(signed int)pViewport->uViewportX;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1520 vd3d[0].pos.x = v12;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1521 vd3d[1].pos.x = v12;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1522 v13 = (double)(signed int)pViewport->uViewportZ;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1523 v26 = pViewport->uViewportW + 1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1524 vd3d[0].diffuse = 0x7F7F7Fu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1525 vd3d[1].diffuse = 0x7F7F7Fu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1526 vd3d[2].pos.x = v13;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1527 vd3d[3].pos.x = v13;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1528 v14 = (double)(signed int)pViewport->uViewportY;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1529 vd3d[2].diffuse = 0x7F7F7Fu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1530 vd3d[3].diffuse = 0x7F7F7Fu;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1531 vd3d[0].specular = 0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1532 vd3d[1].specular = 0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1533 vd3d[0].pos.y = v14;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1534 v15 = (double)(pViewport->uViewportW + 1);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1535 vd3d[2].specular = 0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1536 vd3d[3].specular = 0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1537 vd3d[1].pos.y = v15;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1538 vd3d[2].pos.y = v15;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1539 vd3d[3].pos.y = v14;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1540 vd3d[0].pos.z = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1541 vd3d[1].pos.z = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1542 vd3d[2].pos.z = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1543 vd3d[3].pos.z = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1544 vd3d[0].rhw = 1.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1545 vd3d[1].rhw = 1.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1546 vd3d[2].rhw = 1.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1547 vd3d[3].rhw = 1.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1548 vd3d[0].texcoord.x = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1549 vd3d[1].texcoord.x = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1550 vd3d[2].texcoord.x = 1.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1551 vd3d[3].texcoord.x = 1.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1552 vd3d[0].texcoord.y = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1553 vd3d[1].texcoord.y = 1.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1554 vd3d[2].texcoord.y = 1.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1555 vd3d[3].texcoord.y = 0.0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1556 pRenderer->pRenderD3D->pDevice->SetTexture(
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1557 0,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1558 pSprites_LOD->pHardwareSprites[v11].pTexture);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1559 pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_FOGENABLE, 0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1560 pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_ALPHABLENDENABLE, 1u);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1561 pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_ZWRITEENABLE, 0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1562 pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_SRCBLEND, 2u);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1563 pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_DESTBLEND, 2u);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1564 pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_DITHERENABLE, 0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1565 pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_ZFUNC, 8u);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1566 pRenderer->pRenderD3D->pDevice->DrawPrimitive(
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1567 D3DPT_TRIANGLEFAN,
68
fdacbc653945 BLV render: first image
Nomad
parents: 59
diff changeset
1568 D3DFVF_XYZRHW | D3DFVF_DIFFUSE | D3DFVF_SPECULAR | D3DFVF_TEX1,
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1569 vd3d,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1570 4,
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1571 28);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1572 ErrD3D(pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_SRCBLEND, 2),
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1573 "E:\\WORK\\MSDEV\\MM7\\MM7\\Code\\seffects.cpp:1348");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1574 ErrD3D(pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_DESTBLEND, 1),
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1575 "E:\\WORK\\MSDEV\\MM7\\MM7\\Code\\seffects.cpp:1349");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1576 pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_ALPHABLENDENABLE, 0);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1577 pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_ZWRITEENABLE, true);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1578 pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_DITHERENABLE, true);
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1579 pRenderer->pRenderD3D->pDevice->SetRenderState(D3DRENDERSTATE_ZFUNC, 2);
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1580 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1581 else
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1582 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1583 vsr.pTarget = pRenderer->pTargetSurface;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1584 vsr.uParentBillboardID = -1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1585 vsr.pTargetZ = pRenderer->pActiveZBuffer;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1586 vsr.uScreenSpaceX = (signed int)(pViewport->uViewportZ - pViewport->uViewportX) / 2;
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1587 vsr.uScreenSpaceY = pViewport->uViewportW;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1588 v24 = 16777216;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1589 LODWORD(v18) = 0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1590 HIDWORD(v18) = (signed __int16)(LOWORD(pViewport->uViewportZ) - LOWORD(pViewport->uViewportX));
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1591 vsr.field_10 = v18 / 16777216;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1592 LODWORD(v18) = 0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1593 HIDWORD(v18) = (signed __int16)(LOWORD(pViewport->uViewportW) - LOWORD(pViewport->uViewportY));
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1594 v26 = v18 / 16777216;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1595 vsr.field_14 = v18 / 16777216;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1596 vsr.pPalette = PaletteManager::Get_Dark_or_Red_LUT(v70->uPaletteIndex, 0, 1);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1597 vsr.uTargetPitch = pRenderer->uTargetSurfacePitch;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1598 vsr.uParentBillboardID = -1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1599 vsr.uViewportX = pViewport->uViewportX;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1600 vsr.uViewportZ = pViewport->uViewportZ;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1601 vsr.uViewportY = pViewport->uViewportY;
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1602 vsr.sZValue = 0;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1603 vsr.uViewportW = pViewport->uViewportW;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1604 vsr.uFlags = 0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1605 if ( v11 >= 0 )
45
bcc051713d20 BLV render & seffects
Nomad
parents: 23
diff changeset
1606 pSprites_LOD->pSpriteHeaders[v11]._4ACC38(&vsr, 1);
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1607 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1608 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1609 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1610
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1611 //----- (004A902A) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1612 void stru6::DrawPlayerBuffAnims()
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1613 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1614 __int16 *v1; // edi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1615 char *v2; // esi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1616 unsigned int v3; // eax@3
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1617 unsigned __int8 v4; // zf@3
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1618 char v5; // sf@3
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1619 unsigned __int8 v6; // of@3
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1620 IconFrame *v7; // eax@4
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1621
23
509744251c8e Player-related members
Nomad
parents: 0
diff changeset
1622 uint _it = 0;
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1623 v1 = pPlayerPortraitsXCoords_For_PlayerBuffAnimsDrawing;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1624 v2 = (char *)&this->pPlayerBuffs[0].uSpellIconID;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1625 do
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1626 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1627 if ( *((short *)v2 - 2) )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1628 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1629 v3 = pEventTimer->uTimeElapsed + *(int *)v2;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1630 v6 = __OFSUB__(v3, *((int *)v2 + 1));
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1631 v4 = v3 == *((int *)v2 + 1);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1632 v5 = ((v3 - *((int *)v2 + 1)) & 0x80000000u) != 0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1633 *(int *)v2 = v3;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1634 if ( (unsigned __int8)(v5 ^ v6) | v4 )
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1635 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1636 v7 = pIconsFrameTable->GetFrame(*((int *)v2 + 2), v3);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1637 pRenderer->DrawTextureTransparent(*v1, 0x181u, &pIcons_LOD->pTextures[v7->uTextureID]);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1638 pOtherOverlayList->field_3EC = 1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1639 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1640 else
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1641 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1642 *((short *)v2 - 2) = 0;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1643 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1644 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1645 v2 += 16;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1646 ++v1;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1647 }
23
509744251c8e Player-related members
Nomad
parents: 0
diff changeset
1648 //while ( (signed int)v1 < (signed int)pBaseHealthByClass );
509744251c8e Player-related members
Nomad
parents: 0
diff changeset
1649 while (++_it != 4);
0
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1650 }
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1651
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1652 //----- (004A90A0) --------------------------------------------------------
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1653 void stru6::LoadAnimations()
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1654 {
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1655 stru6 *v1; // esi@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1656 unsigned int v2; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1657 unsigned int v3; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1658 unsigned int v4; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1659 unsigned int v5; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1660 unsigned int v6; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1661 unsigned int v7; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1662 unsigned int v8; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1663 unsigned int v9; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1664 unsigned int v10; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1665 unsigned int v11; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1666 unsigned int v12; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1667 unsigned int v13; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1668 unsigned int v14; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1669 unsigned int v15; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1670 unsigned int v16; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1671 unsigned int v17; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1672 unsigned int v18; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1673 unsigned int v19; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1674 unsigned int v20; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1675 unsigned int v21; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1676 unsigned int v22; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1677 unsigned int v23; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1678 unsigned int v24; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1679 unsigned int v25; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1680 unsigned int v26; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1681 unsigned int v27; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1682 unsigned int v28; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1683 unsigned int v29; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1684 unsigned int v30; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1685 unsigned int v31; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1686 unsigned int v32; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1687 unsigned int v33; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1688 unsigned int v34; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1689 unsigned int v35; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1690 unsigned int v36; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1691 unsigned int v37; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1692 unsigned int v38; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1693 unsigned int v39; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1694 unsigned int v40; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1695 unsigned int v41; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1696 unsigned int v42; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1697 unsigned int v43; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1698 unsigned int v44; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1699 unsigned int v45; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1700 unsigned int v46; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1701 unsigned int v47; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1702 unsigned int v48; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1703 unsigned int v49; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1704 unsigned int v50; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1705 unsigned int v51; // eax@1
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1706
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1707 v1 = this;
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1708 uTextureID_effpar1 = pBitmaps_LOD->LoadTexture("effpar01", TEXTURE_DEFAULT);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1709 uTextureID_effpar2 = pBitmaps_LOD->LoadTexture("effpar02", TEXTURE_DEFAULT);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1710 uTextureID_effpar3 = pBitmaps_LOD->LoadTexture("effpar03", TEXTURE_DEFAULT);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1711 uSpriteID_sp57c = pSprites_LOD->LoadSprite("sp57c", 6);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1712 v2 = pIconsFrameTable->FindIcon("zapp");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1713 pIconsFrameTable->InitializeAnimation(v2);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1714 v3 = pIconsFrameTable->FindIcon("spheal1");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1715 pIconsFrameTable->InitializeAnimation(v3);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1716 v4 = pIconsFrameTable->FindIcon("spheal2");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1717 pIconsFrameTable->InitializeAnimation(v4);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1718 v5 = pIconsFrameTable->FindIcon("spheal3");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1719 pIconsFrameTable->InitializeAnimation(v5);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1720 v6 = pIconsFrameTable->FindIcon("spboost1");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1721 pIconsFrameTable->InitializeAnimation(v6);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1722 v7 = pIconsFrameTable->FindIcon("spboost2");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1723 pIconsFrameTable->InitializeAnimation(v7);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1724 v8 = pIconsFrameTable->FindIcon("spboost3");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1725 pIconsFrameTable->InitializeAnimation(v8);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1726 v9 = pIconsFrameTable->FindIcon("spell03");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1727 pIconsFrameTable->InitializeAnimation(v9);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1728 v10 = pIconsFrameTable->FindIcon("spell05");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1729 pIconsFrameTable->InitializeAnimation(v10);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1730 v11 = pIconsFrameTable->FindIcon("spell14");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1731 pIconsFrameTable->InitializeAnimation(v11);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1732 v12 = pIconsFrameTable->FindIcon("spell17");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1733 pIconsFrameTable->InitializeAnimation(v12);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1734 v13 = pIconsFrameTable->FindIcon("spell21");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1735 pIconsFrameTable->InitializeAnimation(v13);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1736 v14 = pIconsFrameTable->FindIcon("spell25");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1737 pIconsFrameTable->InitializeAnimation(v14);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1738 v15 = pIconsFrameTable->FindIcon("spell27");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1739 pIconsFrameTable->InitializeAnimation(v15);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1740 v16 = pIconsFrameTable->FindIcon("spell36");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1741 pIconsFrameTable->InitializeAnimation(v16);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1742 v17 = pIconsFrameTable->FindIcon("spell38");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1743 pIconsFrameTable->InitializeAnimation(v17);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1744 v18 = pIconsFrameTable->FindIcon("spell46");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1745 pIconsFrameTable->InitializeAnimation(v18);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1746 v19 = pIconsFrameTable->FindIcon("spell51");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1747 pIconsFrameTable->InitializeAnimation(v19);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1748 v20 = pIconsFrameTable->FindIcon("spell55");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1749 pIconsFrameTable->InitializeAnimation(v20);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1750 v21 = pIconsFrameTable->FindIcon("spell58");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1751 pIconsFrameTable->InitializeAnimation(v21);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1752 v22 = pIconsFrameTable->FindIcon("spell69");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1753 pIconsFrameTable->InitializeAnimation(v22);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1754 v23 = pIconsFrameTable->FindIcon("spell71");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1755 pIconsFrameTable->InitializeAnimation(v23);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1756 v24 = pIconsFrameTable->FindIcon("spell73");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1757 pIconsFrameTable->InitializeAnimation(v24);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1758 v25 = pIconsFrameTable->FindIcon("spell75");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1759 pIconsFrameTable->InitializeAnimation(v25);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1760 v26 = pIconsFrameTable->FindIcon("spell96");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1761 pIconsFrameTable->InitializeAnimation(v26);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1762
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1763 v27 = pSpriteFrameTable->FastFindSprite("spell01");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1764 pSpriteFrameTable->InitializeSprite(v27);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1765 v28 = pSpriteFrameTable->FastFindSprite("spell02");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1766 pSpriteFrameTable->InitializeSprite(v28);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1767 v29 = pSpriteFrameTable->FastFindSprite("spell03");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1768 pSpriteFrameTable->InitializeSprite(v29);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1769 v30 = pSpriteFrameTable->FastFindSprite("spell09");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1770 pSpriteFrameTable->InitializeSprite(v30);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1771 v31 = pSpriteFrameTable->FastFindSprite("spell11");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1772 pSpriteFrameTable->InitializeSprite(v31);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1773 v32 = pSpriteFrameTable->FastFindSprite("spell18");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1774 pSpriteFrameTable->InitializeSprite(v32);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1775 v33 = pSpriteFrameTable->FastFindSprite("spell22");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1776 pSpriteFrameTable->InitializeSprite(v33);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1777 v34 = pSpriteFrameTable->FastFindSprite("spell26");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1778 pSpriteFrameTable->InitializeSprite(v34);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1779 v35 = pSpriteFrameTable->FastFindSprite("spell29");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1780 pSpriteFrameTable->InitializeSprite(v35);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1781 v36 = pSpriteFrameTable->FastFindSprite("spell39");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1782 pSpriteFrameTable->InitializeSprite(v36);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1783 v37 = pSpriteFrameTable->FastFindSprite("spell39c");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1784 pSpriteFrameTable->InitializeSprite(v37);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1785 v38 = pSpriteFrameTable->FastFindSprite("spell41");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1786 pSpriteFrameTable->InitializeSprite(v38);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1787 v39 = pSpriteFrameTable->FastFindSprite("spell57c");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1788 pSpriteFrameTable->InitializeSprite(v39);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1789 v40 = pSpriteFrameTable->FastFindSprite("spell62");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1790 pSpriteFrameTable->InitializeSprite(v40);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1791 v41 = pSpriteFrameTable->FastFindSprite("spell65");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1792 pSpriteFrameTable->InitializeSprite(v41);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1793 v42 = pSpriteFrameTable->FastFindSprite("spell66");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1794 pSpriteFrameTable->InitializeSprite(v42);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1795 v43 = pSpriteFrameTable->FastFindSprite("spell70");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1796 pSpriteFrameTable->InitializeSprite(v43);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1797 v44 = pSpriteFrameTable->FastFindSprite("spell76");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1798 pSpriteFrameTable->InitializeSprite(v44);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1799 v45 = pSpriteFrameTable->FastFindSprite("spell84");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1800 pSpriteFrameTable->InitializeSprite(v45);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1801 v46 = pSpriteFrameTable->FastFindSprite("spell90");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1802 pSpriteFrameTable->InitializeSprite(v46);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1803 v47 = pSpriteFrameTable->FastFindSprite("spell92");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1804 pSpriteFrameTable->InitializeSprite(v47);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1805 v48 = pSpriteFrameTable->FastFindSprite("spell93");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1806 pSpriteFrameTable->InitializeSprite(v48);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1807 v49 = pSpriteFrameTable->FastFindSprite("spell97");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1808 pSpriteFrameTable->InitializeSprite(v49);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1809 v50 = pSpriteFrameTable->FastFindSprite("spell97c");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1810 pSpriteFrameTable->InitializeSprite(v50);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1811 v51 = pSpriteFrameTable->FastFindSprite("spell97c");
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1812 pSpriteFrameTable->InitializeSprite(v51);
8b8875f5b359 Initial commit
Nomad
parents:
diff changeset
1813 }