Actually mark the sprite as used when you allocate it!
This commit is contained in:
parent
a6da168420
commit
c032e39fed
1 changed files with 3 additions and 1 deletions
|
@ -105,7 +105,9 @@ public class SpriteHelper
|
|||
|
||||
public static int getFreeSlot(BitSet slots)
|
||||
{
|
||||
return slots.nextSetBit(0);
|
||||
int next=slots.nextSetBit(0);
|
||||
slots.clear(next);
|
||||
return next;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue