no visual but grid made
very primitive. need to import utilities, so im backing up beforehand
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
|
||||
// INSPIRED BY "CODE MONKEY" ON YOUTUBE
|
||||
public class LogicGrid
|
||||
{
|
||||
private int width;
|
||||
private int height;
|
||||
private int[,] gridArray;
|
||||
|
||||
public LogicGrid(int width, int height)
|
||||
{
|
||||
this.width = width;
|
||||
this.height = height;
|
||||
|
||||
gridArray = new int[width, height];
|
||||
|
||||
Debug.Log(width + " " + height);
|
||||
|
||||
for(int x = 0; x < gridArray.GetLength(0); x++)
|
||||
for(int y = 0; y < gridArray.GetLength(1); y++)
|
||||
{
|
||||
Debug.Log(x + ", " + y);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 360353a64b23bca468e4f86836747bf5
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,15 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class TestingScript : MonoBehaviour
|
||||
{
|
||||
// Start is called before the first frame update
|
||||
private void Start()
|
||||
{
|
||||
LogicGrid grid = new LogicGrid(4, 2);
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 8fb3c49ddde2d804487b586bfbf43cc3
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
Reference in New Issue
Block a user