2010-08-02 08:13:51 +00:00
|
|
|
//-------------------------------------------------------------------------
|
|
|
|
/*
|
|
|
|
Copyright (C) 2010 EDuke32 developers and contributors
|
|
|
|
|
|
|
|
This file is part of EDuke32.
|
|
|
|
|
|
|
|
EDuke32 is free software; you can redistribute it and/or
|
|
|
|
modify it under the terms of the GNU General Public License version 2
|
|
|
|
as published by the Free Software Foundation.
|
|
|
|
|
|
|
|
This program is distributed in the hope that it will be useful,
|
|
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
|
|
|
|
|
|
See the GNU General Public License for more details.
|
|
|
|
|
|
|
|
You should have received a copy of the GNU General Public License
|
|
|
|
along with this program; if not, write to the Free Software
|
|
|
|
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|
|
|
*/
|
|
|
|
//-------------------------------------------------------------------------
|
|
|
|
|
|
|
|
#ifndef __global_h__
|
|
|
|
#define __global_h__
|
|
|
|
|
|
|
|
#ifdef __global_c__
|
|
|
|
#define G_EXTERN
|
|
|
|
#else
|
|
|
|
#define G_EXTERN extern
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#define MAXINTERPOLATIONS MAXSPRITES
|
2012-06-17 19:45:41 +00:00
|
|
|
// KEEPINSYNC lunatic/con_lang.lua
|
2012-03-25 22:00:27 +00:00
|
|
|
#define MAXSKILLS 7
|
2010-08-02 08:13:51 +00:00
|
|
|
|
2012-11-05 02:49:08 +00:00
|
|
|
// duke3d global soup :(
|
|
|
|
|
|
|
|
#include "compat.h"
|
|
|
|
#include "build.h"
|
|
|
|
|
|
|
|
G_EXTERN int32_t g_numInterpolations;
|
|
|
|
G_EXTERN int32_t g_interpolationLock;
|
|
|
|
G_EXTERN int32_t oldipos[MAXINTERPOLATIONS];
|
|
|
|
G_EXTERN int32_t *curipos[MAXINTERPOLATIONS];
|
|
|
|
G_EXTERN int32_t bakipos[MAXINTERPOLATIONS];
|
2011-04-07 01:16:29 +00:00
|
|
|
G_EXTERN int32_t connectpoint2[MAXPLAYERS];
|
|
|
|
|
2012-11-05 02:49:08 +00:00
|
|
|
#include "duke3d.h"
|
|
|
|
#include "sector.h"
|
|
|
|
#include "quotes.h"
|
|
|
|
|
|
|
|
G_EXTERN int32_t myconnectindex, numplayers;
|
|
|
|
|
2010-08-02 08:13:51 +00:00
|
|
|
G_EXTERN DukeStatus_t sbar;
|
|
|
|
G_EXTERN actor_t actor[MAXSPRITES];
|
2012-11-11 17:57:06 +00:00
|
|
|
// g_tile: tile-specific data THAT DOES NOT CHANGE during the course of a game
|
2012-10-30 15:54:35 +00:00
|
|
|
G_EXTERN tiledata_t g_tile[MAXTILES];
|
2010-08-02 08:13:51 +00:00
|
|
|
G_EXTERN animwalltype animwall[MAXANIMWALLS];
|
|
|
|
G_EXTERN char *ScriptQuotes[MAXQUOTES],*ScriptQuoteRedefinitions[MAXQUOTES];
|
|
|
|
G_EXTERN char *label;
|
|
|
|
G_EXTERN char EnvMusicFilename[MAXVOLUMES+1][BMAX_PATH];
|
|
|
|
G_EXTERN char g_RTSPlaying;
|
2012-06-04 22:01:45 +00:00
|
|
|
G_EXTERN int32_t g_musicIndex;
|
2012-08-16 21:48:13 +00:00
|
|
|
G_EXTERN char g_loadFromGroupOnly;
|
2012-03-25 22:00:27 +00:00
|
|
|
G_EXTERN char g_numSkills;
|
2010-08-02 08:13:51 +00:00
|
|
|
G_EXTERN char myjumpingtoggle,myonground,myhardlanding,myreturntocenter;
|
|
|
|
G_EXTERN char pus,pub;
|
|
|
|
G_EXTERN char ready2send;
|
|
|
|
G_EXTERN char szPlayerName[32];
|
2012-11-04 23:41:05 +00:00
|
|
|
G_EXTERN char tempbuf[MAXSECTORS<<1],packbuf[PACKBUF_SIZE],menutextbuf[128],buf[1024];
|
2010-08-02 08:13:51 +00:00
|
|
|
G_EXTERN char typebuflen,typebuf[141];
|
|
|
|
G_EXTERN input_t avg;
|
|
|
|
G_EXTERN input_t loc;
|
|
|
|
G_EXTERN input_t recsync[RECSYNCBUFSIZ];
|
2012-12-29 10:58:38 +00:00
|
|
|
G_EXTERN int16_t SpriteDeletionQueue[1024],g_spriteDeleteQueuePos;
|
2010-08-02 08:13:51 +00:00
|
|
|
G_EXTERN int16_t animatesect[MAXANIMATES];
|
|
|
|
G_EXTERN int16_t camsprite;
|
|
|
|
G_EXTERN int16_t cyclers[MAXCYCLERS][6],g_numCyclers;
|
|
|
|
G_EXTERN int16_t g_globalRandom;
|
|
|
|
G_EXTERN int16_t g_mirrorWall[64],g_mirrorSector[64],g_mirrorCount;
|
|
|
|
G_EXTERN int16_t g_numAnimWalls;
|
|
|
|
G_EXTERN int16_t g_numClouds,clouds[128],cloudx[128],cloudy[128];
|
|
|
|
G_EXTERN int16_t myang,omyang,mycursectnum,myjumpingcounter;
|
|
|
|
G_EXTERN int16_t myhoriz,omyhoriz,myhorizoff,omyhorizoff;
|
|
|
|
G_EXTERN int16_t neartagsector,neartagwall,neartagsprite;
|
|
|
|
G_EXTERN int32_t *animateptr[MAXANIMATES];
|
|
|
|
G_EXTERN int32_t animategoal[MAXANIMATES],animatevel[MAXANIMATES],g_animateCount;
|
|
|
|
G_EXTERN int32_t cloudtotalclock;
|
|
|
|
G_EXTERN int32_t fricxv,fricyv;
|
|
|
|
G_EXTERN int32_t g_currentFrameRate;
|
|
|
|
G_EXTERN int32_t g_currentMenu;
|
|
|
|
G_EXTERN int32_t g_damageCameras,g_freezerSelfDamage;
|
|
|
|
G_EXTERN int32_t g_doQuickSave;
|
2013-02-11 17:16:50 +00:00
|
|
|
G_EXTERN uint16_t g_earthquakeTime;
|
2010-08-02 08:13:51 +00:00
|
|
|
G_EXTERN int32_t g_gameQuit;
|
|
|
|
G_EXTERN int32_t g_groupFileHandle;
|
|
|
|
G_EXTERN int32_t g_impactDamage,g_maxPlayerHealth;
|
|
|
|
G_EXTERN int32_t g_musicSize;
|
|
|
|
G_EXTERN int32_t g_numLabels,g_numDefaultLabels;
|
|
|
|
G_EXTERN int32_t g_numRealPalettes;
|
|
|
|
G_EXTERN int32_t g_scriptDebug;
|
|
|
|
G_EXTERN int32_t g_showShareware;
|
2012-11-05 02:49:08 +00:00
|
|
|
G_EXTERN int8_t g_numPlayerSprites;
|
2010-08-02 08:13:51 +00:00
|
|
|
G_EXTERN int32_t g_tripbombLaserMode;
|
|
|
|
G_EXTERN int32_t msx[2048],msy[2048];
|
|
|
|
G_EXTERN int32_t neartaghitdist,lockclock,g_startArmorAmount;
|
|
|
|
G_EXTERN int32_t playerswhenstarted;
|
|
|
|
G_EXTERN int32_t screenpeek;
|
|
|
|
G_EXTERN int32_t startofdynamicinterpolations;
|
2012-12-29 10:58:38 +00:00
|
|
|
G_EXTERN int32_t vel,svel,angvel,horiz,ototalclock;
|
2012-10-30 15:54:35 +00:00
|
|
|
G_EXTERN intptr_t *g_parsingActorPtr;
|
2011-12-04 21:20:17 +00:00
|
|
|
G_EXTERN intptr_t *g_scriptPtr,*insptr;
|
|
|
|
G_EXTERN int32_t *labelcode,*labeltype;
|
2010-08-02 08:13:51 +00:00
|
|
|
G_EXTERN intptr_t *script;
|
2012-02-09 22:44:45 +00:00
|
|
|
G_EXTERN map_t MapInfo[(MAXVOLUMES+1)*MAXLEVELS]; // +1 volume for "intro", "briefing" music
|
2012-11-05 02:49:08 +00:00
|
|
|
#pragma pack(push,1)
|
2010-08-02 08:13:51 +00:00
|
|
|
G_EXTERN playerdata_t g_player[MAXPLAYERS];
|
|
|
|
G_EXTERN playerspawn_t g_playerSpawnPoints[MAXPLAYERS];
|
2012-11-05 02:49:08 +00:00
|
|
|
G_EXTERN input_t inputfifo[MOVEFIFOSIZ][MAXPLAYERS];
|
|
|
|
#pragma pack(pop)
|
2012-11-11 17:57:06 +00:00
|
|
|
G_EXTERN projectile_t ProjectileData[MAXTILES];
|
2012-10-30 15:54:35 +00:00
|
|
|
G_EXTERN projectile_t SpriteProjectile[MAXSPRITES];
|
2010-08-02 08:13:51 +00:00
|
|
|
G_EXTERN sound_t g_sounds[MAXSOUNDS];
|
|
|
|
G_EXTERN uint32_t everyothertime;
|
|
|
|
G_EXTERN uint32_t g_moveThingsCount;
|
|
|
|
G_EXTERN vec3_t my,omy,myvel;
|
|
|
|
G_EXTERN volatile char g_soundlocks[MAXSOUNDS];
|
|
|
|
G_EXTERN int32_t g_rpgBlastRadius;
|
|
|
|
G_EXTERN int32_t g_pipebombBlastRadius;
|
|
|
|
G_EXTERN int32_t g_tripbombBlastRadius;
|
|
|
|
G_EXTERN int32_t g_shrinkerBlastRadius;
|
|
|
|
G_EXTERN int32_t g_morterBlastRadius;
|
|
|
|
G_EXTERN int32_t g_bouncemineBlastRadius;
|
|
|
|
G_EXTERN int32_t g_seenineBlastRadius;
|
|
|
|
G_EXTERN int32_t g_restorePalette;
|
|
|
|
G_EXTERN int32_t g_screenCapture;
|
|
|
|
G_EXTERN int32_t g_noEnemies;
|
|
|
|
|
2012-12-29 10:58:38 +00:00
|
|
|
#ifndef __global_c__
|
|
|
|
G_EXTERN const char *s_buildRev;
|
|
|
|
G_EXTERN const char *s_buildDate;
|
|
|
|
G_EXTERN int32_t g_spriteGravity;
|
|
|
|
G_EXTERN int16_t g_spriteDeleteQueueSize;
|
|
|
|
G_EXTERN char EpisodeNames[MAXVOLUMES][33];
|
|
|
|
G_EXTERN char SkillNames[MAXSKILLS][33];
|
|
|
|
G_EXTERN char GametypeNames[MAXGAMETYPES][33];
|
|
|
|
G_EXTERN int32_t GametypeFlags[MAXGAMETYPES];
|
|
|
|
G_EXTERN char g_numGametypes;
|
|
|
|
G_EXTERN char g_numVolumes;
|
|
|
|
G_EXTERN int32_t g_timerTicsPerSecond;
|
|
|
|
G_EXTERN int32_t g_actorRespawnTime;
|
|
|
|
G_EXTERN int32_t g_itemRespawnTime;
|
|
|
|
G_EXTERN int32_t g_scriptSize;
|
|
|
|
G_EXTERN int16_t BlimpSpawnSprites[15];
|
|
|
|
G_EXTERN int32_t g_playerFriction;
|
|
|
|
G_EXTERN int32_t g_numFreezeBounces;
|
|
|
|
G_EXTERN int32_t g_lastSaveSlot;
|
|
|
|
G_EXTERN char CheatKeys[2];
|
|
|
|
G_EXTERN char setupfilename[BMAX_PATH];
|
|
|
|
#endif
|
|
|
|
|
2010-08-02 08:13:51 +00:00
|
|
|
#endif
|