<commit_before>from terrabot.util.streamer import Streamer
from terrabot.events import Events
from . import packet

class Packet16(packet.Packet):

	def __init__(self, item_id, owner_id):
		super(Packet16, self).__init__(22)
		self.add_structured_data('<h', item_id)
		self.add_data(owner_id)

class Packet16Parser(object):

	def parse(self, world, player, data, ev_man):
		streamer = Streamer(data)
		streamer.next_byte() # Ignore packet number
		item_id = streamer.next_short()
		owner_id = streamer.next_byte()

		ev_man.raise_event(Events.ItemOwnerChanged, (owner_id, item_id))
<commit_msg>Fixed bug with switched arguments<commit_after>from terrabot.util.streamer import Streamer
from terrabot.events import Events
from . import packet

class Packet16(packet.Packet):

	def __init__(self, item_id, owner_id):
		super(Packet16, self).__init__(22)
		self.add_structured_data('<h', item_id)
		self.add_data(owner_id)

class Packet16Parser(object):

	def parse(self, world, player, data, ev_man):
		streamer = Streamer(data)
		streamer.next_byte() # Ignore packet number
		item_id = streamer.next_short()
		owner_id = streamer.next_byte()

		ev_man.raise_event(Events.ItemOwnerChanged, (item_id, owner_id))

{'fraction_non_alphanumeric': 0.1076158940397351, 'fraction_numerical': 0.013245033112582781, 'mean_word_length': 5.988439306358382, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6013970', 'n_tokens_mistral': 449, 'n_tokens_neox': 412, 'n_words': 90}