mirror of
https://github.com/DrBeef/Raze.git
synced 2024-11-15 08:52:00 +00:00
- manual update of some missed content.
This commit is contained in:
parent
f60fa44efb
commit
6a0785bbd4
10 changed files with 429 additions and 366 deletions
|
@ -2262,9 +2262,9 @@ const THINGINFO thingInfo[] = {
|
||||||
800,
|
800,
|
||||||
(char)-128,
|
(char)-128,
|
||||||
0,
|
0,
|
||||||
48,
|
44,
|
||||||
48,
|
44,
|
||||||
64, 64, 112, 64, 0, 96, 96,
|
0, 1024, 512, 1024, 0, 64, 512,
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -2359,7 +2359,7 @@ const EXPLOSION explodeInfo[] = {
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
|
int gDudeDrag = 0x2a00;
|
||||||
|
|
||||||
short gAffectedSectors[kMaxSectors];
|
short gAffectedSectors[kMaxSectors];
|
||||||
short gAffectedXWalls[kMaxXWalls];
|
short gAffectedXWalls[kMaxXWalls];
|
||||||
|
@ -5260,7 +5260,8 @@ void actExplodeSprite(spritetype *pSprite)
|
||||||
return;
|
return;
|
||||||
sfxKill3DSound(pSprite, -1, -1);
|
sfxKill3DSound(pSprite, -1, -1);
|
||||||
evKill(pSprite->index, 3);
|
evKill(pSprite->index, 3);
|
||||||
int nType;
|
int nType = kExplosionStandard;
|
||||||
|
|
||||||
switch (pSprite->type)
|
switch (pSprite->type)
|
||||||
{
|
{
|
||||||
case kMissileFireballNapam:
|
case kMissileFireballNapam:
|
||||||
|
|
|
@ -365,14 +365,14 @@ static void ThrowThing(int nXIndex, bool impact) {
|
||||||
case kModernThingEnemyLifeLeech:
|
case kModernThingEnemyLifeLeech:
|
||||||
XSPRITE* pXThing = &xsprite[pThing->extra];
|
XSPRITE* pXThing = &xsprite[pThing->extra];
|
||||||
if (pLeech != NULL) pXThing->health = pXLeech->health;
|
if (pLeech != NULL) pXThing->health = pXLeech->health;
|
||||||
else pXThing->health = 300 * gGameOptions.nDifficulty;
|
else pXThing->health = ((pThinkInfo->startHealth << 4) * gGameOptions.nDifficulty) >> 1;
|
||||||
|
|
||||||
sfxPlay3DSound(pSprite, 490, -1, 0);
|
sfxPlay3DSound(pSprite, 490, -1, 0);
|
||||||
|
|
||||||
if (gGameOptions.nDifficulty <= 2) pXThing->data3 = 32700;
|
pXThing->data3 = 512 / (gGameOptions.nDifficulty + 1);
|
||||||
else pXThing->data3 = Random(10);
|
|
||||||
pThing->cstat &= ~CSTAT_SPRITE_BLOCK;
|
pThing->cstat &= ~CSTAT_SPRITE_BLOCK;
|
||||||
pThing->pal = 6;
|
pThing->pal = 6;
|
||||||
|
pThing->clipdist = 0;
|
||||||
pXThing->target = pTarget->index;
|
pXThing->target = pTarget->index;
|
||||||
pXThing->Proximity = true;
|
pXThing->Proximity = true;
|
||||||
pXThing->stateTimer = 1;
|
pXThing->stateTimer = 1;
|
||||||
|
@ -438,17 +438,19 @@ static void thinkChase( spritetype* pSprite, XSPRITE* pXSprite ) {
|
||||||
if (pXTarget == NULL) { // target lost
|
if (pXTarget == NULL) { // target lost
|
||||||
if(spriteIsUnderwater(pSprite,false)) aiGenDudeNewState(pSprite, &genDudeSearchShortW);
|
if(spriteIsUnderwater(pSprite,false)) aiGenDudeNewState(pSprite, &genDudeSearchShortW);
|
||||||
else aiGenDudeNewState(pSprite, &genDudeSearchShortL);
|
else aiGenDudeNewState(pSprite, &genDudeSearchShortL);
|
||||||
|
pXSprite->target = -1;
|
||||||
return;
|
return;
|
||||||
|
|
||||||
} else if (pXTarget->health <= 0) { // target is dead
|
} else if (pXTarget->health <= 0) { // target is dead
|
||||||
PLAYER* pPlayer = NULL;
|
PLAYER* pPlayer = NULL;
|
||||||
if ((!IsPlayerSprite(pTarget)) || ((pPlayer = getPlayerById(pTarget->type)) != NULL && pPlayer->fraggerId == pSprite->index)) {
|
if ((!IsPlayerSprite(pTarget)) || ((pPlayer = getPlayerById(pTarget->type)) != NULL && pPlayer->fraggerId == pSprite->index)) {
|
||||||
playGenDudeSound(pSprite, kGenDudeSndTargetDead);
|
playGenDudeSound(pSprite, kGenDudeSndTargetDead);
|
||||||
if (spriteIsUnderwater(pSprite, false)) aiGenDudeNewState(pSprite, &genDudeSearchShortW);
|
if (spriteIsUnderwater(pSprite, false)) aiGenDudeNewState(pSprite, &genDudeSearchShortW);
|
||||||
else aiGenDudeNewState(pSprite, &genDudeSearchShortL);
|
else aiGenDudeNewState(pSprite, &genDudeSearchShortL);
|
||||||
}
|
}
|
||||||
else if (spriteIsUnderwater(pSprite, false)) aiGenDudeNewState(pSprite, &genDudeGotoW);
|
else if (spriteIsUnderwater(pSprite, false)) aiGenDudeNewState(pSprite, &genDudeGotoW);
|
||||||
else aiGenDudeNewState(pSprite, &genDudeGotoL);
|
else aiGenDudeNewState(pSprite, &genDudeGotoL);
|
||||||
|
pXSprite->target = -1;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -477,6 +479,7 @@ static void thinkChase( spritetype* pSprite, XSPRITE* pXSprite ) {
|
||||||
if (powerupCheck(pPlayer, kPwUpShadowCloak) > 0) {
|
if (powerupCheck(pPlayer, kPwUpShadowCloak) > 0) {
|
||||||
if (spriteIsUnderwater(pSprite, false)) aiGenDudeNewState(pSprite, &genDudeSearchShortW);
|
if (spriteIsUnderwater(pSprite, false)) aiGenDudeNewState(pSprite, &genDudeSearchShortW);
|
||||||
else aiGenDudeNewState(pSprite, &genDudeSearchShortL);
|
else aiGenDudeNewState(pSprite, &genDudeSearchShortL);
|
||||||
|
pXSprite->target = -1;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1388,57 +1391,57 @@ void scaleDamage(XSPRITE* pXSprite) {
|
||||||
switch (surfType) {
|
switch (surfType) {
|
||||||
case 1: // stone
|
case 1: // stone
|
||||||
curScale[kDmgFall] = 0;
|
curScale[kDmgFall] = 0;
|
||||||
curScale[kDmgBullet] -= 128;
|
curScale[kDmgBullet] -= 200;
|
||||||
curScale[kDmgBurn] -= 50;
|
curScale[kDmgBurn] -= 100;
|
||||||
curScale[kDmgExplode] -= 40;
|
curScale[kDmgExplode] -= 80;
|
||||||
curScale[kDmgChoke] += 30;
|
curScale[kDmgChoke] += 30;
|
||||||
curScale[kDmgElectric] += 20;
|
curScale[kDmgElectric] += 20;
|
||||||
break;
|
break;
|
||||||
case 2: // metal
|
case 2: // metal
|
||||||
curScale[kDmgFall] = 16;
|
curScale[kDmgFall] = 16;
|
||||||
curScale[kDmgBullet] -= 64;
|
curScale[kDmgBullet] -= 128;
|
||||||
curScale[kDmgBurn] -= 45;
|
curScale[kDmgBurn] -= 90;
|
||||||
curScale[kDmgExplode] -= 35;
|
curScale[kDmgExplode] -= 55;
|
||||||
curScale[kDmgChoke] += 20;
|
curScale[kDmgChoke] += 20;
|
||||||
curScale[kDmgElectric] += 30;
|
curScale[kDmgElectric] += 30;
|
||||||
break;
|
break;
|
||||||
case 3: // wood
|
case 3: // wood
|
||||||
curScale[kDmgBullet] -= 5;
|
curScale[kDmgBullet] -= 10;
|
||||||
curScale[kDmgBurn] += 50;
|
curScale[kDmgBurn] += 50;
|
||||||
curScale[kDmgExplode] += 40;
|
curScale[kDmgExplode] += 40;
|
||||||
curScale[kDmgChoke] += 10;
|
curScale[kDmgChoke] += 10;
|
||||||
curScale[kDmgElectric] -= 30;
|
curScale[kDmgElectric] -= 60;
|
||||||
break;
|
break;
|
||||||
case 5: // water
|
case 5: // water
|
||||||
case 6: // dirt
|
case 6: // dirt
|
||||||
case 7: // clay
|
case 7: // clay
|
||||||
case 13: // goo
|
case 13: // goo
|
||||||
curScale[kDmgFall] = 8;
|
curScale[kDmgFall] = 8;
|
||||||
curScale[kDmgBullet] -= 10;
|
curScale[kDmgBullet] -= 20;
|
||||||
curScale[kDmgBurn] -= 128;
|
curScale[kDmgBurn] -= 200;
|
||||||
curScale[kDmgExplode] -= 30;
|
curScale[kDmgExplode] -= 60;
|
||||||
curScale[kDmgChoke] = 0;
|
curScale[kDmgChoke] = 0;
|
||||||
curScale[kDmgElectric] += 40;
|
curScale[kDmgElectric] += 40;
|
||||||
break;
|
break;
|
||||||
case 8: // snow
|
case 8: // snow
|
||||||
case 9: // ice
|
case 9: // ice
|
||||||
curScale[kDmgFall] = 8;
|
curScale[kDmgFall] = 8;
|
||||||
curScale[kDmgBullet] -= 10;
|
curScale[kDmgBullet] -= 20;
|
||||||
curScale[kDmgBurn] -= 60;
|
curScale[kDmgBurn] -= 100;
|
||||||
curScale[kDmgExplode] -= 40;
|
curScale[kDmgExplode] -= 50;
|
||||||
curScale[kDmgChoke] = 0;
|
curScale[kDmgChoke] = 0;
|
||||||
curScale[kDmgElectric] += 40;
|
curScale[kDmgElectric] += 40;
|
||||||
break;
|
break;
|
||||||
case 10: // leaves
|
case 10: // leaves
|
||||||
case 12: // plant
|
case 12: // plant
|
||||||
curScale[kDmgFall] = 0;
|
curScale[kDmgFall] = 0;
|
||||||
curScale[kDmgBullet] -= 5;
|
curScale[kDmgBullet] -= 10;
|
||||||
curScale[kDmgBurn] += 70;
|
curScale[kDmgBurn] += 70;
|
||||||
curScale[kDmgExplode] += 50;
|
curScale[kDmgExplode] += 50;
|
||||||
break;
|
break;
|
||||||
case 11: // cloth
|
case 11: // cloth
|
||||||
curScale[kDmgFall] = 8;
|
curScale[kDmgFall] = 8;
|
||||||
curScale[kDmgBullet] -= 5;
|
curScale[kDmgBullet] -= 10;
|
||||||
curScale[kDmgBurn] += 30;
|
curScale[kDmgBurn] += 30;
|
||||||
curScale[kDmgExplode] += 20;
|
curScale[kDmgExplode] += 20;
|
||||||
break;
|
break;
|
||||||
|
@ -2116,7 +2119,7 @@ bool genDudePrepare(spritetype* pSprite, int propId) {
|
||||||
pExtra->nLifeLeech = -1;
|
pExtra->nLifeLeech = -1;
|
||||||
if (pSprite->owner != kMaxSprites - 1) {
|
if (pSprite->owner != kMaxSprites - 1) {
|
||||||
for (int nSprite = headspritestat[kStatThing]; nSprite >= 0; nSprite = nextspritestat[nSprite]) {
|
for (int nSprite = headspritestat[kStatThing]; nSprite >= 0; nSprite = nextspritestat[nSprite]) {
|
||||||
if (sprite[nSprite].owner == pSprite->index && pSprite->type == kModernThingEnemyLifeLeech) {
|
if (sprite[nSprite].owner == pSprite->index && sprite[nSprite].type == kModernThingEnemyLifeLeech) {
|
||||||
pExtra->nLifeLeech = nSprite;
|
pExtra->nLifeLeech = nSprite;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
@ -38,6 +38,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||||
|
|
||||||
BEGIN_BLD_NS
|
BEGIN_BLD_NS
|
||||||
|
|
||||||
|
bool gModernMap = false;
|
||||||
unsigned short gStatCount[kMaxStatus + 1];
|
unsigned short gStatCount[kMaxStatus + 1];
|
||||||
|
|
||||||
XSPRITE xsprite[kMaxXSprites];
|
XSPRITE xsprite[kMaxXSprites];
|
||||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -195,6 +195,7 @@ struct OBJECTS_TO_TRACK {
|
||||||
};
|
};
|
||||||
|
|
||||||
struct TRCONDITION {
|
struct TRCONDITION {
|
||||||
|
signed int xindex: 16;
|
||||||
unsigned int length: 8;
|
unsigned int length: 8;
|
||||||
OBJECTS_TO_TRACK obj[kMaxTracedObjects];
|
OBJECTS_TO_TRACK obj[kMaxTracedObjects];
|
||||||
};
|
};
|
||||||
|
@ -289,7 +290,7 @@ void seqTxSendCmdAll(XSPRITE* pXSource, int nIndex, COMMAND_ID cmd, bool modernS
|
||||||
// ------------------------------------------------------------------------- //
|
// ------------------------------------------------------------------------- //
|
||||||
void trPlayerCtrlLink(XSPRITE* pXSource, PLAYER* pPlayer, bool checkCondition);
|
void trPlayerCtrlLink(XSPRITE* pXSource, PLAYER* pPlayer, bool checkCondition);
|
||||||
void trPlayerCtrlSetRace(XSPRITE* pXSource, PLAYER* pPlayer);
|
void trPlayerCtrlSetRace(XSPRITE* pXSource, PLAYER* pPlayer);
|
||||||
void trPlayerCtrlStartScene(XSPRITE* pXSource, PLAYER* pPlayer);
|
void trPlayerCtrlStartScene(XSPRITE* pXSource, PLAYER* pPlayer, bool force);
|
||||||
void trPlayerCtrlStopScene(PLAYER* pPlayer);
|
void trPlayerCtrlStopScene(PLAYER* pPlayer);
|
||||||
void trPlayerCtrlSetMoveSpeed(XSPRITE* pXSource, PLAYER* pPlayer);
|
void trPlayerCtrlSetMoveSpeed(XSPRITE* pXSource, PLAYER* pPlayer);
|
||||||
void trPlayerCtrlSetJumpHeight(XSPRITE* pXSource, PLAYER* pPlayer);
|
void trPlayerCtrlSetJumpHeight(XSPRITE* pXSource, PLAYER* pPlayer);
|
||||||
|
|
|
@ -568,21 +568,7 @@ void OperateSprite(int nSprite, XSPRITE *pXSprite, EVENT event)
|
||||||
evPost(nSprite, 3, 18, kCmdOff);
|
evPost(nSprite, 3, 18, kCmdOff);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
/*if (pSprite->statnum != kStatRespawn) {
|
|
||||||
switch (event.cmd) {
|
|
||||||
case kCmdOn:
|
|
||||||
actExplodeSprite(pSprite);
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
sfxPlay3DSound(pSprite, 454, 0, 0);
|
|
||||||
evPost(nSprite, 3, 18, kCmdOff);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}*/
|
|
||||||
break;
|
|
||||||
|
|
||||||
case kThingArmedProxBomb:
|
case kThingArmedProxBomb:
|
||||||
if (pSprite->statnum != kStatRespawn) {
|
if (pSprite->statnum != kStatRespawn) {
|
||||||
switch (event.cmd) {
|
switch (event.cmd) {
|
||||||
|
@ -2157,10 +2143,6 @@ void trInit(void)
|
||||||
if (pXSprite->waitTime > 0)
|
if (pXSprite->waitTime > 0)
|
||||||
evPost(i, 3, (pXSprite->waitTime * 120) / 10, pXSprite->restState ? kCmdOn : kCmdOff);
|
evPost(i, 3, (pXSprite->waitTime * 120) / 10, pXSprite->restState ? kCmdOn : kCmdOff);
|
||||||
break;
|
break;
|
||||||
case kModernCondition:
|
|
||||||
if (pXSprite->busyTime <= 0 || pXSprite->locked) break;
|
|
||||||
evPost(i, 3, ClipLow(pXSprite->busyTime, 5), kCallbackCondition);
|
|
||||||
break;
|
|
||||||
#endif
|
#endif
|
||||||
case kGenTrigger:
|
case kGenTrigger:
|
||||||
case kGenDripWater:
|
case kGenDripWater:
|
||||||
|
|
|
@ -2419,12 +2419,12 @@ void viewProcessSprites(int32_t cX, int32_t cY, int32_t cZ, int32_t cA, int32_t
|
||||||
pTSprite->ang = (pTSprite->ang+((int)totalclock<<3))&2047;
|
pTSprite->ang = (pTSprite->ang+((int)totalclock<<3))&2047;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((pTSprite->cstat&48) != 48 && usemodels && !(spriteext[nSprite].flags&SPREXT_NOTMD))
|
if ((pTSprite->cstat&48) != 48 && hw_models && !(spriteext[nSprite].flags&SPREXT_NOTMD))
|
||||||
{
|
{
|
||||||
int const nRootTile = pTSprite->picnum;
|
int const nRootTile = pTSprite->picnum;
|
||||||
int nAnimTile = pTSprite->picnum + animateoffs_replace(pTSprite->picnum, 32768+pTSprite->owner);
|
int nAnimTile = pTSprite->picnum + animateoffs_replace(pTSprite->picnum, 32768+pTSprite->owner);
|
||||||
|
|
||||||
if (usemodels && tile2model[Ptile2tile(nAnimTile, pTSprite->pal)].modelid >= 0 &&
|
if (tile2model[Ptile2tile(nAnimTile, pTSprite->pal)].modelid >= 0 &&
|
||||||
tile2model[Ptile2tile(nAnimTile, pTSprite->pal)].framenum >= 0)
|
tile2model[Ptile2tile(nAnimTile, pTSprite->pal)].framenum >= 0)
|
||||||
{
|
{
|
||||||
pTSprite->yoffset += picanm[nAnimTile].yofs;
|
pTSprite->yoffset += picanm[nAnimTile].yofs;
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
#include <memory>
|
||||||
#include "c_cvars.h"
|
#include "c_cvars.h"
|
||||||
#include "zstring.h"
|
#include "zstring.h"
|
||||||
#include "inputstate.h"
|
#include "inputstate.h"
|
||||||
|
|
|
@ -95,7 +95,7 @@ int32_t FileStream::Seek(int32_t offset, SeekDirection direction)
|
||||||
nStatus = file.Seek(offset, FileReader::SeekCur);
|
nStatus = file.Seek(offset, FileReader::SeekCur);
|
||||||
}
|
}
|
||||||
else if (kSeekEnd == direction) {
|
else if (kSeekEnd == direction) {
|
||||||
nStatus = klseek(file, offset, SEEK_END);
|
nStatus = file.Seek(offset, FileReader::SeekEnd);
|
||||||
}
|
}
|
||||||
|
|
||||||
return nStatus;
|
return nStatus;
|
||||||
|
|
|
@ -47,13 +47,9 @@
|
||||||
#ifndef playmve_h_
|
#ifndef playmve_h_
|
||||||
#define playmve_h_
|
#define playmve_h_
|
||||||
|
|
||||||
#include "a.h"
|
|
||||||
#include "baselayer.h"
|
#include "baselayer.h"
|
||||||
#include "build.h"
|
#include "build.h"
|
||||||
#include "cache1d.h"
|
|
||||||
#include "compat.h"
|
#include "compat.h"
|
||||||
#include "fx_man.h"
|
|
||||||
#include "keyboard.h"
|
|
||||||
#include "pragmas.h"
|
#include "pragmas.h"
|
||||||
|
|
||||||
bool playmve(const char* filename);
|
bool playmve(const char* filename);
|
||||||
|
|
Loading…
Reference in a new issue