Search in sources :

Example 91 with Client

use of org.orcid.jaxb.model.v3.dev1.client.Client in project powerbot by powerbot.

the class HintArrow method valid.

@Override
public boolean valid() {
    final Client client = ctx.client();
    if (client == null) {
        return false;
    }
    final org.powerbot.bot.rt6.client.HintArrow[] arr = client.getHintArrows();
    return arrow.obj.get() != null && arr != null && Arrays.asList(arr).contains(arrow);
}
Also used : Client(org.powerbot.bot.rt6.client.Client)

Example 92 with Client

use of org.orcid.jaxb.model.v3.dev1.client.Client in project powerbot by powerbot.

the class HintArrows method get.

/**
 * {@inheritDoc}
 */
@Override
protected List<org.powerbot.script.rt6.HintArrow> get() {
    final List<org.powerbot.script.rt6.HintArrow> items = new ArrayList<org.powerbot.script.rt6.HintArrow>();
    final Client client = ctx.client();
    if (client == null) {
        return items;
    }
    final HintArrow[] arr = client.getHintArrows();
    for (final HintArrow arrow : arr != null ? arr : new HintArrow[0]) {
        if (arrow.isNull()) {
            items.add(new org.powerbot.script.rt6.HintArrow(ctx, arrow));
        }
    }
    return items;
}
Also used : HintArrow(org.powerbot.bot.rt6.client.HintArrow) ArrayList(java.util.ArrayList) Client(org.powerbot.bot.rt6.client.Client)

Example 93 with Client

use of org.orcid.jaxb.model.v3.dev1.client.Client in project powerbot by powerbot.

the class Players method local.

public Player local() {
    final Player r = new Player(ctx, null);
    final Client client = ctx.client();
    if (client == null) {
        return r;
    }
    return new Player(ctx, client.getPlayer());
}
Also used : Client(org.powerbot.bot.rt4.client.Client)

Example 94 with Client

use of org.orcid.jaxb.model.v3.dev1.client.Client in project powerbot by powerbot.

the class Skills method realLevels.

public int[] realLevels() {
    final Client c = ctx.client();
    final int[] arr = c != null ? c.getSkillLevels2() : new int[0];
    return arr != null ? arr : new int[0];
}
Also used : Client(org.powerbot.bot.rt4.client.Client)

Example 95 with Client

use of org.orcid.jaxb.model.v3.dev1.client.Client in project powerbot by powerbot.

the class Skills method levels.

public int[] levels() {
    final Client c = ctx.client();
    final int[] arr = c != null ? c.getSkillLevels1() : new int[0];
    return arr != null ? arr : new int[0];
}
Also used : Client(org.powerbot.bot.rt4.client.Client)

Aggregations

Client (org.powerbot.bot.rt4.client.Client)36 Client (org.powerbot.bot.rt6.client.Client)33 Point (java.awt.Point)25 ArrayList (java.util.ArrayList)18 Test (org.junit.Test)17 Client (org.orcid.jaxb.model.v3.dev1.client.Client)11 ClientDetailsEntity (org.orcid.persistence.jpa.entities.ClientDetailsEntity)9 Tile (org.powerbot.script.Tile)8 HashSet (java.util.HashSet)6 ClientRedirectUri (org.orcid.jaxb.model.v3.dev1.client.ClientRedirectUri)5 Rectangle (java.awt.Rectangle)4 ClientSummary (org.orcid.jaxb.model.v3.dev1.client.ClientSummary)4 DBUnitTest (org.orcid.test.DBUnitTest)4 Reflector (org.powerbot.bot.Reflector)4 Condition (org.powerbot.script.Condition)4 Client (client.Client)3 CopyOnWriteArrayList (java.util.concurrent.CopyOnWriteArrayList)3 ArgumentMatchers.anyString (org.mockito.ArgumentMatchers.anyString)3 PersonExternalIdentifier (org.orcid.jaxb.model.v3.dev1.record.PersonExternalIdentifier)3 SourceEntity (org.orcid.persistence.jpa.entities.SourceEntity)3