Skip to content

Commit 6c30c79

Browse files
committed
[bugfix] Create bot substitution events per team
1 parent 5c8de54 commit 6c30c79

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

internal/app/controller/engine.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -290,18 +290,18 @@ func (e *Engine) Continue() {
290290
if substitutionIntend != TeamUnknown {
291291
if substitutionIntend == TeamBoth {
292292
yellowTeam := TeamYellow.toProto()
293-
event := GameEvent{
293+
yellowEvent := GameEvent{
294294
Type: GameEventBotSubstitution,
295295
Details: GameEventDetails{
296296
BotSubstitution: &refproto.GameEvent_BotSubstitution{ByTeam: &yellowTeam}}}
297-
e.AddGameEvent(&event)
297+
e.AddGameEvent(&yellowEvent)
298298

299299
blueTeam := TeamBlue.toProto()
300-
event = GameEvent{
300+
blueEvent := GameEvent{
301301
Type: GameEventBotSubstitution,
302302
Details: GameEventDetails{
303303
BotSubstitution: &refproto.GameEvent_BotSubstitution{ByTeam: &blueTeam}}}
304-
e.AddGameEvent(&event)
304+
e.AddGameEvent(&blueEvent)
305305
} else {
306306
teamProto := substitutionIntend.toProto()
307307
event := GameEvent{

0 commit comments

Comments
 (0)