Is there a way to access a png and music/sound effects as objects in a function? I was planning on using a function which would bring up a melody and an image based on what number is randomly generated. While I don’t have the code set up in Lua, I could go over what I want it to do in pseudo-code.
local function theFunction (x, y, z)
{
if randomNumber == x
{
start y
display z
}
}
Then run it sort of like…
theFunction(1, melody1, png1)
I’m not sure if this is doable in Corona or not. Any assistance would be greatly appreciated!