Skip to content

Commit cdd3007

Browse files
MatthewMarinetsAustinSumigray
authored andcommitted
sc2: Fixed sc2 client's /received command breaking after PR 1933 merged (ArchipelagoMW#3497)
1 parent caab538 commit cdd3007

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

worlds/sc2/Client.py

+4-4
Original file line numberDiff line numberDiff line change
@@ -107,10 +107,10 @@ def __call__(self, text: str) -> 'ColouredMessage':
107107
def coloured(self, text: str, colour: str) -> 'ColouredMessage':
108108
add_json_text(self.parts, text, type="color", color=colour)
109109
return self
110-
def location(self, location_id: int, player_id: int = 0) -> 'ColouredMessage':
110+
def location(self, location_id: int, player_id: int) -> 'ColouredMessage':
111111
add_json_location(self.parts, location_id, player_id)
112112
return self
113-
def item(self, item_id: int, player_id: int = 0, flags: int = 0) -> 'ColouredMessage':
113+
def item(self, item_id: int, player_id: int, flags: int = 0) -> 'ColouredMessage':
114114
add_json_item(self.parts, item_id, player_id, flags)
115115
return self
116116
def player(self, player_id: int) -> 'ColouredMessage':
@@ -256,7 +256,7 @@ def print_faction_title():
256256
for item in received_items_of_this_type:
257257
print_faction_title()
258258
has_printed_faction_title = True
259-
(ColouredMessage('* ').item(item.item, flags=item.flags)
259+
(ColouredMessage('* ').item(item.item, self.ctx.slot, flags=item.flags)
260260
(" from ").location(item.location, self.ctx.slot)
261261
(" by ").player(item.player)
262262
).send(self.ctx)
@@ -277,7 +277,7 @@ def print_faction_title():
277277
received_items_of_this_type = items_received.get(child_item, [])
278278
for item in received_items_of_this_type:
279279
filter_match_count += len(received_items_of_this_type)
280-
(ColouredMessage(' * ').item(item.item, flags=item.flags)
280+
(ColouredMessage(' * ').item(item.item, self.ctx.slot, flags=item.flags)
281281
(" from ").location(item.location, self.ctx.slot)
282282
(" by ").player(item.player)
283283
).send(self.ctx)

0 commit comments

Comments
 (0)