mirror of
https://github.com/zoriya/Bomberman.git
synced 2026-05-31 01:25:21 +00:00
change collision with bomb
This commit is contained in:
@@ -18,7 +18,6 @@ namespace BBM {
|
||||
if (!bombHolder)
|
||||
return;
|
||||
bombHolder->maxBombCount++;
|
||||
std::cout << "BombHolder : " << bombHolder->maxBombCount << std::endl;
|
||||
}
|
||||
|
||||
void Bonus::ExplosionRangeBonus(WAL::Entity &player, const WAL::Entity &bonus, CollisionComponent::CollidedAxis axis)
|
||||
@@ -42,7 +41,6 @@ namespace BBM {
|
||||
if (!controllable || !playerBonus)
|
||||
return;
|
||||
controllable->speed += 0.05f;
|
||||
std::cout << "Speed : " << controllable->speed << std::endl;
|
||||
}
|
||||
|
||||
void Bonus::NoClipBonus(WAL::Entity &player, const WAL::Entity &bonus, CollisionComponent::CollidedAxis axis)
|
||||
@@ -60,8 +58,7 @@ namespace BBM {
|
||||
{
|
||||
double rnd = static_cast<double>(std::rand()) / RAND_MAX;
|
||||
|
||||
std::cout << "Random" << rnd << std::endl;
|
||||
if (rnd <= 1)
|
||||
if (rnd <= 0.8)
|
||||
return (static_cast<BonusType>((std::rand() % NOCLIP) + 1));
|
||||
return (NOTHING);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user