mirror of
https://github.com/HarbourMasters/SpaghettiKart
synced 2026-07-03 21:20:12 -04:00
[modding] Add Actors (#113)
* fix * Add Actors * Refactor * Update Game.cpp
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
#include <libultraship.h>
|
||||
|
||||
#include "Actor.h"
|
||||
|
||||
//GameActor()
|
||||
|
||||
AActor::AActor() {}
|
||||
|
||||
// Virtual functions to be overridden by derived classes
|
||||
void AActor::Tick() { }
|
||||
void AActor::Draw(Camera *camera) { }
|
||||
void AActor::Collision() {}
|
||||
void AActor::Destroy() { }
|
||||
@@ -0,0 +1,36 @@
|
||||
#pragma once
|
||||
|
||||
#include <libultraship.h>
|
||||
|
||||
extern "C" {
|
||||
#include "macros.h"
|
||||
#include "main.h"
|
||||
#include "camera.h"
|
||||
#include "common_structs.h"
|
||||
}
|
||||
|
||||
class AActor {
|
||||
public:
|
||||
uint8_t uuid[16];
|
||||
|
||||
/* 0x00 */ s16 Type;
|
||||
/* 0x02 */ s16 Flags;
|
||||
/* 0x04 */ s16 Unk_04;
|
||||
/* 0x06 */ s16 State;
|
||||
/* 0x08 */ f32 Unk_08;
|
||||
/* 0x0C */ f32 BoundingBoxSize;
|
||||
/* 0x10 */ Vec3s Rot = {0, 0, 0};
|
||||
/* 0x16 */ s16 Unk_16;
|
||||
/* 0x18 */ Vec3f Pos;
|
||||
/* 0x24 */ Vec3f Velocity = {0, 0, 0};
|
||||
/* 0x30 */ Collision Unk30;
|
||||
|
||||
virtual ~AActor() = default; // Virtual destructor for proper cleanup in derived classes
|
||||
|
||||
explicit AActor();
|
||||
|
||||
virtual void Tick();
|
||||
virtual void Draw(Camera*);
|
||||
virtual void Collision();
|
||||
virtual void Destroy();
|
||||
};
|
||||
@@ -13,9 +13,8 @@ extern "C" {
|
||||
GameObject::GameObject() {}
|
||||
|
||||
// Virtual functions to be overridden by derived classes
|
||||
void GameObject::Init() { }
|
||||
void GameObject::Update() { }
|
||||
void GameObject::Render(Camera* camera) { }
|
||||
void GameObject::Tick() { }
|
||||
void GameObject::Draw(Camera* camera) { }
|
||||
void GameObject::Collision() {}
|
||||
void GameObject::Expire() { }
|
||||
void GameObject::Destroy() { }
|
||||
|
||||
@@ -16,9 +16,8 @@ public:
|
||||
|
||||
explicit GameObject();
|
||||
|
||||
virtual void Init();
|
||||
virtual void Update();
|
||||
virtual void Render(Camera* camera);
|
||||
virtual void Tick();
|
||||
virtual void Draw(Camera* camera);
|
||||
virtual void Collision();
|
||||
virtual void Expire();
|
||||
virtual void Destroy();
|
||||
|
||||
@@ -53,7 +53,6 @@ void TrainCrossing::AICrossingBehaviour(s32 playerId) {
|
||||
(set_vehicle_render_distance_flags(gPlayers[playerId].pos, TRAIN_CROSSING_AI_DISTANCE, 0))) {
|
||||
if ((OnTriggered == 1) && ((Timer) > FRAMES_SINCE_CROSSING_ACTIVATED)) {
|
||||
if ((sSomeNearestWaypoint > WaypointMin) && (sSomeNearestWaypoint < WaypointMax)) {
|
||||
printf("STOP AI\n");
|
||||
bStopAICrossing[playerId] = 1;
|
||||
}
|
||||
}
|
||||
|
||||
+32
-7
@@ -172,21 +172,46 @@ void World::PreviousCourse() {
|
||||
gWorldInstance.CurrentCourse = Courses[CourseIndex];
|
||||
}
|
||||
|
||||
Object* World::SpawnObject(std::unique_ptr<GameObject> object) {
|
||||
Object* World::AddObject(std::unique_ptr<GameObject> object) {
|
||||
GameObject* rawPtr = object.get();
|
||||
this->GameObjects.push_back(std::move(object));
|
||||
GameObjects.push_back(std::move(object));
|
||||
return &rawPtr->o;
|
||||
}
|
||||
|
||||
void World::UpdateObjects() {
|
||||
for (const auto& object : this->GameObjects) {
|
||||
object->Update();
|
||||
AActor* World::AddActor(std::unique_ptr<AActor> actor) {
|
||||
AActor* rawPtr = actor.get();
|
||||
Actors.push_back(std::move(actor));
|
||||
return rawPtr;
|
||||
}
|
||||
|
||||
void World::TickActors() {
|
||||
for (auto& actor : Actors) {
|
||||
actor->Tick();
|
||||
}
|
||||
}
|
||||
|
||||
void World::RenderObjects(Camera *camera) {
|
||||
void World::DrawActors(Camera* camera) {
|
||||
for (auto& actor : Actors) {
|
||||
actor->Draw(camera);
|
||||
}
|
||||
}
|
||||
|
||||
void RemoveExpiredActors() {
|
||||
//Actors.erase(
|
||||
// std::remove_if(Actors.begin(), Actors.end(),
|
||||
// [](const std::unique_ptr<AActor>& actor) { return actor->uuid == 0; }), // Example condition
|
||||
// Actors.end());
|
||||
}
|
||||
|
||||
void World::TickObjects() {
|
||||
for (const auto& object : this->GameObjects) {
|
||||
object->Render(camera);
|
||||
object->Tick();
|
||||
}
|
||||
}
|
||||
|
||||
void World::DrawObjects(Camera *camera) {
|
||||
for (const auto& object : this->GameObjects) {
|
||||
object->Draw(camera);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+18
-16
@@ -8,6 +8,7 @@
|
||||
#include "vehicles/Car.h"
|
||||
#include "TrainCrossing.h"
|
||||
#include <memory>
|
||||
#include "Actor.h"
|
||||
|
||||
extern "C" {
|
||||
#include "camera.h"
|
||||
@@ -64,30 +65,31 @@ class World {
|
||||
} Properties;
|
||||
|
||||
public:
|
||||
//Actor actors;
|
||||
virtual ~World() = default;
|
||||
explicit World();
|
||||
|
||||
// virtual Actor* SpawnActor(std::unique_ptr<GameActor> actor);
|
||||
AActor* AddActor(std::unique_ptr<AActor> actor);
|
||||
void TickActors();
|
||||
void DrawActors(Camera* camera);
|
||||
void RemoveExpiredActors();
|
||||
|
||||
virtual Object* SpawnObject(std::unique_ptr<GameObject> object);
|
||||
Object* AddObject(std::unique_ptr<GameObject> object);
|
||||
|
||||
|
||||
virtual CProperties* GetCourseProps();
|
||||
virtual void UpdateObjects();
|
||||
virtual void RenderObjects(Camera *camera);
|
||||
virtual void ExpiredObjects();
|
||||
virtual void DestroyObjects();
|
||||
virtual Object *GetObjectByIndex(size_t);
|
||||
CProperties* GetCourseProps();
|
||||
void TickObjects();
|
||||
void DrawObjects(Camera *camera);
|
||||
void ExpiredObjects();
|
||||
void DestroyObjects();
|
||||
Object *GetObjectByIndex(size_t);
|
||||
|
||||
Cup* AddCup(const char* name, std::vector<Course*> courses);
|
||||
Cup* GetCup();
|
||||
const char* GetCupName();
|
||||
virtual u32 GetCupIndex();
|
||||
virtual void SetCupIndex(int16_t courseId);
|
||||
virtual u32 NextCup();
|
||||
virtual u32 PreviousCup();
|
||||
virtual void SetCourseFromCup();
|
||||
u32 GetCupIndex();
|
||||
void SetCupIndex(int16_t courseId);
|
||||
u32 NextCup();
|
||||
u32 PreviousCup();
|
||||
void SetCourseFromCup();
|
||||
void SetCup();
|
||||
|
||||
World* GetWorld(void);
|
||||
@@ -107,7 +109,7 @@ public:
|
||||
size_t CupIndex = 1;
|
||||
|
||||
std::vector<std::unique_ptr<GameObject>> GameObjects;
|
||||
// std::vector<std::unique_ptr<GameActor>> GameActors;
|
||||
std::vector<std::unique_ptr<AActor>> Actors;
|
||||
|
||||
void AddBoat(f32 speed, uint32_t waypoint);
|
||||
void AddTrain(size_t numCarriages, f32 speed, uint32_t waypoint);
|
||||
|
||||
@@ -0,0 +1,60 @@
|
||||
#include <libultraship.h>
|
||||
|
||||
#include "ABanana.h"
|
||||
#include "engine/Actor.h"
|
||||
|
||||
extern "C" {
|
||||
#include "macros.h"
|
||||
#include "actor_types.h"
|
||||
void update_actor_banana(struct BananaActor*);
|
||||
void render_actor_banana(Camera*, float[4][4], struct BananaActor*);
|
||||
}
|
||||
|
||||
ABanana::ABanana(uint16_t playerId, const float pos[3], const s16 rot[3], const float velocity[3]) {
|
||||
// Initialize the BananaActor's position, rotation, and velocity
|
||||
std::copy(pos, pos + 3, Pos);
|
||||
//std::copy(rot, rot + 3, this->a.rot);
|
||||
std::copy(velocity, velocity + 3, Velocity);
|
||||
|
||||
Type = 6; // ACTOR_BANANA
|
||||
Flags = -0x8000;
|
||||
Unk_04 = 20;
|
||||
State = HELD_BANANA;
|
||||
|
||||
PlayerId = playerId;
|
||||
|
||||
//this->a.unk_08 = 0.0f;
|
||||
Flags |= 0x4000 | 0x1000;
|
||||
BoundingBoxSize = 2.0f;
|
||||
|
||||
Unk30.meshIndexYX = 5000;
|
||||
Unk30.meshIndexZX = 5000;
|
||||
Unk30.meshIndexZY = 5000;
|
||||
Unk30.unk30 = 0;
|
||||
Unk30.unk32 = 0;
|
||||
Unk30.unk34 = 0;
|
||||
Unk30.surfaceDistance[0] = 0;
|
||||
Unk30.surfaceDistance[1] = 0;
|
||||
Unk30.surfaceDistance[2] = 0;
|
||||
Unk30.unk48[0] = 0;
|
||||
Unk30.unk48[1] = 0;
|
||||
Unk30.unk48[2] = 1.0f;
|
||||
Unk30.unk54[0] = 1.0f;
|
||||
Unk30.unk54[1] = 0.0f;
|
||||
Unk30.unk54[2] = 0.0f;
|
||||
Unk30.orientationVector[0] = 0.0f;
|
||||
Unk30.orientationVector[1] = 1.0f;
|
||||
Unk30.orientationVector[2] = 0.0f;
|
||||
}
|
||||
|
||||
void ABanana::Tick() {
|
||||
update_actor_banana((BananaActor*)this);
|
||||
}
|
||||
|
||||
void ABanana::Draw(Camera *camera) {
|
||||
render_actor_banana(camera, NULL, (BananaActor*)this);
|
||||
}
|
||||
void ABanana::Collision() { }
|
||||
void ABanana::Destroy() { }
|
||||
|
||||
//void ABanana::Held() {}
|
||||
@@ -0,0 +1,21 @@
|
||||
#pragma once
|
||||
|
||||
#include <libultraship.h>
|
||||
#include "engine/Actor.h"
|
||||
|
||||
class ABanana : public AActor {
|
||||
public:
|
||||
|
||||
uint16_t PlayerId;
|
||||
|
||||
// Constructor
|
||||
ABanana(uint16_t playerId, const float pos[3], const s16 rot[3], const float velocity[3]);
|
||||
|
||||
virtual ~ABanana() override = default;
|
||||
|
||||
// Virtual functions to be overridden by derived classes
|
||||
virtual void Tick() override;
|
||||
virtual void Draw(Camera*) override;
|
||||
virtual void Collision() override;
|
||||
virtual void Destroy() override;
|
||||
};
|
||||
@@ -0,0 +1,42 @@
|
||||
#include "AWarioSign.h"
|
||||
|
||||
#include <libultra/gbi.h>
|
||||
#include <assets/wario_stadium_data.h>
|
||||
|
||||
extern "C" {
|
||||
#include "common_structs.h"
|
||||
#include "math_util.h"
|
||||
#include "main.h"
|
||||
}
|
||||
|
||||
AWarioSign::AWarioSign(Vec3f pos) {
|
||||
Pos[0] = pos[0];
|
||||
Pos[1] = pos[1];
|
||||
Pos[2] = pos[2];
|
||||
}
|
||||
|
||||
// Virtual functions to be overridden by derived classes
|
||||
void AWarioSign::Tick() {
|
||||
Rot[1] += 0xB6;
|
||||
}
|
||||
|
||||
void AWarioSign::Draw(Camera *camera) {
|
||||
Mat4 sp38;
|
||||
f32 unk =
|
||||
is_within_render_distance(camera->pos, Pos, camera->rot[1], 0, gCameraZoom[camera - camera1], 16000000.0f);
|
||||
|
||||
if (CVarGetInteger("gNoCulling", 0) == 1) {
|
||||
unk = MAX(unk, 0.0f);
|
||||
}
|
||||
|
||||
if (!(unk < 0.0f)) {
|
||||
gSPSetGeometryMode(gDisplayListHead++, G_SHADING_SMOOTH);
|
||||
gSPClearGeometryMode(gDisplayListHead++, G_LIGHTING);
|
||||
|
||||
mtxf_pos_rotation_xyz(sp38, Pos, Rot);
|
||||
if (render_set_position(sp38, 0) != 0) {
|
||||
|
||||
gSPDisplayList(gDisplayListHead++, (Gfx*)d_course_wario_stadium_dl_sign);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,19 @@
|
||||
#pragma once
|
||||
|
||||
#include <libultraship.h>
|
||||
#include "engine/Actor.h"
|
||||
|
||||
extern "C" {
|
||||
#include "common_structs.h"
|
||||
}
|
||||
|
||||
class AWarioSign : public AActor {
|
||||
public:
|
||||
|
||||
|
||||
virtual ~AWarioSign() = default;
|
||||
explicit AWarioSign(Vec3f pos);
|
||||
|
||||
virtual void Tick() override;
|
||||
virtual void Draw(Camera*) override;
|
||||
};
|
||||
@@ -191,13 +191,13 @@ void BansheeBoardwalk::WhatDoesThisDoAI(Player* player, int8_t playerId) {
|
||||
}
|
||||
|
||||
void BansheeBoardwalk::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(140, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(165, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(330, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(550, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(595, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(140, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(165, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(330, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(550, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(595, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -215,13 +215,13 @@ void BowsersCastle::WhatDoesThisDoAI(Player* player, int8_t playerId) {
|
||||
}
|
||||
|
||||
void BowsersCastle::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(140, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(165, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(330, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(550, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(595, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(140, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(165, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(330, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(550, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(595, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -168,13 +168,13 @@ void ChocoMountain::WhatDoesThisDoAI(Player* player, int8_t playerId) {
|
||||
}
|
||||
|
||||
void ChocoMountain::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(140, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(165, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(330, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(550, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(595, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(140, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(165, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(330, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(550, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(595, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -196,13 +196,13 @@ void DKJungle::WhatDoesThisDoAI(Player* player, int8_t playerId) {
|
||||
}
|
||||
|
||||
void DKJungle::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -189,13 +189,13 @@ void FrappeSnowland::WhatDoesThisDo(Player* player, int8_t playerId) {}
|
||||
void FrappeSnowland::WhatDoesThisDoAI(Player* player, int8_t playerId) {}
|
||||
|
||||
void FrappeSnowland::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(140, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(165, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(330, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(550, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(595, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(140, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(165, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(330, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(550, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(595, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -184,13 +184,13 @@ void KalimariDesert::WhatDoesThisDo(Player* player, int8_t playerId) {}
|
||||
void KalimariDesert::WhatDoesThisDoAI(Player* player, int8_t playerId) {}
|
||||
|
||||
void KalimariDesert::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(140, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(165, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(330, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(550, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(595, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(140, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(165, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(330, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(550, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(595, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -183,13 +183,13 @@ void KoopaTroopaBeach::WhatDoesThisDo(Player* player, int8_t playerId) {}
|
||||
void KoopaTroopaBeach::WhatDoesThisDoAI(Player* player, int8_t playerId) {}
|
||||
|
||||
void KoopaTroopaBeach::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(140, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(165, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(330, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(550, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(595, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(140, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(165, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(330, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(550, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(595, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -190,13 +190,13 @@ void LuigiRaceway::WhatDoesThisDoAI(Player* player, int8_t playerId) {
|
||||
}
|
||||
|
||||
void LuigiRaceway::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -195,13 +195,13 @@ void MarioRaceway::WhatDoesThisDoAI(Player* player, int8_t playerId) {
|
||||
}
|
||||
|
||||
void MarioRaceway::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -240,13 +240,13 @@ void MooMooFarm::WhatDoesThisDoAI(Player* player, int8_t playerId) {
|
||||
}
|
||||
|
||||
void MooMooFarm::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -166,13 +166,13 @@ void PodiumCeremony::WhatDoesThisDoAI(Player* player, int8_t playerId) {
|
||||
}
|
||||
|
||||
void PodiumCeremony::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -160,13 +160,13 @@ void RainbowRoad::WhatDoesThisDo(Player* player, int8_t playerId) {}
|
||||
void RainbowRoad::WhatDoesThisDoAI(Player* player, int8_t playerId) {}
|
||||
|
||||
void RainbowRoad::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -181,13 +181,13 @@ void RoyalRaceway::WhatDoesThisDoAI(Player* player, int8_t playerId) {
|
||||
}
|
||||
|
||||
void RoyalRaceway::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -149,13 +149,13 @@ void SherbetLand::WhatDoesThisDo(Player* player, int8_t playerId) {}
|
||||
void SherbetLand::WhatDoesThisDoAI(Player* player, int8_t playerId) {}
|
||||
|
||||
void SherbetLand::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -286,13 +286,13 @@ void TestCourse::WhatDoesThisDoAI(Player* player, int8_t playerId) {
|
||||
}
|
||||
|
||||
void TestCourse::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -160,13 +160,13 @@ void ToadsTurnpike::WhatDoesThisDoAI(Player* player, int8_t playerId) {
|
||||
}
|
||||
|
||||
void ToadsTurnpike::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
#include "World.h"
|
||||
#include "BombKart.h"
|
||||
#include "assets/wario_stadium_data.h"
|
||||
#include "engine/actors/AWarioSign.h"
|
||||
|
||||
extern "C" {
|
||||
#include "main.h"
|
||||
@@ -111,15 +112,27 @@ void WarioStadium::SpawnActors() {
|
||||
Vec3s rotation = { 0, 0, 0 };
|
||||
|
||||
spawn_all_item_boxes((struct ActorSpawnData*)LOAD_ASSET_RAW(d_course_wario_stadium_item_box_spawns));
|
||||
vec3f_set(position, -131.0f, 83.0f, 286.0f);
|
||||
position[0] *= gCourseDirection;
|
||||
add_actor_to_empty_slot(position, rotation, velocity, ACTOR_WARIO_SIGN);
|
||||
vec3f_set(position, -2353.0f, 72.0f, -1608.0f);
|
||||
position[0] *= gCourseDirection;
|
||||
add_actor_to_empty_slot(position, rotation, velocity, ACTOR_WARIO_SIGN);
|
||||
vec3f_set(position, -2622.0f, 79.0f, 739.0f);
|
||||
position[0] *= gCourseDirection;
|
||||
add_actor_to_empty_slot(position, rotation, velocity, ACTOR_WARIO_SIGN);
|
||||
// vec3f_set(position, -131.0f, 83.0f, 286.0f);
|
||||
// position[0] *= gCourseDirection;
|
||||
// add_actor_to_empty_slot(position, rotation, velocity, ACTOR_WARIO_SIGN);
|
||||
// vec3f_set(position, -2353.0f, 72.0f, -1608.0f);
|
||||
// position[0] *= gCourseDirection;
|
||||
// add_actor_to_empty_slot(position, rotation, velocity, ACTOR_WARIO_SIGN);
|
||||
// vec3f_set(position, -2622.0f, 79.0f, 739.0f);
|
||||
// position[0] *= gCourseDirection;
|
||||
// add_actor_to_empty_slot(position, rotation, velocity, ACTOR_WARIO_SIGN);
|
||||
|
||||
Vec3f pos = {-131.0f, 83.0f, 286.0f};
|
||||
pos[0] *= gCourseDirection;
|
||||
gWorldInstance.AddActor(std::make_unique<AWarioSign>(pos));
|
||||
|
||||
Vec3f pos2 = {-2353.0f, 72.0f, -1608.0f};
|
||||
pos2[0] *= gCourseDirection;
|
||||
gWorldInstance.AddActor(std::make_unique<AWarioSign>(pos2));
|
||||
|
||||
Vec3f pos3 = {-2622.0f, 79.0f, 739.0f};
|
||||
pos3[0] *= gCourseDirection;
|
||||
gWorldInstance.AddActor(std::make_unique<AWarioSign>(pos3));
|
||||
}
|
||||
|
||||
void WarioStadium::Init() {}
|
||||
@@ -157,13 +170,13 @@ void WarioStadium::WhatDoesThisDo(Player* player, int8_t playerId) {}
|
||||
void WarioStadium::WhatDoesThisDoAI(Player* player, int8_t playerId) {}
|
||||
|
||||
void WarioStadium::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(40, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(100, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(265, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(285, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(420, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -171,13 +171,13 @@ void YoshiValley::WhatDoesThisDo(Player* player, int8_t playerId) {}
|
||||
void YoshiValley::WhatDoesThisDoAI(Player* player, int8_t playerId) {}
|
||||
|
||||
void YoshiValley::SpawnBombKarts() {
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(140, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(165, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(330, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(550, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(595, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.SpawnObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(140, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(165, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(330, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(550, 1, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(595, 3, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
gWorldInstance.AddObject(std::make_unique<OBombKart>(0, 0, 0.8333333, 0, 0, 0, 0));
|
||||
}
|
||||
|
||||
// Positions the finishline on the minimap
|
||||
|
||||
@@ -1,92 +0,0 @@
|
||||
#pragma once
|
||||
|
||||
#include <libultraship.h>
|
||||
|
||||
typedef float Vec3f[3];
|
||||
typedef unsigned short Vec3su[3];
|
||||
|
||||
typedef struct {
|
||||
/* 0x00 */ u16 unk30;
|
||||
/* 0x02 */ u16 unk32;
|
||||
/* 0x04 */ u16 unk34;
|
||||
/* 0x06 */ u16 meshIndexYX;
|
||||
/* 0x08 */ u16 meshIndexZY;
|
||||
// This may be an index to the tilemap?
|
||||
/* 0x0A */ u16 meshIndexZX;
|
||||
/* 0x0C */ float surfaceDistance[3]; // Appears to be distance from actor to surface for zx, yx, and zy planes.
|
||||
/* 0x18 */ float unk48[3];
|
||||
/* 0x24 */ float unk54[3];
|
||||
/* 0x30 */ float orientationVector[3];
|
||||
/* 0x3C */ f32 unk6C;
|
||||
} Collision;
|
||||
|
||||
struct Actor {
|
||||
/* 0x00 */ s16 type;
|
||||
/* 0x02 */ s16 flags;
|
||||
/* 0x04 */ s16 unk_04;
|
||||
/* 0x06 */ s16 state;
|
||||
/* 0x08 */ f32 unk_08;
|
||||
/* 0x0C */ f32 boundingBoxSize;
|
||||
/* 0x10 */ s16 rot[3];
|
||||
/* 0x16 */ s16 unk_16;
|
||||
/* 0x18 */ Vec3f pos;
|
||||
/* 0x24 */ Vec3f velocity;
|
||||
/* 0x30 */ Collision unk30;
|
||||
}; // size = 0x70
|
||||
|
||||
struct BananaActor {
|
||||
/* 0x00 */ s16 type;
|
||||
/* 0x02 */ s16 flags;
|
||||
/* 0x04 */ s16 unk_04;
|
||||
/* 0x06 */ s16 state;
|
||||
/* 0x08 */ s16 parentIndex;
|
||||
/* 0x0A */ s16 bananaId; // ? Appears to indiciate which banana of the bunch this one is
|
||||
/* 0x0C */ f32 boundingBoxSize;
|
||||
/* 0x10 */ s16 playerId; // Id of the player that owns this banana
|
||||
/* 0x12 */ s16 elderIndex; // Index in gActorList of the next-oldest banana in the bunch
|
||||
/* 0x14 */ s16 youngerIndex; // Index in gActorList of the next-youngest banana in the bunch
|
||||
/* 0x16 */ s16 unk_16;
|
||||
/* 0x18 */ float pos[3];
|
||||
/* 0x24 */ float velocity[3];
|
||||
/* 0x30 */ Collision unk30;
|
||||
}; // size = 0x70
|
||||
|
||||
typedef struct {
|
||||
f32 unk_0;
|
||||
s16 unk_4;
|
||||
s16 unk_6;
|
||||
s16 unk_8;
|
||||
} UnkCameraInner;
|
||||
|
||||
typedef struct {
|
||||
/* 0x00 */ float pos[3];
|
||||
/* 0x0C */ Vec3f lookAt;
|
||||
// This is expected to be a normalized vector, indicates what direction is "up" for the camera
|
||||
/* 0x18 */ Vec3f up;
|
||||
// I think these are the "nautical angles" between pos and lookAt
|
||||
// rot[0] = roll? Does nothing?, rot[1] = yaw, rot[2] = pitch
|
||||
/* 0x24 */ s16 rot[3];
|
||||
/* 0x2A */ u16 someBitFlags;
|
||||
/* 0x2C */ s16 unk_2C;
|
||||
/* 0x2E */ s16 unk_2E;
|
||||
/* 0x30 */ Vec3f unk_30;
|
||||
/* 0x3C */ Vec3f unk_3C;
|
||||
/* 0x48 */ s32 unk_48;
|
||||
/* 0x4C */ s32 unk_4C;
|
||||
/* 0x50 */ s32 unk_50;
|
||||
/* 0x54 */ Collision collision;
|
||||
// When you hit a wall (or another driver) the camera's pos and lookAt bounce up and down. This is the velocity(?)
|
||||
// of that bouncing
|
||||
/* 0x94 */ UnkCameraInner unk_94;
|
||||
// Timer for wall-hit bounce. Counts up instead of down
|
||||
/* 0xA0 */ f32 unk_A0;
|
||||
/* 0xA4 */ s32 unk_A4;
|
||||
/* 0xA8 */ s32 unk_A8;
|
||||
/* 0xAC */ s16 unk_AC;
|
||||
// Id of the player the camera is following.
|
||||
/* 0xAE */ s16 playerId;
|
||||
// Seems related to camera movement during drifting
|
||||
/* 0xB0 */ s16 unk_B0;
|
||||
/* 0xB2 */ s16 unk_B2;
|
||||
/* 0xB4 */ f32 unk_B4;
|
||||
} Camera; /* size = 0xB8 */
|
||||
@@ -200,7 +200,6 @@ void ATrain::Tick() {
|
||||
smokePos[2] = (f32) ((f64) Locomotive.position[2] + 25.0);
|
||||
adjust_position_by_angle(smokePos, Locomotive.position, orientationYUpdate);
|
||||
//spawn_train_smoke(Index, smokePos, 1.1f);
|
||||
printf("\nSMOKE HERE: %d\n\n", Index);
|
||||
AddSmoke(Index, smokePos, 1.1f);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user