package mapped;

import net.runelite.mapping.ObfuscatedGetter;
import net.runelite.mapping.ObfuscatedName;
import net.runelite.mapping.ObfuscatedSignature;
import net.runelite.rs.api.RSBuddyRankComparator;

@ObfuscatedName("eg")
public class BuddyRankComparator extends AbstractUserComparator implements RSBuddyRankComparator {
   @ObfuscatedName("wz")
   @ObfuscatedGetter(
      intValue = -1052831761
   )
   static int foundItemIdCount;
   @ObfuscatedName("gw")
   @ObfuscatedSignature(
      descriptor = "Loh;"
   )
   static Archive field1460;
   @ObfuscatedName("at")
   final boolean reversed;

   public BuddyRankComparator(boolean var1) {
      this.reversed = var1;
   }

   @ObfuscatedName("at")
   @ObfuscatedSignature(
      descriptor = "(Lrh;Lrh;B)I",
      garbageValue = "95"
   )
   int method3005(Buddy var1, Buddy var2) {
      return var2.rank != var1.rank?(this.reversed?var1.rank - var2.rank:var2.rank - var1.rank):this.method8173(var1, var2);
   }

   public int compare(Object var1, Object var2) {
      return this.method3005((Buddy)var1, (Buddy)var2);
   }

   @ObfuscatedName("ab")
   @ObfuscatedSignature(
      descriptor = "(I)Z",
      garbageValue = "-457265261"
   )
   public static boolean method3006_base() {
      return !class316.field3413.isEmpty()?true:(!class316.musicSongs.isEmpty() && class316.musicSongs.get(0) != null && ((MusicSong)class316.musicSongs.get(0)).midiPcmStream != null?((MusicSong)class316.musicSongs.get(0)).midiPcmStream.isReady_base():false);
   }
}
