Hi,
when I load the same soundfile twice like so:
s1 = audio.loadSound( soundFile )
s2 = audio.loadSound( soundFile )
the two handles point to the same userdata:
print(s1)
print(s2)
=>
userdata: 0x2014bc910
userdata: 0x2014bc910
I can dispose both separately, whereas disposing s1 twice raises an error. I’m confused.
When I do the above, will I need 2 times the memory?
In other words: Is it safe to write audio.playSound( audio.loadSound( sfilename ) ) with the same sfilename more than once or will I fill up the memory with the same loaded sound file?
(I know I shouldn’t, because I can’t dispose the sounds this way. But the game is small and there are not many sounds so I’d like to leave memory management to the os when I leave the game.)