//public void SpawnCube(Cube cube, Vector3 position, Action<Cube> addCubeToLists, bool checkIfPositionAvailable) { // if (checkIfPositionAvailable) { // foreach (var item in positionsLog) { // if (position == item) return; // } // } // Cube tmp = Instantiate(cube, position, Quaternion.identity) // //.withID((ulong)((position.x + 1) * (position.z + 1) * (position.y + 1))) // .withSystem(this); // tmp.transform.parent = this.transform; // addCubeToLists(tmp); //} public void AddCubeToList(Cube cube) { positionsLog.Add(cube.transform.position); cubes.Add(cube.transform.position, cube); }
//public CubeDestroyedEvent cubeDestroyedEvent; public void InvokeCubeDestroyedEvent(Cube cube) { p_system.UpdatePlayerMoneyWhenCubeGetsDestroyed(cube); }