test
This commit is contained in:
@@ -11,15 +11,20 @@ namespace Game::AGame {
|
||||
|
||||
void Trash::update(float deltaTime) {
|
||||
(void)deltaTime;
|
||||
if (mSeaOnly) {
|
||||
/*if (mSeaOnly) {
|
||||
const float landBoundaryX = GameManager::getSharedData<float>("terrainLandBoundaryX");
|
||||
const float margin = 25.f;
|
||||
const float halfWidth = getTexture() ? getTexture()->getWidth() * mTransform.adjustedScaleX() / 2.f : 0.f;
|
||||
if (mTransform.x - halfWidth < landBoundaryX + margin) {
|
||||
mTransform.x = landBoundaryX + margin + halfWidth;
|
||||
}
|
||||
}
|
||||
return;
|
||||
}*/
|
||||
|
||||
// Naključno premikanje
|
||||
mTransform.x += static_cast<float>(Utils::getUtils().rirng32(-50, 50)) * deltaTime;
|
||||
mTransform.y += static_cast<float>(Utils::getUtils().rirng32(-50, 50)) * deltaTime;
|
||||
|
||||
//return;
|
||||
}
|
||||
|
||||
void Trash::onCollisionEnter(Object::Entity* other) {
|
||||
|
||||
Reference in New Issue
Block a user