first commit, frontend ish done
							
								
								
									
										15
									
								
								.classpath
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,15 @@ | |||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| <classpath> | ||||
| 	<classpathentry kind="src" path="src"/> | ||||
| 	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-17"> | ||||
| 		<attributes> | ||||
| 			<attribute name="module" value="true"/> | ||||
| 		</attributes> | ||||
| 	</classpathentry> | ||||
| 	<classpathentry kind="con" path="org.eclipse.fx.ide.jdt.core.JAVAFX_CONTAINER"> | ||||
| 		<attributes> | ||||
| 			<attribute name="module" value="true"/> | ||||
| 		</attributes> | ||||
| 	</classpathentry> | ||||
| 	<classpathentry kind="output" path="bin"/> | ||||
| </classpath> | ||||
							
								
								
									
										23
									
								
								.project
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,23 @@ | |||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| <projectDescription> | ||||
| 	<name>Wordle</name> | ||||
| 	<comment></comment> | ||||
| 	<projects> | ||||
| 	</projects> | ||||
| 	<buildSpec> | ||||
| 		<buildCommand> | ||||
| 			<name>org.eclipse.jdt.core.javabuilder</name> | ||||
| 			<arguments> | ||||
| 			</arguments> | ||||
| 		</buildCommand> | ||||
| 		<buildCommand> | ||||
| 			<name>org.eclipse.xtext.ui.shared.xtextBuilder</name> | ||||
| 			<arguments> | ||||
| 			</arguments> | ||||
| 		</buildCommand> | ||||
| 	</buildSpec> | ||||
| 	<natures> | ||||
| 		<nature>org.eclipse.xtext.ui.shared.xtextNature</nature> | ||||
| 		<nature>org.eclipse.jdt.core.javanature</nature> | ||||
| 	</natures> | ||||
| </projectDescription> | ||||
							
								
								
									
										2
									
								
								.settings/org.eclipse.core.resources.prefs
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,2 @@ | |||
| eclipse.preferences.version=1 | ||||
| encoding/<project>=UTF-8 | ||||
							
								
								
									
										14
									
								
								.settings/org.eclipse.jdt.core.prefs
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,14 @@ | |||
| eclipse.preferences.version=1 | ||||
| org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled | ||||
| org.eclipse.jdt.core.compiler.codegen.targetPlatform=17 | ||||
| org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve | ||||
| org.eclipse.jdt.core.compiler.compliance=17 | ||||
| org.eclipse.jdt.core.compiler.debug.lineNumber=generate | ||||
| org.eclipse.jdt.core.compiler.debug.localVariable=generate | ||||
| org.eclipse.jdt.core.compiler.debug.sourceFile=generate | ||||
| org.eclipse.jdt.core.compiler.problem.assertIdentifier=error | ||||
| org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled | ||||
| org.eclipse.jdt.core.compiler.problem.enumIdentifier=error | ||||
| org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning | ||||
| org.eclipse.jdt.core.compiler.release=enabled | ||||
| org.eclipse.jdt.core.compiler.source=17 | ||||
							
								
								
									
										
											BIN
										
									
								
								bin/Controllers/CreditsSceneController.class
									
										
									
									
									
										Normal file
									
								
							
							
						
						
							
								
								
									
										
											BIN
										
									
								
								bin/Controllers/GameSceneController.class
									
										
									
									
									
										Normal file
									
								
							
							
						
						
							
								
								
									
										
											BIN
										
									
								
								bin/Controllers/MainSceneController.class
									
										
									
									
									
										Normal file
									
								
							
							
						
						
							
								
								
									
										
											BIN
										
									
								
								bin/Controllers/RulesSceneController.class
									
										
									
									
									
										Normal file
									
								
							
							
						
						
							
								
								
									
										25
									
								
								bin/FXML/CreditsScene.fxml
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,25 @@ | |||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| 
 | ||||
| <?import javafx.scene.control.Button?> | ||||
| <?import javafx.scene.control.Label?> | ||||
| <?import javafx.scene.layout.AnchorPane?> | ||||
| <?import javafx.scene.text.Font?> | ||||
| 
 | ||||
