Skip to content

Fix Java bindings using short instead of boolean for some methods#108

Open
HalfVoxel wants to merge 1 commit into
battlecode:masterfrom
HalfVoxel:master
Open

Fix Java bindings using short instead of boolean for some methods#108
HalfVoxel wants to merge 1 commit into
battlecode:masterfrom
HalfVoxel:master

Conversation

@HalfVoxel

@HalfVoxel HalfVoxel commented Jan 13, 2018

Copy link
Copy Markdown
Contributor

Now things like this work

if (gc.queueResearch(UnitType.Knight)) {
    System.out.println("Bools work!");
}

instead of having to do

if (gc.queueResearch(UnitType.Knight) == 1) {
    System.out.println("Bools work!");
}

@kazimuth

Copy link
Copy Markdown
Contributor

Oh, dang, hm.

Unfortunately this is a breaking-change to the API, and given our update system I don't want to break people's code underneath them. Maybe it would be best to define some new methods called e.g. queueResearchBool? That will require some plumbing though.

@HalfVoxel

Copy link
Copy Markdown
Contributor Author

Well... Considering how much people are complaining about it being that way in Discord. I don't think people will complain much when it is fixed.

@Daspy11

Daspy11 commented Jan 14, 2018

Copy link
Copy Markdown

please just fix it. tag everyone in the discord. it's awful.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants