小编Uta*_*aru的帖子

如何在VSCode树视图中隐藏具有特定扩展名的文件

我使用VS3与Unity3D,我想知道有没有办法隐藏/忽略/过滤某些类型的文件,例如VSCode树视图中的*.meta文件?我无法在设置中找到任何合适的选项.

unity-game-engine visual-studio-code

12
推荐指数
2
解决办法
1757
查看次数

如何在检查器视图中更改 ReorderableList 的元素高度

我为 Journal 类创建了自定义检查器以显示List<T>ReorderableList<T>. 为了显示类结构我编写了以下代码:

private ReorderableList list;

private void OnEnable()
{
            list.drawElementCallback =
            (Rect rect, int index, bool isActive, bool isFocused) =>
            {
                rect = new Rect(rect.x, rect.y, rect.width, rect.height * 2);
                var element = list.serializedProperty.GetArrayElementAtIndex(index);
                rect.y += 2;
                EditorGUI.PropertyField(
                    new Rect(rect.x, rect.y, 100, EditorGUIUtility.singleLineHeight),
                    element.FindPropertyRelative("Name"), GUIContent.none);
                EditorGUI.PropertyField(
                    new Rect(rect.x + 100, rect.y, rect.width - 100, EditorGUIUtility.singleLineHeight),
                    element.FindPropertyRelative("Image"), GUIContent.none);
                EditorGUI.PropertyField(
                    new Rect(rect.x, rect.y + EditorGUIUtility.singleLineHeight + 2f, rect.width, EditorGUIUtility.singleLineHeight),
                    element.FindPropertyRelative("Description"), GUIContent.none);
            };
Run Code Online (Sandbox Code Playgroud)

我期望它会像这样显示:

[1: Name] [1: …
Run Code Online (Sandbox Code Playgroud)

c# unity-game-engine

6
推荐指数
1
解决办法
5436
查看次数

VS Code的launch.json在调试后继续重置

我正在使用VS Code的调试器来调试我的Unity3D项目.每次我启动调试器消息时都会出现读取

请添加属性"request":"attach"到您的配置.

我按下配置按钮(带有齿轮图标),它在文本编辑器中打开"launch.json"文件,然后我添加"请求":"附加"行到配置,启动调试器 - 一切正常.但是在我停止调试并尝试再次启动之后,我必须再次执行相同的操作,因为行"request":"attach"由于某种原因消失了.

有谁知道如何使VS Code不重置配置文件?

debugging unity-game-engine visual-studio-code

6
推荐指数
0
解决办法
367
查看次数

索尼Xperia游戏崩溃

电话:索尼Xperia LT25i.

我安装了游戏.推出它.看到黑屏和无响应的应用程序.

并且logcat在控制台中继续发送垃圾邮件:

W/Adreno-EGL(23297): <qeglDrvAPI_eglCreateContext:2342>: EGL_BAD_ATTRIBUTE
W/Adreno-EGL(23297): <qeglDrvAPI_eglCreateContext:2342>: EGL_BAD_ATTRIBUTE
I/Unity   (23297): Skipped frame because GfxDevice is in invalid state (device lost)
I/Unity   (23297):  
I/Unity   (23297): (Filename:  Line: 1585)
I/Unity   (23297):  
Run Code Online (Sandbox Code Playgroud)

有没有人知道最新情况以及如何解决这个问题?

我尝试过不同的应用.我甚至用空场景创建了空项目 - 结果相同.

android unity-game-engine sony-xperia

5
推荐指数
1
解决办法
638
查看次数