Skip to content

Commit

Permalink
missed movement code fixes from my mod? b7ef4c8
Browse files Browse the repository at this point in the history
  • Loading branch information
jacob1 committed Oct 1, 2016
1 parent e8b4f99 commit 85e2516
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/simulation/Simulation.cpp
Expand Up @@ -4097,8 +4097,8 @@ void Simulation::UpdateParticles(int start, int end)
fin_y = (int)(fin_yf+0.5f);
if (edgeMode == 2)
{
bool x_ok = (fin_x >= CELL && fin_x < XRES-CELL);
bool y_ok = (fin_y >= CELL && fin_y < YRES-CELL);
bool x_ok = (fin_xf >= CELL-.5f && fin_xf < XRES-CELL-.5f);
bool y_ok = (fin_yf >= CELL-.5f && fin_yf < YRES-CELL-.5f);
if (!x_ok)
fin_xf = remainder_p(fin_xf-CELL+.5f, XRES-CELL*2.0f)+CELL-.5f;
if (!y_ok)
Expand Down Expand Up @@ -4186,8 +4186,8 @@ void Simulation::UpdateParticles(int start, int end)
if (stickman)
for (int i = 0; i < 16; i+=2)
{
stickman->legs[i] += (nx-oldnx)+.5f;
stickman->legs[i+1] += (ny-oldny)+.5f;
stickman->legs[i] += (nx-oldnx);
stickman->legs[i+1] += (ny-oldny);
stickman->accs[i/2] *= .95f;
}
parts[i].vy *= .95f;
Expand Down

0 comments on commit 85e2516

Please sign in to comment.