Wing Commander II
Reconstructed Win32 source (1996)
Loading...
Searching...
No Matches
destroy.c
Go to the documentation of this file.
1/*
2 * Ship destruction and mission ejection pods.
3 *
4 * Retail object 0x446710-0x44690F (link order; see docs/ORDER.md).
5 */
6#include "game.h"
7
8short g_bMissionDeathSequencePending = 0; /* 0x0049b720 */
9short g_bMissionEjectionPodSpawned = 0; /* 0x0049b724 */
10
11/* Function start: 0x446710 */
36
37void set_objects_data(short obj, short type, short owner, short matchObjectClass);
38void PlaySfxWaveFileByNumber(int soundNumber, int sourceObject, int looping);
39void set_special(short ship, short special);
40void zero_vector(FixedVector *vector);
41
42/* Function start: 0x446823 */
44{
45 short initialShip;
46
48 OBJECT_DATA_EJECTION_POD].shapeSet == 0) {
51 FetchDiskPacketRetrying("pilotanm.vga", 2, 0);
52 }
57 for (initialShip = 0; initialShip < 8; initialShip++) {
60 g_acMissionShipStatusFlagsBytes[initialShip] |= 2;
61 if (obj == g_nYourWingman)
62 g_nYourWingman = -1;
63 }
64 }
65}
66
67/* Linker commons defined here. LINK lays a unit's commons out by the
68 * identifiers' hash keys, so these spellings follow the original addresses. */
69short g_nPendingEjectionShip; /* 0x005d1bc4 */
void set_special(short ship, short special)
Definition logic.c:493
short ShipExplosion(short obj)
Definition ship.c:1786
void * FetchDiskPacketRetrying(char *fileName, short section, short flags)
Definition disk.c:187
void zero_vector(FixedVector *vector)
Definition geom.c:197
void BeginShipDestructionSequence(short obj)
Definition destroy.c:12
void SpawnMissionEjectionPod(short obj)
Definition destroy.c:43
void PlaySfxWaveFileByNumber(int soundNumber, int sourceObject, int looping)
Definition music.c:490
void send_message(short obj, signed char message)
Definition cockpt.c:3116
void RecordCannedSceneObjectEvent(short obj, int event)
Definition taperec.c:176
void set_objects_data(short obj, short type, short owner, short matchObjectClass)
Definition ship.c:347
void explosion_shock_wave(short obj, short blastDamage)
Definition ship.c:1729
Shared Win32 declarations, types and library interfaces.
@ OBJECT_DATA_EJECTION_POD
Definition game_data.h:457
@ OBJECT_TYPE_EXPLOSION2
Definition game_data.h:105
#define OBJECT_DATA_INDEX(sourceType)
Definition game_data.h:1596
@ SPECIAL_MANEUVER_UNKNOWN_9
Definition game_data.h:269
short g_nYourWingman
Definition viewrect.c:75
short g_7_asShipBurstStageCountdown[10]
Definition ship.c:3063
short g_bMissionEjectionPodSpawned
Definition destroy.c:9
ObjectTypeData g_aObjectTypeData[OBJECT_DATA_COUNT]
Definition campglob.c:310
short g_asObjectScreenX[SPACE_OBJECT_COUNT]
Definition viewrect.c:95
signed char g_acMissionShipStatusFlagsBytes[8]
Definition logic.c:1054
FixedVector g_aShipVelocity[SPACE_OBJECT_COUNT]
Definition viewrect.c:109
short g_asShipMissionIndex[12]
Definition viewrect.c:153
MissionShipRecord g_aMissionShips[MISSION_SHIP_COUNT]
Definition hotspot.c:240
signed char g_acObjectType[SPACE_OBJECT_COUNT]
Definition viewrect.c:101
short g_asObjectCounter[SPACE_OBJECT_COUNT]
Definition viewrect.c:110
short g_nPendingEjectionShip
Definition destroy.c:69
MissionHeader g_13_stMissionHeaderBlock
Definition hotspot.c:253
short g_bMissionDeathSequencePending
Definition destroy.c:8
short initialMissionShips[8]
Definition game_data.h:1347
signed char state
Definition game_data.h:1380
unsigned char * shapeSet
Definition game_data.h:392