Debian Codegraph @

src/varz.c

raw symbols SCIP
1 /*
2 * OpenTyrian: A modern cross-platform port of Tyrian
3 * Copyright (C) 2007-2009 The OpenTyrian Development Team
4 *
5 * This program is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU General Public License
7 * as published by the Free Software Foundation; either version 2
8 * of the License, or (at your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
18 */
19 #ifdef TARGET_UNIXcxx . . $ `<built-in>:411:9`!
20 #include <unistd.h>
21 #endif
22
23 #include "varz.h"cxx . . $ `<file>/src/varz.h`/
24
25 #include "config.h"cxx . . $ `<file>/src/config.h`/
26 #include "editship.h"cxx . . $ `<file>/src/editship.h`/
27 #include "episodes.h"cxx . . $ `<file>/src/episodes.h`/
28 #include "joystick.h"cxx . . $ `<file>/src/joystick.h`/
29 #include "lds_play.h"cxx . . $ `<file>/src/lds_play.h`/
30 #include "loudness.h"cxx . . $ `<file>/src/loudness.h`/
31 #include "mainint.h"cxx . . $ `<file>/src/mainint.h`/
32 #include "mouse.h"cxx . . $ `<file>/src/mouse.h`/
33 #include "mtrand.h"cxx . . $ `<file>/src/mtrand.h`/
34 #include "network.h"cxx . . $ `<file>/src/network.h`/
35 #include "nortsong.h"cxx . . $ `<file>/src/nortsong.h`/
36 #include "nortvars.h"cxx . . $ `<file>/src/nortvars.h`/
37 #include "opentyr.h"cxx . . $ `<file>/src/opentyr.h`/
38 #include "shots.h"cxx . . $ `<file>/src/shots.h`/
39 #include "sprite.h"cxx . . $ `<file>/src/sprite.h`/
40 #include "vga256d.h"cxx . . $ `<file>/src/vga256d.h`/
41 #include "video.h"cxx . . $ `<file>/src/video.h`/
42
43 JE_integercxx . . $ JE_integer# tempDatcxx . . $ tempDat., tempDat2cxx . . $ tempDat2., tempDat3cxx . . $ tempDat3.;
44
45 const JE_bytecxx . . $ JE_byte# SANextShipcxx . . $ SANextShip.[SAcxx . . $ `src/varz.h:29:9`! + 2] /* [0..SA + 1] */ = { 3, 9, 6, 2, 5, 1, 4, 3, 7 }; // 0 -> 3 -> 2 -> 6 -> 4 -> 5 -> 1 -> 9 -> 7
46 const JE_wordcxx . . $ JE_word# SASpecialWeaponcxx . . $ SASpecialWeapon.[SAcxx . . $ `src/varz.h:29:9`!] /* [1..SA] */ = { 7, 8, 9, 10, 11, 12, 13 };
47 const JE_wordcxx . . $ JE_word# SASpecialWeaponBcxx . . $ SASpecialWeaponB.[SAcxx . . $ `src/varz.h:29:9`!] /* [1..SA] */ = {37, 6, 15, 40, 16, 14, 41 };
48 const JE_bytecxx . . $ JE_byte# SAShipcxx . . $ SAShip.[SAcxx . . $ `src/varz.h:29:9`!] /* [1..SA] */ = { 3, 1, 5, 10, 2, 11, 12 };
49 const JE_wordcxx . . $ JE_word# SAWeaponcxx . . $ SAWeapon.[SAcxx . . $ `src/varz.h:29:9`!][5] /* [1..SA, 1..5] */ =
50 { /* R Bl Bk G P */
51 { 9, 31, 32, 33, 34 }, /* Stealth Ship */
52 { 19, 8, 22, 41, 34 }, /* StormWind */
53 { 27, 5, 20, 42, 31 }, /* Techno */
54 { 15, 3, 28, 22, 12 }, /* Enemy */
55 { 23, 35, 25, 14, 6 }, /* Weird */
56 { 2, 5, 21, 4, 7 }, /* Unknown */
57 { 40, 38, 37, 41, 36 } /* NortShip Z */
58 };
59
60 const JE_bytecxx . . $ JE_byte# specialArcadeWeaponcxx . . $ specialArcadeWeapon.[PORT_NUMcxx . . $ `src/lvlmast.h:27:9`!] /* [1..Portnum] */ =
61 {
62 17,17,18,0,0,0,10,0,0,0,0,0,44,0,10,0,19,0,0,-0,0,0,0,0,0,0,
63 -0,0,0,0,45,0,0,0,0,0,0,0,0,0,0,0
64 };
65
66 const JE_bytecxx . . $ JE_byte# optionSelectcxx . . $ optionSelect.[16][3][2] /* [0..15, 1..3, 1..2] */ =
67 { /* MAIN OPT FRONT */
68 { { 0, 0},{ 0, 0},{ 0, 0} }, /**/
69 { { 1, 1},{16,16},{30,30} }, /*Single Shot*/
70 { { 2, 2},{29,29},{29,20} }, /*Dual Shot*/
71 { { 3, 3},{21,21},{12, 0} }, /*Charge Cannon*/
72 { { 4, 4},{18,18},{16,23} }, /*Vulcan*/
73 { { 0, 0},{ 0, 0},{ 0, 0} }, /**/
74 { { 6, 6},{29,16},{ 0,22} }, /*Super Missile*/
75 { { 7, 7},{19,19},{19,28} }, /*Atom Bomb*/
76 { { 0, 0},{ 0, 0},{ 0, 0} }, /**/
77 { { 0, 0},{ 0, 0},{ 0, 0} }, /**/
78 { {10,10},{21,21},{21,27} }, /*Mini Missile*/
79 { { 0, 0},{ 0, 0},{ 0, 0} }, /**/
80 { { 0, 0},{ 0, 0},{ 0, 0} }, /**/
81 { {13,13},{17,17},{13,26} }, /*MicroBomb*/
82 { { 0, 0},{ 0, 0},{ 0, 0} }, /**/
83 { {15,15},{15,16},{15,16} } /*Post-It*/
84 };
85
86 const JE_wordcxx . . $ JE_word# PGRcxx . . $ PGR.[21] /* [1..21] */ =
87 {
88 4,
89 1,2,3,
90 41-21,57-21,73-21,89-21,105-21,
91 121-21,137-21,153-21,
92 151,151,151,151,73-21,73-21,1,2,4
93 /*151,151,151*/
94 };
95 const JE_bytecxx . . $ JE_byte# PAnicxx . . $ PAni.[21] /* [1..21] */ = {1,0,0,0,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,1};
96
97 const JE_wordcxx . . $ JE_word# linkGunWeaponscxx . . $ linkGunWeapons.[38] /* [1..38] */ =
98 {
99 0,0,0,0,0,0,0,0,444,445,446,447,0,448,449,0,0,0,0,0,450,451,0,506,0,564,
100 445,446,447,448,449,445,446,447,448,449,450,451
101 };
102 const JE_wordcxx . . $ JE_word# chargeGunWeaponscxx . . $ chargeGunWeapons.[38] /* [1..38] */ =
103 {
104 0,0,0,0,0,0,0,0,476,458,464,482,0,488,470,0,0,0,0,0,494,500,0,528,0,558,
105 458,458,458,458,458,458,458,458,458,458,458,458
106 };
107 const JE_bytecxx . . $ JE_byte# randomEnemyLaunchSoundscxx . . $ randomEnemyLaunchSounds.[3] /* [1..3] */ = {13,6,26};
108
109 /* YKS: Twiddle cheat sheet:
110 * 1: UP
111 * 2: DOWN
112 * 3: LEFT
113 * 4: RIGHT
114 * 5: UP+FIRE
115 * 6: DOWN+FIRE
116 * 7: LEFT+FIRE
117 * 8: RIGHT+FIRE
118 * 9: Release all keys (directions and fire)
119 */
120 const JE_bytecxx . . $ JE_byte# keyboardComboscxx . . $ keyboardCombos.[26][8] /* [1..26, 1..8] */ =
121 {
122 { 2, 1, 2, 5, 137, 0, 0, 0}, /*Invulnerability*/
123 { 4, 3, 2, 5, 138, 0, 0, 0}, /*Atom Bomb*/
124 { 3, 4, 6, 139, 0, 0, 0, 0}, /*Seeker Bombs*/
125 { 2, 5, 142, 0, 0, 0, 0, 0}, /*Ice Blast*/
126 { 6, 2, 6, 143, 0, 0, 0, 0}, /*Auto Repair*/
127 { 6, 7, 5, 8, 6, 7, 5, 112 }, /*Spin Wave*/
128 { 7, 8, 101, 0, 0, 0, 0, 0}, /*Repulsor*/
129 { 1, 7, 6, 146, 0, 0, 0, 0}, /*Protron Field*/
130 { 8, 6, 7, 1, 120, 0, 0, 0}, /*Minefield*/
131 { 3, 6, 8, 5, 121, 0, 0, 0}, /*Post-It Blast*/
132 { 1, 2, 7, 8, 119, 0, 0, 0}, /*Drone Ship - TBC*/
133 { 3, 4, 3, 6, 123, 0, 0, 0}, /*Repair Player 2*/
134 { 6, 7, 5, 8, 124, 0, 0, 0}, /*Super Bomb - TBC*/
135 { 1, 6, 125, 0, 0, 0, 0, 0}, /*Hot Dog*/
136 { 9, 5, 126, 0, 0, 0, 0, 0}, /*Lightning UP */
137 { 1, 7, 127, 0, 0, 0, 0, 0}, /*Lightning UP+LEFT */
138 { 1, 8, 128, 0, 0, 0, 0, 0}, /*Lightning UP+RIGHT*/
139 { 9, 7, 129, 0, 0, 0, 0, 0}, /*Lightning LEFT */
140 { 9, 8, 130, 0, 0, 0, 0, 0}, /*Lightning RIGHT*/
141 { 4, 2, 3, 5, 131, 0, 0, 0}, /*Warfly */
142 { 3, 1, 2, 8, 132, 0, 0, 0}, /*FrontBlaster */
143 { 2, 4, 5, 133, 0, 0, 0, 0}, /*Gerund */
144 { 3, 4, 2, 8, 134, 0, 0, 0}, /*FireBomb */
145 { 1, 4, 6, 135, 0, 0, 0, 0}, /*Indigo */
146 { 1, 3, 6, 137, 0, 0, 0, 0}, /*Invulnerability [easier] */
147 { 1, 4, 3, 4, 7, 136, 0, 0} /*D-Media Protron Drone */
148 };
149
150 const JE_bytecxx . . $ JE_byte# shipCombosBcxx . . $ shipCombosB.[21] /* [1..21] */ =
151 {15,16,17,18,19,20,21,22,23,24, 7, 8, 5,25,14, 4, 6, 3, 9, 2,26};
152 /*!! SUPER Tyrian !!*/
153 const JE_bytecxx . . $ JE_byte# superTyrianSpecialscxx . . $ superTyrianSpecials.[4] /* [1..4] */ = {1,2,4,5};
154
155 const JE_bytecxx . . $ JE_byte# shipComboscxx . . $ shipCombos.[14][3] /* [0..12, 1..3] */ =
156 {
157 { 5, 4, 7}, /*2nd Player ship*/
158 { 1, 2, 0}, /*USP Talon*/
159 {14, 4, 0}, /*Super Carrot*/
160 { 4, 5, 0}, /*Gencore Phoenix*/
161 { 6, 5, 0}, /*Gencore Maelstrom*/
162 { 7, 8, 0}, /*MicroCorp Stalker*/
163 { 7, 9, 0}, /*MicroCorp Stalker-B*/
164 {10, 3, 5}, /*Prototype Stalker-C*/
165 { 5, 8, 9}, /*Stalker*/
166 { 1, 3, 0}, /*USP Fang*/
167 { 7,16,17}, /*U-Ship*/
168 { 2,11,12}, /*1st Player ship*/
169 { 3, 8,10}, /*Nort ship*/
170 { 0, 0, 0} // Dummy entry added for Stalker 21.126
171 };
172
173 /*Street-Fighter Commands*/
174 JE_bytecxx . . $ JE_byte# SFCurrentCodecxx . . $ SFCurrentCode.[2][21]; /* [1..2, 1..21] */
175 JE_bytecxx . . $ JE_byte# SFExecutedcxx . . $ SFExecuted.[2]; /* [1..2] */
176
177 /*Special General Data*/
178 JE_bytecxx . . $ JE_byte# lvlFileNumcxx . . $ lvlFileNum.;
179 JE_wordcxx . . $ JE_word# maxEventcxx . . $ maxEvent., eventLoccxx . . $ eventLoc.;
180 /*JE_word maxenemies;*/
181 JE_wordcxx . . $ JE_word# tempBackMovecxx . . $ tempBackMove., explodeMovecxx . . $ explodeMove.; /*Speed of background movement*/
182 JE_bytecxx . . $ JE_byte# levelEndcxx . . $ levelEnd.;
183 JE_wordcxx . . $ JE_word# levelEndFxWaitcxx . . $ levelEndFxWait.;
184 JE_shortintcxx . . $ JE_shortint# levelEndWarpcxx . . $ levelEndWarp.;
185 JE_booleancxx . . $ JE_boolean# endLevelcxx . . $ endLevel., reallyEndLevelcxx . . $ reallyEndLevel., waitToEndLevelcxx . . $ waitToEndLevel., playerEndLevelcxx . . $ playerEndLevel.,
186 normalBonusLevelCurrentcxx . . $ normalBonusLevelCurrent., bonusLevelCurrentcxx . . $ bonusLevelCurrent.,
187 smallEnemyAdjustcxx . . $ smallEnemyAdjust., readyToEndLevelcxx . . $ readyToEndLevel., quitRequestedcxx . . $ quitRequested.;
188
189 JE_bytecxx . . $ JE_byte# newPLcxx . . $ newPL.[10]; /* [0..9] */ /*Eventsys event 75 parameter*/
190 JE_wordcxx . . $ JE_word# returnLoccxx . . $ returnLoc.;
191 JE_booleancxx . . $ JE_boolean# returnActivecxx . . $ returnActive.;
192 JE_wordcxx . . $ JE_word# galagaShotFreqcxx . . $ galagaShotFreq.;
193 JE_longintcxx . . $ JE_longint# galagaLifecxx . . $ galagaLife.;
194
195 JE_booleancxx . . $ JE_boolean# debugcxx . . $ debug. = falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!; /*Debug Mode*/
196 Uint32cxx . . $ Uint32# debugTimecxx . . $ debugTime., lastDebugTimecxx . . $ lastDebugTime.;
197 JE_longintcxx . . $ JE_longint# debugHistCountcxx . . $ debugHistCount.;
198 JE_realcxx . . $ JE_real# debugHistcxx . . $ debugHist.;
199 JE_wordcxx . . $ JE_word# curLoccxx . . $ curLoc.; /*Current Pixel location of background 1*/
200
201 JE_booleancxx . . $ JE_boolean# firstGameOvercxx . . $ firstGameOver., gameLoadedcxx . . $ gameLoaded., enemyStillExplodingcxx . . $ enemyStillExploding.;
202
203 /* Destruction Ratio */
204 JE_wordcxx . . $ JE_word# totalEnemycxx . . $ totalEnemy.;
205 JE_wordcxx . . $ JE_word# enemyKilledcxx . . $ enemyKilled.;
206
207 /* Shape/Map Data - All in one Segment! */
208 struct JE_MegaDataType1cxx . . $ JE_MegaDataType1# megaData1cxx . . $ megaData1.;
209 struct JE_MegaDataType2cxx . . $ JE_MegaDataType2# megaData2cxx . . $ megaData2.;
210 struct JE_MegaDataType3cxx . . $ JE_MegaDataType3# megaData3cxx . . $ megaData3.;
211
212 /* Secret Level Display */
213 JE_bytecxx . . $ JE_byte# flashcxx . . $ flash.;
214 JE_shortintcxx . . $ JE_shortint# flashChangecxx . . $ flashChange.;
215 JE_bytecxx . . $ JE_byte# displayTimecxx . . $ displayTime.;
216
217 /* Demo Stuff */
218 boolcxx . . $ `<external>/14268322491693841775/stdbool.h:36:9`! play_democxx . . $ play_demo. = falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, record_democxx . . $ record_demo. = falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, stopped_democxx . . $ stopped_demo. = falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!;
219 Uint8cxx . . $ Uint8# demo_numcxx . . $ demo_num. = 0;
220 FILEcxx . . $ FILE# *demo_filecxx . . $ demo_file. = NULLcxx . . $ `/usr/lib/gcc/x86_64-linux-gnu/15/include/stddef.h:419:9`!;
221
222 Uint8cxx . . $ Uint8# demo_keyscxx . . $ demo_keys.;
223 Uint16cxx . . $ Uint16# demo_keys_waitcxx . . $ demo_keys_wait.;
224
225 /* Sound Effects Queue */
226 JE_bytecxx . . $ JE_byte# soundQueuecxx . . $ soundQueue.[8]; /* [0..7] */
227
228 /*Level Event Data*/
229 JE_booleancxx . . $ JE_boolean# enemyContinualDamagecxx . . $ enemyContinualDamage.;
230 JE_booleancxx . . $ JE_boolean# enemiesActivecxx . . $ enemiesActive.;
231 JE_booleancxx . . $ JE_boolean# forceEventscxx . . $ forceEvents.;
232 JE_booleancxx . . $ JE_boolean# stopBackgroundscxx . . $ stopBackgrounds.;
233 JE_bytecxx . . $ JE_byte# stopBackgroundNumcxx . . $ stopBackgroundNum.;
234 JE_bytecxx . . $ JE_byte# damageRatecxx . . $ damageRate.; /*Rate at which a player takes damage*/
235 JE_booleancxx . . $ JE_boolean# background3x1cxx . . $ background3x1.; /*Background 3 enemies use Background 1 X offset*/
236 JE_booleancxx . . $ JE_boolean# background3x1bcxx . . $ background3x1b.; /*Background 3 enemies moved 8 pixels left*/
237
238 JE_booleancxx . . $ JE_boolean# levelTimercxx . . $ levelTimer.;
239 JE_wordcxx . . $ JE_word# levelTimerCountdowncxx . . $ levelTimerCountdown.;
240 JE_wordcxx . . $ JE_word# levelTimerJumpTocxx . . $ levelTimerJumpTo.;
241 JE_booleancxx . . $ JE_boolean# randomExplosionscxx . . $ randomExplosions.;
242
243 JE_booleancxx . . $ JE_boolean# editShip1cxx . . $ editShip1., editShip2cxx . . $ editShip2.;
244
245 JE_booleancxx . . $ JE_boolean# globalFlagscxx . . $ globalFlags.[10]; /* [1..10] */
246 JE_bytecxx . . $ JE_byte# levelSongcxx . . $ levelSong.;
247
248 /* DESTRUCT game */
249 JE_booleancxx . . $ JE_boolean# loadDestructcxx . . $ loadDestruct.;
250
251 /* MapView Data */
252 JE_wordcxx . . $ JE_word# mapOrigincxx . . $ mapOrigin., mapPNumcxx . . $ mapPNum.;
253 JE_bytecxx . . $ JE_byte# mapPlanetcxx . . $ mapPlanet.[5], mapSectioncxx . . $ mapSection.[5]; /* [1..5] */
254
255 /* Interface Constants */
256 JE_booleancxx . . $ JE_boolean# moveTyrianLogoUpcxx . . $ moveTyrianLogoUp.;
257 JE_booleancxx . . $ JE_boolean# skipStarShowVGAcxx . . $ skipStarShowVGA.;
258
259 /*EnemyData*/
260 JE_MultiEnemyTypecxx . . $ JE_MultiEnemyType# enemycxx . . $ enemy.;
261 JE_EnemyAvailTypecxx . . $ JE_EnemyAvailType# enemyAvailcxx . . $ enemyAvail.; /* values: 0: used, 1: free, 2: secret pick-up */
262 JE_wordcxx . . $ JE_word# enemyOffsetcxx . . $ enemyOffset.;
263 JE_wordcxx . . $ JE_word# enemyOnScreencxx . . $ enemyOnScreen.;
264 JE_wordcxx . . $ JE_word# superEnemy254Jumpcxx . . $ superEnemy254Jump.;
265
266 /*EnemyShotData*/
267 JE_booleancxx . . $ JE_boolean# fireButtonHeldcxx . . $ fireButtonHeld.;
268 JE_booleancxx . . $ JE_boolean# enemyShotAvailcxx . . $ enemyShotAvail.[ENEMY_SHOT_MAXcxx . . $ `src/varz.h:45:9`!]; /* [1..Enemyshotmax] */
269 EnemyShotTypecxx . . $ EnemyShotType# enemyShotcxx . . $ enemyShot.[ENEMY_SHOT_MAXcxx . . $ `src/varz.h:45:9`!]; /* [1..Enemyshotmax] */
270
271 /* Player Shot Data */
272 JE_bytecxx . . $ JE_byte# zinglonDurationcxx . . $ zinglonDuration.;
273 JE_bytecxx . . $ JE_byte# astralDurationcxx . . $ astralDuration.;
274 JE_wordcxx . . $ JE_word# flareDurationcxx . . $ flareDuration.;
275 JE_booleancxx . . $ JE_boolean# flareStartcxx . . $ flareStart.;
276 JE_shortintcxx . . $ JE_shortint# flareColChgcxx . . $ flareColChg.;
277 JE_bytecxx . . $ JE_byte# specialWaitcxx . . $ specialWait.;
278 JE_bytecxx . . $ JE_byte# nextSpecialWaitcxx . . $ nextSpecialWait.;
279 JE_booleancxx . . $ JE_boolean# spraySpecialcxx . . $ spraySpecial.;
280 JE_bytecxx . . $ JE_byte# doIcedcxx . . $ doIced.;
281 JE_booleancxx . . $ JE_boolean# infiniteShotcxx . . $ infiniteShot.;
282
283 /*PlayerData*/
284 JE_booleancxx . . $ JE_boolean# allPlayersGonecxx . . $ allPlayersGone.; /*Both players dead and finished exploding*/
285
286 const uintcxx . . $ uint# shadowYDistcxx . . $ shadowYDist. = 10;
287
288 JE_realcxx . . $ JE_real# optionSatelliteRotatecxx . . $ optionSatelliteRotate.;
289
290 JE_integercxx . . $ JE_integer# optionAttachmentMovecxx . . $ optionAttachmentMove.;
291 JE_booleancxx . . $ JE_boolean# optionAttachmentLinkedcxx . . $ optionAttachmentLinked., optionAttachmentReturncxx . . $ optionAttachmentReturn.;
292
293 JE_bytecxx . . $ JE_byte# chargeWaitcxx . . $ chargeWait., chargeLevelcxx . . $ chargeLevel., chargeMaxcxx . . $ chargeMax., chargeGrcxx . . $ chargeGr., chargeGrWaitcxx . . $ chargeGrWait.;
294
295 JE_wordcxx . . $ JE_word# neatcxx . . $ neat.;
296
297 /*ExplosionData*/
298 explosion_typecxx . . $ explosion_type# explosionscxx . . $ explosions.[MAX_EXPLOSIONScxx . . $ `src/varz.h:49:9`!]; /* [1..ExplosionMax] */
299 JE_integercxx . . $ JE_integer# explosionFollowAmountXcxx . . $ explosionFollowAmountX., explosionFollowAmountYcxx . . $ explosionFollowAmountY.;
300
301 /*Repeating Explosions*/
302 rep_explosion_typecxx . . $ rep_explosion_type# rep_explosionscxx . . $ rep_explosions.[MAX_REPEATING_EXPLOSIONScxx . . $ `src/varz.h:50:9`!]; /* [1..20] */
303
304 /*SuperPixels*/
305 superpixel_typecxx . . $ superpixel_type# superpixelscxx . . $ superpixels.[MAX_SUPERPIXELScxx . . $ `src/varz.h:51:9`!]; /* [0..MaxSP] */
306 unsigned int last_superpixelcxx . . $ last_superpixel.;
307
308 /*Temporary Numbers*/
309 JE_bytecxx . . $ JE_byte# tempcxx . . $ temp., temp2cxx . . $ temp2., temp3cxx . . $ temp3.;
310 JE_wordcxx . . $ JE_word# tempXcxx . . $ tempX., tempYcxx . . $ tempY.;
311 JE_wordcxx . . $ JE_word# tempWcxx . . $ tempW.;
312
313 JE_booleancxx . . $ JE_boolean# doNotSaveBackupcxx . . $ doNotSaveBackup.;
314
315 JE_wordcxx . . $ JE_word# xcxx . . $ x., ycxx . . $ y.;
316 JE_integercxx . . $ JE_integer# bcxx . . $ b.;
317
318 JE_bytecxx . . $ JE_byte# **BKwrap1tocxx . . $ BKwrap1to., **BKwrap2tocxx . . $ BKwrap2to., **BKwrap3tocxx . . $ BKwrap3to.,
319 **BKwrap1cxx . . $ BKwrap1., **BKwrap2cxx . . $ BKwrap2., **BKwrap3cxx . . $ BKwrap3.;
320
321 JE_shortintcxx . . $ JE_shortint# specialWeaponFiltercxx . . $ specialWeaponFilter., specialWeaponFreqcxx . . $ specialWeaponFreq.;
322 JE_wordcxx . . $ JE_word# specialWeaponWpncxx . . $ specialWeaponWpn.;
323 JE_booleancxx . . $ JE_boolean# linkToPlayercxx . . $ linkToPlayer.;
324
325 JE_wordcxx . . $ JE_word# shipGrcxx . . $ shipGr., shipGr2cxx . . $ shipGr2.;
326 Sprite2_arraycxx . . $ Sprite2_array# *shipGrPtrcxx . . $ shipGrPtr., *shipGr2ptrcxx . . $ shipGr2ptr.;
327
328 void JE_getShipInfocxx . . $ JE_getShipInfo(49f6e7a06ebc5aa8).(void)
329 {
330 JE_booleancxx . . $ JE_boolean# extraShip, extraShip2;
331
332 shipGrPtrcxx . . $ shipGrPtr. = &spriteSheet9cxx . . $ spriteSheet9.;
333 shipGr2ptrcxx . . $ shipGr2ptr. = &spriteSheet9cxx . . $ spriteSheet9.;
334
335 powerAddcxx . . $ powerAdd. = powerSyscxx . . $ powerSys.[playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..generatorcxx . . $ $anonymous_type_55bed0e189d5bed_2#generator.].powercxx . . $ $anonymous_type_66fcae0887b82ce8_2#power.;
336
337 extraShip = playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..shipcxx . . $ $anonymous_type_55bed0e189d5bed_2#ship. > 90;
338 if (extraShip)
339 {
340 JE_bytecxx . . $ JE_byte# base = (playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..shipcxx . . $ $anonymous_type_55bed0e189d5bed_2#ship. - 91) * 15;
341 shipGrcxx . . $ shipGr. = JE_SGrcxx . . $ JE_SGr(638b2d25147dc206).(playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..shipcxx . . $ $anonymous_type_55bed0e189d5bed_2#ship. - 90, &shipGrPtrcxx . . $ shipGrPtr.);
342 playercxx . . $ player.[0].armorcxx . . $ $anonymous_type_55bed0e189d5bed_4#armor. = extraShipscxx . . $ extraShips.[base + 7];
343 }
344 else
345 {
346 shipGrcxx . . $ shipGr. = shipscxx . . $ ships.[playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..shipcxx . . $ $anonymous_type_55bed0e189d5bed_2#ship.].shipgraphiccxx . . $ $anonymous_type_66fcae0887b82ce8_6#shipgraphic.;
347 playercxx . . $ player.[0].armorcxx . . $ $anonymous_type_55bed0e189d5bed_4#armor. = shipscxx . . $ ships.[playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..shipcxx . . $ $anonymous_type_55bed0e189d5bed_2#ship.].dmgcxx . . $ $anonymous_type_66fcae0887b82ce8_6#dmg.;
348 }
349
350 extraShip2 = playercxx . . $ player.[1].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..shipcxx . . $ $anonymous_type_55bed0e189d5bed_2#ship. > 90;
351 if (extraShip2)
352 {
353 JE_bytecxx . . $ JE_byte# base2 = (playercxx . . $ player.[1].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..shipcxx . . $ $anonymous_type_55bed0e189d5bed_2#ship. - 91) * 15;
354 shipGr2cxx . . $ shipGr2. = JE_SGrcxx . . $ JE_SGr(638b2d25147dc206).(playercxx . . $ player.[1].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..shipcxx . . $ $anonymous_type_55bed0e189d5bed_2#ship. - 90, &shipGr2ptrcxx . . $ shipGr2ptr.);
355 playercxx . . $ player.[1].armorcxx . . $ $anonymous_type_55bed0e189d5bed_4#armor. = extraShipscxx . . $ extraShips.[base2 + 7]; /* bug? */
356 }
357 else
358 {
359 shipGr2cxx . . $ shipGr2. = 0;
360 playercxx . . $ player.[1].armorcxx . . $ $anonymous_type_55bed0e189d5bed_4#armor. = 10;
361 }
362
363 for (uintcxx . . $ uint# i = 0; i < COUNTOFcxx . . $ `src/opentyr.h:27:9`!(player); ++i)
364 {
365 playercxx . . $ player.[i].initial_armorcxx . . $ $anonymous_type_55bed0e189d5bed_4#initial_armor. = playercxx . . $ player.[i].armorcxx . . $ $anonymous_type_55bed0e189d5bed_4#armor.;
366
367 uintcxx . . $ uint# temp = ((i == 0 && extraShip) ||
368 (i == 1 && extraShip2)) ? 2 : shipscxx . . $ ships.[playercxx . . $ player.[i].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..shipcxx . . $ $anonymous_type_55bed0e189d5bed_2#ship.].anicxx . . $ $anonymous_type_66fcae0887b82ce8_6#ani.;
369
370 if (temp == 0)
371 {
372 playercxx . . $ player.[i].shot_hit_area_xcxx . . $ $anonymous_type_55bed0e189d5bed_4#shot_hit_area_x. = 12;
373 playercxx . . $ player.[i].shot_hit_area_ycxx . . $ $anonymous_type_55bed0e189d5bed_4#shot_hit_area_y. = 10;
374 }
375 else
376 {
377 playercxx . . $ player.[i].shot_hit_area_xcxx . . $ $anonymous_type_55bed0e189d5bed_4#shot_hit_area_x. = 11;
378 playercxx . . $ player.[i].shot_hit_area_ycxx . . $ $anonymous_type_55bed0e189d5bed_4#shot_hit_area_y. = 14;
379 }
380 }
381 }
382
383 JE_wordcxx . . $ JE_word# JE_SGrcxx . . $ JE_SGr(638b2d25147dc206).(JE_wordcxx . . $ JE_word# ship, Sprite2_arraycxx . . $ Sprite2_array# **ptr)
384 {
385 const JE_wordcxx . . $ JE_word# GR[15] /* [1..15] */ = {233, 157, 195, 271, 81, 0, 119, 5, 43, 81, 119, 157, 195, 233, 271};
386
387 JE_wordcxx . . $ JE_word# tempW = extraShipscxx . . $ extraShips.[(ship - 1) * 15];
388 if (tempW > 7)
389 *ptr = extraShapescxx . . $ extraShapes.;
390
391 return GR[tempW-1];
392 }
393
394 void JE_drawOptionscxx . . $ JE_drawOptions(49f6e7a06ebc5aa8).(void)
395 {
396 SDL_Surfacecxx . . $ SDL_Surface# *temp_surface = VGAScreencxx . . $ VGAScreen.;
397 VGAScreencxx . . $ VGAScreen. = VGAScreenSegcxx . . $ VGAScreenSeg.;
398
399 Playercxx . . $ Player# *this_player = &playercxx . . $ player.[twoPlayerModecxx . . $ twoPlayerMode. ? 1 : 0];
400
401 for (uintcxx . . $ uint# i = 0; i < COUNTOFcxx . . $ `src/opentyr.h:27:9`!(this_player->sidekick); ++i)
402 {
403 JE_OptionTypecxx . . $ JE_OptionType# *this_option = &optionscxx . . $ options.[this_player->itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..sidekickcxx . . $ $anonymous_type_55bed0e189d5bed_2#sidekick.[i]];
404
405 this_player->sidekickcxx . . $ $anonymous_type_55bed0e189d5bed_4#sidekick.[i].ammocxx . . $ $anonymous_type_55bed0e189d5bed_4#$anonymous_type_5#ammo. =
406 this_player->sidekickcxx . . $ $anonymous_type_55bed0e189d5bed_4#sidekick.[i].ammo_maxcxx . . $ $anonymous_type_55bed0e189d5bed_4#$anonymous_type_5#ammo_max. = this_option->ammocxx . . $ $anonymous_type_66fcae0887b82ce8_4#ammo.;
407
408 this_player->sidekickcxx . . $ $anonymous_type_55bed0e189d5bed_4#sidekick.[i].ammo_refill_tickscxx . . $ $anonymous_type_55bed0e189d5bed_4#$anonymous_type_5#ammo_refill_ticks. =
409 this_player->sidekickcxx . . $ $anonymous_type_55bed0e189d5bed_4#sidekick.[i].ammo_refill_ticks_maxcxx . . $ $anonymous_type_55bed0e189d5bed_4#$anonymous_type_5#ammo_refill_ticks_max. = (105 - this_player->sidekickcxx . . $ $anonymous_type_55bed0e189d5bed_4#sidekick.[i].ammocxx . . $ $anonymous_type_55bed0e189d5bed_4#$anonymous_type_5#ammo.) * 4;
410
411 this_player->sidekickcxx . . $ $anonymous_type_55bed0e189d5bed_4#sidekick.[i].stylecxx . . $ $anonymous_type_55bed0e189d5bed_4#$anonymous_type_5#style. = this_option->trcxx . . $ $anonymous_type_66fcae0887b82ce8_4#tr.;
412
413 this_player->sidekickcxx . . $ $anonymous_type_55bed0e189d5bed_4#sidekick.[i].animation_enabledcxx . . $ $anonymous_type_55bed0e189d5bed_4#$anonymous_type_5#animation_enabled. = (this_option->optioncxx . . $ $anonymous_type_66fcae0887b82ce8_4#option. == 1);
414 this_player->sidekickcxx . . $ $anonymous_type_55bed0e189d5bed_4#sidekick.[i].animation_framecxx . . $ $anonymous_type_55bed0e189d5bed_4#$anonymous_type_5#animation_frame. = 0;
415
416 this_player->sidekickcxx . . $ $anonymous_type_55bed0e189d5bed_4#sidekick.[i].chargecxx . . $ $anonymous_type_55bed0e189d5bed_4#$anonymous_type_5#charge. = 0;
417 this_player->sidekickcxx . . $ $anonymous_type_55bed0e189d5bed_4#sidekick.[i].charge_tickscxx . . $ $anonymous_type_55bed0e189d5bed_4#$anonymous_type_5#charge_ticks. = 20;
418
419 // draw initial sidekick HUD
420 const int y = hud_sidekick_ycxx . . $ hud_sidekick_y.[twoPlayerModecxx . . $ twoPlayerMode. ? 1 : 0][i];
421
422 fill_rectangle_xycxx . . $ fill_rectangle_xy(da1d960d0d6e485d).(VGAScreenSegcxx . . $ VGAScreenSeg., 284, y, 284 + 28, y + 15, 0);
423 if (this_option->icongrcxx . . $ $anonymous_type_66fcae0887b82ce8_4#icongr. > 0)
424 blit_spritecxx . . $ blit_sprite(ee201c8e1efc2766).(VGAScreenSegcxx . . $ VGAScreenSeg., 284, y, OPTION_SHAPEScxx . . $ `src/sprite.h:34:9`!, this_option->icongrcxx . . $ $anonymous_type_66fcae0887b82ce8_4#icongr. - 1); // sidekick HUD icon
425 draw_segmented_gaugecxx . . $ draw_segmented_gauge(915c4eaa04ad7c00).(VGAScreenSegcxx . . $ VGAScreenSeg., 284, y + 13, 112, 2, 2, MAXcxx . . $ `src/opentyr.h:29:9`!(1, this_player->sidekick[i].ammo_max / 10), this_player->sidekickcxx . . $ $anonymous_type_55bed0e189d5bed_4#sidekick.[i].ammocxx . . $ $anonymous_type_55bed0e189d5bed_4#$anonymous_type_5#ammo.);
426 }
427
428 VGAScreencxx . . $ VGAScreen. = temp_surface;
429
430 JE_drawOptionLevelcxx . . $ JE_drawOptionLevel(49f6e7a06ebc5aa8).();
431 }
432
433 void JE_drawOptionLevelcxx . . $ JE_drawOptionLevel(49f6e7a06ebc5aa8).(void)
434 {
435 if (twoPlayerModecxx . . $ twoPlayerMode.)
436 {
437 for (tempcxx . . $ temp. = 1; tempcxx . . $ temp. <= 3; tempcxx . . $ temp.++)
438 {
439 fill_rectangle_xycxx . . $ fill_rectangle_xy(da1d960d0d6e485d).(VGAScreenSegcxx . . $ VGAScreenSeg., 268, 127 + (tempcxx . . $ temp. - 1) * 6, 269, 127 + 3 + (tempcxx . . $ temp. - 1) * 6, 193 + ((playercxx . . $ player.[1].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..sidekick_levelcxx . . $ $anonymous_type_55bed0e189d5bed_2#sidekick_level. - 100) == tempcxx . . $ temp.) * 11);
440 }
441 }
442 }
443
444 void JE_tyrianHaltcxx . . $ JE_tyrianHalt(ac50b47256ae7414).(JE_bytecxx . . $ JE_byte# code)
445 {
446 deinit_audiocxx . . $ deinit_audio(49f6e7a06ebc5aa8).();
447 deinit_videocxx . . $ deinit_video(49f6e7a06ebc5aa8).();
448 deinit_joystickscxx . . $ deinit_joysticks(49f6e7a06ebc5aa8).();
449
450 /* TODO: NETWORK */
451
452 free_main_shape_tablescxx . . $ free_main_shape_tables(49f6e7a06ebc5aa8).();
453
454 free_sprite2scxx . . $ free_sprite2s(da72ff5ad2e190db).(&shopSpriteSheetcxx . . $ shopSpriteSheet.);
455 free_sprite2scxx . . $ free_sprite2s(da72ff5ad2e190db).(&explosionSpriteSheetcxx . . $ explosionSpriteSheet.);
456 free_sprite2scxx . . $ free_sprite2s(da72ff5ad2e190db).(&destructSpriteSheetcxx . . $ destructSpriteSheet.);
457
458 for (int i = 0; i < SOUND_COUNTcxx . . $ `src/sndmast.h:26:9`!; i++)
459 {
460 freecxx . . $ free(5d22bdacc48458e8).(soundSamplescxx . . $ soundSamples.[i]);
461 }
462
463 if (code != 9)
464 {
465 /*
466 TODO?
467 JE_drawANSI("exitmsg.bin");
468 JE_gotoXY(1,22);*/
469
470 JE_saveConfigurationcxx . . $ JE_saveConfiguration(49f6e7a06ebc5aa8).();
471 }
472
473 /* endkeyboard; */
474
475 if (code == 9)
476 {
477 /* OutputString('call=file0002.EXE' + #0'); TODO? */
478 }
479
480 if (code == 5)
481 {
482 code = 0;
483 }
484
485 if (trentWincxx . . $ trentWin.)
486 {
487 printfcxx . . $ printf(581fddd72a8db8fc).("\n"
488 "\n"
489 "\n"
490 "\n"
491 "Sleep well, Trent, you deserve the rest.\n"
492 "You now have permission to borrow my ship on your next mission.\n"
493 "\n"
494 "Also, you might want to try out the YESXMAS parameter.\n"
495 " Type: File0001 YESXMAS\n"
496 "\n"
497 "You'll need the 2.1 patch, though!\n"
498 "\n");
499 }
500
501 SDL_Quitcxx . . $ SDL_Quit(49f6e7a06ebc5aa8).();
502
503 #ifdef TARGET_UNIXcxx . . $ `<built-in>:411:9`!
504 #define MISSING_TEXTcxx . . $ `src/varz.c:504:9`! "One or more of the required Tyrian " TYRIAN_VERSIONcxx . . $ `src/opentyr.h:54:9`! " data files could not be found.\n" \
505 "These can be installed using game-data-packager.\n"
506 if (code == 1)
507 {
508 char* argv[6];
509 pid_tcxx . . $ pid_t# child_pid;
510 child_pid = forkcxx . . $ fork(b126dc7c1de90089).();
511 if(child_pid == 0) {
512 argv[0] = "zenity";
513 argv[1] = "--error";
514 argv[2] = "--text=" MISSING_TEXTcxx . . $ `src/varz.c:504:9`!;
515 argv[3] = "--title=Tyrian";
516 argv[4] = NULLcxx . . $ `/usr/lib/gcc/x86_64-linux-gnu/15/include/stddef.h:419:9`!;
517 execvpcxx . . $ execvp(8a4102a9cf05ffcd).(argv[0], argv);
518 argv[0] = "yad";
519 execvpcxx . . $ execvp(8a4102a9cf05ffcd).(argv[0], argv);
520 argv[0] = "kdialog";
521 argv[2] = MISSING_TEXTcxx . . $ `src/varz.c:504:9`!;
522 execvpcxx . . $ execvp(8a4102a9cf05ffcd).(argv[0], argv);
523 argv[0] = "xmessage";
524 argv[1] = "-center";
525 argv[3] = NULLcxx . . $ `/usr/lib/gcc/x86_64-linux-gnu/15/include/stddef.h:419:9`!;
526 execvpcxx . . $ execvp(8a4102a9cf05ffcd).(argv[0], argv);
527 argv[0] = "notify-send";
528 argv[1] = "Tyrian";
529 argv[3] = "-i";
530 argv[4] = "dialog-error";
531 argv[5] = NULLcxx . . $ `/usr/lib/gcc/x86_64-linux-gnu/15/include/stddef.h:419:9`!;
532 execvpcxx . . $ execvp(8a4102a9cf05ffcd).(argv[0], argv);
533 }
534 }
535 #endif
536 exitcxx . . $ exit(3ca292c338df9bb3).(code);
537 }
538
539 void JE_specialCompletecxx . . $ JE_specialComplete(8fbe6856f5410d23).(JE_bytecxx . . $ JE_byte# playerNum, JE_bytecxx . . $ JE_byte# specialType)
540 {
541 nextSpecialWaitcxx . . $ nextSpecialWait. = 0;
542 switch (specialcxx . . $ special.[specialType].stypecxx . . $ $anonymous_type_66fcae0887b82ce8_3#stype.)
543 {
544 /*Weapon*/
545 case 1:
546 if (playerNum == 1)
547 bcxx . . $ b. = player_shot_createcxx . . $ player_shot_create(47a6dcf6307ecf82).(0, SHOT_SPECIAL2cxx . . $ SHOT_SPECIAL2., playercxx . . $ player.[0].xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x., playercxx . . $ player.[0].ycxx . . $ $anonymous_type_55bed0e189d5bed_4#y., mouseXcxx . . $ mouseX., mouseYcxx . . $ mouseY., specialcxx . . $ special.[specialType].wpncxx . . $ $anonymous_type_66fcae0887b82ce8_3#wpn., playerNum);
548 else
549 bcxx . . $ b. = player_shot_createcxx . . $ player_shot_create(47a6dcf6307ecf82).(0, SHOT_SPECIAL2cxx . . $ SHOT_SPECIAL2., playercxx . . $ player.[1].xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x., playercxx . . $ player.[1].ycxx . . $ $anonymous_type_55bed0e189d5bed_4#y., mouseXcxx . . $ mouseX., mouseYcxx . . $ mouseY., specialcxx . . $ special.[specialType].wpncxx . . $ $anonymous_type_66fcae0887b82ce8_3#wpn., playerNum);
550
551 shotRepeatcxx . . $ shotRepeat.[SHOT_SPECIALcxx . . $ SHOT_SPECIAL.] = shotRepeatcxx . . $ shotRepeat.[SHOT_SPECIAL2cxx . . $ SHOT_SPECIAL2.];
552 break;
553 /*Repulsor*/
554 case 2:
555 for (tempcxx . . $ temp. = 0; tempcxx . . $ temp. < ENEMY_SHOT_MAXcxx . . $ `src/varz.h:45:9`!; tempcxx . . $ temp.++)
556 {
557 if (!enemyShotAvailcxx . . $ enemyShotAvail.[tempcxx . . $ temp.])
558 {
559 if (playercxx . . $ player.[0].xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x. > enemyShotcxx . . $ enemyShot.[tempcxx . . $ temp.].sxcxx . . $ $anonymous_type_75a5d6b19c4f0372_4#sx.)
560 enemyShotcxx . . $ enemyShot.[tempcxx . . $ temp.].sxmcxx . . $ $anonymous_type_75a5d6b19c4f0372_4#sxm.--;
561 else if (playercxx . . $ player.[0].xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x. < enemyShotcxx . . $ enemyShot.[tempcxx . . $ temp.].sxcxx . . $ $anonymous_type_75a5d6b19c4f0372_4#sx.)
562 enemyShotcxx . . $ enemyShot.[tempcxx . . $ temp.].sxmcxx . . $ $anonymous_type_75a5d6b19c4f0372_4#sxm.++;
563
564 if (playercxx . . $ player.[0].ycxx . . $ $anonymous_type_55bed0e189d5bed_4#y. > enemyShotcxx . . $ enemyShot.[tempcxx . . $ temp.].sycxx . . $ $anonymous_type_75a5d6b19c4f0372_4#sy.)
565 enemyShotcxx . . $ enemyShot.[tempcxx . . $ temp.].symcxx . . $ $anonymous_type_75a5d6b19c4f0372_4#sym.--;
566 else if (playercxx . . $ player.[0].ycxx . . $ $anonymous_type_55bed0e189d5bed_4#y. < enemyShotcxx . . $ enemyShot.[tempcxx . . $ temp.].sycxx . . $ $anonymous_type_75a5d6b19c4f0372_4#sy.)
567 enemyShotcxx . . $ enemyShot.[tempcxx . . $ temp.].symcxx . . $ $anonymous_type_75a5d6b19c4f0372_4#sym.++;
568 }
569 }
570 break;
571 /*Zinglon Blast*/
572 case 3:
573 zinglonDurationcxx . . $ zinglonDuration. = 50;
574 shotRepeatcxx . . $ shotRepeat.[SHOT_SPECIALcxx . . $ SHOT_SPECIAL.] = 100;
575 soundQueuecxx . . $ soundQueue.[7] = S_SOUL_OF_ZINGLONcxx . . $ S_SOUL_OF_ZINGLON.;
576 break;
577 /*Attractor*/
578 case 4:
579 for (tempcxx . . $ temp. = 0; tempcxx . . $ temp. < 100; tempcxx . . $ temp.++)
580 {
581 if (enemyAvailcxx . . $ enemyAvail.[tempcxx . . $ temp.] != 1 && enemycxx . . $ enemy.[tempcxx . . $ temp.].scoreitemcxx . . $ JE_SingleEnemyType#scoreitem. &&
582 enemycxx . . $ enemy.[tempcxx . . $ temp.].evaluecxx . . $ JE_SingleEnemyType#evalue. != 0)
583 {
584 if (playercxx . . $ player.[0].xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x. > enemycxx . . $ enemy.[tempcxx . . $ temp.].excxx . . $ JE_SingleEnemyType#ex.)
585 enemycxx . . $ enemy.[tempcxx . . $ temp.].exccxx . . $ JE_SingleEnemyType#exc.++;
586 else if (playercxx . . $ player.[0].xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x. < enemycxx . . $ enemy.[tempcxx . . $ temp.].excxx . . $ JE_SingleEnemyType#ex.)
587 enemycxx . . $ enemy.[tempcxx . . $ temp.].exccxx . . $ JE_SingleEnemyType#exc.--;
588
589 if (playercxx . . $ player.[0].ycxx . . $ $anonymous_type_55bed0e189d5bed_4#y. > enemycxx . . $ enemy.[tempcxx . . $ temp.].eycxx . . $ JE_SingleEnemyType#ey.)
590 enemycxx . . $ enemy.[tempcxx . . $ temp.].eyccxx . . $ JE_SingleEnemyType#eyc.++;
591 else if (playercxx . . $ player.[0].ycxx . . $ $anonymous_type_55bed0e189d5bed_4#y. < enemycxx . . $ enemy.[tempcxx . . $ temp.].eycxx . . $ JE_SingleEnemyType#ey.)
592 enemycxx . . $ enemy.[tempcxx . . $ temp.].eyccxx . . $ JE_SingleEnemyType#eyc.--;
593 }
594 }
595 break;
596 /*Flare*/
597 case 5:
598 case 6:
599 case 7:
600 case 8:
601 case 9:
602 case 10:
603 case 11:
604 case 16:
605 if (flareDurationcxx . . $ flareDuration. == 0)
606 flareStartcxx . . $ flareStart. = truecxx . . $ `<external>/14268322491693841775/stdbool.h:37:9`!;
607
608 specialWeaponWpncxx . . $ specialWeaponWpn. = specialcxx . . $ special.[specialType].wpncxx . . $ $anonymous_type_66fcae0887b82ce8_3#wpn.;
609 linkToPlayercxx . . $ linkToPlayer. = falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!;
610 spraySpecialcxx . . $ spraySpecial. = falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!;
611 switch (specialcxx . . $ special.[specialType].stypecxx . . $ $anonymous_type_66fcae0887b82ce8_3#stype.)
612 {
613 case 5:
614 specialWeaponFiltercxx . . $ specialWeaponFilter. = 7;
615 specialWeaponFreqcxx . . $ specialWeaponFreq. = 2;
616 flareDurationcxx . . $ flareDuration. = 50;
617 break;
618 case 6:
619 specialWeaponFiltercxx . . $ specialWeaponFilter. = 1;
620 specialWeaponFreqcxx . . $ specialWeaponFreq. = 7;
621 flareDurationcxx . . $ flareDuration. = 200 + 25 * playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..weaponcxx . . $ $anonymous_type_55bed0e189d5bed_2#weapon.[FRONT_WEAPONcxx . . $ FRONT_WEAPON.].powercxx . . $ $anonymous_type_55bed0e189d5bed_2#$anonymous_type_3#power.;
622 break;
623 case 7:
624 specialWeaponFiltercxx . . $ specialWeaponFilter. = 3;
625 specialWeaponFreqcxx . . $ specialWeaponFreq. = 3;
626 flareDurationcxx . . $ flareDuration. = 50 + 10 * playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..weaponcxx . . $ $anonymous_type_55bed0e189d5bed_2#weapon.[FRONT_WEAPONcxx . . $ FRONT_WEAPON.].powercxx . . $ $anonymous_type_55bed0e189d5bed_2#$anonymous_type_3#power.;
627 zinglonDurationcxx . . $ zinglonDuration. = 50;
628 shotRepeatcxx . . $ shotRepeat.[SHOT_SPECIALcxx . . $ SHOT_SPECIAL.] = 100;
629 soundQueuecxx . . $ soundQueue.[7] = S_SOUL_OF_ZINGLONcxx . . $ S_SOUL_OF_ZINGLON.;
630 break;
631 case 8:
632 specialWeaponFiltercxx . . $ specialWeaponFilter. = -99;
633 specialWeaponFreqcxx . . $ specialWeaponFreq. = 7;
634 flareDurationcxx . . $ flareDuration. = 10 + playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..weaponcxx . . $ $anonymous_type_55bed0e189d5bed_2#weapon.[FRONT_WEAPONcxx . . $ FRONT_WEAPON.].powercxx . . $ $anonymous_type_55bed0e189d5bed_2#$anonymous_type_3#power.;
635 break;
636 case 9:
637 specialWeaponFiltercxx . . $ specialWeaponFilter. = -99;
638 specialWeaponFreqcxx . . $ specialWeaponFreq. = 8;
639 flareDurationcxx . . $ flareDuration. = 8 + 2 * playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..weaponcxx . . $ $anonymous_type_55bed0e189d5bed_2#weapon.[FRONT_WEAPONcxx . . $ FRONT_WEAPON.].powercxx . . $ $anonymous_type_55bed0e189d5bed_2#$anonymous_type_3#power.;
640 linkToPlayercxx . . $ linkToPlayer. = truecxx . . $ `<external>/14268322491693841775/stdbool.h:37:9`!;
641 nextSpecialWaitcxx . . $ nextSpecialWait. = specialcxx . . $ special.[specialType].pwrcxx . . $ $anonymous_type_66fcae0887b82ce8_3#pwr.;
642 break;
643 case 10:
644 specialWeaponFiltercxx . . $ specialWeaponFilter. = -99;
645 specialWeaponFreqcxx . . $ specialWeaponFreq. = 8;
646 flareDurationcxx . . $ flareDuration. = 14 + 4 * playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..weaponcxx . . $ $anonymous_type_55bed0e189d5bed_2#weapon.[FRONT_WEAPONcxx . . $ FRONT_WEAPON.].powercxx . . $ $anonymous_type_55bed0e189d5bed_2#$anonymous_type_3#power.;
647 linkToPlayercxx . . $ linkToPlayer. = truecxx . . $ `<external>/14268322491693841775/stdbool.h:37:9`!;
648 break;
649 case 11:
650 specialWeaponFiltercxx . . $ specialWeaponFilter. = -99;
651 specialWeaponFreqcxx . . $ specialWeaponFreq. = specialcxx . . $ special.[specialType].pwrcxx . . $ $anonymous_type_66fcae0887b82ce8_3#pwr.;
652 flareDurationcxx . . $ flareDuration. = 10 + 10 * playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..weaponcxx . . $ $anonymous_type_55bed0e189d5bed_2#weapon.[FRONT_WEAPONcxx . . $ FRONT_WEAPON.].powercxx . . $ $anonymous_type_55bed0e189d5bed_2#$anonymous_type_3#power.;
653 astralDurationcxx . . $ astralDuration. = 20 + 10 * playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..weaponcxx . . $ $anonymous_type_55bed0e189d5bed_2#weapon.[FRONT_WEAPONcxx . . $ FRONT_WEAPON.].powercxx . . $ $anonymous_type_55bed0e189d5bed_2#$anonymous_type_3#power.;
654 break;
655 case 16:
656 specialWeaponFiltercxx . . $ specialWeaponFilter. = -99;
657 specialWeaponFreqcxx . . $ specialWeaponFreq. = 8;
658 flareDurationcxx . . $ flareDuration. = temp2cxx . . $ temp2. * 16 + 8;
659 linkToPlayercxx . . $ linkToPlayer. = truecxx . . $ `<external>/14268322491693841775/stdbool.h:37:9`!;
660 spraySpecialcxx . . $ spraySpecial. = truecxx . . $ `<external>/14268322491693841775/stdbool.h:37:9`!;
661 break;
662 }
663 break;
664 case 12:
665 playercxx . . $ player.[playerNum-1].invulnerable_tickscxx . . $ $anonymous_type_55bed0e189d5bed_4#invulnerable_ticks. = temp2cxx . . $ temp2. * 10;
666
667 if (superArcadeModecxx . . $ superArcadeMode. > 0 && superArcadeModecxx . . $ superArcadeMode. <= SAcxx . . $ `src/varz.h:29:9`!)
668 {
669 shotRepeatcxx . . $ shotRepeat.[SHOT_SPECIALcxx . . $ SHOT_SPECIAL.] = 250;
670 bcxx . . $ b. = player_shot_createcxx . . $ player_shot_create(47a6dcf6307ecf82).(0, SHOT_SPECIAL2cxx . . $ SHOT_SPECIAL2., playercxx . . $ player.[0].xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x., playercxx . . $ player.[0].ycxx . . $ $anonymous_type_55bed0e189d5bed_4#y., mouseXcxx . . $ mouseX., mouseYcxx . . $ mouseY., 707, 1);
671 playercxx . . $ player.[0].invulnerable_tickscxx . . $ $anonymous_type_55bed0e189d5bed_4#invulnerable_ticks. = 100;
672 }
673 break;
674 case 13:
675 playercxx . . $ player.[0].armorcxx . . $ $anonymous_type_55bed0e189d5bed_4#armor. += temp2cxx . . $ temp2. / 4 + 1;
676
677 soundQueuecxx . . $ soundQueue.[3] = S_POWERUPcxx . . $ S_POWERUP.;
678 break;
679 case 14:
680 playercxx . . $ player.[1].armorcxx . . $ $anonymous_type_55bed0e189d5bed_4#armor. += temp2cxx . . $ temp2. / 4 + 1;
681
682 soundQueuecxx . . $ soundQueue.[3] = S_POWERUPcxx . . $ S_POWERUP.;
683 break;
684
685 case 17: // spawn left or right sidekick
686 soundQueuecxx . . $ soundQueue.[3] = S_POWERUPcxx . . $ S_POWERUP.;
687
688 if (playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..sidekickcxx . . $ $anonymous_type_55bed0e189d5bed_2#sidekick.[LEFT_SIDEKICKcxx . . $ LEFT_SIDEKICK.] == specialcxx . . $ special.[specialType].wpncxx . . $ $anonymous_type_66fcae0887b82ce8_3#wpn.)
689 {
690 playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..sidekickcxx . . $ $anonymous_type_55bed0e189d5bed_2#sidekick.[RIGHT_SIDEKICKcxx . . $ RIGHT_SIDEKICK.] = specialcxx . . $ special.[specialType].wpncxx . . $ $anonymous_type_66fcae0887b82ce8_3#wpn.;
691 shotMultiPoscxx . . $ shotMultiPos.[RIGHT_SIDEKICKcxx . . $ RIGHT_SIDEKICK.] = 0;
692 }
693 else
694 {
695 playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..sidekickcxx . . $ $anonymous_type_55bed0e189d5bed_2#sidekick.[LEFT_SIDEKICKcxx . . $ LEFT_SIDEKICK.] = specialcxx . . $ special.[specialType].wpncxx . . $ $anonymous_type_66fcae0887b82ce8_3#wpn.;
696 shotMultiPoscxx . . $ shotMultiPos.[LEFT_SIDEKICKcxx . . $ LEFT_SIDEKICK.] = 0;
697 }
698
699 JE_drawOptionscxx . . $ JE_drawOptions(49f6e7a06ebc5aa8).();
700 break;
701
702 case 18: // spawn right sidekick
703 playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..sidekickcxx . . $ $anonymous_type_55bed0e189d5bed_2#sidekick.[RIGHT_SIDEKICKcxx . . $ RIGHT_SIDEKICK.] = specialcxx . . $ special.[specialType].wpncxx . . $ $anonymous_type_66fcae0887b82ce8_3#wpn.;
704
705 JE_drawOptionscxx . . $ JE_drawOptions(49f6e7a06ebc5aa8).();
706
707 soundQueuecxx . . $ soundQueue.[4] = S_POWERUPcxx . . $ S_POWERUP.;
708
709 shotMultiPoscxx . . $ shotMultiPos.[RIGHT_SIDEKICKcxx . . $ RIGHT_SIDEKICK.] = 0;
710 break;
711 }
712 }
713
714 void JE_doSpecialShotcxx . . $ JE_doSpecialShot(69ec12f035786005).(JE_bytecxx . . $ JE_byte# playerNum, uintcxx . . $ uint# *armor, uintcxx . . $ uint# *shield)
715 {
716 if (playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..specialcxx . . $ $anonymous_type_55bed0e189d5bed_2#special. > 0)
717 {
718 if (shotRepeatcxx . . $ shotRepeat.[SHOT_SPECIALcxx . . $ SHOT_SPECIAL.] == 0 && specialWaitcxx . . $ specialWait. == 0 && flareDurationcxx . . $ flareDuration. < 2 && zinglonDurationcxx . . $ zinglonDuration. < 2)
719 blit_sprite2cxx . . $ blit_sprite2(b5d0f2be3b000a5b).(VGAScreencxx . . $ VGAScreen., 47, 4, spriteSheet9cxx . . $ spriteSheet9., 94);
720 else
721 blit_sprite2cxx . . $ blit_sprite2(b5d0f2be3b000a5b).(VGAScreencxx . . $ VGAScreen., 47, 4, spriteSheet9cxx . . $ spriteSheet9., 93);
722 }
723
724 if (shotRepeatcxx . . $ shotRepeat.[SHOT_SPECIALcxx . . $ SHOT_SPECIAL.] > 0)
725 {
726 --shotRepeatcxx . . $ shotRepeat.[SHOT_SPECIALcxx . . $ SHOT_SPECIAL.];
727 }
728 if (specialWaitcxx . . $ specialWait. > 0)
729 {
730 specialWaitcxx . . $ specialWait.--;
731 }
732 tempcxx . . $ temp. = SFExecutedcxx . . $ SFExecuted.[playerNum-1];
733 if (tempcxx . . $ temp. > 0 && shotRepeatcxx . . $ shotRepeat.[SHOT_SPECIALcxx . . $ SHOT_SPECIAL.] == 0 && flareDurationcxx . . $ flareDuration. == 0)
734 {
735 temp2cxx . . $ temp2. = specialcxx . . $ special.[tempcxx . . $ temp.].pwrcxx . . $ $anonymous_type_66fcae0887b82ce8_3#pwr.;
736
737 boolcxx . . $ `<external>/14268322491693841775/stdbool.h:36:9`! can_afford = truecxx . . $ `<external>/14268322491693841775/stdbool.h:37:9`!;
738
739 if (temp2cxx . . $ temp2. > 0)
740 {
741 if (temp2cxx . . $ temp2. < 98) // costs some shield
742 {
743 if (*shield >= temp2cxx . . $ temp2.)
744 *shield -= temp2cxx . . $ temp2.;
745 else
746 can_afford = falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!;
747 }
748 else if (temp2cxx . . $ temp2. == 98) // costs all shield
749 {
750 if (*shield < 4)
751 can_afford = falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!;
752 temp2cxx . . $ temp2. = *shield;
753 *shield = 0;
754 }
755 else if (temp2cxx . . $ temp2. == 99) // costs half shield
756 {
757 temp2cxx . . $ temp2. = *shield / 2;
758 *shield = temp2cxx . . $ temp2.;
759 }
760 else // costs some armor
761 {
762 temp2cxx . . $ temp2. -= 100;
763 if (*armor > temp2cxx . . $ temp2.)
764 *armor -= temp2cxx . . $ temp2.;
765 else
766 can_afford = falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!;
767 }
768 }
769
770 shotMultiPoscxx . . $ shotMultiPos.[SHOT_SPECIALcxx . . $ SHOT_SPECIAL.] = 0;
771 shotMultiPoscxx . . $ shotMultiPos.[SHOT_SPECIAL2cxx . . $ SHOT_SPECIAL2.] = 0;
772
773 if (can_afford)
774 JE_specialCompletecxx . . $ JE_specialComplete(8fbe6856f5410d23).(playerNum, tempcxx . . $ temp.);
775
776 SFExecutedcxx . . $ SFExecuted.[playerNum-1] = 0;
777
778 JE_wipeShieldArmorBarscxx . . $ JE_wipeShieldArmorBars(49f6e7a06ebc5aa8).();
779 VGAScreencxx . . $ VGAScreen. = VGAScreenSegcxx . . $ VGAScreenSeg.; /* side-effect of game_screen */
780 JE_drawShieldcxx . . $ JE_drawShield(49f6e7a06ebc5aa8).();
781 JE_drawArmorcxx . . $ JE_drawArmor(49f6e7a06ebc5aa8).();
782 VGAScreencxx . . $ VGAScreen. = game_screencxx . . $ game_screen.; /* side-effect of game_screen */
783 }
784
785 if (playerNum == 1 && playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..specialcxx . . $ $anonymous_type_55bed0e189d5bed_2#special. > 0)
786 { /*Main Begin*/
787
788 if (superArcadeModecxx . . $ superArcadeMode. > 0 && (buttoncxx . . $ button.[2-1] || buttoncxx . . $ button.[3-1]))
789 {
790 fireButtonHeldcxx . . $ fireButtonHeld. = falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!;
791 }
792 if (!buttoncxx . . $ button.[1-1] && !(superArcadeModecxx . . $ superArcadeMode. != SA_NONEcxx . . $ SA_NONE. && (buttoncxx . . $ button.[2-1] || buttoncxx . . $ button.[3-1])))
793 {
794 fireButtonHeldcxx . . $ fireButtonHeld. = falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!;
795 }
796 else if (shotRepeatcxx . . $ shotRepeat.[SHOT_SPECIALcxx . . $ SHOT_SPECIAL.] == 0 && !fireButtonHeldcxx . . $ fireButtonHeld. && !(flareDurationcxx . . $ flareDuration. > 0) && specialWaitcxx . . $ specialWait. == 0)
797 {
798 fireButtonHeldcxx . . $ fireButtonHeld. = truecxx . . $ `<external>/14268322491693841775/stdbool.h:37:9`!;
799 JE_specialCompletecxx . . $ JE_specialComplete(8fbe6856f5410d23).(playerNum, playercxx . . $ player.[0].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..specialcxx . . $ $anonymous_type_55bed0e189d5bed_2#special.);
800 }
801
802 } /*Main End*/
803
804 if (astralDurationcxx . . $ astralDuration. > 0)
805 astralDurationcxx . . $ astralDuration.--;
806
807 shotAvailcxx . . $ shotAvail.[MAX_PWEAPONcxx . . $ `src/shots.h:33:9`!-1] = 0;
808 if (flareDurationcxx . . $ flareDuration. > 1)
809 {
810 if (specialWeaponFiltercxx . . $ specialWeaponFilter. != -99)
811 {
812 if (levelFiltercxx . . $ levelFilter. == -99 && levelBrightnesscxx . . $ levelBrightness. == -99)
813 {
814 filterActivecxx . . $ filterActive. = falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!;
815 }
816 if (!filterActivecxx . . $ filterActive.)
817 {
818 levelFiltercxx . . $ levelFilter. = specialWeaponFiltercxx . . $ specialWeaponFilter.;
819 if (levelFiltercxx . . $ levelFilter. == 7)
820 {
821 levelBrightnesscxx . . $ levelBrightness. = 0;
822 }
823 filterActivecxx . . $ filterActive. = truecxx . . $ `<external>/14268322491693841775/stdbool.h:37:9`!;
824 }
825
826 if (mt_randcxx . . $ mt_rand(f708dce9a8856c70).() % 2 == 0)
827 flareColChgcxx . . $ flareColChg. = -1;
828 else
829 flareColChgcxx . . $ flareColChg. = 1;
830
831 if (levelFiltercxx . . $ levelFilter. == 7)
832 {
833 if (levelBrightnesscxx . . $ levelBrightness. < -6)
834 {
835 flareColChgcxx . . $ flareColChg. = 1;
836 }
837 if (levelBrightnesscxx . . $ levelBrightness. > 6)
838 {
839 flareColChgcxx . . $ flareColChg. = -1;
840 }
841 levelBrightnesscxx . . $ levelBrightness. += flareColChgcxx . . $ flareColChg.;
842 }
843 }
844
845 if ((signed)(mt_randcxx . . $ mt_rand(f708dce9a8856c70).() % 6) < specialWeaponFreqcxx . . $ specialWeaponFreq.)
846 {
847 bcxx . . $ b. = MAX_PWEAPONcxx . . $ `src/shots.h:33:9`!;
848
849 if (linkToPlayercxx . . $ linkToPlayer.)
850 {
851 if (shotRepeatcxx . . $ shotRepeat.[SHOT_SPECIALcxx . . $ SHOT_SPECIAL.] == 0)
852 {
853 bcxx . . $ b. = player_shot_createcxx . . $ player_shot_create(47a6dcf6307ecf82).(0, SHOT_SPECIALcxx . . $ SHOT_SPECIAL., playercxx . . $ player.[0].xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x., playercxx . . $ player.[0].ycxx . . $ $anonymous_type_55bed0e189d5bed_4#y., mouseXcxx . . $ mouseX., mouseYcxx . . $ mouseY., specialWeaponWpncxx . . $ specialWeaponWpn., playerNum);
854 }
855 }
856 else
857 {
858 bcxx . . $ b. = player_shot_createcxx . . $ player_shot_create(47a6dcf6307ecf82).(0, SHOT_SPECIALcxx . . $ SHOT_SPECIAL., mt_randcxx . . $ mt_rand(f708dce9a8856c70).() % 280, mt_randcxx . . $ mt_rand(f708dce9a8856c70).() % 180, mouseXcxx . . $ mouseX., mouseYcxx . . $ mouseY., specialWeaponWpncxx . . $ specialWeaponWpn., playerNum);
859 }
860
861 if (spraySpecialcxx . . $ spraySpecial. && bcxx . . $ b. != MAX_PWEAPONcxx . . $ `src/shots.h:33:9`!)
862 {
863 playerShotDatacxx . . $ playerShotData.[bcxx . . $ b.].shotXMcxx . . $ $anonymous_type_fd5daa34a534a1d9_0#shotXM. = (mt_randcxx . . $ mt_rand(f708dce9a8856c70).() % 5) - 2;
864 playerShotDatacxx . . $ playerShotData.[bcxx . . $ b.].shotYMcxx . . $ $anonymous_type_fd5daa34a534a1d9_0#shotYM. = (mt_randcxx . . $ mt_rand(f708dce9a8856c70).() % 5) - 2;
865 if (playerShotDatacxx . . $ playerShotData.[bcxx . . $ b.].shotYMcxx . . $ $anonymous_type_fd5daa34a534a1d9_0#shotYM. == 0)
866 {
867 playerShotDatacxx . . $ playerShotData.[bcxx . . $ b.].shotYMcxx . . $ $anonymous_type_fd5daa34a534a1d9_0#shotYM.++;
868 }
869 }
870 }
871
872 flareDurationcxx . . $ flareDuration.--;
873 if (flareDurationcxx . . $ flareDuration. == 1)
874 {
875 specialWaitcxx . . $ specialWait. = nextSpecialWaitcxx . . $ nextSpecialWait.;
876 }
877 }
878 else if (flareStartcxx . . $ flareStart.)
879 {
880 flareStartcxx . . $ flareStart. = falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!;
881 shotRepeatcxx . . $ shotRepeat.[SHOT_SPECIALcxx . . $ SHOT_SPECIAL.] = linkToPlayercxx . . $ linkToPlayer. ? 15 : 200;
882 flareDurationcxx . . $ flareDuration. = 0;
883 if (levelFiltercxx . . $ levelFilter. == specialWeaponFiltercxx . . $ specialWeaponFilter.)
884 {
885 levelFiltercxx . . $ levelFilter. = -99;
886 levelBrightnesscxx . . $ levelBrightness. = -99;
887 filterActivecxx . . $ filterActive. = falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!;
888 }
889 }
890
891 if (zinglonDurationcxx . . $ zinglonDuration. > 1)
892 {
893 tempcxx . . $ temp. = 25 - abscxx . . $ abs(7864480464b09eea).(zinglonDurationcxx . . $ zinglonDuration. - 25);
894
895 JE_barBrightcxx . . $ JE_barBright(ad548318d53dbf5e).(VGAScreencxx . . $ VGAScreen., playercxx . . $ player.[0].xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x. + 7 - tempcxx . . $ temp., 0, playercxx . . $ player.[0].xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x. + 7 + tempcxx . . $ temp., 184);
896 JE_barBrightcxx . . $ JE_barBright(ad548318d53dbf5e).(VGAScreencxx . . $ VGAScreen., playercxx . . $ player.[0].xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x. + 7 - tempcxx . . $ temp. - 2, 0, playercxx . . $ player.[0].xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x. + 7 + tempcxx . . $ temp. + 2, 184);
897
898 zinglonDurationcxx . . $ zinglonDuration.--;
899 if (zinglonDurationcxx . . $ zinglonDuration. % 5 == 0)
900 {
901 shotAvailcxx . . $ shotAvail.[MAX_PWEAPONcxx . . $ `src/shots.h:33:9`!-1] = 1;
902 }
903 }
904 }
905
906 void JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(signed int x, signed int y, signed int delta_y, unsigned int type, boolcxx . . $ `<external>/14268322491693841775/stdbool.h:36:9`! fixed_position, boolcxx . . $ `<external>/14268322491693841775/stdbool.h:36:9`! follow_player)
907 {
908 const structcxx . . $ JE_setupExplosion(9c65cb39d99632c2).$anonymous_type_0# {
909 JE_wordcxx . . $ JE_word# spritecxx . . $ JE_setupExplosion(9c65cb39d99632c2).$anonymous_type_0#sprite.;
910 JE_bytecxx . . $ JE_byte# ttlcxx . . $ JE_setupExplosion(9c65cb39d99632c2).$anonymous_type_0#ttl.;
911 } explosion_data[53] /* [1..53] */ = {
912 { 144, 7 },
913 { 120, 12 },
914 { 190, 12 },
915 { 209, 12 },
916 { 152, 12 },
917 { 171, 12 },
918 { 133, 7 }, /*White Smoke*/
919 { 1, 12 },
920 { 20, 12 },
921 { 39, 12 },
922 { 58, 12 },
923 { 110, 3 },
924 { 76, 7 },
925 { 91, 3 },
926 /*15*/ { 227, 3 },
927 { 230, 3 },
928 { 233, 3 },
929 { 252, 3 },
930 { 246, 3 },
931 /*20*/ { 249, 3 },
932 { 265, 3 },
933 { 268, 3 },
934 { 271, 3 },
935 { 236, 3 },
936 /*25*/ { 239, 3 },
937 { 242, 3 },
938 { 261, 3 },
939 { 274, 3 },
940 { 277, 3 },
941 /*30*/ { 280, 3 },
942 { 299, 3 },
943 { 284, 3 },
944 { 287, 3 },
945 { 290, 3 },
946 /*35*/ { 293, 3 },
947 { 165, 8 }, /*Coin Values*/
948 { 184, 8 },
949 { 203, 8 },
950 { 222, 8 },
951 { 168, 8 },
952 { 187, 8 },
953 { 206, 8 },
954 { 225, 10 },
955 { 169, 10 },
956 { 188, 10 },
957 { 207, 20 },
958 { 226, 14 },
959 { 170, 14 },
960 { 189, 14 },
961 { 208, 14 },
962 { 246, 14 },
963 { 227, 14 },
964 { 265, 14 }
965 };
966
967 if (y > -16 && y < 190)
968 {
969 for (int i = 0; i < MAX_EXPLOSIONScxx . . $ `src/varz.h:49:9`!; i++)
970 {
971 if (explosionscxx . . $ explosions.[i].ttlcxx . . $ $anonymous_type_75a5d6b19c4f0372_5#ttl. == 0)
972 {
973 explosionscxx . . $ explosions.[i].xcxx . . $ $anonymous_type_75a5d6b19c4f0372_5#x. = x;
974 explosionscxx . . $ explosions.[i].ycxx . . $ $anonymous_type_75a5d6b19c4f0372_5#y. = y;
975 if (type == 6)
976 {
977 explosionscxx . . $ explosions.[i].ycxx . . $ $anonymous_type_75a5d6b19c4f0372_5#y. += 12;
978 explosionscxx . . $ explosions.[i].xcxx . . $ $anonymous_type_75a5d6b19c4f0372_5#x. += 2;
979 }
980 else if (type == 98)
981 {
982 type = 6;
983 }
984 explosionscxx . . $ explosions.[i].spritecxx . . $ $anonymous_type_75a5d6b19c4f0372_5#sprite. = explosion_data[type].spritecxx . . $ JE_setupExplosion(9c65cb39d99632c2).$anonymous_type_0#sprite.;
985 explosionscxx . . $ explosions.[i].ttlcxx . . $ $anonymous_type_75a5d6b19c4f0372_5#ttl. = explosion_data[type].ttlcxx . . $ JE_setupExplosion(9c65cb39d99632c2).$anonymous_type_0#ttl.;
986 explosionscxx . . $ explosions.[i].follow_playercxx . . $ $anonymous_type_75a5d6b19c4f0372_5#follow_player. = follow_player;
987 explosionscxx . . $ explosions.[i].fixed_positioncxx . . $ $anonymous_type_75a5d6b19c4f0372_5#fixed_position. = fixed_position;
988 explosionscxx . . $ explosions.[i].delta_xcxx . . $ $anonymous_type_75a5d6b19c4f0372_5#delta_x. = 0;
989 explosionscxx . . $ explosions.[i].delta_ycxx . . $ $anonymous_type_75a5d6b19c4f0372_5#delta_y. = delta_y;
990 break;
991 }
992 }
993 }
994 }
995
996 void JE_setupExplosionLargecxx . . $ JE_setupExplosionLarge(c08e0f34ac44585d).(JE_booleancxx . . $ JE_boolean# enemyGround, JE_bytecxx . . $ JE_byte# exploNum, JE_integercxx . . $ JE_integer# x, JE_integercxx . . $ JE_integer# y)
997 {
998 if (y >= 0)
999 {
1000 if (enemyGround)
1001 {
1002 JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(x - 6, y - 14, 0, 2, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!);
1003 JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(x + 6, y - 14, 0, 4, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!);
1004 JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(x - 6, y, 0, 3, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!);
1005 JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(x + 6, y, 0, 5, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!);
1006 }
1007 else
1008 {
1009 JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(x - 6, y - 14, 0, 7, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!);
1010 JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(x + 6, y - 14, 0, 9, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!);
1011 JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(x - 6, y, 0, 8, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!);
1012 JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(x + 6, y, 0, 10, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!);
1013 }
1014
1015 boolcxx . . $ `<external>/14268322491693841775/stdbool.h:36:9`! big;
1016
1017 if (exploNum > 10)
1018 {
1019 exploNum -= 10;
1020 big = truecxx . . $ `<external>/14268322491693841775/stdbool.h:37:9`!;
1021 }
1022 else
1023 {
1024 big = falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!;
1025 }
1026
1027 if (exploNum)
1028 {
1029 for (int i = 0; i < MAX_REPEATING_EXPLOSIONScxx . . $ `src/varz.h:50:9`!; i++)
1030 {
1031 if (rep_explosionscxx . . $ rep_explosions.[i].ttlcxx . . $ $anonymous_type_75a5d6b19c4f0372_6#ttl. == 0)
1032 {
1033 rep_explosionscxx . . $ rep_explosions.[i].ttlcxx . . $ $anonymous_type_75a5d6b19c4f0372_6#ttl. = exploNum;
1034 rep_explosionscxx . . $ rep_explosions.[i].delaycxx . . $ $anonymous_type_75a5d6b19c4f0372_6#delay. = 2;
1035 rep_explosionscxx . . $ rep_explosions.[i].xcxx . . $ $anonymous_type_75a5d6b19c4f0372_6#x. = x;
1036 rep_explosionscxx . . $ rep_explosions.[i].ycxx . . $ $anonymous_type_75a5d6b19c4f0372_6#y. = y;
1037 rep_explosionscxx . . $ rep_explosions.[i].bigcxx . . $ $anonymous_type_75a5d6b19c4f0372_6#big. = big;
1038 break;
1039 }
1040 }
1041 }
1042 }
1043 }
1044
1045 void JE_wipeShieldArmorBarscxx . . $ JE_wipeShieldArmorBars(49f6e7a06ebc5aa8).(void)
1046 {
1047 if (!twoPlayerModecxx . . $ twoPlayerMode. || galagaModecxx . . $ galagaMode.)
1048 {
1049 fill_rectangle_xycxx . . $ fill_rectangle_xy(da1d960d0d6e485d).(VGAScreenSegcxx . . $ VGAScreenSeg., 270, 137, 278, 194 - playercxx . . $ player.[0].shieldcxx . . $ $anonymous_type_55bed0e189d5bed_4#shield. * 2, 0);
1050 }
1051 else
1052 {
1053 fill_rectangle_xycxx . . $ fill_rectangle_xy(da1d960d0d6e485d).(VGAScreenSegcxx . . $ VGAScreenSeg., 270, 60 - 44, 278, 60, 0);
1054 fill_rectangle_xycxx . . $ fill_rectangle_xy(da1d960d0d6e485d).(VGAScreenSegcxx . . $ VGAScreenSeg., 270, 194 - 44, 278, 194, 0);
1055 }
1056 if (!twoPlayerModecxx . . $ twoPlayerMode. || galagaModecxx . . $ galagaMode.)
1057 {
1058 fill_rectangle_xycxx . . $ fill_rectangle_xy(da1d960d0d6e485d).(VGAScreenSegcxx . . $ VGAScreenSeg., 307, 137, 315, 194 - playercxx . . $ player.[0].armorcxx . . $ $anonymous_type_55bed0e189d5bed_4#armor. * 2, 0);
1059 }
1060 else
1061 {
1062 fill_rectangle_xycxx . . $ fill_rectangle_xy(da1d960d0d6e485d).(VGAScreenSegcxx . . $ VGAScreenSeg., 307, 60 - 44, 315, 60, 0);
1063 fill_rectangle_xycxx . . $ fill_rectangle_xy(da1d960d0d6e485d).(VGAScreenSegcxx . . $ VGAScreenSeg., 307, 194 - 44, 315, 194, 0);
1064 }
1065 }
1066
1067 JE_bytecxx . . $ JE_byte# JE_playerDamagecxx . . $ JE_playerDamage(9c37ec4f31b8640b).(JE_bytecxx . . $ JE_byte# temp,
1068 Playercxx . . $ Player# *this_player)
1069 {
1070 int playerDamage = 0;
1071 soundQueuecxx . . $ soundQueue.[7] = S_SHIELD_HITcxx . . $ S_SHIELD_HIT.;
1072
1073 /* Player Damage Routines */
1074 if (this_player->shieldcxx . . $ $anonymous_type_55bed0e189d5bed_4#shield. < temp)
1075 {
1076 playerDamage = temp;
1077 temp -= this_player->shieldcxx . . $ $anonymous_type_55bed0e189d5bed_4#shield.;
1078 this_player->shieldcxx . . $ $anonymous_type_55bed0e189d5bed_4#shield. = 0;
1079
1080 if (temp > 0)
1081 {
1082 /*Through Shields - Now Armor */
1083
1084 if (this_player->armorcxx . . $ $anonymous_type_55bed0e189d5bed_4#armor. < temp)
1085 {
1086 temp -= this_player->armorcxx . . $ $anonymous_type_55bed0e189d5bed_4#armor.;
1087 this_player->armorcxx . . $ $anonymous_type_55bed0e189d5bed_4#armor. = 0;
1088
1089 if (this_player->is_alivecxx . . $ $anonymous_type_55bed0e189d5bed_4#is_alive. && !youAreCheatingcxx . . $ youAreCheating.)
1090 {
1091 levelTimercxx . . $ levelTimer. = falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!;
1092 this_player->is_alivecxx . . $ $anonymous_type_55bed0e189d5bed_4#is_alive. = falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!;
1093 this_player->exploding_tickscxx . . $ $anonymous_type_55bed0e189d5bed_4#exploding_ticks. = 60;
1094 levelEndcxx . . $ levelEnd. = 40;
1095 tempVolumecxx . . $ tempVolume. = tyrMusicVolumecxx . . $ tyrMusicVolume.;
1096 soundQueuecxx . . $ soundQueue.[1] = S_EXPLOSION_22cxx . . $ S_EXPLOSION_22.;
1097 }
1098 }
1099 else
1100 {
1101 this_player->armorcxx . . $ $anonymous_type_55bed0e189d5bed_4#armor. -= temp;
1102 soundQueuecxx . . $ soundQueue.[7] = S_HULL_HITcxx . . $ S_HULL_HIT.;
1103 }
1104 }
1105 }
1106 else
1107 {
1108 this_player->shieldcxx . . $ $anonymous_type_55bed0e189d5bed_4#shield. -= temp;
1109
1110 JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(this_player->xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x. - 17, this_player->ycxx . . $ $anonymous_type_55bed0e189d5bed_4#y. - 12, 0, 14, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, !twoPlayerModecxx . . $ twoPlayerMode.);
1111 JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(this_player->xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x. - 5 , this_player->ycxx . . $ $anonymous_type_55bed0e189d5bed_4#y. - 12, 0, 15, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, !twoPlayerModecxx . . $ twoPlayerMode.);
1112 JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(this_player->xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x. + 7 , this_player->ycxx . . $ $anonymous_type_55bed0e189d5bed_4#y. - 12, 0, 16, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, !twoPlayerModecxx . . $ twoPlayerMode.);
1113 JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(this_player->xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x. + 19, this_player->ycxx . . $ $anonymous_type_55bed0e189d5bed_4#y. - 12, 0, 17, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, !twoPlayerModecxx . . $ twoPlayerMode.);
1114
1115 JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(this_player->xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x. - 17, this_player->ycxx . . $ $anonymous_type_55bed0e189d5bed_4#y. + 2, 0, 18, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, !twoPlayerModecxx . . $ twoPlayerMode.);
1116 JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(this_player->xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x. + 19, this_player->ycxx . . $ $anonymous_type_55bed0e189d5bed_4#y. + 2, 0, 19, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, !twoPlayerModecxx . . $ twoPlayerMode.);
1117
1118 JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(this_player->xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x. - 17, this_player->ycxx . . $ $anonymous_type_55bed0e189d5bed_4#y. + 16, 0, 20, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, !twoPlayerModecxx . . $ twoPlayerMode.);
1119 JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(this_player->xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x. - 5 , this_player->ycxx . . $ $anonymous_type_55bed0e189d5bed_4#y. + 16, 0, 21, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, !twoPlayerModecxx . . $ twoPlayerMode.);
1120 JE_setupExplosioncxx . . $ JE_setupExplosion(9c65cb39d99632c2).(this_player->xcxx . . $ $anonymous_type_55bed0e189d5bed_4#x. + 7 , this_player->ycxx . . $ $anonymous_type_55bed0e189d5bed_4#y. + 16, 0, 22, falsecxx . . $ `<external>/14268322491693841775/stdbool.h:38:9`!, !twoPlayerModecxx . . $ twoPlayerMode.);
1121 }
1122
1123 JE_wipeShieldArmorBarscxx . . $ JE_wipeShieldArmorBars(49f6e7a06ebc5aa8).();
1124 VGAScreencxx . . $ VGAScreen. = VGAScreenSegcxx . . $ VGAScreenSeg.; /* side-effect of game_screen */
1125 JE_drawShieldcxx . . $ JE_drawShield(49f6e7a06ebc5aa8).();
1126 JE_drawArmorcxx . . $ JE_drawArmor(49f6e7a06ebc5aa8).();
1127 VGAScreencxx . . $ VGAScreen. = game_screencxx . . $ game_screen.; /* side-effect of game_screen */
1128
1129 return playerDamage;
1130 }
1131
1132 JE_wordcxx . . $ JE_word# JE_portConfigscxx . . $ JE_portConfigs(32a7769d58713265).(void)
1133 {
1134 const uintcxx . . $ uint# player_index = twoPlayerModecxx . . $ twoPlayerMode. ? 1 : 0;
1135 return tempWcxx . . $ tempW. = weaponPortcxx . . $ weaponPort.[playercxx . . $ player.[player_index].itemscxx . . $ $anonymous_type_55bed0e189d5bed_4#items..weaponcxx . . $ $anonymous_type_55bed0e189d5bed_2#weapon.[REAR_WEAPONcxx . . $ REAR_WEAPON.].idcxx . . $ $anonymous_type_55bed0e189d5bed_2#$anonymous_type_3#id.].opnumcxx . . $ $anonymous_type_66fcae0887b82ce8_1#opnum.;
1136 }
1137
1138 void JE_drawShieldcxx . . $ JE_drawShield(49f6e7a06ebc5aa8).(void)
1139 {
1140 if (twoPlayerModecxx . . $ twoPlayerMode. && !galagaModecxx . . $ galagaMode.)
1141 {
1142 for (uintcxx . . $ uint# i = 0; i < COUNTOFcxx . . $ `src/opentyr.h:27:9`!(player); ++i)
1143 JE_dBar3cxx . . $ JE_dBar3(6011c4bc33073089).(VGAScreencxx . . $ VGAScreen., 270, 60 + 134 * i, roundf(playercxx . . $ player.[i].shieldcxx . . $ $anonymous_type_55bed0e189d5bed_4#shield. * 0.8f), 144);
1144 }
1145 else
1146 {
1147 JE_dBar3cxx . . $ JE_dBar3(6011c4bc33073089).(VGAScreencxx . . $ VGAScreen., 270, 194, playercxx . . $ player.[0].shieldcxx . . $ $anonymous_type_55bed0e189d5bed_4#shield., 144);
1148 if (playercxx . . $ player.[0].shieldcxx . . $ $anonymous_type_55bed0e189d5bed_4#shield. != playercxx . . $ player.[0].shield_maxcxx . . $ $anonymous_type_55bed0e189d5bed_4#shield_max.)
1149 {
1150 const uintcxx . . $ uint# y = 193 - (playercxx . . $ player.[0].shield_maxcxx . . $ $anonymous_type_55bed0e189d5bed_4#shield_max. * 2);
1151 JE_rectanglecxx . . $ JE_rectangle(fa5faf37b232239e).(VGAScreencxx . . $ VGAScreen., 270, y, 278, y, 68); /* <MXD> SEGa000 */
1152 }
1153 }
1154 }
1155
1156 void JE_drawArmorcxx . . $ JE_drawArmor(49f6e7a06ebc5aa8).(void)
1157 {
1158 for (uintcxx . . $ uint# i = 0; i < COUNTOFcxx . . $ `src/opentyr.h:27:9`!(player); ++i)
1159 if (playercxx . . $ player.[i].armorcxx . . $ $anonymous_type_55bed0e189d5bed_4#armor. > 28)
1160 playercxx . . $ player.[i].armorcxx . . $ $anonymous_type_55bed0e189d5bed_4#armor. = 28;
1161
1162 if (twoPlayerModecxx . . $ twoPlayerMode. && !galagaModecxx . . $ galagaMode.)
1163 {
1164 for (uintcxx . . $ uint# i = 0; i < COUNTOFcxx . . $ `src/opentyr.h:27:9`!(player); ++i)
1165 JE_dBar3cxx . . $ JE_dBar3(6011c4bc33073089).(VGAScreencxx . . $ VGAScreen., 307, 60 + 134 * i, roundf(playercxx . . $ player.[i].armorcxx . . $ $anonymous_type_55bed0e189d5bed_4#armor. * 0.8f), 224);
1166 }
1167 else
1168 {
1169 JE_dBar3cxx . . $ JE_dBar3(6011c4bc33073089).(VGAScreencxx . . $ VGAScreen., 307, 194, playercxx . . $ player.[0].armorcxx . . $ $anonymous_type_55bed0e189d5bed_4#armor., 224);
1170 }
1171 }
1172
1173 void JE_doSPcxx . . $ JE_doSP(92c8302fc7928c72).(JE_wordcxx . . $ JE_word# x, JE_wordcxx . . $ JE_word# y, JE_wordcxx . . $ JE_word# num, JE_bytecxx . . $ JE_byte# explowidth, JE_bytecxx . . $ JE_byte# color) /* superpixels */
1174 {
1175 for (tempcxx . . $ temp. = 0; tempcxx . . $ temp. < num; tempcxx . . $ temp.++)
1176 {
1177 JE_realcxx . . $ JE_real# tempr = mt_rand_lt1cxx . . $ mt_rand_lt1(9b8c9e39889c762c).() * (2 * M_PIcxx . . $ `<external>/11263917310783833665/math.h:1121:10`!);
1178 signed int tempy = roundf(cosf(tempr) * mt_rand_1cxx . . $ mt_rand_1(9b8c9e39889c762c).() * explowidth);
1179 signed int tempx = roundf(sinf(tempr) * mt_rand_1cxx . . $ mt_rand_1(9b8c9e39889c762c).() * explowidth);
1180
1181 if (++last_superpixelcxx . . $ last_superpixel. >= MAX_SUPERPIXELScxx . . $ `src/varz.h:51:9`!)
1182 last_superpixelcxx . . $ last_superpixel. = 0;
1183 superpixelscxx . . $ superpixels.[last_superpixelcxx . . $ last_superpixel.].xcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#x. = tempx + x;
1184 superpixelscxx . . $ superpixels.[last_superpixelcxx . . $ last_superpixel.].ycxx . . $ $anonymous_type_75a5d6b19c4f0372_7#y. = tempy + y;
1185 superpixelscxx . . $ superpixels.[last_superpixelcxx . . $ last_superpixel.].delta_xcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#delta_x. = tempx;
1186 superpixelscxx . . $ superpixels.[last_superpixelcxx . . $ last_superpixel.].delta_ycxx . . $ $anonymous_type_75a5d6b19c4f0372_7#delta_y. = tempy + 1;
1187 superpixelscxx . . $ superpixels.[last_superpixelcxx . . $ last_superpixel.].colorcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#color. = color;
1188 superpixelscxx . . $ superpixels.[last_superpixelcxx . . $ last_superpixel.].zcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#z. = 15;
1189 }
1190 }
1191
1192 void JE_drawSPcxx . . $ JE_drawSP(49f6e7a06ebc5aa8).(void)
1193 {
1194 for (int i = MAX_SUPERPIXELScxx . . $ `src/varz.h:51:9`!; i--; )
1195 {
1196 if (superpixelscxx . . $ superpixels.[i].zcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#z.)
1197 {
1198 superpixelscxx . . $ superpixels.[i].xcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#x. += superpixelscxx . . $ superpixels.[i].delta_xcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#delta_x.;
1199 superpixelscxx . . $ superpixels.[i].ycxx . . $ $anonymous_type_75a5d6b19c4f0372_7#y. += superpixelscxx . . $ superpixels.[i].delta_ycxx . . $ $anonymous_type_75a5d6b19c4f0372_7#delta_y.;
1200
1201 if (superpixelscxx . . $ superpixels.[i].xcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#x. < (unsigned)VGAScreencxx . . $ VGAScreen.->wcxx . . $ SDL_Surface#w. && superpixelscxx . . $ superpixels.[i].ycxx . . $ $anonymous_type_75a5d6b19c4f0372_7#y. < (unsigned)VGAScreencxx . . $ VGAScreen.->hcxx . . $ SDL_Surface#h.)
1202 {
1203 Uint8cxx . . $ Uint8# *s = (Uint8cxx . . $ Uint8# *)VGAScreencxx . . $ VGAScreen.->pixelscxx . . $ SDL_Surface#pixels.; /* screen pointer, 8-bit specific */
1204 s += superpixelscxx . . $ superpixels.[i].ycxx . . $ $anonymous_type_75a5d6b19c4f0372_7#y. * VGAScreencxx . . $ VGAScreen.->pitchcxx . . $ SDL_Surface#pitch.;
1205 s += superpixelscxx . . $ superpixels.[i].xcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#x.;
1206
1207 *s = (((*s & 0x0f) + superpixelscxx . . $ superpixels.[i].zcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#z.) >> 1) + superpixelscxx . . $ superpixels.[i].colorcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#color.;
1208 if (superpixelscxx . . $ superpixels.[i].xcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#x. > 0)
1209 *(s - 1) = (((*(s - 1) & 0x0f) + (superpixelscxx . . $ superpixels.[i].zcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#z. >> 1)) >> 1) + superpixelscxx . . $ superpixels.[i].colorcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#color.;
1210 if (superpixelscxx . . $ superpixels.[i].xcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#x. < VGAScreencxx . . $ VGAScreen.->wcxx . . $ SDL_Surface#w. - 1u)
1211 *(s + 1) = (((*(s + 1) & 0x0f) + (superpixelscxx . . $ superpixels.[i].zcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#z. >> 1)) >> 1) + superpixelscxx . . $ superpixels.[i].colorcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#color.;
1212 if (superpixelscxx . . $ superpixels.[i].ycxx . . $ $anonymous_type_75a5d6b19c4f0372_7#y. > 0)
1213 *(s - VGAScreencxx . . $ VGAScreen.->pitchcxx . . $ SDL_Surface#pitch.) = (((*(s - VGAScreencxx . . $ VGAScreen.->pitchcxx . . $ SDL_Surface#pitch.) & 0x0f) + (superpixelscxx . . $ superpixels.[i].zcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#z. >> 1)) >> 1) + superpixelscxx . . $ superpixels.[i].colorcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#color.;
1214 if (superpixelscxx . . $ superpixels.[i].ycxx . . $ $anonymous_type_75a5d6b19c4f0372_7#y. < VGAScreencxx . . $ VGAScreen.->hcxx . . $ SDL_Surface#h. - 1u)
1215 *(s + VGAScreencxx . . $ VGAScreen.->pitchcxx . . $ SDL_Surface#pitch.) = (((*(s + VGAScreencxx . . $ VGAScreen.->pitchcxx . . $ SDL_Surface#pitch.) & 0x0f) + (superpixelscxx . . $ superpixels.[i].zcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#z. >> 1)) >> 1) + superpixelscxx . . $ superpixels.[i].colorcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#color.;
1216 }
1217
1218 superpixelscxx . . $ superpixels.[i].zcxx . . $ $anonymous_type_75a5d6b19c4f0372_7#z.--;
1219 }
1220 }
1221 }