Help with game similar to Monster Rancher Explorer

So I’m messing around and want to make something like Monster Rancher Explorer for the Gameboy Color.
Link to Monster Rancher Explorer GamePlay:

Basically, I have my guy moving around a small area and jumping. The jump isn’t like the game and I wanna work on that eventually. My main concern right now is how to spawn the boxes.

I was planning to use instantiate but I need a way to snap it to the unity grid and for the player not to be able to instantiate if there is already a box in that spot.

Instantiate code I have: Instantiate(box,new Vector3(this.transform.position.x+1f, this.transform.position.y, 0), Quaternion.identity);//Spawn box to the right side

Any ideas?

In terms of snapping to the unity grid; if you ensure that your box texture image is a square image (power of 2’s are good, like 32x32, 64x64 etc) you can then set the pixels per unit in the textures inspector window to its resolution. So if its a 32x32 texture, set it so that 32 pixels is one unity unit. Then when it is spawned it will take up exactly one unit. (You can of course make it half of a unit per box or whatever works for your project.)

As for the player not spawning if there is a box, in the simplest terms you can spawn the player at a specific point and ensure that you never also spawn a box in that spot. Otherwise there are many ways to approach this issue. A fairly normal way to approach it would be to keep an array that represents what is spawned in the level and check to see what is in the position that you want to spawn the player at before doing so.

Hope that helps!

I’m using the default unity grid so my sprites are 100x100. But say my sprite is at position .3f,1f,0f and I press left control, I want the brick to spawn at 1.5f,1f,0f.