예제 #1
0
void Character::Render(const SVector2& offset)
{
	const int kTextureWidth = mSprite.GetWidth();
	const int kTextureHeight = mSprite.GetHeight();
	SVector2 renderPos(mPosition.x - (kTextureWidth * 0.5f), mPosition.y - kTextureHeight);
	mSprite.SetPosition(renderPos + offset);
	mSprite.Render();
}
예제 #2
0
void Fighter::Render()
{
	const float kHalfWidth = mSprite.GetWidth() * 0.5f;
	const float kHalfHeight = mSprite.GetHeight() * 0.5f;
	SVector2 renderPos(mPosition.x - kHalfWidth, mPosition.y - kHalfHeight);
	mSprite.SetPosition(renderPos);
	mSprite.Render();
}