This commit is contained in:
Daveo 2001-08-21 14:44:16 +00:00
parent 6b839bc818
commit 60fdda39b9
12 changed files with 27 additions and 15 deletions

View File

@ -157,7 +157,7 @@ eng=Load Error!\n\nPress the X button to continue
[STR__MEMCARD__NOSPACEONCARD] [STR__MEMCARD__NOSPACEONCARD]
eng=Insufficient free blocks available on MEMORY CARD in MEMORY CARD SLOT 1. One free block required eng=Insufficient free blocks available on MEMORY CARD in MEMORY CARD SLOT 1. One free block required
[STR__MEMCARD__DUPLICATESAVENAME] [STR__MEMCARD__DUPLICATESAVENAME]
eng=Are you sure you want to\noverwrite the existing file on the MEMORY CARD in MEMORY CARD slot 1? eng=File already exists on the\nMEMORY CARD in MEMORY CARD slot 1\nAre you sure you want to overwrite the previous file?
[STR__MEMCARD__DOYOUWANTTOFORMATCARD] [STR__MEMCARD__DOYOUWANTTOFORMATCARD]
eng=MEMORY CARD in MEMORY CARD slot 1 is not formatted. Do you wish to format? eng=MEMORY CARD in MEMORY CARD slot 1 is not formatted. Do you wish to format?
[STR__MEMCARD__FORMATTINGPLEASEWIAT] [STR__MEMCARD__FORMATTINGPLEASEWIAT]

View File

