当前位置:网站首页>Unity 构建错误:当前上下文中不存在名称“EditorUtility”
Unity 构建错误:当前上下文中不存在名称“EditorUtility”
2022-07-07 10:46:00 【charlsdm】
您现在出现错误的原因是,Unity 在为其设计的编译时删除了“UnityEditor”命名空间。这就是为什么当您尝试在平台上使用它时,“EditorUtility”将永远不会存在于除 UnityEditor 之外的任何平台上。因为“EditorUtility”在“UnityEditor”命名空间中。
因此,如果您想使用“EditorUtility”执行与在 Unity 编辑器中所做的相同的工作,您应该像他们一样实现它。
#if UNITY_EDITOR
EditorUtility.DisplayDialog(“Great!”, “You got the pattern right!”, “Next Level!”);
#else
YOUROWNCLASS.DisplayDialog(“Great!”, “You got the pattern right!”, “Next Level!”);
#endif
边栏推荐
- CMU15445 (Fall 2019) 之 Project#2 - Hash Table 详解
- ACL 2022 | 序列标注的小样本NER:融合标签语义的双塔BERT模型
- The IDM server response shows that you do not have permission to download the solution tutorial
- Financial data acquisition (III) when a crawler encounters a web page that needs to scroll with the mouse wheel to refresh the data (nanny level tutorial)
- PHP调用纯真IP数据库返回具体地址
- What if does not match your user account appears when submitting the code?
- BGP third experiment report
- ICLR 2022 | 基于对抗自注意力机制的预训练语言模型
- 2022 examination questions and online simulation examination for safety production management personnel of hazardous chemical production units
- Cookie
猜你喜欢
[statistical learning methods] learning notes - improvement methods
leetcode刷题:二叉树23(二叉搜索树中的众数)
如何将 @Transactional 事务注解运用到炉火纯青?
What if does not match your user account appears when submitting the code?
Importance of database security
图像像素读写操作
JS to convert array to tree data
Session
IPv6 experiment
ACL 2022 | 序列标注的小样本NER:融合标签语义的双塔BERT模型
随机推荐
《ASP.NET Core 6框架揭秘》样章[200页/5章]
Design and implementation of communication protocol
红杉中国完成新一期90亿美元基金募集
[Q&A]AttributeError: module ‘signal‘ has no attribute ‘SIGALRM‘
layer弹出层的关闭问题
Leetcode skimming: binary tree 23 (mode in binary search tree)
Utiliser la pile pour convertir le binaire en décimal
2022-07-07日报:GAN发明者Ian Goodfellow正式加入DeepMind
数据库安全的重要性
[learn wechat from 0] [00] Course Overview
Realize all, race, allsettled and any of the simple version of promise by yourself
ACL 2022 | small sample ner of sequence annotation: dual tower Bert model integrating tag semantics
2022聚合工艺考试题模拟考试题库及在线模拟考试
Day-19 IO stream
Decrypt gd32 MCU product family, how to choose the development board?
@Resource和@Autowired的区别?
Leetcode skimming: binary tree 22 (minimum absolute difference of binary search tree)
[statistical learning methods] learning notes - Chapter 5: Decision Tree
【从 0 开始学微服务】【00】课程概述
2022a special equipment related management (boiler, pressure vessel and pressure pipeline) simulated examination question bank simulated examination platform operation