| <AnchorPane maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="500.0" prefWidth="400.0" style="-fx-background-color: #252525;" xmlns="http://javafx.com/javafx/19" xmlns:fx="http://javafx.com/fxml/1" fx:controller="Controllers.CreditsSceneController"> | ||||
|    <children> | ||||
|       <Button layoutX="113.0" layoutY="438.0" mnemonicParsing="false" onAction="#btnMenuClicked" prefHeight="27.0" prefWidth="174.0" style="-fx-background-color: white;" text="Go back to Menu"> | ||||
|          <font> | ||||
|             <Font name="Bodoni MT Black" size="12.0" /> | ||||
|          </font></Button> | ||||
|       <Label layoutX="142.0" layoutY="39.0" text="Credits" textFill="WHITE"> | ||||
|          <font> | ||||
|             <Font name="System Bold" size="36.0" /> | ||||
|          </font> | ||||
|       </Label> | ||||
|       <Label layoutX="15.0" layoutY="92.0" prefHeight="290.0" prefWidth="372.0" textFill="WHITE"> | ||||
|          <font> | ||||
|             <Font size="18.0" /> | ||||
|          </font> | ||||
|       </Label> | ||||
|    </children> | ||||
| </AnchorPane> | ||||
							
								
								
									
										56
									
								
								bin/FXML/GameScene.fxml
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,56 @@ | |||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| 
 | ||||
| <?import javafx.scene.control.Button?> | ||||
| <?import javafx.scene.control.Label?> | ||||
| <?import javafx.scene.control.TextField?> | ||||
| <?import javafx.scene.image.Image?> | ||||
| <?import javafx.scene.image.ImageView?> | ||||
| <?import javafx.scene.layout.AnchorPane?> | ||||
| <?import javafx.scene.text.Font?> | ||||
| 
 | ||||
| <AnchorPane maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="500.0" prefWidth="400.0" style="-fx-background-color: #252525;" xmlns="http://javafx.com/javafx/19" xmlns:fx="http://javafx.com/fxml/1" fx:controller="Controllers.GameSceneController"> | ||||
|    <children> | ||||
|       <ImageView fitHeight="204.0" fitWidth="210.0" layoutX="98.0" layoutY="-34.0" pickOnBounds="true" preserveRatio="true"> | ||||
|          <image> | ||||
|             <Image url="@../logo4.jpg" /> | ||||
|          </image> | ||||
|       </ImageView> | ||||
|       <Button layoutX="335.0" layoutY="448.0" mnemonicParsing="false" onAction="#btnResetClicked" prefHeight="10.0" prefWidth="58.0" style="-fx-background-color: white;" text="Reset" textFill="RED"> | ||||
|          <font> | ||||
|             <Font name="Bodoni MT Black" size="12.0" /> | ||||
|          </font> | ||||
|       </Button> | ||||
|       <TextField layoutX="74.0" layoutY="442.0" prefHeight="33.0" prefWidth="186.0" promptText="Write a word here!" style="-fx-background-color: #5166A9; -fx-border-color: white;" /> | ||||
|       <Button layoutX="269.0" layoutY="442.0" mnemonicParsing="false" onAction="#btnGoClicked" prefHeight="33.0" prefWidth="58.0" style="-fx-background-color: white;" text="Go"> | ||||
|          <font> | ||||
|             <Font name="Bodoni MT Black" size="14.0" /> | ||||
|          </font> | ||||
|       </Button> | ||||
|       <Label fx:id="lb1" layoutX="55.0" layoutY="134.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="115.0" layoutY="134.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="175.0" layoutY="134.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="235.0" layoutY="134.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="295.0" layoutY="134.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="55.0" layoutY="194.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="115.0" layoutY="194.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="175.0" layoutY="194.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="235.0" layoutY="194.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="295.0" layoutY="194.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="55.0" layoutY="254.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="115.0" layoutY="254.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="175.0" layoutY="254.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="235.0" layoutY="254.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="295.0" layoutY="254.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="55.0" layoutY="314.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="115.0" layoutY="314.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="175.0" layoutY="314.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="235.0" layoutY="314.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="295.0" layoutY="314.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="55.0" layoutY="374.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="115.0" layoutY="374.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="175.0" layoutY="374.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="235.0" layoutY="374.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="295.0" layoutY="374.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Button layoutX="130.0" layoutY="14.0" mnemonicParsing="false" onAction="#btnMenuClicked" prefHeight="107.0" prefWidth="148.0" style="-fx-background-color: transparent;" textFill="TRANSPARENT" /> | ||||
|    </children> | ||||
| </AnchorPane> | ||||
							
								
								
									
										32
									
								
								bin/FXML/MainScene.fxml
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,32 @@ | |||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| 
 | ||||
