This commit is contained in:
Paul 2001-02-21 14:54:40 +00:00
parent a9d6a74527
commit 49fba3d958
2 changed files with 137 additions and 0 deletions

View File

@ -0,0 +1,76 @@
/*=========================================================================
pglasses.cpp
Author: PKG
Created:
Project: Spongebob
Purpose:
Copyright (c) 2001 Climax Development Ltd
===========================================================================*/
/*----------------------------------------------------------------------
Includes
-------- */
#ifndef __GFX_SPRBANK_H__
#include "gfx\sprbank.h" // Damnit.. include order! :( (pkg)
#endif
#include "pickups\pglasses.h"
/* Std Lib
------- */
/* Data
---- */
#ifndef __SPR_INGAMEFX_H__
#include <ingamefx.h>
#endif
/*----------------------------------------------------------------------
Tyepdefs && Defines
------------------- */
/*----------------------------------------------------------------------
Structure defintions
-------------------- */
/*----------------------------------------------------------------------
Function Prototypes
------------------- */
/*----------------------------------------------------------------------
Vars
---- */
/*----------------------------------------------------------------------
Function:
Purpose:
Params:
Returns:
---------------------------------------------------------------------- */
void CSpatulaPickup::render()
{
DVECTOR ofs;
SpriteBank *sprites;
sFrameHdr *fh;
int x,y;
ofs=getRenderOffset();
sprites=getSpriteBank();
fh=sprites->getFrameHeader(FRM__SPATULA);
x=Pos.vx-ofs.vx-(fh->W/2);
y=Pos.vy-ofs.vy-(fh->H/2);
sprites->printFT4(fh,x,y,0,0,2);
CBasePickup::render();
}
/*===========================================================================
end */

61
source/pickups/pglasses.h Normal file
View File

@ -0,0 +1,61 @@
/*=========================================================================
pglasses.h
Author: PKG
Created:
Project: Spongebob
Purpose:
Copyright (c) 2001 Climax Development Ltd
===========================================================================*/
#ifndef __PICKUPS_PGLASSES_H__
#define __PICKUPS_PGLASSES_H__
/*----------------------------------------------------------------------
Includes
-------- */
#ifndef __PICKUPS_PICKUP_H__
#include "pickups/pickup.h"
#endif
/* Std Lib
------- */
/*----------------------------------------------------------------------
Tyepdefs && Defines
------------------- */
/*----------------------------------------------------------------------
Structure defintions
-------------------- */
class CGlassesPickup : public CBasePickup
{
public:
virtual void render();
virtual void collect(class CPlayer *_player);
private:
};
/*----------------------------------------------------------------------
Globals
------- */
/*----------------------------------------------------------------------
Functions
--------- */
/*---------------------------------------------------------------------- */
#endif /* __PICKUPS_PGLASSES_H__ */
/*===========================================================================
end */