Skip to content

Commit

Permalink
Implement BulletManager::InitializeToZero
Browse files Browse the repository at this point in the history
  • Loading branch information
roblabla committed Sep 12, 2024
1 parent e53e566 commit 91a186b
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
1 change: 1 addition & 0 deletions config/implemented.csv
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ th06::BulletManager::RegisterChain
th06::BulletManager::CutChain
th06::BulletManager::AddedCallback
th06::BulletManager::DeletedCallback
th06::BulletManager::InitializeToZero
th06::BulletManager::SpawnBulletPattern
th06::BulletManager::SpawnSingleBullet
th06::BulletManager::OnUpdate
Expand Down
1 change: 0 additions & 1 deletion config/stubbed.csv
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@ th06::Enemy::MovePosTime
th06::Enemy::MoveDirTime
th06::Enemy::MoveTime
th06::BulletManager::DespawnBullets
th06::BulletManager::InitializeToZero
th06::BulletManager::RemoveAllBullets
th06::BulletManager::SpawnLaserPattern
th06::BulletManager::TurnAllBulletsIntoPoints
Expand Down
5 changes: 5 additions & 0 deletions src/BulletManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,11 @@ DIFFABLE_STATIC_ARRAY_ASSIGN(BulletTypeInfo, 10, g_BulletTypeInfos) = {
ASB4(SPAWN_BUBBLE_NORMAL)},
};

void BulletManager::InitializeToZero()
{
memset(this, 0, sizeof(BulletManager));
}

#pragma var_order(bulletSpeed, local_c, bullet, bulletAngle)
u32 BulletManager::SpawnSingleBullet(EnemyBulletShooter *bulletProps, i32 bulletIdx1, i32 bulletIdx2, f32 angle)
{
Expand Down

0 comments on commit 91a186b

Please sign in to comment.