More compiling.

This commit is contained in:
Steven Fuller 2001-07-30 00:05:20 +00:00 committed by Patryk Obara
parent 4db15e7459
commit a9cf09aa34
9 changed files with 49 additions and 59 deletions

View file

@ -11,13 +11,13 @@ LDLIBS += -L/usr/X11R6/lib -lX11 -lXext `sdl-config --libs`
AFLAGS = -g -Iinclude/ -w+macro-params -w+orphan-labels -w+number-overflow
ROOT = main.c stubs.c afont.c frustum.c kshape.c map.c maths.c md5.c mem3dc.c mem3dcpp.cpp module.c morph.c mslhand.c object.c shpanim.c sphere.c tables.c vdb.c version.c
AVP = ai_sight.c avpview.c bh_agun.c bh_ais.c bh_alien.c bh_binsw.c bh_cable.c bh_corpse.c bh_deathvol.c bh_debri.c bh_dummy.c bh_fan.c bh_far.c bh_fhug.c bh_gener.c bh_ldoor.c bh_lift.c bh_light.c bh_lnksw.c bh_ltfx.c bh_marin.c bh_mission.c bh_near.c bh_pargen.c bh_plachier.c bh_plift.c bh_pred.c bh_queen.c bh_rubberduck.c bh_selfdest.c bh_snds.c bh_spcl.c bh_swdor.c bh_track.c bh_types.c bh_videoscreen.c bh_waypt.c bh_weap.c bh_xeno.c bonusabilities.c cconvars.cpp cdtrackselection.cpp cheatmodes.c comp_map.c comp_shp.c consolelog.cpp davehook.cpp deaths.c decal.c detaillevels.c dynamics.c dynblock.c equipmnt.c equiputl.cpp extents.c game.c gamecmds.cpp gameflow.c gamevars.cpp hmodel.c hud.c inventry.c language.c lighting.c load_shp.c los.c maps.c mempool.c messagehistory.c missions.cpp movement.c paintball.c particle.c pfarlocs.c pheromon.c pmove.c psndproj.c pvisible.c savegame.c scream.cpp secstats.c sfx.c stratdef.c targeting.c track.c triggers.c weapons.c
AVP = ai_sight.c avpview.c bh_agun.c bh_ais.c bh_alien.c bh_binsw.c bh_cable.c bh_corpse.c bh_deathvol.c bh_debri.c bh_dummy.c bh_fan.c bh_far.c bh_fhug.c bh_gener.c bh_ldoor.c bh_lift.c bh_light.c bh_lnksw.c bh_ltfx.c bh_marin.c bh_mission.c bh_near.c bh_pargen.c bh_plachier.c bh_plift.c bh_pred.c bh_queen.c bh_rubberduck.c bh_selfdest.c bh_snds.c bh_spcl.c bh_swdor.c bh_track.c bh_types.c bh_videoscreen.c bh_waypt.c bh_weap.c bh_xeno.c bonusabilities.c cconvars.cpp cdtrackselection.cpp cheatmodes.c comp_map.c comp_shp.c consolelog.cpp davehook.cpp deaths.c decal.c detaillevels.c dynamics.c dynblock.c equipmnt.c equiputl.cpp extents.c game.c gamecmds.cpp gameflow.c gamevars.cpp hmodel.c hud.c inventry.c language.c lighting.c load_shp.c los.c maps.c mempool.c messagehistory.c missions.cpp movement.c paintball.c particle.c pfarlocs.c pheromon.c player.c pmove.c psnd.c psndproj.c pvisible.c savegame.c scream.cpp secstats.c sfx.c stratdef.c targeting.c track.c triggers.c weapons.c
SHAPES = cube.c
SUPPORT = consbind.cpp consbtch.cpp coordstr.cpp daemon.cpp r2base.cpp r2pos666.cpp reflist.cpp refobj.cpp scstring.cpp strtab.cpp strutil.c trig666.cpp wrapstr.cpp
AVPWIN95 = avpchunk.cpp cheat.c chtcodes.cpp d3d_hud.cpp endianio.c ffread.cpp ffstdio.cpp gflwplat.c hierplace.cpp iofocus.cpp jsndsup.cpp kzsort.c langplat.c modcmds.cpp npcsetup.cpp objsetup.cpp pathchnk.cpp platsup.c pldghost.c projload.cpp strachnk.cpp system.c vision.c
FRONTEND = avp_envinfo.c avp_intro.cpp
GADGETS = ahudgadg.cpp conscmnd.cpp conssym.cpp consvar.cpp gadget.cpp hudgadg.cpp rootgadg.cpp t_ingadg.cpp teletype.cpp textexp.cpp textin.cpp trepgadg.cpp
WIN95 = animchnk.cpp animobs.cpp awiffld.cpp bmpnames.cpp chnkload.cpp chnktexi.cpp chnktype.cpp chunk.cpp chunkpal.cpp debuglog.cpp dummyobjectchunk.cpp enumchnk.cpp enumsch.cpp envchunk.cpp fail.c fragchnk.cpp gsprchnk.cpp hierchnk.cpp huffman.cpp iff.cpp iff_ilbm.cpp ilbm_ext.cpp io.c list_tem.cpp ltchunk.cpp media.cpp mishchnk.cpp obchunk.cpp oechunk.cpp our_mem.c plat_shp.c plspecfn.c shpchunk.cpp sndchunk.cpp sprchunk.cpp string.cpp texio.c toolchnk.cpp txioctrl.cpp wpchunk.cpp zsp.cpp
WIN95 = animchnk.cpp animobs.cpp awbmpld.cpp awiffld.cpp awpnmld.cpp bmpnames.cpp chnkload.cpp chnktexi.cpp chnktype.cpp chunk.cpp chunkpal.cpp debuglog.cpp dummyobjectchunk.cpp enumchnk.cpp enumsch.cpp envchunk.cpp fail.c fragchnk.cpp gsprchnk.cpp hierchnk.cpp huffman.cpp iff.cpp iff_ilbm.cpp ilbm_ext.cpp io.c list_tem.cpp ltchunk.cpp media.cpp mishchnk.cpp obchunk.cpp oechunk.cpp our_mem.c plat_shp.c plspecfn.c shpchunk.cpp sndchunk.cpp sprchunk.cpp string.cpp texio.c toolchnk.cpp txioctrl.cpp wpchunk.cpp zsp.cpp
# the following should really be autogenerated...

