How do I make a object correspond with data in array?

Get help using Construct 2

Post » Fri May 06, 2016 4:04 am


I am trying to figure out a formula, and I need your help. I have an array that differes in dimensions, and a fixed size layout, with an object in the middle being a spawn. Inside array I randomly choosing position of Start cell. I'm trying to figure out a way to generate level from that array, but where the Start cell corresponds to that sprite object in the middle of the layout. Could you guys help me figuring out the formula? Cheers
My professional Royalty Free Music at Scirra Assets Store
Specs: i5 2500, 16gb of ram, gtx 770, win 7, Focusrite Scarlett 8i6, Mackie mr8mk2, Alesis 320, browsing the net on chrome.
Posts: 1,987
Reputation: 20,203

Post » Sat May 07, 2016 1:47 am

There is not enough information. Since you mentioned

generate level from that array

How about you tell us first what kind of game you are trying to make? What kind of fabulous experience are you trying to craft? Or else, we might not be able to help you validly.

But on the primitive level, you could store number or text in the array and then refer to these values to create certain specific objects when you wanna generate the level. You have to define all these yourself. I don't think there is a much of a formula you can look for.
I got a game that you multiply, breath fire with two heads and brawl foes to oblivion with your clones: (use Chrome on Windows for best performance)

My sites:
Posts: 411
Reputation: 8,469

Return to How do I....?

Who is online

Users browsing this forum: Metathronos and 12 guests