Random Coin Spawner

Hello guys!

Anyone around here knows how to spawn random coins around the screen? I know that you can do that using a timer, for example when the timer hits 100 for example, you can make it spawn a random coin, even tho i dont really know how to do it.Does anyone know a better way for a jumping game, or can someone tell me how to spawn these coins using the timer but also from the objects group? Thanks a lot

Random object from the group:https://imgur.com/a/VJ1N796
And remember if you have 3 objects and you use “Random”, use Random(2) because it counts 0 too. In that imgur link you see I used Random(3) and because of that it counts 0,1,2,3 and I have only 3 objects and none of them is called “Enemy0” so when rng hits 0, no objects is spawning.

Edit. I don’t know is that imgur link working…

It worked really well, thx a lot.The only problem is that the coins are too big now, even tho i set the size 90x90 in properties pannel, it wont keep it that way, and every time i preview the coins would come back to their original size…

Edit:I did it, would still appreciate some help, some of the coins/enemies are spawning on the very edge of the screen border,
sorry for being such a headache

You can’t set a default scale for sprites, with the properties panel you can change the size of instances already added to the scene only. If you’re creating the coins through events you’ve to use events too to change the size, specifically the action to modify the scale:

Conditions: Your conditions to create a coin Actions: Create object Coin at X ; Y Do = 0.5 to the scale of Coin
0.5 for example, you should know the scale, to make it exactly 90 x 90, assuming the original size is squared too, it should be:

Do = 90 / Coin.Width() to the scale of Coin