Setting max Camera distance to 30.
This commit is contained in:
parent
75c88681ee
commit
1fb288b220
@ -47,8 +47,8 @@ void Camera:: updateDistance(float distance) {
|
|||||||
if (this->distance + distance <= 1.0f) {
|
if (this->distance + distance <= 1.0f) {
|
||||||
this->distance = 1.0f;
|
this->distance = 1.0f;
|
||||||
}
|
}
|
||||||
else if (this->distance + distance >= 100.0f) {
|
else if (this->distance + distance >= 30.0f) {
|
||||||
this->distance = 100.f;
|
this->distance = 30.f;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
this->distance += distance;
|
this->distance += distance;
|
||||||
|
Loading…
Reference in New Issue
Block a user