Ok, then code as in your first example.
When the player overlaps the star, you can set a boolean to true. ( and off again after 10 seconds ).
Then, when the player overlaps an enemy, destroy them if the bool is true.
Ok, then code as in your first example.
When the player overlaps the star, you can set a boolean to true. ( and off again after 10 seconds ).
Then, when the player overlaps an enemy, destroy them if the bool is true.