| <?import javafx.scene.control.Button?> | ||||
| <?import javafx.scene.image.Image?> | ||||
| <?import javafx.scene.image.ImageView?> | ||||
| <?import javafx.scene.layout.AnchorPane?> | ||||
| <?import javafx.scene.text.Font?> | ||||
| 
 | ||||
| <AnchorPane maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="500.0" prefWidth="400.0" style="-fx-background-color: #252525;" xmlns="http://javafx.com/javafx/19" xmlns:fx="http://javafx.com/fxml/1" fx:controller="Controllers.MainSceneController"> | ||||
|    <children> | ||||
|       <ImageView fitHeight="400.0" fitWidth="413.0" layoutY="-48.0" pickOnBounds="true" preserveRatio="true"> | ||||
|          <image> | ||||
|             <Image url="@../logo4.jpg" /> | ||||
|          </image> | ||||
|       </ImageView> | ||||
|       <Button layoutX="115.0" layoutY="275.0" mnemonicParsing="false" onAction="#btnPlayClicked" prefHeight="53.0" prefWidth="171.0" style="-fx-background-color: white;" text="Play"> | ||||
|          <font> | ||||
|             <Font name="Bodoni MT Black" size="24.0" /> | ||||
|          </font> | ||||
|       </Button> | ||||
|       <Button layoutX="115.0" layoutY="342.0" mnemonicParsing="false" onAction="#btnRulesClicked" prefHeight="53.0" prefWidth="171.0" style="-fx-background-color: white;" text="How to Play"> | ||||
|          <font> | ||||
|             <Font name="Bodoni MT Black" size="18.0" /> | ||||
|          </font> | ||||
|       </Button> | ||||
|       <Button layoutX="115.0" layoutY="410.0" mnemonicParsing="false" onAction="#btnCreditsClicked" prefHeight="53.0" prefWidth="171.0" style="-fx-background-color: white;" text="Credits"> | ||||
|          <font> | ||||
|             <Font name="Bodoni MT Black" size="24.0" /> | ||||
|          </font> | ||||
|       </Button> | ||||
|    </children> | ||||
| </AnchorPane> | ||||
							
								
								
									
										25
									
								
								bin/FXML/RulesScene.fxml
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,25 @@ | |||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| 
 | ||||
| <?import javafx.scene.control.Button?> | ||||
| <?import javafx.scene.control.Label?> | ||||
| <?import javafx.scene.layout.AnchorPane?> | ||||
| <?import javafx.scene.text.Font?> | ||||
| 
 | ||||
