Skip to content
This repository has been archived by the owner on Jul 6, 2020. It is now read-only.

Commit

Permalink
[Dawn] Dynamic Team Flag
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinmasd committed Apr 15, 2017
1 parent 5b072ab commit 5f5c594
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
3 changes: 2 additions & 1 deletion dawn/main/ansible/Ansible.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import {
} from '../../renderer/actions/InfoActions';
import { updatePeripherals } from '../../renderer/actions/PeripheralActions';
import { uploadStatus, robotState, Logger, defaults } from '../../renderer/utils/utils';
import { stationNumber } from './LCM';

const dawnBuilder = ProtoBuf.loadProtoFile(`${__dirname}/ansible.proto`);
const DawnData = dawnBuilder.build('DawnData');
Expand Down Expand Up @@ -59,7 +60,7 @@ function buildProto(data) {
return new DawnData({
student_code_status: status,
gamepads,
team_color: 0,
team_color: (stationNumber < 2) ? DawnData.TeamColor.BLUE : DawnData.TeamColor.GOLD,
});
}

Expand Down
1 change: 0 additions & 1 deletion dawn/renderer/reducers/FieldStore.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import { ActionTypes } from '../constants/Constants';
import { stationNumber } from '../../main/ansible/LCM';

const initialFieldState = {
rIsBlue: stationNumber < 2,
rTeamNumber: 0,
rTeamName: 'Unknown',
rStationTag: (stationNumber < 2) ? `Blue ${stationNumber + 1} ` : `Gold ${stationNumber - 1} `,
Expand Down

0 comments on commit 5f5c594

Please sign in to comment.