the argumant audio clip in playclipatpoint function its from reference of audio clip which attached to the script which attached to the gamobject block , so how he stiil work after the gamobject destroyed?why its different from component ? both of them attached to the script
If you pause your game after a block is broken and check the inspector you can see that a new game object is created just before the block is destroyed its called one shot audio and it has its own audio source component with the audio clip assigned to it by the block script. This is how it still works, the information is preserved on the new game object.
1 Like