blob: 636f84eb49be4f2a83b3a9a99a521dd51e7cc992 (
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
42
43
44
45
|
#pragma once
#include "StarWeightedPool.hpp"
#include "StarParticle.hpp"
namespace Star {
struct WeatherType {
struct ParticleConfig {
Particle particle;
float density;
bool autoRotate;
};
struct ProjectileConfig {
String projectile;
Json parameters;
Vec2F velocity;
float ratePerX;
int spawnAboveRegion;
int spawnHorizontalPad;
float windAffectAmount;
};
WeatherType();
WeatherType(Json config, String path = String());
Json toJson() const;
String name;
List<ParticleConfig> particles;
List<ProjectileConfig> projectiles;
StringList statusEffects;
float maximumWind;
Vec2F duration;
StringList weatherNoises;
};
typedef WeightedPool<String> WeatherPool;
DataStream& operator>>(DataStream& ds, WeatherType& weatherType);
DataStream& operator<<(DataStream& ds, WeatherType const& weatherType);
}
|