Page Menu
Home
Phabricator (Chris)
Search
Configure Global Search
Log In
Files
F632793
ChestEntity.h
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Authored By
Unknown
Size
948 B
Referenced Files
None
Subscribers
None
ChestEntity.h
View Options
#ifndef CHESTENTITY_H
#define CHESTENTITY_H
#include
"sfml_game/CollidingSpriteEntity.h"
#include
"Items.h"
#include
"Constants.h"
class
ChestEntity
:
public
CollidingSpriteEntity
{
public
:
ChestEntity
(
float
x
,
float
y
,
int
chestType
,
bool
isOpen
);
virtual
void
animate
(
float
delay
);
virtual
void
render
(
sf
::
RenderTarget
*
app
);
virtual
void
calculateBB
();
void
open
();
void
makeAppear
();
bool
getOpened
();
int
getChestType
();
protected
:
virtual
void
readCollidingEntity
(
CollidingSpriteEntity
*
entity
);
private
:
bool
isOpen
;
int
chestType
;
float
appearTimer
;
float
timer
;
void
fallRock
();
void
initFallingGrid
();
void
generateStar
(
sf
::
Color
starColor
);
void
dropItem
(
enumItemType
item
);
bool
fallingGrid
[
MAP_WIDTH
][
MAP_HEIGHT
];
enum
enumTrap
{
TrapStones
,
TrapExplosion
,
TrapSnakes
};
enumTrap
trap
;
};
#endif
// CHESTENTITY_H
File Metadata
Details
Attached
Mime Type
text/x-c++
Expires
Sun, Nov 15, 3:19 PM (1 d, 21 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
120956
Default Alt Text
ChestEntity.h (948 B)
Attached To
Mode
R78 witchblast
Attached
Detach File
Event Timeline