Open Nearoo opened 9 years ago
It's actually not that important currently. With the new engine
argument in the components, it's very easy to implement it much later, when sound will be actually needed.
It will be straightforward to initiate a streaming music file.
How are collisions handled?
Sorry, I see you clarified the collision handler in another thread.
Tell me if you need help.
There's no programming done regarding playing sound. In it's current state, the game needs no sound, but if sound should be needed later down the road, it's better if a dummy-sound-engine is already implemented now.
A draft of how it could work:
It then gets passed the same way as Input, World or Graphics. Maybe sounds should even be bound to game-actors, so they can stop sounds they are currently playing... but that's something that can be decided in the future, and be added as a non-standard argument. (e.g. id = id(self))