Which version of Java are you using for running Robocode? I recommend that you use Java 11 or never, e.g. Java 17.
You can check this by running this command from the command line:
java -version
You can also try to execute Options -> 'Clean robot cache' from the menu in Robocode.
Also, notice if error messages are being written out in the console etc.