♟️ Create an Online Chess Game - Spawning Chess Pieces - 2/5 [Unity tutorial 2021][C#] - creating3dgames.com

♟️ Create an Online Chess Game – Spawning Chess Pieces – 2/5 [Unity tutorial 2021][C#]

Epitome
Views: 1164
Like: 41
We spawn 3D Chess Pieces on top of the tiles created last episode, and position them where they belong. We create them in a multi dimensional array of Chess Pieces, and define a new c# class for every single one of them. Pawn, Rook, Knight, Bishop, Queen and King will be inheriting from a base class called Chess Piece

Be careful as I’ve misplaced the king and queen on their X index, sorry!

Link to the Chess Assets, by my friend Z3nder (affiliate) :

– – – – –
0:00 Preview
0:34 Defining Pieces
5:45 Creating Pieces Prefabs
7:15 Spawning a Single Piece
12:30 Spawning ALL the Pieces
17:08 Positioning the Pieces
– – – – –

►♟️ Learn how to make a Online Multiplayer Chess Game (on Youtube!)

► ⚔️ FREE Top Down RPG Course (on Youtube!):

► Develop a FULL Mobile Game with the help of my Udemy Course :

► Want the files? You can find everything on the website!
► Need help? Join our discord community!

Discord 👊
Website 📡
Email me! 📧 info.epitome.games@gmail.com

Personal channel 🇨🇦

Social Media 🤳
📸
🐦

#gameDev #unityEngine #unityTutorial #n3k #epitome

8 Comments

  1. Great series, but I've run into a minor issue.. my black pieces render white, but they have the correct script… help?

  2. Perfect explanation and clear speech, so even me, a guy from Russia, can understand everything. Спасибо!

  3. Epitome it really cool project thanks but can you make different gun buying system and how to use plz iam u are subscribe.

  4. Help! All my code is accurate, but around line 144-146 in 'SpawnSinglePiece' method i get an error in Unity when i start the game saying:

    NullReferenceException: Object reference not set to an instance of an object
    Chessboard.SpawnSinglePiece (ChessPieceType type, System.Int32 team) (at Assets/Scripts/Chessboard.cs:146)
    Chessboard.SpawnAllPieces () (at Assets/Scripts/Chessboard.cs:117)
    Chessboard.Awake () (at Assets/Scripts/Chessboard.cs:28)

    I only have 1 piece on the board. Not an Array of pieces.

    I messed around with changing the number value in the Instantiate function from 'type – 1' to 'type – 2' and so on. It always only changes 1 piece or none.

    How can I fix my issue?

Leave a Reply

Your email address will not be published. Required fields are marked *