3 ms·
I do Haskell as my job. In general I would much rather have a function in the vein of `DeltaState -> [SoundEffects]` than another layer of effects. If the sound
by danharaj 11y ago
I do Haskell as my job. In general I would much rather have a function in the vein of `DeltaState -> [SoundEffects]` than another layer of effects. If the sounds aren't dependent on by what means the state changed, but only on what the change in state is, then you may as well factor out the sound logic. Conversely, since I want to keep the program well factored I endeavor to separate concerns into pure computations as much as possible and minimize effects.