use of no.stelar7.api.r4j.impl.R4J in project L4J8 by stelar7.
the class TestVALMatch method getDeep.
@Test
public void getDeep() {
R4J api = new R4J(SecretFile.CREDS);
VALMatchAPI matchAPI = api.getVALAPI().getMatchAPI();
RiotAccount account = api.getAccountAPI().getAccountByTag(RegionShard.EUROPE, "Jbzz", "EUW");
List<String> ids = new ArrayList<>();
ids.add(account.getPUUID());
List<MatchReference> matchlist = matchAPI.getMatchList(ValorantShard.EU, account.getPUUID());
matchlist.forEach(m -> {
VALMatch match = matchAPI.getMatch(ValorantShard.EU, m.getMatchId());
match.getRoundResults().forEach(r -> {
if (match.getPlayers().stream().anyMatch(p -> p.getCharacter() == null)) {
System.out.println();
}
r.getPlayerStats().forEach(s -> {
if (s.getAbility().getGrenadeEffects() != null && !s.getAbility().getGrenadeEffects().equals("null")) {
System.out.println();
}
});
});
match.getPlayers().forEach(p -> ids.add(p.getPUUID()));
});
ids.forEach(puuid -> {
List<MatchReference> matches = matchAPI.getMatchList(ValorantShard.EU, puuid);
matches.forEach(m -> {
VALMatch match = matchAPI.getMatch(ValorantShard.EU, m.getMatchId());
match.getRoundResults().forEach(r -> {
r.getPlayerStats().forEach(s -> {
if (s.getAbility().getGrenadeEffects() != null && !s.getAbility().getGrenadeEffects().equals("null")) {
System.out.println();
}
});
});
});
});
}
use of no.stelar7.api.r4j.impl.R4J in project L4J8 by stelar7.
the class TestSharedAccount method getByTag.
@Test
@Order(1)
public void getByTag() {
R4J api = new R4J(SecretFile.CREDS);
RiotAccount account = api.getAccountAPI().getAccountByTag(RegionShard.EUROPE, "stelar7", "STL7");
System.out.println(account);
}
use of no.stelar7.api.r4j.impl.R4J in project L4J8 by stelar7.
the class TestSharedAccount method getByPUUID.
@Test
@Order(2)
public void getByPUUID() {
R4J api = new R4J(SecretFile.CREDS);
RiotAccount accountTag = api.getAccountAPI().getAccountByTag(RegionShard.EUROPE, "stelar7", "STL7");
RiotAccount account = api.getAccountAPI().getAccountByPUUID(RegionShard.EUROPE, accountTag.getPUUID());
System.out.println(account);
}
use of no.stelar7.api.r4j.impl.R4J in project L4J8 by stelar7.
the class StatusTest method testNullInit.
@Test
public void testNullInit() {
final R4J r4J = new R4J(null);
r4J.getDDragonAPI().getRealm();
}
use of no.stelar7.api.r4j.impl.R4J in project L4J8 by stelar7.
the class TestVALRanked method getLeaderboard.
@Test
public void getLeaderboard() {
R4J api = new R4J(SecretFile.CREDS);
VALRankedAPI ranked = api.getVALAPI().getRankedAPI();
Leaderboard leaderboard = ranked.getLeaderboard(ValorantShard.EU, Season.EPISODE_2_ACT_1.getActId(), 0, 200);
System.out.println(leaderboard);
}
Aggregations