| <AnchorPane maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="500.0" prefWidth="400.0" style="-fx-background-color: #252525;" xmlns="http://javafx.com/javafx/19" xmlns:fx="http://javafx.com/fxml/1" fx:controller="Controllers.RulesSceneController"> | ||||
|    <children> | ||||
|       <Button layoutX="113.0" layoutY="438.0" mnemonicParsing="false" onAction="#btnMenuClicked" prefHeight="27.0" prefWidth="174.0" style="-fx-background-color: white;" text="Go back to Menu"> | ||||
|          <font> | ||||
|             <Font name="Bodoni MT Black" size="12.0" /> | ||||
|          </font></Button> | ||||
|       <Label layoutX="98.0" layoutY="39.0" text="How to Play" textFill="WHITE"> | ||||
|          <font> | ||||
|             <Font name="System Bold" size="36.0" /> | ||||
|          </font> | ||||
|       </Label> | ||||
|       <Label layoutX="15.0" layoutY="92.0" prefHeight="290.0" prefWidth="372.0" text="1. Lorem ipasum ...
2. tseter
3. wow
4. ok
5. shit" textFill="WHITE"> | ||||
|          <font> | ||||
|             <Font size="18.0" /> | ||||
|          </font> | ||||
|       </Label> | ||||
|    </children> | ||||
| </AnchorPane> | ||||
							
								
								
									
										1
									
								
								bin/application.css
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1 @@ | |||
| /* JavaFX CSS - Leave this comment until you have at least create one rule which uses -fx-Property */ | ||||
							
								
								
									
										
											BIN
										
									
								
								bin/application/Main.class
									
										
									
									
									
										Normal file
									
								
							
							
						
						
							
								
								
									
										
											BIN
										
									
								
								bin/logo.jpg
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 32 KiB | 
							
								
								
									
										
											BIN
										
									
								
								bin/logo.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 13 KiB | 
							
								
								
									
										
											BIN
										
									
								
								bin/logo2.jpg
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 39 KiB | 
							
								
								
									
										
											BIN
										
									
								
								bin/logo3.jpg
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 31 KiB | 
							
								
								
									
										
											BIN
										
									
								
								bin/logo4.jpg
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 32 KiB | 
							
								
								
									
										8
									
								
								build.fxbuild
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,8 @@ | |||
| <?xml version="1.0" encoding="ASCII"?> | ||||
| <anttasks:AntTask xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:anttasks="http://org.eclipse.fx.ide.jdt/1.0" buildDirectory="${project}/build"> | ||||
|   <deploy> | ||||
|     <application name="Wordle"/> | ||||
|     <info/> | ||||
|   </deploy> | ||||
|   <signjar/> | ||||
| </anttasks:AntTask> | ||||
							
								
								
									
										26
									
								
								src/Controllers/CreditsSceneController.java
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,26 @@ | |||
| package Controllers; | ||||
| 
 | ||||
| import java.io.IOException; | ||||
| 
 | ||||
| import javafx.event.ActionEvent; | ||||
| import javafx.fxml.FXML; | ||||
| import javafx.fxml.FXMLLoader; | ||||
| import javafx.scene.Node; | ||||
| import javafx.scene.Parent; | ||||
| import javafx.scene.Scene; | ||||
| import javafx.stage.Stage; | ||||
| 
 | ||||
| public class CreditsSceneController { | ||||
| 
 | ||||
| 	// Event Listener on Button.onAction | ||||
| 	@FXML | ||||
| 	public void btnMenuClicked(ActionEvent event) throws IOException { | ||||
| 		Parent creditsSceneParent = FXMLLoader.load(getClass().getResource("/FXML/MainScene.fxml")); | ||||
| 		Scene creditsScene = new Scene(creditsSceneParent); | ||||
| 		 | ||||
| 		Stage window = (Stage) ((Node)event.getSource()).getScene().getWindow(); | ||||
| 		window.setTitle("Sids Wordle"); | ||||
| 		window.setScene(creditsScene); | ||||
| 		window.show(); | ||||
| 	} | ||||
| } | ||||
							
								
								
									
										36
									
								
								src/Controllers/GameSceneController.java
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,36 @@ | |||
| package Controllers; | ||||
| 
 | ||||
| import java.io.IOException; | ||||
| 
 | ||||
| import javafx.event.ActionEvent; | ||||
| import javafx.fxml.FXML; | ||||
| import javafx.fxml.FXMLLoader; | ||||
| import javafx.scene.Node; | ||||
| import javafx.scene.Parent; | ||||
| import javafx.scene.Scene; | ||||
| import javafx.stage.Stage; | ||||
| 
 | ||||
