Nadales | Build Your Own Metaverse with Unity | E-Book | www.sack.de
E-Book

E-Book, Englisch, 586 Seiten

Nadales Build Your Own Metaverse with Unity

A practical guide to developing your own cross-platform Metaverse with Unity3D and Firebase
1. Auflage 2023
ISBN: 978-1-83763-561-0
Verlag: De Gruyter
Format: EPUB
Kopierschutz: 0 - No protection

A practical guide to developing your own cross-platform Metaverse with Unity3D and Firebase

E-Book, Englisch, 586 Seiten

ISBN: 978-1-83763-561-0
Verlag: De Gruyter
Format: EPUB
Kopierschutz: 0 - No protection



Build Your Own Metaverse with Unity is a practical guide for developers with step-by-step explanations, practical examples, and screenshots to guide them through essential concepts.
You'll start by learning how to install Unity and create a character that can move around the virtual world. Next, you'll learn how to integrate multiplayer functionality, user identification, and registration in your game universe. You'll explore how to create interactive characters dealing with different attributes of the virtual world, including acquiring homes and decorating them with various features. Additionally, you'll understand how to use Firebase tools to make your Metaverse unique. By following the expert advice, you'll be able to create a feature rich Metaverse where players can interact with NPCs, acquire homes, and interact with other players online. Finally, you'll discover how to compile and distribute the finished project to various platforms, while acquiring with necessary skills and knowledge to create a unique and groundbreaking Metaverse.
By the end of this book, you'll be well-equipped to create a Metaverse with infinite possibilities.

Nadales Build Your Own Metaverse with Unity jetzt bestellen!

Autoren/Hrsg.


Weitere Infos & Material


Table of Contents - Getting Started with Unity and Firebase
- Preparing Our Player
- Preparing Our Home Sweet Home: Part 1
- Preparing Our Home Sweet Home: Part 2
- Preparing a New World for Travel
- Adding a Registration and Login Form for Our Users
- Building an NPC That Allows Us to Travel
- Acquiring a House
- Turning Our World into a Multiplayer Room
- Adding Text and a Voice Chat to the Room
- Creating an NPC That Allows Us to Change Our Appearance
- Streaming Video Like a Cinema
- Adding Compatibility for the Meta Quest 2
- Distributing


1


Getting Started with Unity and Firebase


The metaverse and the future are a combination of increasingly united concepts, a new formula that was born to stay and lay the foundations for new forms of communication in the coming years. A metaverse is a shared, three-dimensional virtual world where people can interact with each other and with digital objects in real time. Its utility lies in providing an expansive space for creativity, collaboration, and entertainment.

It allows users to explore immersive virtual environments, engage in social, commercial, and educational activities, and experience new forms of expression and experiences. In addition, the metaverse can serve as a platform for developing innovative solutions in a variety of areas, such as remote work, distance learning, product design, and simulation, offering endless possibilities for human interaction and imagination.

In the coming years, the way we attend work meetings, concerts, training courses, and even dating to find a partner may occur in the metaverse. This book will help you get started with programming a metaverse by using the Unity 3D video game engine, the Google Firebase suite, and other amazing tools.

In this first chapter, you will learn the first steps of configuring your computer so that you can start developing virtual worlds in Unity 3D. We will start by laying down the basics about the Unity 3D video game engine, introducing the services offered by Firebase and explaining how they will help us in our project, and covering what other tools we will need.

Once we have reviewed all the concepts and technologies we will use, we will install Unity 3D on our computers. This chapter’s mission is to ensure we completely configure our work environment for satisfactory project development.

We will cover the following topics:

  • Installing Unity
  • Organizing your project assets
  • Choosing an input handler
  • Understanding Firebase services

Note for advanced readers

If you have previously worked with Unity, you will know how to install it correctly on your system. If you already have it installed, you can skip the following steps – just keep the version of Unity that we will use as a base in this project in mind to avoid incompatibilities in future chapters.

Technical requirements


For the Unity 3D game engine, you will need a Windows or Mac computer. Normally, Unity can be run on most computers nowadays, but if you want to have a look at the minimum requirements for a computer to run Unity, go to https://docs.unity3d.com/Manual/system-requirements.html.

If you plan to compile your metaverse for iOS or Mac, you must have a Mac, with the latest version of macOS and also a current Apple developer account. If you only want to compile for Android, Windows, or Linux, you can use a Windows or Mac computer indifferently. In this book, the screenshots provided have been taken from a Mac, but this should not affect you in any way, even if you have Windows.

Fortunately, our project can be tested by running the scene directly from Unity. This will make it much easier for you to progressively see small changes with just one click. Only when we get closer to the end of this book will we need an Android and/or iOS device to test compilations on mobile devices, but the latter is optional if you want to compile for mobile devices.

You must follow this first chapter in detail to make sure that your computer uses the same version of Unity and other dependent plugins that we will show throughout.

Almost certainly, the project that we will be creating throughout this book will be compatible with future versions of Unity 3D. So, if, for any reason, you need to use another version of Unity that’s different from the one recommended here, it will not be a problem.

