debut rules implementation

pc deconne je finirai a la maison
This commit is contained in:
Timéo 2024-05-28 16:13:31 +02:00
parent ae82901690
commit a461769f93
2 changed files with 4 additions and 4 deletions

View File

@ -137,9 +137,9 @@ public class Simulator extends Thread {
// Apply Game of Life rules
//for (int x = 0; x < getWidth(); x++) {
// for (int y = 0; y < getHeight(); y++) {
// int aliveNeighbors = countAliveNeighbors(x, y);
for (int x = 0; x < getWidth(); x++) {
for (int y = 0; y < getHeight(); y++) {
int aliveNeighbors = countAliveNeighbors(x, y);
// if (world[x][y] == 1) {
// newWorld[x][y] = (aliveNeighbors < 2 || aliveNeighbors > 3) ? 0 : 1;
// } else {

View File

@ -307,7 +307,7 @@ public class MyInterface extends JFrame {
//trying to make the baseworld
//to integrate the baseworld
public void clicLoadFileButtonCSV(String fileName) {
Simulator loadedSim = new Simulator(this);
//String fileName="baseworld.csv";