| public class GameSceneController { | ||||
| 
 | ||||
| 	// Event Listener on Button.onAction | ||||
| 	@FXML | ||||
| 	public void btnResetClicked(ActionEvent event) { | ||||
| 		// TODO Autogenerated | ||||
| 	} | ||||
| 	// Event Listener on Button.onAction | ||||
| 	@FXML | ||||
| 	public void btnGoClicked(ActionEvent event) { | ||||
| 		// TODO Autogenerated | ||||
| 	} | ||||
| 	// Event Listener on Button.onAction | ||||
| 	@FXML | ||||
| 	public void btnMenuClicked(ActionEvent event) throws IOException { | ||||
| 		Parent gameSceneParent = FXMLLoader.load(getClass().getResource("/FXML/MainScene.fxml")); | ||||
| 		Scene gameScene = new Scene(gameSceneParent); | ||||
| 		 | ||||
| 		Stage window = (Stage) ((Node)event.getSource()).getScene().getWindow(); | ||||
| 		window.setTitle("Sids Wordle"); | ||||
| 		window.setScene(gameScene); | ||||
| 		window.show(); | ||||
| 	} | ||||
| } | ||||
							
								
								
									
										49
									
								
								src/Controllers/MainSceneController.java
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,49 @@ | |||
| package Controllers; | ||||
| 
 | ||||
| import java.io.IOException; | ||||
| 
 | ||||
| import javafx.event.ActionEvent; | ||||
| import javafx.fxml.FXML; | ||||
| import javafx.fxml.FXMLLoader; | ||||
| import javafx.scene.Node; | ||||
| import javafx.scene.Parent; | ||||
| import javafx.scene.Scene; | ||||
| import javafx.stage.Stage; | ||||
| 
 | ||||
| public class MainSceneController { | ||||
| 
 | ||||
| 	// Event Listener on Button.onAction | ||||
| 	@FXML | ||||
| 	public void btnPlayClicked(ActionEvent event) throws IOException { | ||||
| 		Parent rulesSceneParent = FXMLLoader.load(getClass().getResource("/FXML/GameScene.fxml")); | ||||
| 		Scene rulesScene = new Scene(rulesSceneParent); | ||||
| 		 | ||||
| 		Stage window = (Stage) ((Node)event.getSource()).getScene().getWindow(); | ||||
| 		window.setTitle("Sids Wordle"); | ||||
| 		window.setScene(rulesScene); | ||||
| 		window.show(); | ||||
| 	} | ||||
| 	// Event Listener on Button.onAction | ||||
| 	@FXML | ||||
| 	public void btnRulesClicked(ActionEvent event) throws IOException { | ||||
| 		Parent rulesSceneParent = FXMLLoader.load(getClass().getResource("/FXML/RulesScene.fxml")); | ||||
| 		Scene rulesScene = new Scene(rulesSceneParent); | ||||
| 		 | ||||
| 		Stage window = (Stage) ((Node)event.getSource()).getScene().getWindow(); | ||||
| 		window.setTitle("How to Play"); | ||||
| 		window.setScene(rulesScene); | ||||
| 		window.show(); | ||||
| 	} | ||||
| 	 | ||||
| 	// Event Listener on Button.onAction | ||||
| 	@FXML | ||||
| 	public void btnCreditsClicked(ActionEvent event) throws IOException { | ||||
| 		Parent rulesSceneParent = FXMLLoader.load(getClass().getResource("/FXML/CreditsScene.fxml")); | ||||
| 		Scene rulesScene = new Scene(rulesSceneParent); | ||||
| 		 | ||||
| 		Stage window = (Stage) ((Node)event.getSource()).getScene().getWindow(); | ||||
| 		window.setTitle("Credits"); | ||||
| 		window.setScene(rulesScene); | ||||
| 		window.show(); | ||||
| 	} | ||||
| } | ||||
							
								
								
									
										26
									
								
								src/Controllers/RulesSceneController.java
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,26 @@ | |||
| package Controllers; | ||||
| 
 | ||||
| import java.io.IOException; | ||||
| 
 | ||||
