For property-scale, apply the squared option before factor, etc.
This commit is contained in:
parent
00738f22f7
commit
0296c04e32
1 changed files with 2 additions and 2 deletions
|
@ -543,9 +543,9 @@ do_property_scale (const SGPropertyNode * arg, SGCommandState ** state)
|
|||
bool squared =
|
||||
((PropertyCommandState *)(*state))->getSquared()->getBoolValue();
|
||||
|
||||
double result = (setting + offset) * factor;
|
||||
if (squared)
|
||||
result = (result < 0 ? -1 : 1) * result * result;
|
||||
setting = (setting < 0 ? -1 : 1) * setting * setting;
|
||||
double result = (setting + offset) * factor;
|
||||
|
||||
return prop->setDoubleValue(result);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue