This commit is contained in:
Charles 2001-06-08 14:05:48 +00:00
parent 01fca54fb1
commit 24dc221b50
3 changed files with 24 additions and 1 deletions

View File

@ -183,13 +183,13 @@ void CBasePickup::collidedWith(CThing *_thisThing)
switch(_thisThing->getThingType())
{
case TYPE_PLAYER:
case TYPE_NPC:
collect((CPlayer*)_thisThing);
CSoundMediator::playSfx(sfxToPlayWhenCollected());
break;
default:
ASSERT(0);
case TYPE_NPC:
break;
}
}

View File

@ -130,6 +130,28 @@ void CKelpTokenPickup::renderPickup(DVECTOR *_pos)
sprites->printFT4(fh,x,y,0,0,OTPOS__PICKUP_POS);
}
/*----------------------------------------------------------------------
Function:
Purpose:
Params:
Returns:
---------------------------------------------------------------------- */
void CKelpTokenPickup::collidedWith(CThing *_thisThing)
{
switch(_thisThing->getThingType())
{
case TYPE_PLAYER:
case TYPE_NPC:
collect((CPlayer*)_thisThing);
CSoundMediator::playSfx(sfxToPlayWhenCollected());
break;
default:
ASSERT(0);
break;
}
}
/*===========================================================================
end */

View File

@ -45,6 +45,7 @@ public:
void setTokenNumber(int _number) {m_tokenNumber=_number;}
protected:
virtual void collidedWith(CThing *_thisThing);
virtual void renderPickup(DVECTOR *_pos);
private: