2020-07-18 02:47:33 +02:00
|
|
|
#ifndef _VARIABLES_H_
|
|
|
|
#define _VARIABLES_H_
|
|
|
|
|
|
|
|
#include "ultra64.h"
|
|
|
|
#include "common_structs.h"
|
2020-08-10 23:35:37 +02:00
|
|
|
#include "types.h"
|
2020-10-13 03:28:01 +02:00
|
|
|
#include "macros.h"
|
2020-08-23 01:39:45 +02:00
|
|
|
#include "enums.h"
|
2020-07-18 02:47:33 +02:00
|
|
|
|
2020-09-22 05:10:53 +02:00
|
|
|
extern PlayerStatus* gPlayerStatusPtr;
|
2020-10-03 22:04:49 +02:00
|
|
|
extern CollisionStatus gCollisionStatus;
|
2021-03-23 03:25:48 +01:00
|
|
|
extern GameStatus gGameStatus;
|
|
|
|
extern GameStatus* gGameStatusPtr;
|
2023-05-22 16:37:25 +02:00
|
|
|
extern u32 gRandSeed;
|
2022-05-18 09:53:28 +02:00
|
|
|
extern ItemData gItemTable[365];
|
2020-08-17 14:40:21 +02:00
|
|
|
extern UNK_FUN_PTR(gCurrentUpdateFunction);
|
2022-01-16 14:28:09 +01:00
|
|
|
extern MoveData gMoveTable[185];
|
2020-08-14 16:25:33 +02:00
|
|
|
|
2020-10-16 22:29:55 +02:00
|
|
|
extern s32 gBattleState;
|
2020-09-22 02:56:17 +02:00
|
|
|
extern BattleStatus gBattleStatus;
|
2023-01-15 10:22:41 +01:00
|
|
|
extern s32 gLastDrawBattleState;
|
2021-07-19 13:49:30 +02:00
|
|
|
extern s32 D_800DC4D4;
|
2023-01-10 07:33:09 +01:00
|
|
|
extern s32 gDefeatedBattleSubstate;
|
2022-11-16 10:46:50 +01:00
|
|
|
extern s32 gBattleSubState;
|
2023-01-10 07:33:09 +01:00
|
|
|
extern s32 gDefeatedBattleState;
|
2022-11-22 05:12:28 +01:00
|
|
|
extern s32 gCurrentBattleID;
|
2021-07-19 13:49:30 +02:00
|
|
|
extern s32 D_800DC4E0;
|
2023-01-15 10:22:41 +01:00
|
|
|
extern s32 gCurrentStageID;
|
2021-07-19 13:49:30 +02:00
|
|
|
extern s32 D_800DC4F0;
|
2023-01-15 10:22:41 +01:00
|
|
|
extern struct Battle* gOverrideBattlePtr;
|
2021-07-19 13:49:30 +02:00
|
|
|
extern s32 D_800DC4F8;
|
2020-09-22 02:56:17 +02:00
|
|
|
|
2020-09-18 22:57:52 +02:00
|
|
|
extern s32 D_802DAC98;
|
2020-08-14 16:25:33 +02:00
|
|
|
|
2020-10-22 02:07:00 +02:00
|
|
|
extern EntityList gWorldEntityList;
|
|
|
|
extern EntityList gBattleEntityList;
|
|
|
|
extern EntityList* gCurrentEntityListPtr;
|
2020-08-17 14:40:21 +02:00
|
|
|
|
2022-11-22 05:12:28 +01:00
|
|
|
extern WorkerList gWorldWorkerList;
|
|
|
|
extern WorkerList gBattleWorkerList;
|
|
|
|
extern WorkerList* gCurrentWorkerListPtr;
|
2020-09-25 23:18:09 +02:00
|
|
|
|
2020-10-22 02:07:00 +02:00
|
|
|
extern NpcList gWorldNpcList;
|
|
|
|
extern NpcList gBattleNpcList;
|
|
|
|
extern NpcList* gCurrentNpcListPtr;
|
2020-08-17 14:40:21 +02:00
|
|
|
|
2020-10-22 02:07:00 +02:00
|
|
|
extern ShadowList gWorldShadowList;
|
|
|
|
extern ShadowList gBattleShadowList;
|
|
|
|
extern ShadowList* gCurrentShadowListPtr;
|
2020-08-17 14:40:21 +02:00
|
|
|
|
2020-08-20 00:48:15 +02:00
|
|
|
extern Camera gCameras[4];
|
2020-09-06 17:53:48 +02:00
|
|
|
extern s32 gCurrentCameraID;
|
2020-08-20 00:48:15 +02:00
|
|
|
|
2021-02-16 11:32:34 +01:00
|
|
|
extern CollisionData gCollisionData;
|
|
|
|
|
2020-08-12 20:48:51 +02:00
|
|
|
extern s8 D_800A0900;
|
2022-03-26 12:47:10 +01:00
|
|
|
extern f32 GravityParamsStartFall[];
|
2022-09-13 08:26:57 +02:00
|
|
|
extern s16 FootstepSoundSelector;
|
2023-01-13 08:56:28 +01:00
|
|
|
extern u8* gBackgroundFogModePtr;
|
2023-02-06 01:13:45 +01:00
|
|
|
extern u16 gCurrentRoomDoorSounds;
|
2022-04-12 08:01:58 +02:00
|
|
|
extern s32 gEntityHideMode;
|
2020-12-03 09:07:39 +01:00
|
|
|
|
2021-02-18 12:54:07 +01:00
|
|
|
extern s32 D_8010C92C;
|
2022-01-20 14:08:24 +01:00
|
|
|
extern s32 D_8010C950;
|
2022-08-06 14:14:04 +02:00
|
|
|
extern HiddenPanelsData gCurrentHiddenPanels;
|
2022-03-10 10:55:38 +01:00
|
|
|
|
2020-08-16 05:19:00 +02:00
|
|
|
extern BackgroundHeader gBackgroundImage;
|
2020-07-18 02:47:33 +02:00
|
|
|
|
2022-06-17 11:21:13 +02:00
|
|
|
extern s32 CreateEntityVarArgBuffer[4];
|
2020-11-18 06:32:18 +01:00
|
|
|
|
2022-09-08 14:21:07 +02:00
|
|
|
extern f32 D_800F7B74;
|
2021-04-17 13:46:17 +02:00
|
|
|
|
2022-03-28 11:29:47 +02:00
|
|
|
extern CollisionData gZoneCollisionData;
|
2021-06-30 04:27:12 +02:00
|
|
|
|
2020-11-08 05:33:15 +01:00
|
|
|
// Animation related
|
2020-11-08 21:40:26 +01:00
|
|
|
extern AnimatedMeshList* gCurrentAnimMeshListPtr;
|
|
|
|
|
2020-11-08 05:33:15 +01:00
|
|
|
extern PartnerAnimations gPartnerAnimations[12];
|
2020-11-08 21:40:26 +01:00
|
|
|
|
2020-08-13 07:03:47 +02:00
|
|
|
// Triggers
|
2020-08-19 02:23:52 +02:00
|
|
|
extern s16 gTriggerCount;
|
2021-08-29 15:44:17 +02:00
|
|
|
extern TriggerList wTriggerList;
|
|
|
|
extern TriggerList bTriggerList;
|
2020-10-22 02:07:00 +02:00
|
|
|
extern TriggerList* gCurrentTriggerListPtr;
|
2020-08-13 07:03:47 +02:00
|
|
|
|
2020-10-15 00:22:43 +02:00
|
|
|
// Map transition data. Should probably be a struct
|
2021-08-16 20:14:58 +02:00
|
|
|
extern s16 gMapTransitionAlpha;
|
2021-03-21 13:16:00 +01:00
|
|
|
extern s8 D_800A0930;
|
|
|
|
extern s8 D_800A0931;
|
|
|
|
extern s16 D_800A0932[1];
|
2022-10-07 20:45:58 +02:00
|
|
|
extern s16 gMapTransitionFadeRate;
|
|
|
|
extern s16 gMapTransitionState;
|
|
|
|
extern s16 gMapTransitionStateTime;
|
2020-11-06 01:30:17 +01:00
|
|
|
extern s16 D_800A0948;
|
2020-10-15 00:22:43 +02:00
|
|
|
extern s16 D_800A0954;
|
|
|
|
extern s16 D_800A0956;
|
|
|
|
extern s16 D_800A0958;
|
|
|
|
extern s16 D_800A095A;
|
|
|
|
extern u8 D_800A095B;
|
|
|
|
extern s16 D_800A095C;
|
|
|
|
extern u8 D_800A095D;
|
|
|
|
extern s16 D_800A095E;
|
|
|
|
extern u8 D_800A095F;
|
|
|
|
extern s32 D_800A0960;
|
|
|
|
extern s32 D_800A0964;
|
2023-02-24 05:02:57 +01:00
|
|
|
extern s8 gNpcPlayerCollisionsEnabled;
|
2020-12-03 15:11:20 +01:00
|
|
|
extern s16 D_800A0BB8;
|
2020-08-11 23:38:21 +02:00
|
|
|
|
2023-02-17 02:56:57 +01:00
|
|
|
extern SpriteShadingProfile* gAuxSpriteShadingProfile;
|
|
|
|
extern SpriteShadingProfile* gSpriteShadingProfile;
|
2021-12-13 10:27:28 +01:00
|
|
|
|
2021-09-02 13:17:40 +02:00
|
|
|
extern Window gWindows[64];
|
2020-11-12 19:38:17 +01:00
|
|
|
|
2022-11-01 13:27:10 +01:00
|
|
|
extern s32 gEncounterState;
|
2021-06-15 10:05:16 +02:00
|
|
|
extern s16 gNpcCount;
|
2021-03-19 11:25:14 +01:00
|
|
|
extern s32 gOverrideFlags;
|
2022-04-05 14:53:40 +02:00
|
|
|
extern s16 D_8009A6A0;
|
|
|
|
extern s16 D_8009A6A2;
|
|
|
|
extern s16 D_8009A6A4;
|
|
|
|
extern s16 D_8009A6A6;
|
2020-08-12 22:53:01 +02:00
|
|
|
|
2021-04-01 20:00:29 +02:00
|
|
|
extern s8 D_800A0920;
|
2022-12-06 00:29:22 +01:00
|
|
|
extern s32 SavedReverbMode;
|
2021-04-01 20:00:29 +02:00
|
|
|
extern s8 D_800A0921;
|
|
|
|
extern s16 D_800A0922;
|
2022-10-16 00:24:05 +02:00
|
|
|
extern char wMapTexName[];
|
2022-09-06 17:09:50 +02:00
|
|
|
extern char wMapHitName[];
|
|
|
|
extern char wMapShapeName[];
|
2022-12-06 00:29:22 +01:00
|
|
|
extern char wMapBgName[];
|
2021-04-22 05:19:31 +02:00
|
|
|
extern u8 D_802D9D70; // player alpha1 copy?
|
|
|
|
extern u8 D_802D9D71; // player alpha2 copy?
|
|
|
|
|
2021-04-26 19:47:38 +02:00
|
|
|
extern DisplayContext D_80164000[];
|
2021-04-22 05:19:31 +02:00
|
|
|
|
2022-03-10 10:55:38 +01:00
|
|
|
extern WindowStyle gWindowStyles[];
|
|
|
|
|
2021-07-13 15:43:14 +02:00
|
|
|
extern MessagePrintState gMessagePrinters[3];
|
|
|
|
|
2021-04-22 05:19:31 +02:00
|
|
|
extern f32 gCurtainScale;
|
|
|
|
extern f32 gCurtainScaleGoal;
|
|
|
|
extern f32 gCurtainFade;
|
|
|
|
extern f32 gCurtainFadeGoal;
|
|
|
|
extern UNK_FUN_PTR(gCurtainDrawCallback);
|
2021-04-01 20:00:29 +02:00
|
|
|
|
2023-02-06 01:13:45 +01:00
|
|
|
extern u16 gCurrentDoorSounds;
|
2020-08-11 23:38:21 +02:00
|
|
|
|
2020-08-10 23:35:37 +02:00
|
|
|
extern UNK_TYPE D_800E92D8;
|
2020-08-12 03:01:33 +02:00
|
|
|
extern UNK_TYPE D_80147574;
|
2023-06-29 14:06:23 +02:00
|
|
|
extern b8 D_8014C248;
|
2021-06-16 11:52:15 +02:00
|
|
|
|
2023-01-02 02:58:39 +01:00
|
|
|
extern UNK_FUN_PTR(TalkNotificationCallback);
|
2023-03-06 08:44:48 +01:00
|
|
|
extern UNK_FUN_PTR(InteractNotificationCallback);
|
|
|
|
extern UNK_FUN_PTR(ISpyNotificationCallback);
|
|
|
|
extern UNK_FUN_PTR(PulseStoneNotificationCallback);
|
|
|
|
|
2022-03-26 12:47:10 +01:00
|
|
|
extern Entity* TweesterTouchingPartner;
|
2022-07-17 18:38:19 +02:00
|
|
|
extern Entity* TweesterTouchingPlayer;
|
2023-03-06 08:44:48 +01:00
|
|
|
|
2022-09-13 08:26:57 +02:00
|
|
|
extern s32 PrevPlayerDirection;
|
2022-09-15 21:39:16 +02:00
|
|
|
extern s32 PeachDisguiseNpcIndex;
|
2021-06-16 11:52:15 +02:00
|
|
|
extern s32 D_8010C980;
|
|
|
|
extern s32 D_8010C9A0;
|
2022-09-13 08:26:57 +02:00
|
|
|
extern s32 PrevPlayerCamRelativeYaw;
|
2021-06-16 11:52:15 +02:00
|
|
|
extern s32 D_800F7B44;
|
|
|
|
extern f32 D_8010C938;
|
|
|
|
extern f32 D_8010C990;
|
2023-02-18 09:13:07 +01:00
|
|
|
extern s32 NpcHitQueryColliderID;
|
2021-12-28 12:43:24 +01:00
|
|
|
extern Vec3s btl_actorHomePositions[];
|
2021-06-16 11:52:15 +02:00
|
|
|
|
2020-09-19 17:16:02 +02:00
|
|
|
extern SaveData gCurrentSaveFile;
|
|
|
|
|
2022-11-01 13:27:10 +01:00
|
|
|
extern s32 gEncounterSubState;
|
2021-04-22 05:19:31 +02:00
|
|
|
extern s32 timeFreezeMode;
|
2021-03-30 19:39:44 +02:00
|
|
|
extern s32 D_8009A678;
|
2020-10-14 03:55:04 +02:00
|
|
|
|
2020-10-15 00:22:43 +02:00
|
|
|
extern u8 D_800779B0;
|
2020-12-08 11:50:14 +01:00
|
|
|
extern u32 D_80078174;
|
2022-11-11 20:34:36 +01:00
|
|
|
extern s32 D_8008EEC0[12]; // partner IDs
|
2020-10-15 00:22:43 +02:00
|
|
|
extern u8 D_800A0963;
|
|
|
|
|
2022-07-17 18:38:19 +02:00
|
|
|
extern s32 D_802EA310[];
|
|
|
|
extern s32 Entity_WoodenCrate_RenderShatteredScript[];
|
|
|
|
|
2020-11-21 08:40:54 +01:00
|
|
|
|
2020-10-08 21:03:58 +02:00
|
|
|
// Scripts
|
2023-05-20 19:26:11 +02:00
|
|
|
extern EvtScript EVS_NpcDefeat;
|
2022-01-16 14:28:09 +01:00
|
|
|
extern EvtScript ShakeCam1;
|
|
|
|
extern EvtScript ShakeCamX;
|
2020-10-08 21:03:58 +02:00
|
|
|
|
2021-04-01 20:00:29 +02:00
|
|
|
extern MusicSettings gMusicSettings[4];
|
2020-10-08 21:03:58 +02:00
|
|
|
|
2020-12-25 00:39:47 +01:00
|
|
|
// OS
|
2022-12-11 08:43:29 +01:00
|
|
|
extern OSThread IdleThread; // idle thread, id 1
|
|
|
|
extern OSThread MainThread; // id 3
|
2021-03-11 09:08:22 +01:00
|
|
|
extern OSDevMgr __osPiDevMgr;
|
2020-12-25 00:39:47 +01:00
|
|
|
|
2021-01-11 04:52:08 +01:00
|
|
|
// gfx
|
|
|
|
extern DisplayContext* gDisplayContext;
|
2023-03-08 17:55:54 +01:00
|
|
|
extern Gfx* gMainGfxPos;
|
2021-01-11 04:52:08 +01:00
|
|
|
extern u16 gMatrixListPos;
|
2021-03-19 11:25:14 +01:00
|
|
|
extern s32 gCurrentDisplayContextIndex;
|
2021-01-11 04:52:08 +01:00
|
|
|
|
2021-02-10 15:42:36 +01:00
|
|
|
extern s32 D_80291FA8[];
|
|
|
|
extern s32 D_80291FD0[];
|
|
|
|
extern s32 D_80291FF8[];
|
|
|
|
extern s32 D_80292020[];
|
|
|
|
extern s32 D_80292048[];
|
|
|
|
extern s32 D_80292070[];
|
|
|
|
extern s32 D_80292098[];
|
|
|
|
extern s32 D_802920C0[];
|
|
|
|
extern s32 D_802920E8[];
|
|
|
|
extern s32 D_80292110[];
|
|
|
|
|
2022-09-13 08:26:57 +02:00
|
|
|
extern AnimID KoopatrolDisguiseExtraAnims[];
|
|
|
|
extern AnimID HammerBroDisguiseExtraAnims[];
|
2021-02-10 16:26:26 +01:00
|
|
|
|
2021-04-22 05:19:31 +02:00
|
|
|
extern s16 gCurrentCamID;
|
|
|
|
|
2022-01-08 06:47:52 +01:00
|
|
|
extern s32 D_8029C890[10][5];
|
2021-07-19 20:27:56 +02:00
|
|
|
|
2021-11-07 17:58:57 +01:00
|
|
|
extern HeapNode heap_battleHead;
|
2021-04-01 20:00:29 +02:00
|
|
|
|
2022-02-24 16:12:33 +01:00
|
|
|
extern u32 bMarioIdleAnims[];
|
2021-06-16 11:52:15 +02:00
|
|
|
extern s32 bMarioDefendAnims[];
|
|
|
|
extern s32 bPeachIdleAnims[];
|
|
|
|
|
2022-06-02 04:56:36 +02:00
|
|
|
extern s32 D_802EBFF0[];
|
|
|
|
extern s32 D_802EC010[];
|
|
|
|
extern s32 D_802EC030[];
|
|
|
|
extern s32 D_802EC050[];
|
|
|
|
extern s32 D_802EC070[];
|
|
|
|
extern s32 D_802EC090[];
|
|
|
|
extern s32 D_802EC0B0[];
|
|
|
|
extern s32 D_802EC0D0[];
|
|
|
|
extern s32 D_802EC0F0[];
|
|
|
|
extern s32 D_802EC110[];
|
|
|
|
extern s32 D_802EC130[];
|
|
|
|
extern s32 D_802EC150[];
|
|
|
|
extern s32 D_802EC170[];
|
|
|
|
extern s32 D_802EC190[];
|
|
|
|
extern s32 D_802EC1B0[];
|
|
|
|
extern s32 D_802EC1D0[];
|
|
|
|
extern s32 D_802EC1F0[];
|
|
|
|
extern s32 D_802EC210[];
|
|
|
|
extern s32 D_802EC230[];
|
|
|
|
extern s32 D_802EC250[];
|
|
|
|
extern s32 D_802EC270[];
|
|
|
|
extern s32 D_802EC290[];
|
|
|
|
extern s32 D_802EC2B0[];
|
|
|
|
extern s32 D_802EC2D0[];
|
|
|
|
extern s32 D_802EC2F0[];
|
|
|
|
extern s32 D_802EC310[];
|
|
|
|
extern s32 D_802EC330[];
|
|
|
|
extern s32 D_802EC350[];
|
|
|
|
extern s32 D_802EC370[];
|
|
|
|
extern s32 D_802EC390[];
|
|
|
|
extern s32 D_802EC3B0[];
|
|
|
|
extern s32 D_802EC3D0[];
|
2021-08-02 20:03:51 +02:00
|
|
|
|
2023-03-16 07:41:26 +01:00
|
|
|
extern PartnerStatus gPartnerStatus;
|
2022-06-13 18:34:22 +02:00
|
|
|
extern UiStatus gUIStatus;
|
|
|
|
extern PlayerStatus gPlayerStatus;
|
|
|
|
extern PlayerSpinState gPlayerSpinState;
|
|
|
|
extern PlayerData gPlayerData;
|
|
|
|
|
2023-03-26 19:03:19 +02:00
|
|
|
#if VERSION_PAL
|
|
|
|
extern s32 gCurrentLanguage;
|
|
|
|
#endif
|
|
|
|
|
2020-07-18 02:47:33 +02:00
|
|
|
#endif
|