This commit is contained in:
Paul 2001-05-01 21:33:51 +00:00
parent be1ae5d646
commit 921bdbac48
2 changed files with 128 additions and 0 deletions

View File

@ -0,0 +1,71 @@
/*=========================================================================
tteleprt.cpp
Author: PKG
Created:
Project: Spongebob
Purpose:
Copyright (c) 2001 Climax Development Ltd
===========================================================================*/
/*----------------------------------------------------------------------
Includes
-------- */
#include "triggers\tteleprt.h"
#ifndef __PLAYER_PLAYER_H__
#include "player\player.h"
#endif
/* Std Lib
------- */
/* Data
---- */
/*----------------------------------------------------------------------
Tyepdefs && Defines
------------------- */
/*----------------------------------------------------------------------
Structure defintions
-------------------- */
/*----------------------------------------------------------------------
Function Prototypes
------------------- */
/*----------------------------------------------------------------------
Vars
---- */
/*----------------------------------------------------------------------
Function:
Purpose:
Params:
Returns:
---------------------------------------------------------------------- */
void CTeleportTrigger::collidedWith(CThing *_thisThing)
{
/*
CRECT collisionArea;
DVECTOR respawnPos;
ASSERT(_thisThing->getThingType()==TYPE_PLAYER);
collisionArea=getCollisionArea();
respawnPos.vx=collisionArea.x1+((collisionArea.x2-collisionArea.x1)/2);
respawnPos.vy=collisionArea.y2;
((CPlayer*)_thisThing)->setRespawnPos(respawnPos);
*/
ASSERT(0);
}
/*===========================================================================
end */

View File

@ -0,0 +1,57 @@
/*=========================================================================
tteleprt.h
Author: PKG
Created:
Project: Spongebob
Purpose:
Copyright (c) 2001 Climax Development Ltd
===========================================================================*/
#ifndef __TRIGGERS_TTELEPRT_H__
#define __TRIGGERS_TTELEPRT_H__
/*----------------------------------------------------------------------
Includes
-------- */
#ifndef __THING_THING_H__
#include "thing/thing.h"
#endif
/* Std Lib
------- */
/*----------------------------------------------------------------------
Tyepdefs && Defines
------------------- */
/*----------------------------------------------------------------------
Structure defintions
-------------------- */
class CTeleportTrigger : public CTriggerThing
{
protected:
virtual void collidedWith(CThing *_thisThing);
};
/*----------------------------------------------------------------------
Globals
------- */
/*----------------------------------------------------------------------
Functions
--------- */
/*---------------------------------------------------------------------- */
#endif /* __TRIGGERS_TTELEPRT_H__ */
/*===========================================================================
end */