Browse Source

Inital commit

master
ComputerNerd 7 years ago
commit
bd6bb43473
  1. BIN
      CGDOOM-minisdk/CGDOOM/CGDOOM_SELECTED.BMP
  2. BIN
      CGDOOM-minisdk/CGDOOM/CGDOOM_UNSELECTED.BMP
  3. BIN
      CGDOOM-minisdk/CGDOOM/CG_Doom.g3a
  4. 39
      CGDOOM-minisdk/CGDOOM/Makefile
  5. 5
      Changelog
  6. 1
      README
  7. 1351
      cgdoom/am_map.c
  8. 52
      cgdoom/am_map.h
  9. 602
      cgdoom/cgdoom.c
  10. 701
      cgdoom/d_englsh.h
  11. 122
      cgdoom/d_event.h
  12. 59
      cgdoom/d_items.c
  13. 52
      cgdoom/d_items.h
  14. 512
      cgdoom/d_main.c
  15. 56
      cgdoom/d_main.h
  16. 219
      cgdoom/d_player.h
  17. 98
      cgdoom/d_think.h
  18. 53
      cgdoom/d_ticcmd.h
  19. 222
      cgdoom/doomdata.h
  20. 319
      cgdoom/doomdef.h
  21. 37
      cgdoom/doomstat.c
  22. 265
      cgdoom/doomstat.h
  23. 65
      cgdoom/doomtype.h
  24. 57
      cgdoom/dstrings.h
  25. 674
      cgdoom/f_finale.c
  26. 53
      cgdoom/f_finale.h
  27. 342
      cgdoom/f_wipe.c
  28. 57
      cgdoom/f_wipe.h
  29. 1165
      cgdoom/g_game.c
  30. 70
      cgdoom/g_game.h
  31. 313
      cgdoom/hu_lib.c
  32. 165
      cgdoom/hu_lib.h
  33. 498
      cgdoom/hu_stuff.c
  34. 66
      cgdoom/hu_stuff.h
  35. 252
      cgdoom/i_system.c
  36. 107
      cgdoom/i_system.h
  37. 153
      cgdoom/i_video.c
  38. 60
      cgdoom/i_video.h
  39. 4593
      cgdoom/info.c
  40. 1417
      cgdoom/info.h
  41. 55
      cgdoom/m_bbox.c
  42. 55
      cgdoom/m_bbox.h
  43. 134
      cgdoom/m_fixed.c
  44. 51
      cgdoom/m_fixed.h
  45. 1295
      cgdoom/m_menu.c
  46. 67
      cgdoom/m_menu.h
  47. 121
      cgdoom/m_misc.c
  48. 44
      cgdoom/m_misc.h
  49. 74
      cgdoom/m_random.c
  50. 47
      cgdoom/m_random.h
  51. 82
      cgdoom/m_swap.c
  52. 51
      cgdoom/m_swap.h
  53. 50
      cgdoom/os.h
  54. 325
      cgdoom/p_ceilng.c
  55. 472
      cgdoom/p_doors.c
  56. 2032
      cgdoom/p_enemy.c
  57. 38
      cgdoom/p_enemy.h
  58. 524
      cgdoom/p_floor.c
  59. 856
      cgdoom/p_inter.c
  60. 41
      cgdoom/p_inter.h
  61. 349
      cgdoom/p_lights.c
  62. 289
      cgdoom/p_local.h
  63. 1307
      cgdoom/p_map.c
  64. 829
      cgdoom/p_maputl.c
  65. 950
      cgdoom/p_mobj.c
  66. 295
      cgdoom/p_mobj.h
  67. 285
      cgdoom/p_plats.c
  68. 810
      cgdoom/p_pspr.c
  69. 89
      cgdoom/p_pspr.h
  70. 333
      cgdoom/p_saveg.c
  71. 51
      cgdoom/p_saveg.h
  72. 805
      cgdoom/p_setup.c
  73. 43
      cgdoom/p_setup.h
  74. 338
      cgdoom/p_sight.c
  75. 1328
      cgdoom/p_spec.c
  76. 575
      cgdoom/p_spec.h
  77. 621
      cgdoom/p_switch.c
  78. 123
      cgdoom/p_telept.c
  79. 178
      cgdoom/p_tick.c
  80. 44
      cgdoom/p_tick.h
  81. 376
      cgdoom/p_user.c
  82. 656
      cgdoom/r_bsp.c
  83. 72
      cgdoom/r_bsp.h
  84. 868
      cgdoom/r_data.c
  85. 59
      cgdoom/r_data.h
  86. 485
      cgdoom/r_defs.h
  87. 544
      cgdoom/r_draw.c
  88. 115
      cgdoom/r_draw.h
  89. 53
      cgdoom/r_local.h
  90. 774
      cgdoom/r_main.c
  91. 172
      cgdoom/r_main.h
  92. 434
      cgdoom/r_plane.c
  93. 87
      cgdoom/r_plane.h
  94. 737
      cgdoom/r_segs.c
  95. 44
      cgdoom/r_segs.h
  96. 61
      cgdoom/r_sky.c
  97. 48
      cgdoom/r_sky.h
  98. 138
      cgdoom/r_state.h
  99. 1006
      cgdoom/r_things.c
  100. 76
      cgdoom/r_things.h

BIN
CGDOOM-minisdk/CGDOOM/CGDOOM_SELECTED.BMP

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

BIN
CGDOOM-minisdk/CGDOOM/CGDOOM_UNSELECTED.BMP

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

BIN
CGDOOM-minisdk/CGDOOM/CG_Doom.g3a

Binary file not shown.

39
CGDOOM-minisdk/CGDOOM/Makefile

@ -0,0 +1,39 @@
CC=sh3eb-elf-gcc
CPP=sh3eb-elf-g++
OBJCOPY=sh3eb-elf-objcopy
MKG3A=mkg3a
RM=rm
CFLAGS=-m4a-nofpu -mb -fgcse-sm -fgcse-las -fgcse-after-reload -Isrc -O3 -fmerge-all-constants -mhitachi -flto -fuse-linker-plugin -Wall -Wextra -I../../../../include -lgcc -L../../../../lib -I./ -I../../cgdoom
LDFLAGS=$(CFLAGS) -nostartfiles -T../../../../toolchain/prizm.x -Wl,-static -Wl,-gc-sections -lgcc
CSOURCES=$(wildcard ../../cgdoom/*.c)
OBJECTS=$(CSOURCES:.c=.o)
PROJ_NAME=CG_Doom
BIN=$(PROJ_NAME).bin
ELF=$(PROJ_NAME).elf
ADDIN=$(PROJ_NAME).g3a
all: $(ADDIN)
$(ADDIN): $(BIN)
$(MKG3A) -n :Doom -i uns:CGDOOM_UNSELECTED.BMP -i sel:CGDOOM_SELECTED.BMP $< $@
.s.o:
$(CC) -c $(CFLAGS) $< -o $@
.c.o:
$(CC) -c $(CFLAGS) $< -o $@
.cpp.o:
$(CC) -c $(CFLAGS) $< -o $@
.cc.o:
$(CC) -c $(CFLAGS) $< -o $@
$(ELF): $(OBJECTS)
$(CC) $(OBJECTS) $(LDFLAGS) -o $@
$(BIN): $(ELF)
$(OBJCOPY) -O binary $(PROJ_NAME).elf $(BIN)
clean:
rm -f $(OBJECTS) $(PROJ_NAME).bin $(PROJ_NAME).elf $(ADDIN)

5
Changelog

@ -0,0 +1,5 @@
Most recent changes are at the top
Fixed a crash by using getSecondaryVramAddress() instead of a hardcoded address.
Update header locations for libfxcg
New makefile

1
README

@ -0,0 +1 @@
This repository is a fork of CGDOOM which was ported originally by MPoupe.

1351
cgdoom/am_map.c

File diff suppressed because it is too large

52
cgdoom/am_map.h

@ -0,0 +1,52 @@
// Emacs style mode select -*- C++ -*-
//-----------------------------------------------------------------------------
//
// $Id:$
//
// Copyright (C) 1993-1996 by id Software, Inc.
//
// This source is available for distribution and/or modification
// only under the terms of the DOOM Source Code License as
// published by id Software. All rights reserved.
//
// The source is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// FITNESS FOR A PARTICULAR PURPOSE. See the DOOM Source Code License
// for more details.
//
// DESCRIPTION:
// AutoMap module.
//
//-----------------------------------------------------------------------------
#ifndef __AMMAP_H__
#define __AMMAP_H__
// Used by ST StatusBar stuff.
#define AM_MSGHEADER (('a'<<24)+('m'<<16))
#define AM_MSGENTERED (AM_MSGHEADER | ('e'<<8))
#define AM_MSGEXITED (AM_MSGHEADER | ('x'<<8))
// Called by main loop.
boolean AM_Responder (event_t* ev);
// Called by main loop.
void AM_Ticker (void);
// Called by main loop,
// called instead of view drawer if automap active.
void AM_Drawer (void);
// Called to force the automap to quit
// if the level is completed while it is up.
void AM_Stop (void);
#endif
//-----------------------------------------------------------------------------
//
// $Log:$
//
//-----------------------------------------------------------------------------

602
cgdoom/cgdoom.c

@ -0,0 +1,602 @@
#include "platform.h"
#include "os.h"
#ifdef CG_EMULATOR
static int iAllocSum = 0;
#endif
void * CGDMalloc(int iSize)
{
#ifdef CG_EMULATOR
iAllocSum += iSize;
printf("malloc %i (%i)\n",iSize,iAllocSum);
#endif
return malloc(iSize);
}
void * CGDCalloc(int iSize)
{
void *p = CGDMalloc(iSize);
if(p != NULL)
{
memset(p,0,iSize);
}
return p;
}
void * CGDRealloc (void *p, int iSize)
{
#ifdef CG_EMULATOR
iAllocSum += iSize;
printf("realloc %i (%i)\n",iSize,iAllocSum);
#endif
if(p == NULL)
{
return malloc(iSize);
}
else
{
return realloc(p,iSize);
}
}
#ifdef CG_EMULATOR
unsigned char aSaveVRAMBuffer[SAVE_VRAM_SIZE]; //for screens[2] (2x64KB) + WAD file mapping
unsigned char aSystemStack[SYSTEM_STACK_SIZE]; //for RAM_I_Zone
#endif
unsigned short *VRAM;
unsigned char *SaveVRAMBuffer; //for screens[2]
unsigned char *SystemStack; //for RAM_I_Zone
void CGDAppendNum09(const char *pszText,int iNum,char *pszBuf)
{
int i = 0;
while(pszText[i])
{
pszBuf[i] = pszText[i];
i++;
}
ASSERT(iNum < 10);
ASSERT(iNum >= 0);
pszBuf[i] = (char)('0'+iNum);
pszBuf[i+1] = 0;
}
void CGDAppendNum0_999(const char *pszText,int iNum,int iMinDigits,char *pszBuf)
{
int i = 0;
int z = 0;
while(pszText[i])
{
pszBuf[i] = pszText[i];
i++;
}
ASSERT(iNum < 1000000);
ASSERT(iNum >= 0);
if((iNum > 999999) || (iMinDigits>6))
{
pszBuf[i] = (char)('0'+(iNum / 1000000));
iNum %= 1000000;
i++;
z = 1;
}
if(z || (iNum > 99990) || (iMinDigits>5))
{
pszBuf[i] = (char)('0'+(iNum / 100000));
iNum %= 100000;
i++;
z = 1;
}
if(z || (iNum > 9999) || (iMinDigits>4))
{
pszBuf[i] = (char)('0'+(iNum / 10000));
iNum %= 10000;
i++;
z = 1;
}
if(z || (iNum > 999) || (iMinDigits>3))
{
pszBuf[i] = (char)('0'+(iNum / 1000));
iNum %= 1000;
i++;
z = 1;
}
if(z || (iNum > 99) || (iMinDigits>2))
{
pszBuf[i] = (char)('0'+(iNum / 100));
iNum %= 100;
i++;
z = 1;
}
if(z || (iNum > 9) || (iMinDigits>1))
{
pszBuf[i] = (char)('0'+(iNum / 10));
iNum %= 10;
i++;
}
pszBuf[i] = (char)('0'+iNum);
pszBuf[i+1] = 0;
}
int CGDstrlen(const char *pszText)
{
int i = 0;
while(pszText[i])
{
i++;
}
return i;
}
void CGDstrcpy(char *pszBuf,const char *pszText)
{
int i = 0;
while(pszText[i])
{
pszBuf[i] = pszText[i];
i++;
}
pszBuf[i] = 0;
}
void CGDstrncpy(char *pszBuf,const char *pszText,int iLen)
{
int i = 0;
while(pszText[i])
{
if(iLen == i)
{
return;
}
pszBuf[i] = pszText[i];
i++;
}
pszBuf[i] = 0;
}
int CGDstrcmp (const char*s1,const char*s2)
{
while(s1[0])
{
unsigned char c1 = (unsigned char)s1[0];
unsigned char c2 = (unsigned char)s2[0];
if(c1 !=c2)
{
return 1;//who cares 1/-1, important is match/nonmatch
}
s1++;
s2++;
}
return (unsigned char)s2[0]>0;
}
/*int CGDstrcmp (const char*s1,const char*s2)
{
int i = CGDstrcmpX(s1,s2);
ASSERT(!i==!strcmp(s1,s2));
return i;
}*/
int CGDstrncmp (const char*s1,const char*s2,int iLen)
{
if(!iLen)
{
return 0;
}
while(s1[0])
{
unsigned char c1 = (unsigned char)s1[0];
unsigned char c2 = (unsigned char)s2[0];
if(c1 !=c2)
{
return 1;//who cares 1/-1, important is match/nonmatch
}
s1++;
s2++;
iLen--;
if(!iLen)
{
return 0;
}
}
return (unsigned char)s2[0]>0;
}
/*int CGDstrncmp (const char*s1,const char*s2,int iLen)
{
int i = CGDstrncmpX(s1,s2,iLen);
ASSERT(!i==!strncmp(s1,s2,iLen));
return i;
}*/
static unsigned char Upper(unsigned char c)
{
if((c>='a')&&(c<='z'))
{
c -='a'-'A';
}
return c;
}
int CGDstrnicmp (const char*s1,const char*s2,int iLen)
{
if(!iLen)
{
return 0;
}
while(s1[0])
{
unsigned char c1 = Upper((unsigned char)s1[0]);
unsigned char c2 = Upper((unsigned char)s2[0]);
if(c1 !=c2)
{
return 1;//who cares 1/-1, important is match/nonmatch
}
s1++;
s2++;
iLen--;
if(!iLen)
{
return 0;
}
}
return (unsigned char)s2[0]>0;
}
/*int CGDstrnicmp (const char*s1,const char*s2,int iLen)
{
int i = CGDstrnicmpX(s1,s2,iLen);
int j = strnicmp(s1,s2,iLen);
ASSERT(!i==!j);
return i;
}
*/
int gWADHandle;
const unsigned short wadfile[] = {'\\','\\','f','l','s','0','\\','d','o','o','m','.','w','a','d',0};
////////////////////////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////////////////////////////
//The whole sound doesn't fir onto the RAM.
//Reading per partes is not possible as this is synchronnous player (there would be silences when reading).
//So I read each page (4KB)of the wav file and try to find it in the flash.
//Simply finding start of the file is not enough because of fragmentation.
//Seach the whole flash, do not assume FS start at 0xA1000000
//(already tried interval 0xA1000000 - 0xA1FFFFFF, but some parts of the file were outside of this interval)
// move this to platform.h, simulator will use static buffer
//#define FLASH_START 0xA0000000
//page has 4 KB (I hope)
//#define FLASH_PAGE_SIZE 4096
//8K pages
//#define FLASH_PAGE_COUNT (4096*2)
//allocate 1024 items for max 1024 fragments of the file.
// 640 KB should to be enough for everyone ;-)
#define MAX_FRAGMENTS 1024
//descriptor for 1 fragment
typedef struct
{
short msOffset;//page index (0 ~ 8K)
short msCount;//count of pages in this fragment
}FileMappingItem;
typedef struct
{
FileMappingItem mTable[MAX_FRAGMENTS];//table of fragments
int miItemCount;
int miTotalLength;//length of the file
int miCurrentLength;//currently returned length (by GetNextdata() )
int miCurrentItem;//active fragment (to be returned by GetNextdata() )
}FileMapping;
//reset reading to start
void ResetData(FileMapping *pMap)
{
pMap->miCurrentItem = 0;
pMap->miCurrentLength = 0;
}
static int memcmp32(const int *p1,const int *p2,int count)
{
while(count)
{
if(*p1 != *p2)
{
return 1;
}
p1++;
p2++;
count--;
}
return 0;
}
//I was able to use memcmp(), it compiled but it seems it returned always 0
// quick fix fot now
/*int Xmemcmp(const char *p1,const char *p2,int len)
{
if(!(len & 3))
{
return memcmp32((int*)p1,(int*)p2,len >>2);
}
while(len)
{
if(*p1 != *p2)
{
return 1;
}
p1++;
p2++;
len--;
}
return 0;
}*/
#define Xmemcmp memcmp
int CreateFileMapping(const unsigned short *pFileName,FileMapping *pMap){
int iResult = 0;
char cBuffer[FLASH_PAGE_SIZE];
int hFile = Bfile_OpenFile_OS(pFileName,0,0);
int iLength;
char *pFlashFS = (char *)FLASH_START;
pMap->miItemCount = 0;
pMap->miTotalLength = 0;
iLength = Bfile_ReadFile_OS(hFile,cBuffer,FLASH_PAGE_SIZE,-1);
while(iLength > 0)
{
//do not optimize (= do not move these 2 variables before loop)!
// fx-cg allocates pages for file in <random> order so page from the end of the file
//can have lower index than page from the beginning
const char *pTgt = pFlashFS;
int iPageIndx = 0;
for(;iPageIndx < FLASH_PAGE_COUNT;iPageIndx++)
{
if(!Xmemcmp(pTgt,cBuffer,iLength))
{
break;
}
pTgt += FLASH_PAGE_SIZE;
}
if(iPageIndx == FLASH_PAGE_COUNT)
{
//page not found !
iResult = -2;
goto lbExit;
}
pMap->miItemCount ++;
if(pMap->miItemCount >= MAX_FRAGMENTS)
{
//file too fragmented !
iResult = -3;
goto lbExit;
}
pMap->mTable[pMap->miItemCount-1].msOffset = (short)iPageIndx;
pMap->mTable[pMap->miItemCount-1].msCount = 0;
//assume fragment has more pages
for(;;)
{
pMap->mTable[pMap->miItemCount-1].msCount++;
pMap->miTotalLength += iLength;
iPageIndx++;
pTgt += FLASH_PAGE_SIZE;
if(iLength < FLASH_PAGE_SIZE)
{
//this was the last page
iResult = pMap->miTotalLength;
goto lbExit;
}
iLength = Bfile_ReadFile_OS(hFile,cBuffer,FLASH_PAGE_SIZE,-1);
if(iLength <= 0)
{
break;
}
if(Xmemcmp(pTgt,cBuffer,iLength))
{
break;
}
}
}
if(iLength < 0)
{
iResult = -1;
}
else
{
if(pMap->miTotalLength >50000)
{
pMap->miTotalLength = 50000;//hack
}
iResult = pMap->miTotalLength;
}
lbExit:
Bfile_CloseFile_OS(hFile);
return iResult;
}
void I_Error (char *error, ...);
static FileMapping *gpWADMap = 0;
int FindInFlash(void **buf, int size, int readpos)
{
int iPageReq = readpos >>FLASH_PAGE_SIZE_LOG2;
int iPageIndx = 0;
int iCurrOffset = 0, iCurrLen;
int iSubOffset;
ASSERT(readpos >=0);
//find item
for(;;)
{
if(iPageIndx >= gpWADMap->miItemCount)
{
return -1;
}
if(iPageReq < gpWADMap->mTable[iPageIndx].msCount)
{
ASSERT(iCurrOffset <= readpos);
break;
}
iPageReq -= gpWADMap->mTable[iPageIndx].msCount;
iCurrOffset += ((int)gpWADMap->mTable[iPageIndx].msCount) << FLASH_PAGE_SIZE_LOG2;
iPageIndx++;
}
iSubOffset = readpos - iCurrOffset;
iCurrLen = (gpWADMap->mTable[iPageIndx].msCount * FLASH_PAGE_SIZE) - iSubOffset;
ASSERT(iCurrLen > 0);
if(iCurrLen > size)
{
iCurrLen = size;
}
*buf = ((char *)FLASH_START)+(gpWADMap->mTable[iPageIndx].msOffset << FLASH_PAGE_SIZE_LOG2)+iSubOffset;
return iCurrLen;
}
int Flash_ReadFile(void *buf, int size, int readpos)
{
void *pSrc;
int iRet = 0;
while(size >0)
{
int i = FindInFlash(&pSrc,size, readpos);
if(i<0)
return i;
memcpy(buf,pSrc,i);
buf = ((char*)buf)+i;
readpos +=i;
size -=i;
iRet +=i;
}
return iRet;
}
int Flash_ReadFileX(void *buf, int size, int readpos)
{
int iRet = 0;
if(gpWADMap->miTotalLength - readpos < size)
{
size = gpWADMap->miTotalLength - readpos;
}
/*
typedef struct
{
short msOffset;//page index (0 ~ 8K)
short msCount;//count of pages in this fragment
}FileMappingItem;
typedef struct
{
FileMappingItem mTable[MAX_FRAGMENTS];//table of fragments
int miItemCount;
int miTotalLength;//length of the file
}FileMapping;*/
ASSERT(readpos >=0);
ASSERT(FLASH_PAGE_SIZE == 1<< FLASH_PAGE_SIZE_LOG2);
for(;;)
{
int iPageReq = readpos >>FLASH_PAGE_SIZE_LOG2;
int iPageIndx = 0;
int iCurrOffset = 0, iCurrLen;
int iSubOffset;
//find item
for(;;)
{
if(iPageIndx >= gpWADMap->miItemCount)
{
return -1;
}
if(iPageReq < gpWADMap->mTable[iPageIndx].msCount)
{
ASSERT(iCurrOffset <= readpos);
break;
}
iPageReq -= gpWADMap->mTable[iPageIndx].msCount;
iCurrOffset += ((int)gpWADMap->mTable[iPageIndx].msCount) << FLASH_PAGE_SIZE_LOG2;
iPageIndx++;
}
iSubOffset = readpos - iCurrOffset;
iCurrLen = (gpWADMap->mTable[iPageIndx].msCount * FLASH_PAGE_SIZE) - iSubOffset;
ASSERT(iCurrLen > 0);
if(iCurrLen > size)
{
iCurrLen = size;
}
memcpy(buf,((char *)FLASH_START)+(gpWADMap->mTable[iPageIndx].msOffset << FLASH_PAGE_SIZE_LOG2)+iSubOffset,iCurrLen);
readpos += iCurrLen;
size -= iCurrLen;
buf = ((char *)buf) +iCurrLen;
iRet += iCurrLen;
if(size ==0)
{
break;
}
}
return iRet;
}
void abort(void){
int x=0,y=160;
PrintMini(&x,&y,"Abort called",0,0xFFFFFFFF,0,0,0xFFFF,0,1,0);
int key;
for(;;)
GetKey(&key);
}
///////////////////////////////////////////////////////////////////////////////////////////////////
void main(void){
InitFlashSimu(wadfile); //load wad file to flash simulation on simulator, do nothing on real HW
#ifdef CG_EMULATOR
SaveVRAMBuffer = aSaveVRAMBuffer;
SystemStack = aSystemStack;
VRAM = (unsigned short*)GetVRAMAddress();
#else
unsigned tmp=((unsigned)getSecondaryVramAddress()+3)&(~3);
SaveVRAMBuffer = (unsigned char*)tmp;
SystemStack = ((unsigned char*)0x880F0000+(10*1024));//hack
VRAM = ((unsigned short *)0x88000000);
#endif
EnableColor(1);
memset(VRAM,0,WIDTH*HEIGHT*2);
gpWADMap = (FileMapping *)(SaveVRAMBuffer + 2*65536);
ASSERT(2*65536 + sizeof(FileMapping) < SAVE_VRAM_SIZE);
gWADHandle = CreateFileMapping(wadfile,gpWADMap);
switch(gWADHandle)
{
case -1:
I_Error ("File read error");
return;
break;
case -2:
I_Error ("Page not found");
return;
break;
case -3:
I_Error ("File too fragmented");
return;
break;
default:
break;
}
D_DoomMain();
}
//todo: wrapper pro (patch_t*), + flash

701
cgdoom/d_englsh.h

@ -0,0 +1,701 @@
// Emacs style mode select -*- C++ -*-
//-----------------------------------------------------------------------------
//
// $Id:$
//
// Copyright (C) 1993-1996 by id Software, Inc.
//
// This source is available for distribution and/or modification
// only under the terms of the DOOM Source Code License as
// published by id Software. All rights reserved.
//
// The source is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// FITNESS FOR A PARTICULAR PURPOSE. See the DOOM Source Code License
// for more details.
//
// DESCRIPTION:
// Printed strings for translation.
// English language support (default).
//
//-----------------------------------------------------------------------------
#ifndef __D_ENGLSH__
#define __D_ENGLSH__
//
// Printed strings for translation
//
//
// D_Main.C
//
#define D_DEVSTR "Development mode ON.\n"
#define D_CDROM "CD-ROM Version: default.cfg from c:\\doomdata\n"
//
// M_Menu.C
//
#define PRESSKEY "press a key."
#define PRESSYN "press y or n."
#define QUITMSG "are you sure you want to\nquit this great game?"
#define LOADNET "you can't do load while in a net game!\n\n"PRESSKEY
#define QLOADNET "you can't quickload during a netgame!\n\n"PRESSKEY
#define QSAVESPOT "you haven't picked a quicksave slot yet!\n\n"PRESSKEY
#define SAVEDEAD "you can't save if you aren't playing!\n\n"PRESSKEY
#define QSPROMPT "quicksave over your game named\n\n'%s'?\n\n"PRESSYN
#define QLPROMPT "do you want to quickload the game named\n\n'%s'?\n\n"PRESSYN
#define NEWGAME \
"you can't start a new game\n"\
"while in a network game.\n\n"PRESSKEY
#define NIGHTMARE \
"are you sure? this skill level\n"\
"isn't even remotely fair.\n\n"PRESSYN
#define SWSTRING \
"this is the shareware version of doom.\n\n"\
"you need to order the entire trilogy.\n\n"PRESSKEY
#define MSGOFF "Messages OFF"
#define MSGON "Messages ON"
#define NETEND "you can't end a netgame!\n\n"PRESSKEY
#define ENDGAME "are you sure you want to end the game?\n\n"PRESSYN
#define DOSY "(press y to quit)"
#define DETAILHI "High detail"
#define DETAILLO "Low detail"
#define GAMMALVL0 "Gamma correction OFF"
#define GAMMALVL1 "Gamma correction level 1"
#define GAMMALVL2 "Gamma correction level 2"
#define GAMMALVL3 "Gamma correction level 3"
#define GAMMALVL4 "Gamma correction level 4"
#define EMPTYSTRING "empty slot"
//
// P_inter.C
//
#define GOTARMOR "Picked up the armor."
#define GOTMEGA "Picked up the MegaArmor!"
#define GOTHTHBONUS "Picked up a health bonus."
#define GOTARMBONUS "Picked up an armor bonus."
#define GOTSTIM "Picked up a stimpack."
#define GOTMEDINEED "Picked up a medikit that you REALLY need!"
#define GOTMEDIKIT "Picked up a medikit."
#define GOTSUPER "Supercharge!"
#define GOTBLUECARD "Picked up a blue keycard."
#define GOTYELWCARD "Picked up a yellow keycard."
#define GOTREDCARD "Picked up a red keycard."
#define GOTBLUESKUL "Picked up a blue skull key."
#define GOTYELWSKUL "Picked up a yellow skull key."
#define GOTREDSKULL "Picked up a red skull key."
#define GOTINVUL "Invulnerability!"
#define GOTBERSERK "Berserk!"
#define GOTINVIS "Partial Invisibility"
#define GOTSUIT "Radiation Shielding Suit"
#define GOTMAP "Computer Area Map"
#define GOTVISOR "Light Amplification Visor"
#define GOTMSPHERE "MegaSphere!"
#define GOTCLIP "Picked up a clip."
#define GOTCLIPBOX "Picked up a box of bullets."
#define GOTROCKET "Picked up a rocket."
#define GOTROCKBOX "Picked up a box of rockets."
#define GOTCELL "Picked up an energy cell."
#define GOTCELLBOX "Picked up an energy cell pack."
#define GOTSHELLS "Picked up 4 shotgun shells."
#define GOTSHELLBOX "Picked up a box of shotgun shells."
#define GOTBACKPACK "Picked up a backpack full of ammo!"
#define GOTBFG9000 "You got the BFG9000! Oh, yes."
#define GOTCHAINGUN "You got the chaingun!"
#define GOTCHAINSAW "A chainsaw! Find some meat!"
#define GOTLAUNCHER "You got the rocket launcher!"
#define GOTPLASMA "You got the plasma gun!"
#define GOTSHOTGUN "You got the shotgun!"
#define GOTSHOTGUN2 "You got the super shotgun!"
//
// P_Doors.C
//
#define PD_BLUEO "You need a blue key to activate this object"
#define PD_REDO "You need a red key to activate this object"
#define PD_YELLOWO "You need a yellow key to activate this object"
#define PD_BLUEK "You need a blue key to open this door"
#define PD_REDK "You need a red key to open this door"
#define PD_YELLOWK "You need a yellow key to open this door"
//
// G_game.C
//
#define GGSAVED "game saved."
//
// HU_stuff.C
//
#define HUSTR_MSGU "[Message unsent]"
#define HUSTR_E1M1 "E1M1: Hangar"
#define HUSTR_E1M2 "E1M2: Nuclear Plant"
#define HUSTR_E1M3 "E1M3: Toxin Refinery"
#define HUSTR_E1M4 "E1M4: Command Control"
#define HUSTR_E1M5 "E1M5: Phobos Lab"
#define HUSTR_E1M6 "E1M6: Central Processing"
#define HUSTR_E1M7 "E1M7: Computer Station"
#define HUSTR_E1M8 "E1M8: Phobos Anomaly"
#define HUSTR_E1M9 "E1M9: Military Base"
#define HUSTR_E2M1 "E2M1: Deimos Anomaly"
#define HUSTR_E2M2 "E2M2: Containment Area"
#define HUSTR_E2M3 "E2M3: Refinery"
#define HUSTR_E2M4 "E2M4: Deimos Lab"
#define HUSTR_E2M5 "E2M5: Command Center"
#define HUSTR_E2M6 "E2M6: Halls of the Damned"
#define HUSTR_E2M7 "E2M7: Spawning Vats"
#define HUSTR_E2M8 "E2M8: Tower of Babel"
#define HUSTR_E2M9 "E2M9: Fortress of Mystery"
#define HUSTR_E3M1 "E3M1: Hell Keep"
#define HUSTR_E3M2 "E3M2: Slough of Despair"
#define HUSTR_E3M3 "E3M3: Pandemonium"
#define HUSTR_E3M4 "E3M4: House of Pain"
#define HUSTR_E3M5 "E3M5: Unholy Cathedral"
#define HUSTR_E3M6 "E3M6: Mt. Erebus"
#define HUSTR_E3M7 "E3M7: Limbo"
#define HUSTR_E3M8 "E3M8: Dis"
#define HUSTR_E3M9 "E3M9: Warrens"
#define HUSTR_E4M1 "E4M1: Hell Beneath"
#define HUSTR_E4M2 "E4M2: Perfect Hatred"
#define HUSTR_E4M3 "E4M3: Sever The Wicked"
#define HUSTR_E4M4 "E4M4: Unruly Evil"
#define HUSTR_E4M5 "E4M5: They Will Repent"
#define HUSTR_E4M6 "E4M6: Against Thee Wickedly"
#define HUSTR_E4M7 "E4M7: And Hell Followed"
#define HUSTR_E4M8 "E4M8: Unto The Cruel"
#define HUSTR_E4M9 "E4M9: Fear"
#define HUSTR_1 "level 1: entryway"
#define HUSTR_2 "level 2: underhalls"
#define HUSTR_3 "level 3: the gantlet"
#define HUSTR_4 "level 4: the focus"
#define HUSTR_5 "level 5: the waste tunnels"
#define HUSTR_6 "level 6: the crusher"
#define HUSTR_7 "level 7: dead simple"
#define HUSTR_8 "level 8: tricks and traps"
#define HUSTR_9 "level 9: the pit"
#define HUSTR_10 "level 10: refueling base"
#define HUSTR_11 "level 11: 'o' of destruction!"
#define HUSTR_12 "level 12: the factory"
#define HUSTR_13 "level 13: downtown"
#define HUSTR_14 "level 14: the inmost dens"
#define HUSTR_15 "level 15: industrial zone"
#define HUSTR_16 "level 16: suburbs"
#define HUSTR_17 "level 17: tenements"
#define HUSTR_18 "level 18: the courtyard"
#define HUSTR_19 "level 19: the citadel"
#define HUSTR_20 "level 20: gotcha!"
#define HUSTR_21 "level 21: nirvana"
#define HUSTR_22 "level 22: the catacombs"
#define HUSTR_23 "level 23: barrels o' fun"
#define HUSTR_24 "level 24: the chasm"
#define HUSTR_25 "level 25: bloodfalls"
#define HUSTR_26 "level 26: the abandoned mines"
#define HUSTR_27 "level 27: monster condo"
#define HUSTR_28 "level 28: the spirit world"
#define HUSTR_29 "level 29: the living end"
#define HUSTR_30 "level 30: icon of sin"
#define HUSTR_31 "level 31: wolfenstein"
#define HUSTR_32 "level 32: grosse"
#define PHUSTR_1 "level 1: congo"
#define PHUSTR_2 "level 2: well of souls"
#define PHUSTR_3 "level 3: aztec"
#define PHUSTR_4 "level 4: caged"
#define PHUSTR_5 "level 5: ghost town"
#define PHUSTR_6 "level 6: baron's lair"
#define PHUSTR_7 "level 7: caughtyard"
#define PHUSTR_8 "level 8: realm"
#define PHUSTR_9 "level 9: abattoire"
#define PHUSTR_10 "level 10: onslaught"
#define PHUSTR_11 "level 11: hunted"
#define PHUSTR_12 "level 12: speed"
#define PHUSTR_13 "level 13: the crypt"
#define PHUSTR_14 "level 14: genesis"
#define PHUSTR_15 "level 15: the twilight"
#define PHUSTR_16 "level 16: the omen"
#define PHUSTR_17 "level 17: compound"
#define PHUSTR_18 "level 18: neurosphere"
#define PHUSTR_19 "level 19: nme"
#define PHUSTR_20 "level 20: the death domain"
#define PHUSTR_21 "level 21: slayer"
#define PHUSTR_22 "level 22: impossible mission"
#define PHUSTR_23 "level 23: tombstone"
#define PHUSTR_24 "level 24: the final frontier"
#define PHUSTR_25 "level 25: the temple of darkness"
#define PHUSTR_26 "level 26: bunker"
#define PHUSTR_27 "level 27: anti-christ"
#define PHUSTR_28 "level 28: the sewers"
#define PHUSTR_29 "level 29: odyssey of noises"
#define PHUSTR_30 "level 30: the gateway of hell"
#define PHUSTR_31 "level 31: cyberden"
#define PHUSTR_32 "level 32: go 2 it"
#define THUSTR_1 "level 1: system control"
#define THUSTR_2 "level 2: human bbq"
#define THUSTR_3 "level 3: power control"
#define THUSTR_4 "level 4: wormhole"
#define THUSTR_5 "level 5: hanger"
#define THUSTR_6 "level 6: open season"
#define THUSTR_7 "level 7: prison"
#define THUSTR_8 "level 8: metal"
#define THUSTR_9 "level 9: stronghold"
#define THUSTR_10 "level 10: redemption"
#define THUSTR_11 "level 11: storage facility"
#define THUSTR_12 "level 12: crater"
#define THUSTR_13 "level 13: nukage processing"
#define THUSTR_14 "level 14: steel works"
#define THUSTR_15 "level 15: dead zone"
#define THUSTR_16 "level 16: deepest reaches"
#define THUSTR_17 "level 17: processing area"
#define THUSTR_18 "level 18: mill"
#define THUSTR_19 "level 19: shipping/respawning"
#define THUSTR_20 "level 20: central processing"
#define THUSTR_21 "level 21: administration center"
#define THUSTR_22 "level 22: habitat"
#define THUSTR_23 "level 23: lunar mining project"
#define THUSTR_24 "level 24: quarry"
#define THUSTR_25 "level 25: baron's den"
#define THUSTR_26 "level 26: ballistyx"
#define THUSTR_27 "level 27: mount pain"
#define THUSTR_28 "level 28: heck"
#define THUSTR_29 "level 29: river styx"
#define THUSTR_30 "level 30: last call"
#define THUSTR_31 "level 31: pharaoh"
#define THUSTR_32 "level 32: caribbean"
#define HUSTR_CHATMACRO1 "I'm ready to kick butt!"
#define HUSTR_CHATMACRO2 "I'm OK."
#define HUSTR_CHATMACRO3 "I'm not looking too good!"
#define HUSTR_CHATMACRO4 "Help!"
#define HUSTR_CHATMACRO5 "You suck!"
#define HUSTR_CHATMACRO6 "Next time, scumbag..."
#define HUSTR_CHATMACRO7 "Come here!"
#define HUSTR_CHATMACRO8 "I'll take care of it."
#define HUSTR_CHATMACRO9 "Yes"
#define HUSTR_CHATMACRO0 "No"
#define HUSTR_TALKTOSELF1 "You mumble to yourself"
#define HUSTR_TALKTOSELF2 "Who's there?"
#define HUSTR_TALKTOSELF3 "You scare yourself"
#define HUSTR_TALKTOSELF4 "You start to rave"
#define HUSTR_TALKTOSELF5 "You've lost it..."
#define HUSTR_MESSAGESENT "[Message Sent]"
// The following should NOT be changed unless it seems
// just AWFULLY necessary
#define HUSTR_PLRGREEN "Green: "
#define HUSTR_PLRINDIGO "Indigo: "
#define HUSTR_PLRBROWN "Brown: "
#define HUSTR_PLRRED "Red: "
#define HUSTR_KEYGREEN 'g'
#define HUSTR_KEYINDIGO 'i'
#define HUSTR_KEYBROWN 'b'
#define HUSTR_KEYRED 'r'
//
// AM_map.C
//
#define AMSTR_FOLLOWON "Follow Mode ON"
#define AMSTR_FOLLOWOFF "Follow Mode OFF"
#define AMSTR_GRIDON "Grid ON"
#define AMSTR_GRIDOFF "Grid OFF"
#define AMSTR_MARKEDSPOT "Marked Spot"
#define AMSTR_MARKSCLEARED "All Marks Cleared"
//
// ST_stuff.C
//
#define STSTR_MUS "Music Change"
#define STSTR_NOMUS "IMPOSSIBLE SELECTION"
#define STSTR_DQDON "Degreelessness Mode On"
#define STSTR_DQDOFF "Degreelessness Mode Off"
#define STSTR_KFAADDED "Very Happy Ammo Added"
#define STSTR_FAADDED "Ammo (no keys) Added"
#define STSTR_NCON "No Clipping Mode ON"
#define STSTR_NCOFF "No Clipping Mode OFF"
#define STSTR_BEHOLD "inVuln, Str, Inviso, Rad, Allmap, or Lite-amp"
#define STSTR_BEHOLDX "Power-up Toggled"
#define STSTR_CHOPPERS "... doesn't suck - GM"
#define STSTR_CLEV "Changing Level..."
//
// F_Finale.C
//
#define E1TEXT \
"Once you beat the big badasses and\n"\
"clean out the moon base you're supposed\n"\
"to win, aren't you? Aren't you? Where's\n"\
"your fat reward and ticket home? What\n"\
"the hell is this? It's not supposed to\n"\
"end this way!\n"\
"\n" \
"It stinks like rotten meat, but looks\n"\
"like the lost Deimos base. Looks like\n"\
"you're stuck on The Shores of Hell.\n"\
"The only way out is through.\n"\
"\n"\
"To continue the DOOM experience, play\n"\
"The Shores of Hell and its amazing\n"\
"sequel, Inferno!\n"
#define E2TEXT \
"You've done it! The hideous cyber-\n"\
"demon lord that ruled the lost Deimos\n"\
"moon base has been slain and you\n"\
"are triumphant! But ... where are\n"\
"you? You clamber to the edge of the\n"\
"moon and look down to see the awful\n"\
"truth.\n" \
"\n"\
"Deimos floats above Hell itself!\n"\
"You've never heard of anyone escaping\n"\
"from Hell, but you'll make the bastards\n"\
"sorry they ever heard of you! Quickly,\n"\
"you rappel down to the surface of\n"\
"Hell.\n"\
"\n" \
"Now, it's on to the final chapter of\n"\
"DOOM! -- Inferno."
#define E3TEXT \
"The loathsome spiderdemon that\n"\
"masterminded the invasion of the moon\n"\
"bases and caused so much death has had\n"\
"its ass kicked for all time.\n"\
"\n"\
"A hidden doorway opens and you enter.\n"\
"You've proven too tough for Hell to\n"\
"contain, and now Hell at last plays\n"\
"fair -- for you emerge from the door\n"\
"to see the green fields of Earth!\n"\
"Home at last.\n" \
"\n"\
"You wonder what's been happening on\n"\
"Earth while you were battling evil\n"\
"unleashed. It's good that no Hell-\n"\
"spawn could have come through that\n"\
"door with you ..."
#define E4TEXT \
"the spider mastermind must have sent forth\n"\
"its legions of hellspawn before your\n"\
"final confrontation with that terrible\n"\
"beast from hell. but you stepped forward\n"\
"and brought forth eternal damnation and\n"\
"suffering upon the horde as a true hero\n"\
"would in the face of something so evil.\n"\
"\n"\
"besides, someone was gonna pay for what\n"\
"happened to daisy, your pet rabbit.\n"\
"\n"\
"but now, you see spread before you more\n"\
"potential pain and gibbitude as a nation\n"\
"of demons run amok among our cities.\n"\
"\n"\
"next stop, hell on earth!"
// after level 6, put this:
#define C1TEXT \
"YOU HAVE ENTERED DEEPLY INTO THE INFESTED\n" \
"STARPORT. BUT SOMETHING IS WRONG. THE\n" \
"MONSTERS HAVE BROUGHT THEIR OWN REALITY\n" \
"WITH THEM, AND THE STARPORT'S TECHNOLOGY\n" \
"IS BEING SUBVERTED BY THEIR PRESENCE.\n" \
"\n"\
"AHEAD, YOU SEE AN OUTPOST OF HELL, A\n" \
"FORTIFIED ZONE. IF YOU CAN GET PAST IT,\n" \
"YOU CAN PENETRATE INTO THE HAUNTED HEART\n" \
"OF THE STARBASE AND FIND THE CONTROLLING\n" \
"SWITCH WHICH HOLDS EARTH'S POPULATION\n" \
"HOSTAGE."
// After level 11, put this:
#define C2TEXT \
"YOU HAVE WON! YOUR VICTORY HAS ENABLED\n" \
"HUMANKIND TO EVACUATE EARTH AND ESCAPE\n"\
"THE NIGHTMARE. NOW YOU ARE THE ONLY\n"\
"HUMAN LEFT ON THE FACE OF THE PLANET.\n"\
"CANNIBAL MUTATIONS, CARNIVOROUS ALIENS,\n"\
"AND EVIL SPIRITS ARE YOUR ONLY NEIGHBORS.\n"\
"YOU SIT BACK AND WAIT FOR DEATH, CONTENT\n"\
"THAT YOU HAVE SAVED YOUR SPECIES.\n"\
"\n"\
"BUT THEN, EARTH CONTROL BEAMS DOWN A\n"\
"MESSAGE FROM SPACE: \"SENSORS HAVE LOCATED\n"\
"THE SOURCE OF THE ALIEN INVASION. IF YOU\n"\
"GO THERE, YOU MAY BE ABLE TO BLOCK THEIR\n"\
"ENTRY. THE ALIEN BASE IS IN THE HEART OF\n"\
"YOUR OWN HOME CITY, NOT FAR FROM THE\n"\
"STARPORT.\" SLOWLY AND PAINFULLY YOU GET\n"\
"UP AND RETURN TO THE FRAY."
// After level 20, put this:
#define C3TEXT \
"YOU ARE AT THE CORRUPT HEART OF THE CITY,\n"\
"SURROUNDED BY THE CORPSES OF YOUR ENEMIES.\n"\
"YOU SEE NO WAY TO DESTROY THE CREATURES'\n"\
"ENTRYWAY ON THIS SIDE, SO YOU CLENCH YOUR\n"\
"TEETH AND PLUNGE THROUGH IT.\n"\
"\n"\
"THERE MUST BE A WAY TO CLOSE IT ON THE\n"\
"OTHER SIDE. WHAT DO YOU CARE IF YOU'VE\n"\
"GOT TO GO THROUGH HELL TO GET TO IT?"
// After level 29, put this:
#define C4TEXT \
"THE HORRENDOUS VISAGE OF THE BIGGEST\n"\
"DEMON YOU'VE EVER SEEN CRUMBLES BEFORE\n"\
"YOU, AFTER YOU PUMP YOUR ROCKETS INTO\n"\
"HIS EXPOSED BRAIN. THE MONSTER SHRIVELS\n"\
"UP AND DIES, ITS THRASHING LIMBS\n"\
"DEVASTATING UNTOLD MILES OF HELL'S\n"\
"SURFACE.\n"\
"\n"\
"YOU'VE DONE IT. THE INVASION IS OVER.\n"\
"EARTH IS SAVED. HELL IS A WRECK. YOU\n"\
"WONDER WHERE BAD FOLKS WILL GO WHEN THEY\n"\
"DIE, NOW. WIPING THE SWEAT FROM YOUR\n"\
"FOREHEAD YOU BEGIN THE LONG TREK BACK\n"\
"HOME. REBUILDING EARTH OUGHT TO BE A\n"\
"LOT MORE FUN THAN RUINING IT WAS.\n"
// Before level 31, put this:
#define C5TEXT \
"CONGRATULATIONS, YOU'VE FOUND THE SECRET\n"\
"LEVEL! LOOKS LIKE IT'S BEEN BUILT BY\n"\
"HUMANS, RATHER THAN DEMONS. YOU WONDER\n"\
"WHO THE INMATES OF THIS CORNER OF HELL\n"\
"WILL BE."
// Before level 32, put this:
#define C6TEXT \
"CONGRATULATIONS, YOU'VE FOUND THE\n"\
"SUPER SECRET LEVEL! YOU'D BETTER\n"\
"BLAZE THROUGH THIS ONE!\n"
// after map 06
#define P1TEXT \
"You gloat over the steaming carcass of the\n"\
"Guardian. With its death, you've wrested\n"\
"the Accelerator from the stinking claws\n"\
"of Hell. You relax and glance around the\n"\
"room. Damn! There was supposed to be at\n"\
"least one working prototype, but you can't\n"\
"see it. The demons must have taken it.\n"\
"\n"\
"You must find the prototype, or all your\n"\
"struggles will have been wasted. Keep\n"\
"moving, keep fighting, keep killing.\n"\
"Oh yes, keep living, too."
// after map 11
#define P2TEXT \
"Even the deadly Arch-Vile labyrinth could\n"\
"not stop you, and you've gotten to the\n"\
"prototype Accelerator which is soon\n"\
"efficiently and permanently deactivated.\n"\
"\n"\
"You're good at that kind of thing."
// after map 20
#define P3TEXT \
"You've bashed and battered your way into\n"\
"the heart of the devil-hive. Time for a\n"\
"Search-and-Destroy mission, aimed at the\n"\
"Gatekeeper, whose foul offspring is\n"\
"cascading to Earth. Yeah, he's bad. But\n"\
"you know who's worse!\n"\
"\n"\
"Grinning evilly, you check your gear, and\n"\
"get ready to give the bastard a little Hell\n"\
"of your own making!"
// after map 30
#define P4TEXT \
"The Gatekeeper's evil face is splattered\n"\
"all over the place. As its tattered corpse\n"\
"collapses, an inverted Gate forms and\n"\
"sucks down the shards of the last\n"\
"prototype Accelerator, not to mention the\n"\
"few remaining demons. You're done. Hell\n"\
"has gone back to pounding bad dead folks \n"\
"instead of good live ones. Remember to\n"\
"tell your grandkids to put a rocket\n"\
"launcher in your coffin. If you go to Hell\n"\
"when you die, you'll need it for some\n"\
"final cleaning-up ..."
// before map 31
#define P5TEXT \
"You've found the second-hardest level we\n"\
"got. Hope you have a saved game a level or\n"\
"two previous. If not, be prepared to die\n"\
"aplenty. For master marines only."
// before map 32
#define P6TEXT \
"Betcha wondered just what WAS the hardest\n"\
"level we had ready for ya? Now you know.\n"\
"No one gets out alive."
#define T1TEXT \
"You've fought your way out of the infested\n"\
"experimental labs. It seems that UAC has\n"\
"once again gulped it down. With their\n"\
"high turnover, it must be hard for poor\n"\
"old UAC to buy corporate health insurance\n"\
"nowadays..\n"\
"\n"\
"Ahead lies the military complex, now\n"\
"swarming with diseased horrors hot to get\n"\
"their teeth into you. With luck, the\n"\
"complex still has some warlike ordnance\n"\
"laying around."
#define T2TEXT \
"You hear the grinding of heavy machinery\n"\
"ahead. You sure hope they're not stamping\n"\
"out new hellspawn, but you're ready to\n"\
"ream out a whole herd if you have to.\n"\
"They might be planning a blood feast, but\n"\
"you feel about as mean as two thousand\n"\
"maniacs packed into one mad killer.\n"\
"\n"\
"You don't plan to go down easy."
#define T3TEXT \
"The vista opening ahead looks real damn\n"\
"familiar. Smells familiar, too -- like\n"\
"fried excrement. You didn't like this\n"\
"place before, and you sure as hell ain't\n"\
"planning to like it now. The more you\n"\
"brood on it, the madder you get.\n"\
"Hefting your gun, an evil grin trickles\n"\
"onto your face. Time to take some names."
#define T4TEXT \
"Suddenly, all is silent, from one horizon\n"\
"to the other. The agonizing echo of Hell\n"\
"fades away, the nightmare sky turns to\n"\
"blue, the heaps of monster corpses start \n"\
"to evaporate along with the evil stench \n"\
"that filled the air. Jeeze, maybe you've\n"\
"done it. Have you really won?\n"\
"\n"\
"Something rumbles in the distance.\n"\
"A blue light begins to glow inside the\n"\
"ruined skull of the demon-spitter."
#define T5TEXT \
"What now? Looks totally different. Kind\n"\
"of like King Tut's condo. Well,\n"\
"whatever's here can't be any worse\n"\
"than usual. Can it? Or maybe it's best\n"\
"to let sleeping gods lie.."
#define T6TEXT \
"Time for a vacation. You've burst the\n"\
"bowels of hell and by golly you're ready\n"\
"for a break. You mutter to yourself,\n"\
"Maybe someone else can kick Hell's ass\n"\
"next time around. Ahead lies a quiet town,\n"\
"with peaceful flowing water, quaint\n"\
"buildings, and presumably no Hellspawn.\n"\
"\n"\
"As you step off the transport, you hear\n"\
"the stomp of a cyberdemon's iron shoe."
//
// Character cast strings F_FINALE.C
//
#define CC_ZOMBIE "ZOMBIEMAN"
#define CC_SHOTGUN "SHOTGUN GUY"
#define CC_HEAVY "HEAVY WEAPON DUDE"
#define CC_IMP "IMP"
#define CC_DEMON "DEMON"
#define CC_LOST "LOST SOUL"
#define CC_CACO "CACODEMON"
#define CC_HELL "HELL KNIGHT"
#define CC_BARON "BARON OF HELL"
#define CC_ARACH "ARACHNOTRON"
#define CC_PAIN "PAIN ELEMENTAL"
#define CC_REVEN "REVENANT"
#define CC_MANCU "MANCUBUS"
#define CC_ARCH "ARCH-VILE"
#define CC_SPIDER "THE SPIDER MASTERMIND"
#define CC_CYBER "THE CYBERDEMON"
#define CC_HERO "OUR HERO"
#endif
//-----------------------------------------------------------------------------
//
// $Log:$
//
//-----------------------------------------------------------------------------

122
cgdoom/d_event.h

@ -0,0 +1,122 @@
// Emacs style mode select -*- C++ -*-
//-----------------------------------------------------------------------------
//
// $Id:$
//
// Copyright (C) 1993-1996 by id Software, Inc.
//
// This source is available for distribution and/or modification
// only under the terms of the DOOM Source Code License as
// published by id Software. All rights reserved.
//
// The source is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// FITNESS FOR A PARTICULAR PURPOSE. See the DOOM Source Code License
// for more details.
//
// DESCRIPTION:
//
//
//-----------------------------------------------------------------------------
#ifndef __D_EVENT__
#define __D_EVENT__
#include "doomtype.h"
//
// Event handling.
//
// Input event types.
typedef enum
{
ev_keydown,
ev_keyup,
ev_mouse,
ev_joystick
} evtype_t;
// Event structure.
typedef struct
{
evtype_t type;
int data1; // keys / mouse/joystick buttons
int data2; // mouse/joystick x move
int data3; // mouse/joystick y move
} event_t;
typedef enum
{
ga_nothing,
ga_loadlevel,
ga_newgame,
ga_loadgame,
ga_savegame,
ga_playdemo,
ga_completed,
ga_victory,
ga_worlddone
} gameaction_t;
//
// Button/action code definitions.
//
typedef enum
{
// Press "Fire".
BT_ATTACK = 1,
// Use button, to open doors, activate switches.
BT_USE = 2,
// Flag: game events, not really buttons.
BT_SPECIAL = 128,
BT_SPECIALMASK = 3,
// Flag, weapon change pending.
// If true, the next 3 bits hold weapon num.
BT_CHANGE = 4,
// The 3bit weapon mask and shift, convenience.
BT_WEAPONMASK = (8+16+32),
BT_WEAPONSHIFT = 3,
// Pause the game.
BTS_PAUSE = 1,
// Save the game at each console.
BTS_SAVEGAME = 2,
// Savegame slot numbers
// occupy the second byte of buttons.
BTS_SAVEMASK = (4+8+16),
BTS_SAVESHIFT = 2,
} buttoncode_t;
//
// GLOBAL VARIABLES
//
#define MAXEVENTS 64
extern event_t events[MAXEVENTS];
extern int eventid;
/*extern int eventhead;
extern int eventtail;*/
extern gameaction_t gameaction;
#endif
//-----------------------------------------------------------------------------
//
// $Log:$
//
//-----------------------------------------------------------------------------

59
cgdoom/d_items.c

@ -0,0 +1,59 @@
// Emacs style mode select -*- C++ -*-
//-----------------------------------------------------------------------------
//
// $Id:$
//
// Copyright (C) 1993-1996 by id Software, Inc.
//
// This source is available for distribution and/or modification
// only under the terms of the DOOM Source Code License as
// published by id Software. All rights reserved.
//
// The source is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// FITNESS FOR A PARTICULAR PURPOSE. See the DOOM Source Code License
// for more details.
//
// $Log:$
//
// DESCRIPTION:
//
//-----------------------------------------------------------------------------
//static const char
//rcsid[] = "$Id:$";
// We are referring to sprite numbers.
#include "info.h"
#ifdef __GNUG__
#pragma implementation "d_items.h"
#endif
#include "d_items.h"
//
// PSPRITE ACTIONS for waepons.
// This struct controls the weapon animations.
//
// Each entry is:
// ammo/amunition type
// upstate
// downstate
// readystate
// atkstate, i.e. attack/fire/hit frame
// flashstate, muzzle flash
//
const weaponinfo_t weaponinfo[NUMWEAPONS] =
{
{am_noammo,S_PUNCHUP,S_PUNCHDOWN,S_PUNCH,S_PUNCH1,S_NULL},// fist
{am_clip,S_PISTOLUP,S_PISTOLDOWN,S_PISTOL,S_PISTOL1,S_PISTOLFLASH},// pistol
{am_shell,S_SGUNUP,S_SGUNDOWN,S_SGUN,S_SGUN1,S_SGUNFLASH1},// shotgun
{am_clip,S_CHAINUP,S_CHAINDOWN,S_CHAIN,S_CHAIN1,S_CHAINFLASH1},// chaingun
{am_misl,S_MISSILEUP,S_MISSILEDOWN,S_MISSILE,S_MISSILE1,S_MISSILEFLASH1},// missile launcher
{am_cell,S_PLASMAUP,S_PLASMADOWN,S_PLASMA,S_PLASMA1,S_PLASMAFLASH1},// plasma rifle
{am_cell,S_BFGUP,S_BFGDOWN,S_BFG,S_BFG1,S_BFGFLASH1},// bfg 9000
{am_noammo,S_SAWUP,S_SAWDOWN,S_SAW,S_SAW1,S_NULL},// chainsaw
{am_shell,S_DSGUNUP,S_DSGUNDOWN,S_DSGUN,S_DSGUN1,S_DSGUNFLASH1},// super shotgun
};

52
cgdoom/d_items.h

@ -0,0 +1,52 @@
// Emacs style mode select -*- C++ -*-
//-----------------------------------------------------------------------------
//
// $Id:$
//
// Copyright (C) 1993-1996 by id Software, Inc.
//
// This source is available for distribution and/or modification
// only under the terms of the DOOM Source Code License as
// published by id Software. All rights reserved.
//
// The source is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// FITNESS FOR A PARTICULAR PURPOSE. See the DOOM Source Code License
// for more details.
//
// DESCRIPTION:
// Items: key cards, artifacts, weapon, ammunition.
//
//-----------------------------------------------------------------------------
#ifndef __D_ITEMS__
#define __D_ITEMS__
#include "doomdef.h"
#ifdef __GNUG__
#pragma interface
#endif
// Weapon info: sprite frames, ammunition use.
typedef struct
{
ammotype_t ammo;
int upstate;
int downstate;
int readystate;