Halite Home

JAR Pogramming Language?


#1

Possible Bug

Some of the people on the leaderboard have their language as JAR.
I think it should be Java.


#2

Nope. They submitted a MyBot.jar file. They could be using any JVM language. To make this look nicer, we plan on adding support for language name overriding.


#3

Yup! My language says JAR and I use Kotlin.


#4

Awesome! Have you thought about submitting a Kotlin starter kit?


#5

I might open source a Gradle based starter project that can be used with any JVM language to automate the creation of MyBot.zip containing MyBot.jar. It follows a typical Java/Kotlin/Groovy/etc. folder structure and works well with IDEs out of the box.

My bot actually uses the Java GameMap and Networking implementations instead of rewriting them in Kotlin - getting started with Kotlin just means writing your MyBot class.


#6

To make this look nicer, we plan on adding support for language name overriding.

This is now supported. Just add a LANGUAGE file to the root directory of your submission and put your desired language name in there.


#7

I submitted a MyBot.jar built with Clojure. It seems the programming language is detected fine but it complained main class cannot be loaded. Same jar did run fine on my local machine (with: java -jar MyBot.jar) and I can see the main class in the jar (MyBot.class and MyBot$_main.class). Any idea?

Here is the error.log:
--- Init ---
Error: Could not find or load main class MyBot
--- Bot used 340 milliseconds ---


--- Frame #1 ---

ERRORED!
No response received.


#8

I was having the same problem with a Clojure bot initially. I found my problem was that I needed to submit my jar within a zip. So zip -r myzipfile.zip MyBot.jar and then submit the zip file.