The default resistance
that is used to calculate how long it will take for the tweening property (or properties) to come to rest by the static ThrowPropsPlugin.to()
and ThrowPropsPlugin.calculateTweenDuration()
methods. Keep in mind that you can define a resistance
value either for each individual property in the throwProps
tween like this:
ThrowPropsPlugin.to(obj, {throwProps: {
x:{
velocity: 500,
resistance: 150
},
y: {
velocity: -300,
resistance: 50
}
}});
OR you can define a single resistance
value that will be used for all of the properties in that particular throwProps
tween like this:
ThrowPropsPlugin.to(obj, {throwProps: {
x: 500,
y: -300,
resistance: 150
}});
//or
ThrowPropsPlugin.to(obj, {throwProps: {
x: {
velocity: 500,
max: 800,
min: 0
},
y: {
velocity: -300,
max: 800,
min: 100
},
resistance: 150
}});