View file

@ -93,9 +93,9 @@ avp/paintball.c
avp/particle.c
avp/pfarlocs.c
avp/pheromon.c
TODO avp/player.c
avp/player.c
avp/pmove.c
TODO avp/psnd.c
avp/psnd.c
avp/psndproj.c
avp/pvisible.c
avp/savegame.c
@ -193,9 +193,9 @@ avp/win95/gadgets/trepgadg.cpp
TODO win95/alt_tab.cpp
win95/animchnk.cpp
win95/animobs.cpp
TODO win95/awbmpld.cpp
win95/awbmpld.cpp
win95/awiffld.cpp
TODO win95/awpnmld.cpp
win95/awpnmld.cpp
TODO win95/awtexld.cpp
win95/bmpnames.cpp
TODO win95/cd_player.c

View file

@ -33,11 +33,13 @@ so player.c is looking a bit bare at the moment. */
#if SupportWindows95
#include "pldnet.h"
#include "pldghost.h"
#include "dp_func.h"
//#include "dp_func.h"
#endif
#include "showcmds.h"
#include "bonusabilities.h"
extern DPID AVPDPNetID;
#define PLAYER_HMODEL 0
/*KJL****************************************************************************************

View file

@ -4,6 +4,8 @@
#define DB_LEVEL 1
#include <stdio.h>
#include "3dc.h"
#include "module.h"
#include "inline.h"
@ -546,11 +548,13 @@ void Sound_Play(SOUNDINDEX soundNumber, char *format, ...)
GameSounds[soundNumber].activeInstances++;
if(externalRef) *externalRef = newIndex;
if(soundStartPosition && ActiveSounds[newIndex].dsBufferP)
{
//sound starts part of the way in
IDirectSoundBuffer_SetCurrentPosition(ActiveSounds[newIndex].dsBufferP,soundStartPosition);
}
// if(soundStartPosition && ActiveSounds[newIndex].dsBufferP)
// {
// //sound starts part of the way in
// IDirectSoundBuffer_SetCurrentPosition(ActiveSounds[newIndex].dsBufferP,soundStartPosition);
// }
if (soundStartPosition)
fprintf(stderr, "Sound_Play: sound starts part of the way in (%d)\n", soundStartPosition);
}
void Sound_Stop(int activeSoundNumber)
@ -829,11 +833,12 @@ void Save_SoundState(int* soundHandle)
block->volume<<=7;
block->volume/=VOLUME_PLAT2DSCALE;
if(sound->dsBufferP)
IDirectSoundBuffer_GetCurrentPosition(sound->dsBufferP,(LPDWORD)&block->position,NULL);
else
// if(sound->dsBufferP)
// IDirectSoundBuffer_GetCurrentPosition(sound->dsBufferP,(LPDWORD)&block->position,NULL);
// else
block->position = 0;
fprintf(stderr, "Save_SoundState: GetCurrentPosition!\n");
strcpy((char*)(block+1),name);
}
@ -918,11 +923,12 @@ void Save_SoundsWithNoReference()
block->volume<<=7;
block->volume/=VOLUME_PLAT2DSCALE;
if(sound->dsBufferP)
IDirectSoundBuffer_GetCurrentPosition(sound->dsBufferP,(LPDWORD)&block->position,NULL);
else
// if(sound->dsBufferP)
// IDirectSoundBuffer_GetCurrentPosition(sound->dsBufferP,(LPDWORD)&block->position,NULL);
// else
block->position = 0;
fprintf(stderr, "Save_SoundsWithNoReference: GetCurrentPosition!\n");
strcpy((char*)(block+1),name);
}
}

View file

@ -19,24 +19,6 @@ extern char * SecondSoundDir;
SecondSoundDir = "./sounds";
}
/* psnd.c */
#include "psnd.h"
void Sound_Play(SOUNDINDEX soundNumber, char* format, ...)
{
fprintf(stderr, "Sound_Play(%d, %s)\n", soundNumber, format);
}
void Sound_Stop(int activeSoundNumber)
{
fprintf(stderr, "Sound_Stop(%d)\n", activeSoundNumber);
}
void Sound_Update3d(int activeSoundNumber, VECTORCH* posn)
{
fprintf(stderr, "Sound_Update3d(%d, %p)\n", activeSoundNumber, posn);
}
/* dd_func.cpp */
void FlipBuffers()

