Version: Unity 6.1 Alpha (6000.1)
LanguageEnglish
  • C#

AndroidArchitecture

enumeration

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

Description

Android CPU architecture.

using UnityEditor.Build;
using UnityEditor;
using UnityEngine;

public class AndroidArchitectureExample : MonoBehaviour { [MenuItem("Build/Android Architectures Example")] public static void AndroidArchitectures() { PlayerSettings.SetScriptingBackend(NamedBuildTarget.Android, ScriptingImplementation.IL2CPP);

//Set the targetArchitecture to ARM64 AndroidAchitecture PlayerSettings.Android.targetArchitectures = AndroidArchitecture.ARM64;

BuildPlayerOptions options = new BuildPlayerOptions(); options.scenes = new[] { "Assets/Scenes/SampleScene.unity" }; options.locationPathName = "Builds/AndroidBuild.apk"; options.target = BuildTarget.Android; options.targetGroup = BuildTargetGroup.Android;

BuildPipeline.BuildPlayer(options); } }

Properties

NoneInvalid architecture.
ARMv732-bit ARM architecture.
ARM6464-bit ARM architecture.
X86_6464-bit Intel architecture.
AllAll architectures.