blob: 699a6876930638b53b42d05c0a9ff785aa17f4f3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
#pragma once
#include <libultraship.h>
#include "engine/Actor.h"
#include "CoreMath.h"
#include "engine/World.h"
#include "engine/registry/RegisterContent.h"
extern "C" {
#include "common_structs.h"
}
class AMarioSign : public AActor {
public:
virtual ~AMarioSign() {
_count -= 1;
};
explicit AMarioSign(const SpawnParams& params);
// This is simply a helper function to keep Spawning code clean
static inline AMarioSign* Spawn(FVector pos, IRotator rot, FVector velocity, FVector scale) {
SpawnParams params = {
.Name = "mk:mario_sign",
.Location = pos,
.Rotation = rot,
.Scale = scale,
.Velocity = velocity,
.Speed = 182,
};
return static_cast<AMarioSign*>(AddActorToWorld<AMarioSign>(params));
}
virtual bool IsMod() override;
virtual void SetSpawnParams(SpawnParams& params) override;
virtual void Tick() override;
virtual void Draw(Camera*) override;
private:
static size_t _count;
size_t _idx;
};
|