| import javafx.event.ActionEvent; | ||||
| import javafx.fxml.FXML; | ||||
| import javafx.fxml.FXMLLoader; | ||||
| import javafx.scene.Node; | ||||
| import javafx.scene.Parent; | ||||
| import javafx.scene.Scene; | ||||
| import javafx.stage.Stage; | ||||
| 
 | ||||
| public class RulesSceneController { | ||||
| 
 | ||||
| 	// Event Listener on Button.onAction | ||||
| 	@FXML | ||||
| 	public void btnMenuClicked(ActionEvent event) throws IOException { | ||||
| 		Parent rulesSceneParent = FXMLLoader.load(getClass().getResource("/FXML/MainScene.fxml")); | ||||
| 		Scene rulesScene = new Scene(rulesSceneParent); | ||||
| 		 | ||||
| 		Stage window = (Stage) ((Node)event.getSource()).getScene().getWindow(); | ||||
| 		window.setTitle("Sids Wordle"); | ||||
| 		window.setScene(rulesScene); | ||||
| 		window.show(); | ||||
| 	} | ||||
| } | ||||
							
								
								
									
										25
									
								
								src/FXML/CreditsScene.fxml
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,25 @@ | |||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| 
 | ||||
| <?import javafx.scene.control.Button?> | ||||
| <?import javafx.scene.control.Label?> | ||||
| <?import javafx.scene.layout.AnchorPane?> | ||||
| <?import javafx.scene.text.Font?> | ||||
| 
 | ||||
| <AnchorPane maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="500.0" prefWidth="400.0" style="-fx-background-color: #252525;" xmlns="http://javafx.com/javafx/19" xmlns:fx="http://javafx.com/fxml/1" fx:controller="Controllers.CreditsSceneController"> | ||||
|    <children> | ||||
|       <Button layoutX="113.0" layoutY="438.0" mnemonicParsing="false" onAction="#btnMenuClicked" prefHeight="27.0" prefWidth="174.0" style="-fx-background-color: white;" text="Go back to Menu"> | ||||
|          <font> | ||||
|             <Font name="Bodoni MT Black" size="12.0" /> | ||||
|          </font></Button> | ||||
|       <Label layoutX="142.0" layoutY="39.0" text="Credits" textFill="WHITE"> | ||||
|          <font> | ||||
|             <Font name="System Bold" size="36.0" /> | ||||
|          </font> | ||||
|       </Label> | ||||
|       <Label layoutX="15.0" layoutY="92.0" prefHeight="290.0" prefWidth="372.0" textFill="WHITE"> | ||||
|          <font> | ||||
|             <Font size="18.0" /> | ||||
|          </font> | ||||
|       </Label> | ||||
|    </children> | ||||
| </AnchorPane> | ||||
							
								
								
									
										56
									
								
								src/FXML/GameScene.fxml
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,56 @@ | |||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| 
 | ||||
| <?import javafx.scene.control.Button?> | ||||
| <?import javafx.scene.control.Label?> | ||||
| <?import javafx.scene.control.TextField?> | ||||
| <?import javafx.scene.image.Image?> | ||||
| <?import javafx.scene.image.ImageView?> | ||||
| <?import javafx.scene.layout.AnchorPane?> | ||||
| <?import javafx.scene.text.Font?> | ||||
| 
 | ||||
