-
Notifications
You must be signed in to change notification settings - Fork 0
Feed
The main purpose of the feed is to allow the user to take back actions that they added. It also serves as a way to see what happened in the last few moments of the game which can be useful during chaotic situations. Another reason why the feed exists is that the user gets visual feedback and sees that their inputs are registered by the app.
The feed UI components can be found in lib > widgets > main_screen > action_feed.dart.
It is a scrollable ListView with dynamically updated row children. Each row contains a text displaying the actionType variable associated with the gameAction entered into the feed (TODO this might change in the future with better naming), a text with the name of the player and a trash can icon.

The logic of the feed can be found in lib > utils > feed_logic.dart it interacts with the feedActions list, feedTimer and boolean variables stored in the corresponding GetX controller.
(removed in the scope of #296)periodicFeedTimerReset is called whenever the periodic feedTimer reaches 0 seconds and pops an item of the feedActions list every x milliseconds. When this popping is performed the periodicResetIsHappening value in the GetX controller is updated to block a second timer reset which can be triggered by the StopWatchExecute.reset (this would set the feedTimer to 0 again calling onFeedTimerEnded and in turn periodicsFeedtimerReset again).
addFeedItem adds a gameAction object to the feedItems list in the GetX controller. When an item is added the feedTimer is reset - starting over from the beginning. That way items only leave the feed during times of inactivity and the amount of items displayed in the feed increases during times of high activity. If the feed is full the oldest item is removed and a new action is added.
removeFeedItem gets called when the user clicks on a feed row, deleting the item from the gamestate and the database
Future changes:
- clicking on feed should highlight the location action has been performed from with an x on the field
- text displaying action should be in the right locale and easier to understand
- feed item lifetime should be adjustable in settings
- player changes should be seen in the feed too
- amount of feed items to be displayed should adjustable in the settings
This sidebar is customized. You can add new pages here by clicking 'Edit sidebar' above. To see all pages that exist in the Wiki click here
Ef Score
Firebase
UI
Figma Screens
Flutter
- Dashboard
- Start Game Screen
- Authentication Screen
- App Settings
- Class Model and Data
- Feed
- First Steps
- Helper Screen
- Settings Screen
- State Management
- Testing
- String Management
- Helpers