Reader small image

You're reading from  Build Your Own Metaverse with Unity

Product typeBook
Published inSep 2023
PublisherPackt
ISBN-139781837631735
Edition1st Edition
Tools
Concepts
Right arrow
Author (1)
David Cantón Nadales
David Cantón Nadales
author image
David Cantón Nadales

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.
Read more about David Cantón Nadales

Right arrow

Distributing

Welcome to the last chapter of this exciting book about creating your own metaverse with Unity 3D and Firebase. This is undoubtedly one of the most exciting moments for a software developer. Compiling and distributing your project to see it running on another device is without a doubt a magical moment.

Throughout these pages, we will see how to apply another optimization process to make our project lighter. We will also see how to compile for the most popular platforms, and finally, we will see an explanation of what steps to take to publish your game in the Google Play Store, Apple App Store, Windows Store, and Oculus Store.

This chapter is modular, which means that if you are not interested in exporting your project to one of the platforms, you can skip to the part you are interested in. Finally, I will reflect on what we have covered throughout this book and give you my opinion on how you can evolve your project in the future.

We will cover the following topics...

Technical requirements

This chapter does not have any special technical requirements, but as we will start programming scripts in C#, it would be advisable to have a basic knowledge of this programming language.

We need an internet connection to browse and download an asset from the Unity Asset Store. We will continue with the project we created in Chapter 1, Getting Started with Unity and Firebase. Remember that we have a GitHub repository, https://github.com/PacktPublishing/Build-Your-Own-Metaverse-with-Unity/tree/main/UnityProject, which contains the complete project that we will work on here.

Optimizing textures

We could dedicate a whole book to understanding all the possible optimizations we can apply to our Unity project. In Chapters 3 and 4, we saw some of them. Now, we will see how to apply one more layer.

By applying some adjustments to the textures that we use in our project, we can achieve the following:

  • Improve loading time
  • Drastically reduce the final size of the executable binary file
  • Save graphics rendering time

The time it takes to apply the settings to the textures is minimal compared to the great optimization result we will obtain.

Tip: Advanced guidance on further optimization processes

Unity offers, in its official documentation, a list of things to take into account for a full advanced optimization. If you are curious about it, you can visit https://docs.unity3d.com/es/530/Manual/OptimizingGraphicsPerformance.html.

To understand the optimization process, we will follow these steps:

  1. In the Project panel, click and...

Compiling for different platforms

As we warned at the beginning of the chapter, this part is modular. You can skip directly to the platform of your choice. Before compiling, we need to make some necessary adjustments on each of the platforms.

Before continuing, make sure you have downloaded the platform you want to compile to; for example, in my case, I don’t have the iOS platform downloaded.

Figure 14.6 – iOS platform in the Build Settings window

Figure 14.6 – iOS platform in the Build Settings window

If this happens on any of the platforms, click on the Install with Unity Hub button. Remember that this step was covered in detail in Chapter 13, Adding Compatibility for the Meta Quest 2.

Windows, Mac, and Linux

The process to compile for Windows, Mac, and Linux is identical in all three cases. First, activate the desired platform in the window that can be found by navigating to the File | Build Settings menu.

Figure 14.7 – Mac incompatibility warning

Figure 14.7 – Mac incompatibility warning

...

Summary

We have reached the end of this wonderful book. In this last chapter, we learned about another optimization technique, texture compression, which offers us the ability to considerably reduce the weight of our project and increase the speed and fluidity of the rendering.

We also learned the necessary steps to compile our project on multiple platforms, such as Windows, Linux, Mac, Android, and iOS. You have successfully exported and tested your metaverse on other devices and are now ready to continue your journey to publication on the app stores.

This chapter closes the circle we started at the beginning of the book; you have learned everything you need to create a virtual universe from conception to export. You have learned how to connect to a Firebase database and how to decorate scenes with buildings and objects. You have created NPCs with logic programmed by you.

We have learned how to make our project compatible with Oculus Quest, and let’s not forget fun...

Next steps

One more thing...

It is with immense gratitude and satisfaction that I turn to you in these lines to express my heartfelt thanks for choosing to immerse yourself in the pages of this book. It has been an exciting and challenging journey to bring these ideas and insights together in one place, and your decision to join me on this journey means a great deal to me.

My greatest wish in writing this book was to share my passion for the fascinating world of metaverses and to give you the tools and knowledge you need to create your own virtual experiences. I hope that you have found these pages a source of inspiration and knowledge that will push you further into this exciting area.

None of this would have been possible without your support and confidence in this project. Your choice to read this book is a valuable recognition of all the effort and dedication I put into every word written. I hope that the content of these pages has been of great use to you and has provided...

lock icon
The rest of the chapter is locked
You have been reading a chapter from
Build Your Own Metaverse with Unity
Published in: Sep 2023Publisher: PacktISBN-13: 9781837631735
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
undefined
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime

Author (1)

author image
David Cantón Nadales

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.
Read more about David Cantón Nadales