public IEnumerator SetupScene() { testGo = new GameObject("test"); testGo.transform.position = Vector3.zero; gridSensorComponent = testGo.AddComponent <GridSensorComponent>(); boxGo = CreateBlock(new Vector3(3f, 0f, 3f), k_Tag1, "box1"); yield return(null); }
public IEnumerator SetupScene() { testGo = new GameObject("test"); testGo.transform.position = Vector3.zero; gridSensorComponent = testGo.AddComponent <GridSensorComponent>(); boxGo = new GameObject("block"); boxGo.tag = k_Tag1; boxGo.transform.position = new Vector3(3f, 0f, 3f); boxGo.AddComponent <BoxCollider>(); yield return(null); }
public static void SetComponentParameters(GridSensorComponent gridComponent, string[] detectableObjects, int[] channelDepth, GridDepthType gridDepthType, float cellScaleX, float cellScaleZ, int gridWidth, int gridHeight, int colliderMaskInt, bool rotateWithAgent, Color[] debugColors) { gridComponent.DetectableObjects = detectableObjects; gridComponent.ChannelDepths = channelDepth; gridComponent.DepthType = gridDepthType; gridComponent.CellScale = new Vector3(cellScaleX, 0.01f, cellScaleZ); gridComponent.GridSize = new Vector3Int(gridWidth, 1, gridHeight); gridComponent.ColliderMask = colliderMaskInt; gridComponent.RotateWithAgent = rotateWithAgent; gridComponent.DebugColors = debugColors; }
public void SetupScene() { testGo = new GameObject("test"); testGo.transform.position = Vector3.zero; gridSensorComponent = testGo.AddComponent <GridSensorComponent>(); }