使用例 using UnityEngine; public class Example : MonoBehaviour { [SerializeField] private SpriteRenderer m_spriteRenderer; private void Start() { m_spriteRenderer.RegisterSpriteChangeCallback( SpriteChangeCallback ); } private void OnDestr…
使用例 using TMPro; using UnityEngine; public class Example : MonoBehaviour { [SerializeField] private TMP_SpriteAsset m_tmpSpriteAsset; private void Awake() { TMP_Text.OnSpriteAssetRequest += OnSpriteAssetRequest; TMP_SpriteAsset OnSprite…
概要 Unity プロジェクトに RevenueCat を導入して Amazon のライブアプリテストで Purchases.GetProducts を実行したところ products が空で返ってくる現象に遭遇した nce you are ready, click on 'Submit IAP' at the top of the page. RevenueCat のドキ…
概要 CommandServiceClient: CommandServiceException happened, retriesLeft=6 com.amazon.a.a.n.a.a.c: COMMAND_SERVICE_NOT_INSTALLED: null: null at com.amazon.a.a.n.a.d.e(CommandServiceClient.java:257) at com.amazon.a.a.n.a.d.a(CommandServiceC…
EditorApplication.focusChanged の使用例 using UnityEditor; using UnityEngine; [InitializeOnLoad] public static class Example { static Example() { EditorApplication.focusChanged += isFocused => { Debug.Log( isFocused ); }; } } EditorApplica…
概要 <SKPaymentQueue: 0x282b3a740>: Payment completed with error: Error Domain=ASDErrorDomain Code=500 "Unhandled exception" UserInfo= {NSUnderlyingError=0x2827c4330 {Error Domain=AMSErrorDomain Code=301 "Invalid Status Code" UserInfo={NSLocalizedDescription=Invalid S</skpaymentqueue:>…
概要 Unity 2023.1 から調整できるようになった?
ソースコード
概要 ArgumentException: JSON parse error: Invalid value. UnityEngine.JsonUtility.FromJson (System.String json, System.Type type) (at <9bede5ff2b1144578a9ed4efb4ed894e>:0) UnityEngine.JsonUtility.FromJson[T] (System.String json) (at <9bede5…
概要 Unity に導入している Firebase 関連のパッケージを 11.6.0 から 11.8.1 にアップデートしてから Android ビルドしたら A failure occurred while executing com.android.build.gradle.internal.tasks.MergeJavaResWorkAction See the Console for deta…
概要 AndroidJavaException: java.lang.NoClassDefFoundError: Failed resolution of: Landroidx/activity/result/ActivityResultLauncher; java.lang.NoClassDefFoundError: Failed resolution of: Landroidx/activity/result/ActivityResultLauncher; at j…
概要 gem install --user-install ffi -- --enable-libffi-alloc ターミナルで上記のコマンドを実行したら Ignoring ffi-1.15.5 because its extensions are not built. Try: gem pristine ffi --version 1.15.5 Ignoring json-1.8.6 because its extensions…
概要 iOS framework addition failed due to a CocoaPods installation failure. This will will likely result in an non-functional Xcode project. After the failure, "pod repo update" was executed and succeeded. "pod install" was then attempted …
ソースコード
ソースコード 使用例 Unity メニューの「Window > Kogane > Merged Android Manifest Path」を選択すると ビルド後に書き出された AndroidManifest.xml を開ける EditorWindow が表示される
使用例 参考サイト様
概要 Unity 2023.1 から、「Preferences > General > Enable Helper Bar」をオンにすると 便利なショートカットキーをエディタ下に表示できるようになった
概要 上記のリポジトリで公開されている UnityEditorDarkMode.dll を Unity プロジェクトで読み込むことで Windows 10 や 11 で Unity エディタの以下の箇所をダークモードにできます タイトルバー メニューバー コンテキストメニュー 導入前 導入後 使い方 …
ソースコード 参考サイト様
使用例 using UnityEngine; public class Example : MonoBehaviour { private void Awake() { Debug.Log( didAwake ); // True Debug.Log( didStart ); // False } private void Start() { Debug.Log( didAwake ); // True Debug.Log( didStart ); // True }…
これまで AssetEditingScope Unity 2023.1 から AssetDatabase.AssetEditingScope が追加されて Start / StopAssetEditing を using で記述できるようになった
使用例 デフォルトではフォントに登録されていない文字を使おうとしたら警告が出力されるが TMP_Text.OnMissingCharacter を使えば「エラーを出す」など自由に処理を追加できる
使用例 補足 最後のビルドの情報は Library/LastBuild.buildreport ファイルに格納されている 参考サイト様
使用例 Unity 6000.0 から追加された IShortcutContext を使用すると 特定の状況でのみ有効になるショートカットキーを設定できる 例えば以下のようなスクリプトを実装すると ExampleEditorWindow という EditorWindow が開いている時にスペースを押すと Exa…
使用例 参考サイト様
概要 Unity 6000.0 や 2023.3 から Android ビルド時に 「Symbols output options」を 「App Bundle」にすることで App Bundle に Debug Symbols を埋め込めるようになった
目次 目次 BuildPlayerWindow.RegisterBuildPlayerHandler BuildPlayerWindow.RegisterGetBuildPlayerOptionsHandler 参考サイト様 BuildPlayerWindow.RegisterBuildPlayerHandler 例えば、上記のようにログを出力するだけの OnBuildPlayer 関数を BuildPlay…
使用例 Unity 2022 までは internal でアクセスできなかったが、 Unity 2023 からは public でアクセスできるようになった? 参考サイト様 https://docs.unity3d.com/ja/2023.2/ScriptReference/EditorApplication-updateMainWindowTitle.html
使用例 デフォルトだと font タグで使用するフォントアセットは Resources/Fonts & Materials/ フォルダに入れておく必要があるが、 TMP_Text.OnFontAssetRequest を使うと font タグで使用する フォントアセットを自由に設定できるため Resources を使わず…
使用例 Unity 2022.2 から使用できるようになった iOS / Android / ユニバーサル Windows プラットフォームで使用できる 参考サイト様