@ -745,10 +745,10 @@ sLayerHdr *layer;
/*****************************************************************************/ /*****************************************************************************/
/*****************************************************************************/ /*****************************************************************************/
/*****************************************************************************/ /*****************************************************************************/
void CLevel::destroyMapArea(DVECTOR const &Pos) void CLevel::destroyMapArea(DVECTOR const &Pos,int ColT)
{ {
DVECTOR TL,BR; DVECTOR TL,BR;
const int ColT=COLLISION_TYPE_DESTRUCTABLE_WALL; //const int ColT=COLLISION_TYPE_DESTRUCTABLE_WALL;
TL.vx=Pos.vx&-16;; TL.vx=Pos.vx&-16;;
@ -775,9 +775,12 @@ DVECTOR DP;
if (*ColElem>>COLLISION_TYPE_FLAG_SHIFT==ColT) if (*ColElem>>COLLISION_TYPE_FLAG_SHIFT==ColT)
{ {
sTileMapElem *MapElem=TileLayers[CLayerTile::LAYER_TILE_TYPE_ACTION]->getMapPtr(DP.vx,DP.vy); sTileMapElem *MapElem=TileLayers[CLayerTile::LAYER_TILE_TYPE_ACTION]->getMapPtr(DP.vx,DP.vy);
if (MapElem->Tile)
{
CFXFallingTile *FX=(CFXFallingTile*)CFX::Create(CFX::FX_TYPE_FALLINGTILE,DP); CFXFallingTile *FX=(CFXFallingTile*)CFX::Create(CFX::FX_TYPE_FALLINGTILE,DP);
FX->SetTile(MapElem->Tile); FX->SetTile(MapElem->Tile);
MapElem->Tile=0; MapElem->Tile=0;
}
*ColElem=0; *ColElem=0;
} }
@ -788,11 +791,11 @@ DVECTOR DP;
/*****************************************************************************/ /*****************************************************************************/
// fixed now, so takes out whole vertical section, wherever it is hit // fixed now, so takes out whole vertical section, wherever it is hit
// Note: relies on tiles not being top or bottom of map tho!! // Note: relies on tiles not being top or bottom of map tho!!
void CLevel::destroyMapTile(DVECTOR const &Pos) void CLevel::destroyMapTile(DVECTOR const &Pos,int ColT)
{ {
int Width=getMapWidth(); int Width=getMapWidth();
DVECTOR MP=Pos; DVECTOR MP=Pos;
const int ColT=COLLISION_TYPE_DESTRUCTABLE_FLOOR; //const int ColT=COLLISION_TYPE_DESTRUCTABLE_FLOOR;
// Goto Top // Goto Top
while (*CollisionLayer->getMapPtr(MP.vx,MP.vy-1)>>COLLISION_TYPE_FLAG_SHIFT==ColT) while (*CollisionLayer->getMapPtr(MP.vx,MP.vy-1)>>COLLISION_TYPE_FLAG_SHIFT==ColT)
@ -805,10 +808,13 @@ sTileMapElem *MapElem=TileLayers[CLayerTile::LAYER_TILE_TYPE_ACTION]->getMapPtr(
// Thrash em down // Thrash em down
while (*ColElem>>COLLISION_TYPE_FLAG_SHIFT==ColT) while (*ColElem>>COLLISION_TYPE_FLAG_SHIFT==ColT)
{
if (MapElem->Tile)
{ {
CFXFallingTile *FX=(CFXFallingTile*)CFX::Create(CFX::FX_TYPE_FALLINGTILE,MP); CFXFallingTile *FX=(CFXFallingTile*)CFX::Create(CFX::FX_TYPE_FALLINGTILE,MP);
FX->SetTile(MapElem->Tile); FX->SetTile(MapElem->Tile);
MapElem->Tile=0; MapElem->Tile=0;
}
*ColElem=0; *ColElem=0;
MapElem+=Width; MapElem+=Width;
@ -851,6 +857,7 @@ DVECTOR DP;
/*****************************************************************************/ /*****************************************************************************/
/*****************************************************************************/ /*****************************************************************************/
/*****************************************************************************/ /*****************************************************************************/
// note: slippery used as special type in 4:4 boss arena
void CLevel::CreateTileStore() void CLevel::CreateTileStore()
{ {
int MapW=getMapWidth(); int MapW=getMapWidth();
@ -866,7 +873,7 @@ int X,Y;
{ {
u8 *ColElem=CollisionLayer->getMapPtr(X*16,Y*16); u8 *ColElem=CollisionLayer->getMapPtr(X*16,Y*16);
int ColT = (*ColElem) & COLLISION_TYPE_MASK; int ColT = (*ColElem) & COLLISION_TYPE_MASK;
if ( ColT==COLLISION_TYPE_FLAG_DESTRUCTABLE_FLOOR || ColT==COLLISION_TYPE_FLAG_DESTRUCTABLE_WALL) if ( ColT==COLLISION_TYPE_FLAG_DESTRUCTABLE_FLOOR || ColT==COLLISION_TYPE_FLAG_DESTRUCTABLE_WALL || ColT==COLLISION_TYPE_FLAG_SLIPPERY)
{ {
m_TileStoreCount++; m_TileStoreCount++;
} }
@ -884,7 +891,7 @@ int X,Y;
{ {
u8 *ColElem=CollisionLayer->getMapPtr(X*16,Y*16); u8 *ColElem=CollisionLayer->getMapPtr(X*16,Y*16);
int ColT = (*ColElem) & COLLISION_TYPE_MASK; int ColT = (*ColElem) & COLLISION_TYPE_MASK;
if ( ColT==COLLISION_TYPE_FLAG_DESTRUCTABLE_FLOOR || ColT==COLLISION_TYPE_FLAG_DESTRUCTABLE_WALL) if ( ColT==COLLISION_TYPE_FLAG_DESTRUCTABLE_FLOOR || ColT==COLLISION_TYPE_FLAG_DESTRUCTABLE_WALL || ColT==COLLISION_TYPE_FLAG_SLIPPERY)
{ {
Ptr->X=X; Ptr->X=X;
Ptr->Y=Y; Ptr->Y=Y;

View File

@ -65,8 +65,8 @@ static int getChapterLoadingText() {return LvlTable[s_globalLevelSelec
static int getLevelLoadingText() {return LvlTable[s_globalLevelSelectThing].LevelLoadingText;} static int getLevelLoadingText() {return LvlTable[s_globalLevelSelectThing].LevelLoadingText;}
static CFmaScene::FMA_SCRIPT_NUMBER getFMAToFollow() {return LvlTable[s_globalLevelSelectThing].FMAToFollow;} static CFmaScene::FMA_SCRIPT_NUMBER getFMAToFollow() {return LvlTable[s_globalLevelSelectThing].FMAToFollow;}
void destroyMapArea(DVECTOR const &Pos); void destroyMapArea(DVECTOR const &Pos,int ColT=COLLISION_TYPE_DESTRUCTABLE_WALL);
void destroyMapTile(DVECTOR const &Pos); void destroyMapTile(DVECTOR const &Pos,int ColT=COLLISION_TYPE_DESTRUCTABLE_FLOOR);
void reverseMapConveyor(); void reverseMapConveyor();

View File

@ -44,6 +44,11 @@ void CNpcFallingBlockPlatform::trigger()
{ {
m_isTriggered = true; m_isTriggered = true;
m_timer = GameState::getOneSecondInFrames(); m_timer = GameState::getOneSecondInFrames();
// Clear collision, flagged with normal - cos rest is solid!
CLevel &level=GameScene.GetLevel();
level.destroyMapArea(Pos,COLLISION_TYPE_SLIPPERY);
} }
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////