mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-06 03:21:49 +00:00
add 'global_up_vector' setting
This commit is contained in:
parent
60c9fedb55
commit
87663e597b
2 changed files with 4 additions and 0 deletions
|
|
@ -34,6 +34,7 @@ dv::value ParticlesPreset::serialize() const {
|
|||
root["collision"] = collision;
|
||||
root["lighting"] = lighting;
|
||||
root["max_distance"] = maxDistance;
|
||||
root["global_up_vector"] = globalUpVector;
|
||||
root["spawn_interval"] = spawnInterval;
|
||||
root["lifetime"] = lifetime;
|
||||
root["lifetime_spread"] = lifetimeSpread;
|
||||
|
|
@ -51,6 +52,7 @@ void ParticlesPreset::deserialize(const dv::value& src) {
|
|||
src.at("texture").get(texture);
|
||||
src.at("collision").get(collision);
|
||||
src.at("lighting").get(lighting);
|
||||
src.at("global_up_vector").get(globalUpVector);
|
||||
src.at("max_distance").get(maxDistance);
|
||||
src.at("spawn_interval").get(spawnInterval);
|
||||
src.at("lifetime").get(lifetime);
|
||||
|
|
|
|||
|
|
@ -24,6 +24,8 @@ struct ParticlesPreset : public Serializable {
|
|||
bool collision = true;
|
||||
/// @brief Apply lighting
|
||||
bool lighting = true;
|
||||
/// @brief Use global up vector instead of camera-dependent one
|
||||
bool globalUpVector = false;
|
||||
/// @brief Max distance of actually spawning particles.
|
||||
float maxDistance = 16.0f;
|
||||
/// @brief Particles spawn interval
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue