mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2025-12-06 08:02:47 +00:00
Fix iteration of players for paintings. Causes undefined behavior otherwise. (#333)
This commit is contained in:
parent
2acb51b314
commit
79b1628dd8
1 changed files with 1 additions and 1 deletions
|
|
@ -839,7 +839,7 @@ void painting_update_floors(struct Painting *painting) {
|
||||||
painting->ripples.enteredMarioIndex = -1;
|
painting->ripples.enteredMarioIndex = -1;
|
||||||
painting->ripples.underMarioIndex = -1;
|
painting->ripples.underMarioIndex = -1;
|
||||||
|
|
||||||
for (int i = 0; i < MAX_PLAYERS + 1; i++) {
|
for (int i = 0; i < MAX_PLAYERS; i++) {
|
||||||
// If the painting was entered (and not a floor painting) no need to look at everyone else this frame
|
// If the painting was entered (and not a floor painting) no need to look at everyone else this frame
|
||||||
if (painting->floorEntered && !floorPainting) { continue; }
|
if (painting->floorEntered && !floorPainting) { continue; }
|
||||||
struct MarioState* m = &gMarioStates[i];
|
struct MarioState* m = &gMarioStates[i];
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue