Guest User

Untitled

a guest
Jun 21st, 2018
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.36 KB | None | 0 0
  1. private void SpawnChessFigure(int index, int x, int y)
  2. {
  3. GameObject go = Instantiate(chessFigures[index], GetTileCenter(x, y), chessFigures[index].transform.rotation) as GameObject;
  4. go.transform.SetParent(transform);
  5. ChessFigurePositions[x, y] = go.GetComponent<ChessFigure>();
  6. ChessFigurePositions[x, y].SetPosition(x, y);
  7. activeFigures.Add(go);
  8. }
Add Comment
Please, Sign In to add comment