fixed amount of iterations because of endless loops on the ls-borg
This commit is contained in:
parent
24ef3480ff
commit
a3f7e211a0
|
@ -300,7 +300,7 @@ void gameoflife() {
|
||||||
/* loop detection */
|
/* loop detection */
|
||||||
if (!pfcmp(pf1, pf2)) {
|
if (!pfcmp(pf1, pf2)) {
|
||||||
insertglider(pf1);
|
insertglider(pf1);
|
||||||
cycle = 1;
|
// cycle = 1;
|
||||||
}
|
}
|
||||||
if (pfempty(pf1)) {
|
if (pfempty(pf1)) {
|
||||||
/* kill game */
|
/* kill game */
|
||||||
|
@ -311,7 +311,7 @@ void gameoflife() {
|
||||||
for (i = 0; i < LOOP_DETECT_BUFFER_SIZE; ++i) {
|
for (i = 0; i < LOOP_DETECT_BUFFER_SIZE; ++i) {
|
||||||
if (!pfcmp(pf1, ldbuf[i])) {
|
if (!pfcmp(pf1, ldbuf[i])) {
|
||||||
insertglider(pf1);
|
insertglider(pf1);
|
||||||
cycle = 1;
|
// cycle = 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
pfcopy(ldbuf[ldbuf_idx], pf1);
|
pfcopy(ldbuf[ldbuf_idx], pf1);
|
||||||
|
|
Loading…
Reference in New Issue