summaryrefslogtreecommitdiff
path: root/src/engine/tracks/DKJungle.cpp
diff options
context:
space:
mode:
authorMegaMech <MegaMech@users.noreply.github.com>2025-12-13 11:50:28 -0700
committerGitHub <noreply@github.com>2025-12-13 11:50:28 -0700
commitb934e98fc34964970ab5efacb2fb7c3372ae0b1a (patch)
treecd96e5fabec7fdcc098d0de33b3b7e2754fb6cd5 /src/engine/tracks/DKJungle.cpp
parente6acb59ef4797ce27ddc9e21982c3f4e40824b52 (diff)
Refactor Track Class To Instantiate On Track Load (#587)
* Initial Commit * First compilation of Registry template * Further changes * wip changes * Impl TrackBrowser and Registry Info * Remove const from TInfo * Prep GetWorld * Name refactor * Refactor gWorldInstance to GetWorld() * wip * Should work now * Data menu work again * Fix editor staying open after program close * Rename LoadLevel to LoadTrackDataFromJson * More changes * Add statue * Add search to content browser using tags * Fix statue pos and register tags * Fix actor loading * Fix delete all bug which deleted cameras * reduce some boiler plate in actor and object * Remove unused rulesets * Search bar for all tabs * fix data screen * fix actor spawning * temp editor fix * Clean up * improve extra mode transformation * fix podium crash * Fix editor clicking * Fix editor clicking 2 * fix extra in custom track * Fix FI for three actors * Fix divide by zero error * Ids managed by Registry * Add scary comment --------- Co-authored-by: MegaMech <7255464+MegaMech@users.noreply.github.com> Co-authored-by: coco875 <pereira.jannin@gmail.com>
Diffstat (limited to 'src/engine/tracks/DKJungle.cpp')
-rw-r--r--src/engine/tracks/DKJungle.cpp20
1 files changed, 8 insertions, 12 deletions
diff --git a/src/engine/tracks/DKJungle.cpp b/src/engine/tracks/DKJungle.cpp
index 47dabe296..75c93c844 100644
--- a/src/engine/tracks/DKJungle.cpp
+++ b/src/engine/tracks/DKJungle.cpp
@@ -133,10 +133,6 @@ void DKJungle::Load() {
find_vtx_and_set_colours((Gfx*) d_course_dks_jungle_parkway_packed_dl_3FA8, 120, 255, 255, 255);
}
-void DKJungle::UnLoad() {
- RestoreTriangleWinding();
-}
-
f32 DKJungle::GetWaterLevel(FVector pos, Collision* collision) {
int32_t temp_v1 = get_track_section_id(collision->meshIndexZX) & 0xFF;
@@ -179,16 +175,16 @@ void DKJungle::BeginPlay() {
// The original game only ran vehicle logic every second frame.
// Thus the speed gets divided by two to set speed to match properly
- ABoat::Spawn((0.6666666f)/4, 0, 0, ABoat::SpawnMode::POINT);
+ SpawnActor<ABoat>((0.6666666f)/4, 0, 0, ABoat::SpawnMode::POINT);
if (gModeSelection == VERSUS) {
- OBombKart::Spawn(0, 50, 3, 0.8333333f);
- OBombKart::Spawn(0, 100, 1, 0.8333333f);
- OBombKart::Spawn(0, 150, 3, 0.8333333f);
- OBombKart::Spawn(0, 190, 1, 0.8333333f);
- OBombKart::Spawn(0, 250, 3, 0.8333333f);
- OBombKart::Spawn(0, 0, 0, 0.8333333f);
- OBombKart::Spawn(0, 0, 0, 0.8333333f);
+ SpawnActor<OBombKart>(0, 50, 3, 0.8333333f);
+ SpawnActor<OBombKart>(0, 100, 1, 0.8333333f);
+ SpawnActor<OBombKart>(0, 150, 3, 0.8333333f);
+ SpawnActor<OBombKart>(0, 190, 1, 0.8333333f);
+ SpawnActor<OBombKart>(0, 250, 3, 0.8333333f);
+ SpawnActor<OBombKart>(0, 0, 0, 0.8333333f);
+ SpawnActor<OBombKart>(0, 0, 0, 0.8333333f);
}
}
}