Merge pull request #21755 from akien-mga/particles-init-velocity
Particles: Reset default velocity to 0, allow negative values
This commit is contained in:
commit
b0d2cc76c2
1 changed files with 2 additions and 2 deletions
|
@ -1123,7 +1123,7 @@ void ParticlesMaterial::_bind_methods() {
|
|||
ADD_GROUP("Gravity", "");
|
||||
ADD_PROPERTY(PropertyInfo(Variant::VECTOR3, "gravity"), "set_gravity", "get_gravity");
|
||||
ADD_GROUP("Initial Velocity", "initial_");
|
||||
ADD_PROPERTYI(PropertyInfo(Variant::REAL, "initial_velocity", PROPERTY_HINT_RANGE, "0,1000,0.01,or_greater"), "set_param", "get_param", PARAM_INITIAL_LINEAR_VELOCITY);
|
||||
ADD_PROPERTYI(PropertyInfo(Variant::REAL, "initial_velocity", PROPERTY_HINT_RANGE, "0,1000,0.01,or_lesser,or_greater"), "set_param", "get_param", PARAM_INITIAL_LINEAR_VELOCITY);
|
||||
ADD_PROPERTYI(PropertyInfo(Variant::REAL, "initial_velocity_random", PROPERTY_HINT_RANGE, "0,1,0.01"), "set_param_randomness", "get_param_randomness", PARAM_INITIAL_LINEAR_VELOCITY);
|
||||
ADD_GROUP("Angular Velocity", "angular_");
|
||||
ADD_PROPERTYI(PropertyInfo(Variant::REAL, "angular_velocity", PROPERTY_HINT_RANGE, "-360,360,0.01"), "set_param", "get_param", PARAM_ANGULAR_VELOCITY);
|
||||
|
@ -1204,7 +1204,7 @@ ParticlesMaterial::ParticlesMaterial() :
|
|||
|
||||
set_spread(45);
|
||||
set_flatness(0);
|
||||
set_param(PARAM_INITIAL_LINEAR_VELOCITY, 1);
|
||||
set_param(PARAM_INITIAL_LINEAR_VELOCITY, 0);
|
||||
set_param(PARAM_ORBIT_VELOCITY, 0);
|
||||
set_param(PARAM_LINEAR_ACCEL, 0);
|
||||
set_param(PARAM_RADIAL_ACCEL, 0);
|
||||
|
|
Loading…
Reference in a new issue