initialisierung

This commit is contained in:
minabajalani 2025-02-09 16:55:30 +01:00
commit 8955085634
6 changed files with 77 additions and 0 deletions

8
.idea/.gitignore generated vendored Normal file
View File

@ -0,0 +1,8 @@
# Default ignored files
/shelf/
/workspace.xml
# Editor-based HTTP Client requests
/httpRequests/
# Datasource local storage ignored files
/dataSources/
/dataSources.local.xml

40
.idea/ManualBot.java generated Normal file
View File

@ -0,0 +1,40 @@
import java.util.Scanner;
public class ManualBot extends Bot {
public ManualBot(String [] args) {
super(args);
}
@Override
public char nextMove(View view) {
Scanner scanner = new Scanner(System.in);
System.out.print("Geben Sie einen Steuerbefehl ein (w/s/a/d/q): ");
String input = scanner.nextLine().trim().toLowerCase();
switch (input) {
case "w":
return '^';
case "s":
return 'v';
case "a":
return '<';
case "d":
return '>';
case "q":
System.out.println("Verbindung abgebrochen.");
System.exit(0);
return 0;
default:
System.out.println("Ungültiger Befehl. Bitte versuchen Sie es erneut.");
return nextMove(view);
}
}
public static void main(String[] args) {
ManualBot bot = new ManualBot(args);
bot.run();
}
}

9
.idea/SnakeBot.iml generated Normal file
View File

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="JAVA_MODULE" version="4">
<component name="NewModuleRootManager" inherit-compiler-output="true">
<exclude-output />
<content url="file://$MODULE_DIR$" />
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>

6
.idea/misc.xml generated Normal file
View File

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectRootManager" version="2" languageLevel="JDK_X" default="true" project-jdk-name="openjdk-23" project-jdk-type="JavaSDK">
<output url="file://$PROJECT_DIR$/out" />
</component>
</project>

8
.idea/modules.xml generated Normal file
View File

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/SnakeBot.iml" filepath="$PROJECT_DIR$/.idea/SnakeBot.iml" />
</modules>
</component>
</project>

6
.idea/vcs.xml generated Normal file
View File

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="" vcs="Git" />
</component>
</project>