summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNuno Donato <nunodonato@gmail.com>2016-02-16 08:56:31 +0000
committerNuno Donato <nunodonato@gmail.com>2016-02-16 08:56:31 +0000
commit2d1de834348473bae7bd676587d2e72ae03a5642 (patch)
treebcb42252f2ea2a2e77433c00e1e526b35f937ee6
parent7496fd4788a2aced44188f3c113eb15994fda4c0 (diff)
refix particles3d issue, bringing down the amount limit to 1024
-rw-r--r--scene/3d/particles.cpp4
-rw-r--r--servers/visual/particle_system_sw.h2
2 files changed, 3 insertions, 3 deletions
diff --git a/scene/3d/particles.cpp b/scene/3d/particles.cpp
index dfd5c38266..47662bcccb 100644
--- a/scene/3d/particles.cpp
+++ b/scene/3d/particles.cpp
@@ -95,7 +95,7 @@ DVector<Face3> Particles::get_faces(uint32_t p_usage_flags) const {
void Particles::set_amount(int p_amount) {
- ERR_FAIL_INDEX(p_amount,4096);
+ ERR_FAIL_INDEX(p_amount,1024);
amount=p_amount;
VisualServer::get_singleton()->particles_set_amount(particles,p_amount);
}
@@ -441,7 +441,7 @@ void Particles::_bind_methods() {
ADD_PROPERTY( PropertyInfo( Variant::OBJECT, "material", PROPERTY_HINT_RESOURCE_TYPE, "Material" ), _SCS("set_material"), _SCS("get_material") );
- ADD_PROPERTY( PropertyInfo( Variant::INT, "amount", PROPERTY_HINT_RANGE, "1,4096,1" ), _SCS("set_amount"), _SCS("get_amount") );
+ ADD_PROPERTY( PropertyInfo( Variant::INT, "amount", PROPERTY_HINT_RANGE, "1,1024,1" ), _SCS("set_amount"), _SCS("get_amount") );
ADD_PROPERTY( PropertyInfo( Variant::BOOL, "emitting" ), _SCS("set_emitting"), _SCS("is_emitting") );
ADD_PROPERTY( PropertyInfo( Variant::_AABB, "visibility" ), _SCS("set_visibility_aabb"), _SCS("get_visibility_aabb") );
ADD_PROPERTY( PropertyInfo( Variant::VECTOR3, "emission_extents" ), _SCS("set_emission_half_extents"), _SCS("get_emission_half_extents") );
diff --git a/servers/visual/particle_system_sw.h b/servers/visual/particle_system_sw.h
index 87c71696cf..9a176ba0d4 100644
--- a/servers/visual/particle_system_sw.h
+++ b/servers/visual/particle_system_sw.h
@@ -38,7 +38,7 @@
struct ParticleSystemSW {
enum {
- MAX_PARTICLES=4096
+ MAX_PARTICLES=1024
};
float particle_vars[VS::PARTICLE_VAR_MAX];