Conventions used
There are a number of text conventions used throughout this book.
Code in text
: Indicates code words in text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles. Here is an example: "If some content is generated at the beginning of the object collision via OnCollisionEnter
, and you want to destroy them when the object collision ends, then you should consider using OnCollisionExit
."
A block of code is set as follows:
using UnityEngine; public class TriggerTest : MonoBehaviour { private void OnTriggerStay(Collider other) { Debug.Log($"{this} stays {other}"); } } }
When we wish to draw your attention to a particular part of a code block, the relevant lines or items are set in bold:
using UnityEngine; public class PingPongBall : MonoBehaviour { [SerializeField] private Rigidbody _rigidbody; [SerializeField] private Vector3 _initialImpulse; private void Start() { _rigidbody.AddForce(_initialImpulse, ForceMode.Impulse); } }
Bold: Indicates a new term, an important word, or words that you see onscreen. For instance, words in menus or dialog boxes appear in bold. Here is an example: "Select 3D Object | Plane to create a new Plane object in the editor."
Tips or Important Notes
Appear like this.