View file

@ -1,9 +1,11 @@
#include "fixer.h"
#ifndef DB_LEVEL
#define DB_LEVEL 4
#endif
#include "db.h"
#include "awTexLd.hpp"
#include "awtexld.hpp"
// BMP Loader
@ -183,9 +185,4 @@ void AwBmpLoader::LoadNextRow(AwTl::PtrUnion pRow)
m_pMedium->MovePos(bmp_filepitchpad);
}
#ifdef _MSC_VER
// VC5.0 tries to compile out code that is in a library
// and it thinks isn't being used
#line 186
#endif
AWTEXLD_IMPLEMENT_DYNCREATE("BM",AwBmpLoader)

View file

@ -245,7 +245,7 @@ void AwIffLoader::LoadHeaderInfo(MediaMedium * pMedium)
if (!m_ifData.Load(pMedium) || !m_ifData.GetContents())
{
// if (NO_ERROR == (awTlLastWinErr = GetLastError()))
// awTlLastErr = AW_TLE_BADFILEDATA;
awTlLastErr = AW_TLE_BADFILEDATA;
// else
// awTlLastErr = AW_TLE_CANTREADFILE;
@ -378,18 +378,18 @@ void AwIffLoader::OnBeginRestoring(unsigned nMaxPaletteSize)
break;
default:
db_log3("AwCreateTexture() [AwIffLoader::OnBeginRestoring] : ERROR: IFF mask field wrong");
// awTlLastErr = AW_TLE_BADFILEDATA;
awTlLastErr = AW_TLE_BADFILEDATA;
}
}
else
{
// awTlLastErr = AW_TLE_CANTPALETTIZE; // no suitable chunk found
awTlLastErr = AW_TLE_CANTPALETTIZE; // no suitable chunk found
db_log3("AwCreateTexture() [AwIffLoader::OnBeginRestoring] : ERROR: No suitable IFF body chunk found");
}
}
else
{
// awTlLastErr = AW_TLE_BADFILEDATA;
awTlLastErr = AW_TLE_BADFILEDATA;
db_log3("AwCreateTexture() [AwIffLoader::OnBeginRestoring] : ERROR: IFF file not loaded or contains no image data");
}
}
@ -465,7 +465,7 @@ void AwIffLoader::ConvertRow(AwTl::PtrUnion pDest, unsigned nDestWidth, AwTl::Pt
break;
default:
db_log3("AwCreateTexture() [AwIffLoader::ConvertRow] : ERROR: IFF mask field wrong");
// awTlLastErr = AW_TLE_BADFILEDATA;
awTlLastErr = AW_TLE_BADFILEDATA;
}
}
}

