Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import com.github.manolo8.darkbot.core.itf.Updatable;
import com.github.manolo8.darkbot.core.objects.facades.AssemblyMediator;
import com.github.manolo8.darkbot.core.objects.facades.AstralGateProxy;
import com.github.manolo8.darkbot.core.objects.facades.AstralGateSelectionProxy;
import com.github.manolo8.darkbot.core.objects.facades.BoosterProxy;
import com.github.manolo8.darkbot.core.objects.facades.ChatProxy;
import com.github.manolo8.darkbot.core.objects.facades.ChrominProxy;
Expand Down Expand Up @@ -58,6 +59,7 @@ public class FacadeManager implements Manager, eu.darkbot.api.API.Singleton, Npc
public final EternalBlacklightProxy blacklightGate;
public final ChrominProxy chrominEvent;
public final AstralGateProxy astralGate;
public final AstralGateSelectionProxy astralGateSelection;
public final HighlightProxy highlight;
public final SpaceMapWindowProxy spaceMapWindowProxy;
public final GauntletPlutusProxy plutus;
Expand All @@ -84,6 +86,7 @@ public FacadeManager(PluginAPI pluginApi) {
this.blacklightGate = registerProxy("eternal_blacklight", EternalBlacklightProxy.class);
this.chrominEvent = registerProxy("chrominEvent", ChrominProxy.class);
this.astralGate = registerProxy("rogue_lite", AstralGateProxy.class);
this.astralGateSelection = registerProxy("rogue_lite_selection", AstralGateSelectionProxy.class);
this.highlight = registerProxy("HighlightProxy", HighlightProxy.class);
this.spaceMapWindowProxy = registerProxy("spacemap", SpaceMapWindowProxy.class);
this.plutus = registerProxy("plutus", GauntletPlutusProxy.class);
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
package com.github.manolo8.darkbot.core.objects.facades;

import com.github.manolo8.darkbot.core.itf.Updatable;
import com.github.manolo8.darkbot.core.objects.swf.FlashList;

import lombok.Getter;
import lombok.ToString;

public class AstralGateSelectionProxy extends Updatable {

@Getter
private final FlashList<AstralShip> astralShips = FlashList.ofVector(AstralShip::new);

@Override
public void update() {
if (address == 0) {
return;
}

astralShips.update(readAtom(0x30, 0x48));
}


@Getter
@ToString
public static class AstralShip extends Auto {
private int hp;
private int shield;
private int speed;
private boolean selected;
private String roleType;
private String shipId;

@Override
public void update(long address) {
super.update(address);

this.hp = readInt(0x20);
this.shield = readInt(0x24);
this.speed = readInt(0x2c);
this.roleType = readString(0x38);

this.shipId = readString(0x40, 0x48);
}

@Override
public void update() {
if (address == 0) {
return;
}

this.selected = readBoolean(0x30, 0x20);
}
}
}
Loading