This book’s GitHub repository contains the complete project that we will work on: https://github.com/PacktPublishing/Build-Your-Own-Metaverse-with-Unity/tree/main/UnityProject.

Installing Unity Hub


To develop our metaverse, just like a video game, we will need to install Unity on our computers. In this section, we will follow all the necessary steps to do so. We will install Unity Hub, which will allow us to manage multiple versions of Unity in a simple and orderly way, create a project from scratch, and explore the fundamental parts of the editor to get familiar with the graphical interface.

Unity Hub is an application that allows us to manage and install multiple versions of the Unity editor on our computer. Also, for each version, it allows us to install different build platforms and tools in an isolated way. It is very common that throughout our professional careers developing video games, we need different versions of Unity to support different projects, which, for whatever reason, cannot be updated or do not work quite right in later versions of Unity.

This is where Unity Hub comes into play – it allows us to easily install any version of Unity in isolation without it conflicting with other versions. It also allows us to load existing Unity projects on our computers and configure which version of Unity it should use when opening.

To install this tool, execute the following steps:

  1. Please download and install the Unity Hub program from https://unity3d.com/get-unity/download. It is recommended that you use Unity Hub to manage the Unity versions on your computer instead of downloading and installing the Unity editor directly.

The screenshots in this book were taken in Unity Hub version 3.0.0. The functions and buttons in earlier or future versions should not change.

  1. You will need to activate a license for Unity if you have not already done so. The Unity User license has free plans for Students and Community; you can decide if you need to upgrade your plan to Plus or Pro in the future. For our project, a free plan is sufficient since all Unity features are open in the free license.
  2. Press the Download For Mac or Download For Windows button, as shown in the following screenshot:

Figure 1.1 – Installing Unity Hub instead of downloading Unity directly

  1. If this is your first experience with Unity or you want to expand your knowledge, I recommend that you take a look at the Learn and Community menus that you will find in Unity Hub when you open it.
  2. If this is the first time you are using Unity Hub, you will need to create a new account for free. You can also log in with your Google, Facebook, or Apple account and accept the terms and conditions of use.

Once we have downloaded Unity Hub, we can proceed to install it on our computers. Unity Hub allows us to manage multiple installations of different versions of the Unity editor on our computers. This will allow us to maintain compatibility with all previous projects that we have or those that we will create in the future. Next, I will guide you through the process of installing a new instance of the Unity editor step by step.

Installing the Unity editor


As a recommendation, whenever you start a new project in Unity, it is interesting to download the latest version available. That is why, in our metaverse, we will do it this way.

When starting a new engine installation, Unity will show us different options, such as the recommended LTS version, other recent versions, and a history of previous versions, all of which are very useful when you have a legacy project that needs a specific version to work.

To start a new installation, execute the following steps:

  1. On the Unity Hub main screen, select the Installs tab and click on the Install Editor button:

Figure 1.2 – The Install Editor button in Unity Hub

  1. Click on the Archive tab and then click on the download archive link, a tab will open in your browser that will show the Unity version catalog. If you wish, you can also go to the url https://unity.com/releases/editor/archive in your browser:

Figure 1.3 – Archive tab in Unity Hub

  1. This project has been built from version 2021.1.14f1. Once you are on the Unity version catalog page, you can search for the desired version. Click on the Unity 2021.X tab to find the 2021.1.14f version, finally click on the Unity Hub button, this action will launch the download in Unity Hub.

About the Unity version

In this book, we have built...


Nadales David Cantón:

David Cantón Nadales, software engineer from Seville, Spain, with more than 15 years of experience. He is currently a Technical Leader at Grupo Viajes El Corte Inglés, a leading travel company in Europe. He has done a multitude of projects and video games with Unity, VR/AR with Oculus, Hololens, HTC Vive, DayDream and LeapMotion. He was ambassador of the Samsung community "Samsung Dev Spain", and organizer of "Google Developers Group Sevilla". He led more than 100 projects throughout his career. As a social entrepreneur stands out Grita, a social network that emerged during the confinement of COVID-19 that allowed to talk to other people and help each other psychologically. In 2022 he won the Top Developers Awards organized by Samsung.



Ihre Fragen, Wünsche oder Anmerkungen
Vorname*
Nachname*
Ihre E-Mail-Adresse*
Kundennr.
Ihre Nachricht*
Lediglich mit * gekennzeichnete Felder sind Pflichtfelder.
Wenn Sie die im Kontaktformular eingegebenen Daten durch Klick auf den nachfolgenden Button übersenden, erklären Sie sich damit einverstanden, dass wir Ihr Angaben für die Beantwortung Ihrer Anfrage verwenden. Selbstverständlich werden Ihre Daten vertraulich behandelt und nicht an Dritte weitergegeben. Sie können der Verwendung Ihrer Daten jederzeit widersprechen. Das Datenhandling bei Sack Fachmedien erklären wir Ihnen in unserer Datenschutzerklärung.