Add missing guild information #466
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The Java API is missing a number of guild features (such as
ranks, as pointed out in #463), so this PR aims to add those, as well as refactoring areas of the Java API relating to guilds.GuildReply.java
Boolean)Guild.getRanks()Guild.getPreferredGames()Guild.getExperienceForGame(GameType)- from web API'sguildExpByGameTypefieldGuild.getAchievementHighScore(GuildAchievement)- from web API'sachievementsfieldMember.getExperienceEarned(LocalDate)- from web API'smembers[i].expHistoryfield
get_id() -> getId(),getCreated() -> getCreationDate(), etc)
Guild.getLegacyRanking()0for guilds created after the guild update (those without a ranking)0was also used to represent 1st place (for "The Foundation" guild).-1in those cases.Banner.java
Banner.getBase() --> Banner.getBaseColor()Pattern.getPattern() --> Pattern.getType()GetGuildExample.java
GetPlayerExampleGuildAchievement.java
getAchievementHighScore()in theGuildclassResolves #463
EDIT
When making this, I purposefully left out 3 fields in particular. The reason for this is that they represent the guild's internal state, and I wouldn't be very surprised if the devs eventually chose to hide/remove them (like they have in the past with certain fields in the "player" endpoint). These fields are:
If there's any demand for these fields and the devs can confirm that they're intended to be public, I'd be fine adding them. But I'd rather not add them in the first place if there's any chance of them suddenly becoming inaccessible and breaking someone's app.guild.chatMuteguild.members[i].mutedTillguild.hideGmTag