Record Class RadioGroupSelectEvent

java.lang.Object
java.lang.Record
com.botwithus.bot.api.event.RadioGroupSelectEvent
Record Components:
interfaceId - the owning interface id
componentId - the component id within the interface
subId - the sub-component id, or -1 when none
value - component-derived secondary id, or -1 when none
opcode - the outbound ClientProt opcode for the chosen option
timestamp - event creation time in milliseconds since epoch
All Implemented Interfaces:
GameEvent

public record RadioGroupSelectEvent(int interfaceId, int componentId, int subId, int value, int opcode, long timestamp) extends Record implements GameEvent
Fired when a radio-group option is selected, observed on the producer's outbound SendRadioButton packet builder. Covers both manual (player) selections and bot-driven ones queued as a RadioGroupSelect action.

A radio select does not ride the normal MiniMenu action packet — the producer hooks the dedicated packet builder and republishes each selection here. interfaceId/componentId identify the radio-group component; subId is the sub-component id (-1 when none); value is a component-derived secondary id (-1 in practice for a plain select); opcode is the resolved ClientProt id, which encodes which option index was chosen.

  • Constructor Summary

    Constructors
    Constructor
    Description
    RadioGroupSelectEvent(int interfaceId, int componentId, int subId, int value, int opcode)
     
    RadioGroupSelectEvent(int interfaceId, int componentId, int subId, int value, int opcode, long timestamp)
    Creates an instance of a RadioGroupSelectEvent record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    Returns the value of the componentId record component.
    final boolean
    Indicates whether some other object is "equal to" this one.
    final int
    Returns a hash code value for this object.
    int
    Returns the value of the interfaceId record component.
    int
    Returns the value of the opcode record component.
    int
    Returns the value of the subId record component.
    long
    Returns the value of the timestamp record component.
    final String
    Returns a string representation of this record class.
    int
    Returns the value of the value record component.

    Methods inherited from class Object

    getClass, notify, notifyAll, wait, wait, wait

    Methods inherited from interface GameEvent

    type
  • Constructor Details

    • RadioGroupSelectEvent

      public RadioGroupSelectEvent(int interfaceId, int componentId, int subId, int value, int opcode)
    • RadioGroupSelectEvent

      public RadioGroupSelectEvent(int interfaceId, int componentId, int subId, int value, int opcode, long timestamp)
      Creates an instance of a RadioGroupSelectEvent record class.
      Parameters:
      interfaceId - the value for the interfaceId record component
      componentId - the value for the componentId record component
      subId - the value for the subId record component
      value - the value for the value record component
      opcode - the value for the opcode record component
      timestamp - the value for the timestamp record component
  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with the compare method from their corresponding wrapper classes.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • interfaceId

      public int interfaceId()
      Returns the value of the interfaceId record component.
      Returns:
      the value of the interfaceId record component
    • componentId

      public int componentId()
      Returns the value of the componentId record component.
      Returns:
      the value of the componentId record component
    • subId

      public int subId()
      Returns the value of the subId record component.
      Returns:
      the value of the subId record component
    • value

      public int value()
      Returns the value of the value record component.
      Returns:
      the value of the value record component
    • opcode

      public int opcode()
      Returns the value of the opcode record component.
      Returns:
      the value of the opcode record component
    • timestamp

      public long timestamp()
      Returns the value of the timestamp record component.
      Specified by:
      timestamp in interface GameEvent
      Returns:
      the value of the timestamp record component