| <AnchorPane maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="500.0" prefWidth="400.0" style="-fx-background-color: #252525;" xmlns="http://javafx.com/javafx/19" xmlns:fx="http://javafx.com/fxml/1" fx:controller="Controllers.GameSceneController"> | ||||
|    <children> | ||||
|       <ImageView fitHeight="204.0" fitWidth="210.0" layoutX="98.0" layoutY="-34.0" pickOnBounds="true" preserveRatio="true"> | ||||
|          <image> | ||||
|             <Image url="@../logo4.jpg" /> | ||||
|          </image> | ||||
|       </ImageView> | ||||
|       <Button layoutX="335.0" layoutY="448.0" mnemonicParsing="false" onAction="#btnResetClicked" prefHeight="10.0" prefWidth="58.0" style="-fx-background-color: white;" text="Reset" textFill="RED"> | ||||
|          <font> | ||||
|             <Font name="Bodoni MT Black" size="12.0" /> | ||||
|          </font> | ||||
|       </Button> | ||||
|       <TextField layoutX="74.0" layoutY="442.0" prefHeight="33.0" prefWidth="186.0" promptText="Write a word here!" style="-fx-background-color: #5166A9; -fx-border-color: white;" /> | ||||
|       <Button layoutX="269.0" layoutY="442.0" mnemonicParsing="false" onAction="#btnGoClicked" prefHeight="33.0" prefWidth="58.0" style="-fx-background-color: white;" text="Go"> | ||||
|          <font> | ||||
|             <Font name="Bodoni MT Black" size="14.0" /> | ||||
|          </font> | ||||
|       </Button> | ||||
|       <Label fx:id="lb1" layoutX="55.0" layoutY="134.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="115.0" layoutY="134.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="175.0" layoutY="134.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="235.0" layoutY="134.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="295.0" layoutY="134.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="55.0" layoutY="194.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="115.0" layoutY="194.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="175.0" layoutY="194.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="235.0" layoutY="194.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="295.0" layoutY="194.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="55.0" layoutY="254.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="115.0" layoutY="254.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="175.0" layoutY="254.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="235.0" layoutY="254.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="295.0" layoutY="254.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="55.0" layoutY="314.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="115.0" layoutY="314.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="175.0" layoutY="314.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="235.0" layoutY="314.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="295.0" layoutY="314.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="55.0" layoutY="374.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="115.0" layoutY="374.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="175.0" layoutY="374.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="235.0" layoutY="374.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Label layoutX="295.0" layoutY="374.0" prefHeight="50.0" prefWidth="50.0" style="-fx-background-color: lightgrey;" /> | ||||
|       <Button layoutX="130.0" layoutY="14.0" mnemonicParsing="false" onAction="#btnMenuClicked" prefHeight="107.0" prefWidth="148.0" style="-fx-background-color: transparent;" textFill="TRANSPARENT" /> | ||||
|    </children> | ||||
| </AnchorPane> | ||||
							
								
								
									
										32
									
								
								src/FXML/MainScene.fxml
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,32 @@ | |||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| 
 | ||||
| <?import javafx.scene.control.Button?> | ||||
| <?import javafx.scene.image.Image?> | ||||
| <?import javafx.scene.image.ImageView?> | ||||
| <?import javafx.scene.layout.AnchorPane?> | ||||
| <?import javafx.scene.text.Font?> | ||||
| 
 | ||||
| <AnchorPane maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="500.0" prefWidth="400.0" style="-fx-background-color: #252525;" xmlns="http://javafx.com/javafx/19" xmlns:fx="http://javafx.com/fxml/1" fx:controller="Controllers.MainSceneController"> | ||||
|    <children> | ||||
|       <ImageView fitHeight="400.0" fitWidth="413.0" layoutY="-48.0" pickOnBounds="true" preserveRatio="true"> | ||||
|          <image> | ||||
|             <Image url="@../logo4.jpg" /> | ||||
|          </image> | ||||
|       </ImageView> | ||||
|       <Button layoutX="115.0" layoutY="275.0" mnemonicParsing="false" onAction="#btnPlayClicked" prefHeight="53.0" prefWidth="171.0" style="-fx-background-color: white;" text="Play"> | ||||
|          <font> | ||||
|             <Font name="Bodoni MT Black" size="24.0" /> | ||||
|          </font> | ||||
|       </Button> | ||||
|       <Button layoutX="115.0" layoutY="342.0" mnemonicParsing="false" onAction="#btnRulesClicked" prefHeight="53.0" prefWidth="171.0" style="-fx-background-color: white;" text="How to Play"> | ||||
|          <font> | ||||
|             <Font name="Bodoni MT Black" size="18.0" /> | ||||
|          </font> | ||||
|       </Button> | ||||
|       <Button layoutX="115.0" layoutY="410.0" mnemonicParsing="false" onAction="#btnCreditsClicked" prefHeight="53.0" prefWidth="171.0" style="-fx-background-color: white;" text="Credits"> | ||||
|          <font> | ||||
|             <Font name="Bodoni MT Black" size="24.0" /> | ||||
|          </font> | ||||
|       </Button> | ||||
|    </children> | ||||
| </AnchorPane> | ||||
							
								
								
									
										25
									
								
								src/FXML/RulesScene.fxml
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,25 @@ | |||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| 
 | ||||
