openDS-oss
openDS-oss copied to clipboard
Add reward on successful action
on correctly passing an obstacle, after several minutes of driving, on passing a cognitively demanding situation
... give a reward (play a song, green screen with trophy icon, ...)
Make this an optional functionality, so the impact can be validated
Subtask of #24
OK, here's an updated plan:
- [ ] implement means to show/act on reward:
- [x] show text/image (e.g :+1: ) on screen ... https://github.com/breznak/openDS/issues/32#issuecomment-253496420
- [x] play a sound:
cz.cvut.utils.PlaySound(String pathToFile)
- [ ] change screen color/flash/blink
cz.cvut.utils.Utils.changeScreenColor(Color c, int timeoutMs, bool smooth)
// static method, extract fromDarkeningDistraction
- [ ] refactor
DisctractionClass
- [x] merge in it functionality of
ListOfDistractions
- [ ]
abstract void showReward()
//can also do nothing - [x] require
int reward
in constructor - update global reward on collection
- [ ] "automatically" detect when/if reward is collected, write to log
- [ ] remove
DistractionSettings
, hold the info in DistractionClass.settings hashmap
- [x] merge in it functionality of