Versions with this page:
Versions without this page:
Devuelve verdadero si el valor es potencia de dos.
using UnityEngine;public class Example : MonoBehaviour { void Start() { // prints false Debug.Log(Mathf.IsPowerOfTwo(7)); // prints true Debug.Log(Mathf.IsPowerOfTwo(32)); } }