| <?import javafx.scene.control.Button?> | ||||
| <?import javafx.scene.control.Label?> | ||||
| <?import javafx.scene.layout.AnchorPane?> | ||||
| <?import javafx.scene.text.Font?> | ||||
| 
 | ||||
| <AnchorPane maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="500.0" prefWidth="400.0" style="-fx-background-color: #252525;" xmlns="http://javafx.com/javafx/19" xmlns:fx="http://javafx.com/fxml/1" fx:controller="Controllers.RulesSceneController"> | ||||
|    <children> | ||||
|       <Button layoutX="113.0" layoutY="438.0" mnemonicParsing="false" onAction="#btnMenuClicked" prefHeight="27.0" prefWidth="174.0" style="-fx-background-color: white;" text="Go back to Menu"> | ||||
|          <font> | ||||
|             <Font name="Bodoni MT Black" size="12.0" /> | ||||
|          </font></Button> | ||||
|       <Label layoutX="98.0" layoutY="39.0" text="How to Play" textFill="WHITE"> | ||||
|          <font> | ||||
|             <Font name="System Bold" size="36.0" /> | ||||
|          </font> | ||||
|       </Label> | ||||
|       <Label layoutX="15.0" layoutY="92.0" prefHeight="290.0" prefWidth="372.0" text="1. Lorem ipasum ...
2. tseter
3. wow
4. ok
5. shit" textFill="WHITE"> | ||||
|          <font> | ||||
|             <Font size="18.0" /> | ||||
|          </font> | ||||
|       </Label> | ||||
|    </children> | ||||
| </AnchorPane> | ||||
							
								
								
									
										1
									
								
								src/application.css
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1 @@ | |||
| /* JavaFX CSS - Leave this comment until you have at least create one rule which uses -fx-Property */ | ||||
							
								
								
									
										28
									
								
								src/application/Main.java
									
										
									
									
									
										Normal file
									
								
							
							
						
						|  | @ -0,0 +1,28 @@ | |||
| package application; | ||||
| 	 | ||||
| import javafx.application.Application; | ||||
| import javafx.fxml.FXMLLoader; | ||||
| import javafx.scene.Parent; | ||||
| import javafx.scene.Scene; | ||||
| import javafx.stage.Stage; | ||||
| 
 | ||||
| 
 | ||||
| public class Main extends Application { | ||||
| 	@Override | ||||
| 	public void start(Stage primaryStage) { | ||||
| 		try { | ||||
| 			Parent root = FXMLLoader.load(getClass().getResource("/FXML/MainScene.fxml")); | ||||
| 			Scene scene = new Scene(root); | ||||
| 			 | ||||
| 			primaryStage.setTitle("Sids Wordle!"); | ||||
| 			primaryStage.setScene(scene); | ||||
| 			primaryStage.show(); | ||||
| 		} catch(Exception e) { | ||||
| 			e.printStackTrace(); | ||||
| 		} | ||||
| 	} | ||||
| 	 | ||||
| 	public static void main(String[] args) { | ||||
| 		launch(args); | ||||
| 	} | ||||
| } | ||||
							
								
								
									
										
											BIN
										
									
								
								src/logo.jpg
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 32 KiB | 
							
								
								
									
										
											BIN
										
									
								
								src/logo.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 13 KiB | 
							
								
								
									
										
											BIN
										
									
								
								src/logo2.jpg
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 39 KiB | 
							
								
								
									
										
											BIN
										
									
								
								src/logo3.jpg
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 31 KiB | 
							
								
								
									
										
											BIN
										
									
								
								src/logo4.jpg
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 32 KiB | 
 Sid
						Sid