View file

@ -1,10 +1,16 @@
#include "advwin32.h"
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
#include <stdarg.h>
#include "fixer.h"
#ifndef DB_LEVEL
#define DB_LEVEL 4
#endif
#include "db.h"
#include "awTexLd.hpp"
#include "awtexld.hpp"
// PNM loaders
@ -87,8 +93,8 @@ void AwPpmLoader::LoadHeaderInfo(MediaMedium * pMedium)
db_logf4(("\tPPM_maxval is %u",pm_maxval));
if (pm_maxval > 255)
{
awTlLastErr = AW_TLE_BADFILEFORMAT;
db_log3("AwCreateTexture(): PPM_maxval too large");
// awTlLastErr = AW_TLE_BADFILEFORMAT;
db_log3("AwCreateTexture() [AwPpmLoader::LoadHeaderInfo] : PPM_maxval too large");
}
m_nPaletteSize = 0;
@ -147,7 +153,7 @@ void AwPgmLoader::LoadHeaderInfo(MediaMedium * pMedium)
if (pm_maxval > 255)
{
awTlLastErr = AW_TLE_BADFILEFORMAT;
db_log3("AwCreateTexture(): PGM_maxval too large");
db_log3("AwCreateTexture() [AwPgmLoader::LoadHeaderInfo] : PGM_maxval too large");
}
m_nPaletteSize = pm_maxval+1;
@ -226,11 +232,6 @@ void AwPbmLoader::LoadNextRow(AwTl::PtrUnion pRow)
}
}
#ifdef _MSC_VER
// VC5.0 tries to compile out code that is in a library
// and it thinks isn't being used
#line 228
#endif
AWTEXLD_IMPLEMENT_DYNCREATE("P6",AwPpmLoader)
AWTEXLD_IMPLEMENT_DYNCREATE("P5",AwPgmLoader)
AWTEXLD_IMPLEMENT_DYNCREATE("P4",AwPbmLoader)

View file

@ -67,6 +67,8 @@ enum
#define ATIncludeSurfaceDb(p, d, s) fprintf(stderr, "ATIncludeSurfaceDb: %s/%d: %s\n", __FILE__, __LINE__, s)
#define ATIncludeTextureDb(p, d, s) fprintf(stderr, "ATIncludeTextureDb: %s/%d: %s\n", __FILE__, __LINE__, s)
extern AW_TL_ERC awTlLastErr;
extern D3DTexture * AwCreateTexture(char const * _argFormatS, ...);
extern DDSurface * AwCreateSurface(char const * _argFormatS, ...);