2022-08-25から1日間の記事一覧
概要 Preferences の「Version Control > Confirmation」の 「When files are created」を「Do not add」にする 参考サイト様
概要 visualElement.Insert( 0, pingButton ); Add ではなく Insert を使う
概要 // すべて True Debug.Log( typeof( bool ).IsValueType ); Debug.Log( typeof( byte ).IsValueType ); Debug.Log( typeof( sbyte ).IsValueType ); Debug.Log( typeof( char ).IsValueType ); Debug.Log( typeof( decimal ).IsValueType ); Debug.Log(…
概要 var array1 = new int[ 0 ]; var array2 = new string[ 0 ]; var array3 = new Vector3[ 0 ]; Debug.Log( array1.GetType().IsArray ); Debug.Log( array2.GetType().IsArray ); Debug.Log( array3.GetType().IsArray ); 参考サイト様
概要 var dictionary1 = new Dictionary<int, string>(); var dictionary2 = new Dictionary<int, Vector3>(); Debug.Log( typeof( Dictionary<,> ).IsAssignableFrom( dictionary1.GetType().GetGenericTypeDefinition() ) ); Debug.Log( typeof( Dictionary<,> ).IsAssignableFrom( di</int,></int,>…
概要 参考サイト様
概要 The target object is null. Check for missing scripts. Unity エディタで上記のエラーが発生する場合は 削除されたスクリプトを参照しているゲームオブジェクトが シーンに存在する可能性があります 「Missing」になっているスクリプトを右クリックし…
はじめに using UnityEngine; public class Example : MonoBehaviour { private void OnValidate() { Apply(); } private void Apply() { var rectTransform = GetComponent<RectTransform>(); rectTransform.sizeDelta = new Vector2 ( Random.Range( 0f, 100f ), Random.R</recttransform>…
概要 Preferences の「Keymap」で「Main Menu > Window > Editor Tabs > Reopen Closed Tab」に ショートカットキーを割り当てると即座に閉じたタブを開けるようになる 参考サイト様
参考サイト様
ソースコード using System; using System.Collections.Generic; using System.IO; using System.Reflection; using UnityEditor; using UnityEditor.PackageManager.UI; using UnityEditorInternal; using UnityEngine.UIElements; using PackageInfo = Uni…
概要 Preferences の「Editor > Color Scheme > General」の 「Editor > Selection background」の「Background」の色を変更する
概要 「システム環境設定 > セキュリティとプライバシー > 画面収録」で 「Rider.app」のチェックを外したら正常に動作するようになった
概要 https://zenn.dev/topics/unity/feed 上記の URL を RSS リーダに追加する
ソースコード using JetBrains.Annotations; using UnityEditor; using UnityEditor.DeviceSimulation; using UnityEngine.UIElements; namespace Kogane.Internal { [UsedImplicitly] internal sealed class DeviceSimulatorMuteAudioPlugin : DeviceSimula…