From b4d980664a380ed4652f99ddf0ac9dec3be95545 Mon Sep 17 00:00:00 2001 From: javacoldbrew Date: Sun, 16 Dec 2018 03:48:38 -0500 Subject: [PATCH 1/4] Added documentation for setting up, modifying, and running the program --- README.md | 78 ++++++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 77 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 25579d6..7a4adc0 100644 --- a/README.md +++ b/README.md @@ -1 +1,77 @@ -# RubiksCubeAI \ No newline at end of file +# RubiksCubeAI +## Initial Setup +### Download and Install Processing 3: https://processing.org/download/ + +### Clone This Repository + +If you have git installed, type the following into your terminal: + +``` +git clone https://github.com/Code-Bullet/RubiksCubeAI.git +``` + +Else, download the zip file and unpack by clicking the green "Clone and download" button on the top right of the screen. + +### Open The Project Files +1. Open the Processing application +2. Click `File > Open` +3. Go to where you downloaded the files for this repository, the folder should be called `RubiksCubeAI` +4. Inside the `RubiksCubeAI` folder there should be another called `RubiksCube` +5. Inside the `RubiksCube` folder click on the file called `RubiksCube.pde` +6. You should now see `RubiksCube.pde` as well as the rest of the files opened up in the Processing application +7. Click the play button to start the program + +## Using The Program +1. Open `RubiksCube.pde` in the Processing application. It is located at. `RubiksCubeAI/RubiksCube/RubiksCube.pde`. (See ***Open The Project Files*** for additional information) +2. Press the ***Run*** button or click `Sketch > Run` +3. Press `L` to Lock/Unlock the cube +4. Press `Space` to initially scramble the cube +5. Press `Space` again to watch the program unscramble the cube + +## Modifying The Program + +### Changing Cube Size +Open `RubiksCube.pde` in the Processing application. It is located at. `RubiksCubeAI/RubiksCube/RubiksCube.pde`. (See ***Open The Project Files*** for additional information) + +On line 8, modify the variable called `numberOfSides` + +``` java +//dont do even sized cubes (it wont work) +//Have fun + +int numberOfSides = 25;//<<< change this to change the size of the cube +``` + +It is initially set to `25`, if you want the standard 3x3 Rubik Cube set `numberOfSides` to `3`. + +#### Example: + +``` java +//dont do even sized cubes (it wont work) +//Have fun + +int numberOfSides = 3;//<<< change this to change the size of the cube +``` + +### Changing Window Size +Open `RubiksCube.pde` in the Processing application. It is located at. `RubiksCubeAI/RubiksCube/RubiksCube.pde`. (See ***Open The Project Files*** for additional information) + +On line 96, modify the function called `size(1000, 1000, P3D);` + +``` java + size(1000, 1000, P3D); + //size(2000, 2000, P3D); //if you've got a 4K monitor then you can uncomment this out to have a bigger window, also make sure to comment out the line before +``` + +The first number is width and second number is height in pixels. + +Modify these to match your screen resolution. + +If you are unsure of your screen resolution go to: http://whatismyscreenresolution.net/ + +If your screen resolution is 1980x1080 modify line 96 like so: + +``` java + size(1920, 1080, P3D); + //size(2000, 2000, P3D); //if you've got a 4K monitor then you can uncomment this out to have a bigger window, also make sure to comment out the line before +``` From 1981edd3a1ff5608fd02d787a56e1f286286ab3c Mon Sep 17 00:00:00 2001 From: javacoldbrew Date: Sun, 16 Dec 2018 04:00:33 -0500 Subject: [PATCH 2/4] Added anchors for Open The Project Files section --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 7a4adc0..2ced55f 100644 --- a/README.md +++ b/README.md @@ -22,7 +22,7 @@ Else, download the zip file and unpack by clicking the green "Clone and download 7. Click the play button to start the program ## Using The Program -1. Open `RubiksCube.pde` in the Processing application. It is located at. `RubiksCubeAI/RubiksCube/RubiksCube.pde`. (See ***Open The Project Files*** for additional information) +1. Open `RubiksCube.pde` in the Processing application. It is located at. `RubiksCubeAI/RubiksCube/RubiksCube.pde`. (See [Open The Project Files](#open-the-project-files) for additional information) 2. Press the ***Run*** button or click `Sketch > Run` 3. Press `L` to Lock/Unlock the cube 4. Press `Space` to initially scramble the cube @@ -31,7 +31,7 @@ Else, download the zip file and unpack by clicking the green "Clone and download ## Modifying The Program ### Changing Cube Size -Open `RubiksCube.pde` in the Processing application. It is located at. `RubiksCubeAI/RubiksCube/RubiksCube.pde`. (See ***Open The Project Files*** for additional information) +Open `RubiksCube.pde` in the Processing application. It is located at. `RubiksCubeAI/RubiksCube/RubiksCube.pde`. (See [Open The Project Files](#open-the-project-files) for additional information) On line 8, modify the variable called `numberOfSides` @@ -54,7 +54,7 @@ int numberOfSides = 3;//<<< change this to change the size of the cube ``` ### Changing Window Size -Open `RubiksCube.pde` in the Processing application. It is located at. `RubiksCubeAI/RubiksCube/RubiksCube.pde`. (See ***Open The Project Files*** for additional information) +Open `RubiksCube.pde` in the Processing application. It is located at. `RubiksCubeAI/RubiksCube/RubiksCube.pde`. (See [Open The Project Files](#open-the-project-files) for additional information) On line 96, modify the function called `size(1000, 1000, P3D);` From cfaa19f64490c62d952207ef9f008e2258f4e440 Mon Sep 17 00:00:00 2001 From: Amish P Date: Mon, 17 Dec 2018 10:58:11 -0500 Subject: [PATCH 3/4] Changed 1980 to 1920 --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 2ced55f..5913c24 100644 --- a/README.md +++ b/README.md @@ -69,7 +69,7 @@ Modify these to match your screen resolution. If you are unsure of your screen resolution go to: http://whatismyscreenresolution.net/ -If your screen resolution is 1980x1080 modify line 96 like so: +If your screen resolution is 1920x1080 modify line 96 like so: ``` java size(1920, 1080, P3D); From cd15f7e4de21c780fe26b0731f5f50b182532524 Mon Sep 17 00:00:00 2001 From: Amish P Date: Mon, 17 Dec 2018 11:03:46 -0500 Subject: [PATCH 4/4] Changed Play Button to Run button or click Sketch > Run --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 5913c24..97cd147 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ Else, download the zip file and unpack by clicking the green "Clone and download 4. Inside the `RubiksCubeAI` folder there should be another called `RubiksCube` 5. Inside the `RubiksCube` folder click on the file called `RubiksCube.pde` 6. You should now see `RubiksCube.pde` as well as the rest of the files opened up in the Processing application -7. Click the play button to start the program +7. Press the ***Run*** button or click `Sketch > Run` ## Using The Program 1. Open `RubiksCube.pde` in the Processing application. It is located at. `RubiksCubeAI/RubiksCube/RubiksCube.pde`. (See [Open The Project Files](#open-the-project-files) for additional information)