## rAthena References: ## - clif_navigateTo class_name NavigateToTargetPacket extends Packet const HEADER := 0x08e2 const BYTE_LENGTH := 27 ## Byte Type: u8 [br] ## Byte Length: 1 [br] ## 0: Coordinates [br] ## 1: Coordinates - but fails if you're already on the map [br] ## 3: Monster var target_type: int ## Byte Type: u8 [br] ## Byte Length: 1 var flags: int ## Byte Type: u8 [br] ## Byte Length: 1 var hide_window: int ## Byte Type: u8 [br] ## Byte Length: 16 var map_name: String ## Byte Type: u16 [br] ## Byte Length: 2 var target_position_x: int ## Byte Type: u16 [br] ## Byte Length: 2 var target_position_y: int ## Byte Type: u16 [br] ## Byte Length: 2 var target_monster_id: int func get_target_position() -> Vector2: return Vector2(target_position_x, target_position_y) static func from_bytes(bytes: PackedByteArray) -> NavigateToTargetPacket: var packet = NavigateToTargetPacket.new() packet.target_type = bytes.decode_u8(2) packet.flags = bytes.decode_u8(3) packet.hide_window = bytes.decode_u8(4) packet.map_name = bytes.slice(5, 5 + 16).get_string_from_utf8() packet.target_position_x = bytes.decode_u16(21) packet.target_position_y = bytes.decode_u16(23) packet.target_monster_id = bytes.decode_u16(25) return packet