Make for smoother zoom.
This commit is contained in:
parent
72e2b3dd09
commit
29cfe699cc
@ -38,7 +38,7 @@ void camera::update(const input *in_sys) {
|
||||
std::get<1>(pos) = dist * sin(yaw);
|
||||
std::get<2>(pos) = dist * cos(yaw) * cos(angle);
|
||||
|
||||
dist -= in_sys->get_scroll();
|
||||
if(dist < 0)
|
||||
dist = 0;
|
||||
dist -= static_cast<float>(in_sys->get_scroll()) / 2.5f;
|
||||
if(dist < 0.0f)
|
||||
dist = 0.0f;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user