package mapped;

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

@ObfuscatedName("do")
public class ScriptEvent extends Node implements RSScriptEvent {
   @ObfuscatedName("at")
   Object[] args;
   @ObfuscatedName("ah")
   boolean field1054;
   @ObfuscatedName("ar")
   @ObfuscatedSignature(
      descriptor = "Lnn;"
   )
   Widget widget;
   @ObfuscatedName("ao")
   @ObfuscatedGetter(
      intValue = -1726623421
   )
   int mouseX;
   @ObfuscatedName("ab")
   @ObfuscatedGetter(
      intValue = -1727687657
   )
   int mouseY;
   @ObfuscatedName("au")
   @ObfuscatedGetter(
      intValue = -139104943
   )
   int opIndex;
   @ObfuscatedName("aa")
   @ObfuscatedSignature(
      descriptor = "Lnn;"
   )
   Widget dragTarget;
   @ObfuscatedName("ac")
   @ObfuscatedGetter(
      intValue = -1406520627
   )
   int keyTyped;
   @ObfuscatedName("al")
   @ObfuscatedGetter(
      intValue = -523581111
   )
   int keyPressed;
   @ObfuscatedName("az")
   String targetName;
   @ObfuscatedName("ap")
   @ObfuscatedGetter(
      intValue = -245472791
   )
   int field1063;
   @ObfuscatedName("av")
   @ObfuscatedGetter(
      intValue = -1161157125
   )
   int type;

   public ScriptEvent() {
      this.type = 76;
   }

   @ObfuscatedName("at")
   @ObfuscatedSignature(
      descriptor = "([Ljava/lang/Object;I)V",
      garbageValue = "-1214962197"
   )
   public void setArgs_base(Object[] var1) {
      this.args = var1;
   }

   @ObfuscatedName("ah")
   @ObfuscatedSignature(
      descriptor = "(II)V",
      garbageValue = "334360487"
   )
   public void setType_base(int var1) {
      this.type = var1;
   }

   @ObfuscatedName("ar")
   @ObfuscatedSignature(
      descriptor = "(Lnn;B)V",
      garbageValue = "102"
   )
   public void method2357(Widget var1) {
      this.widget = var1;
   }

   public void run() {
      SpriteMask.client.runScriptEvent(this);
   }

   public Object[] getArguments() {
      return this.args;
   }

   public void setArguments(Object[] var1) {
      this.args = var1;
   }

   public net.runelite.api.widgets.Widget getSource() {
      return this.widget;
   }

   public RSScriptEvent setSource(net.runelite.api.widgets.Widget var1) {
      this.widget = (Widget)var1;
      return this;
   }

   public int getMouseX() {
      return this.mouseX;
   }

   public int getMouseY() {
      return this.mouseY;
   }

   public int getOp() {
      return this.opIndex;
   }

   public int getTypedKeyCode() {
      return this.keyTyped;
   }

   public int getTypedKeyChar() {
      return this.keyPressed;
   }

   public String getOpbase() {
      return this.targetName;
   }

   @ObfuscatedName("br")
   @ObfuscatedSignature(
      descriptor = "(ILdt;ZB)I",
      garbageValue = "0"
   )
   static int method2367(int var0, Script var1, boolean var2) {
      return 2;
   }
}
