diff options
| author | MegaMech <MegaMech@users.noreply.github.com> | 2024-12-04 11:19:49 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-12-04 11:19:49 -0700 |
| commit | eb158e2abd86579d3fa3c69436c3322cffd28d59 (patch) | |
| tree | d799662c6ba6464527648b9a94089543f0e57cce /src/engine/World.cpp | |
| parent | a4a03820b4bf2689a945068d736cbe60210baf0b (diff) | |
| parent | 00aa01bed83c5712c7339da3a29102bb728dcbb7 (diff) | |
Merge pull request #131 from MegaMech/modsnew
Implement Penguins
Diffstat (limited to 'src/engine/World.cpp')
| -rw-r--r-- | src/engine/World.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/engine/World.cpp b/src/engine/World.cpp index aae7f3568..b8371b2c8 100644 --- a/src/engine/World.cpp +++ b/src/engine/World.cpp @@ -47,6 +47,7 @@ static size_t tankerTrucks; static size_t cars; static size_t boats; static size_t thwomps; +static size_t penguins; /** * Note that you can only remove the tender if there are no carriages @@ -104,6 +105,13 @@ void World::AddThwomp(s16 x, s16 z, s16 direction, f32 scale, s16 behaviour, s16 gNumActiveThwomps = thwomps; } +std::shared_ptr<OPenguin> World::AddPenguin(Vec3f pos, u16 direction, OPenguin::PenguinType type, OPenguin::Behaviour behaviour) { + auto penguin = std::make_shared<OPenguin>(penguins, pos, direction, type, behaviour); + Penguins.push_back(penguin); + penguins++; + return penguin; +} + u32 World::GetCupIndex() { return this->CupIndex; } |
