可以手动插入分组属性:类型是 TYPE_NIL,name 就是这个分组显示的名称,usage 需要是 PROPERTY_USAGE_GROUP,hint_string 为空就是后续的所有属性都是该分组里的,非空就是后续的 name 前缀与 hint_string 匹配才算该分组里的。详细可以看 https://docs.godotengine.org/en/3.5/classes/class_editorinspector.html ...
hint_string="GDScript",# 类型为 GDScript})# 比上次的小,则减少属性 elif diff<0:varidx=-1foriinabs(diff):idx=__script_list.size()-1__script_list.remove(idx);script_count=value # 更新属性表property_list_changed_notify()func_get_property_list():# 属性列表varp_list=[]# 属性类别 p_lis...
()->is_editor_hint(), &plugin_callbacks_res, &managed_callbacks,// 存放c#暴露给引擎 的所有函数 interop_funcs, // 存放引擎提供给脚本 的所有函数 interop_funcs_size); } void CSharpLanguage::_editor_init_callback() { int32_t interop_funcs_size = 0; // 注册editor 相关操作到c# const ...
string json=file.GetAsText(); //解析json var jsonResult=Json.ParseString(json); var data=jsonResult.AsGodotDictionary(); if(data==null) { return; } saveData = new SaveData() { meta_upgrade_currency = (int)data["meta_upgrade_currency"], meta_upgrades = data["meta_upgrades"].As<Dic...
"hint_string": "one,two,three" } ProjectSettings.add_property_info(property_info) [/gdscript] [csharp] ProjectSettings.Singleton.Set("category/property_name", 0); var propertyInfo = new Godot.Collections.Dictionary { {"name", "category/propertyName"}, {"type", (int)Variant.T...
目前的解决方法是,使用了吧主的方法判断.点号,然后再使用get_word_at_pos获取点号前面的单词。另外有请教一下set_code_hint函数,函数在左侧的时候,代码提示的时候显示不全,怎么解决?能设置提示文本的显示位置吗?CodeEdit的is_in_string怎么使用?无论我输入什么字符都是返回-1。
1.修改添加release 的keystore文件为非本项目资源浏览方式,这样就不必把keystore文件复制到godot项目内。p_list->push_back( PropertyInfo( Variant::STRING, "keystore/release",PROPERTY_HINT_FILE,"keystore") );改为p_list->push_back( PropertyInfo( Variant::STRING, "keystore/release",PROPERTY_HINT_...
21. export(String,DIR) var f # string is a path to a directory # 字符串是目录 22. export(String,FILE,"*.txt") var f # string is a path to a file, custom filter provided as hint # 字符串是一个文件路径,自定义过滤器提示
func get_goods_data(goods_name: String): var data = goods_data[goods_name] # 物品数据 var temp = {} # 设置资源的格式:变量[属性名] = 属性值 temp[GoodsPropertyList.Name] = data['Name'] temp[GoodsPropertyList.Damage] = int(data['Damage']) ...
Fix PropertyInfo to use hint/usage default constants by @Naros in #1440 [Math] Add is_finite methods by @AThousandShips in #1436 Implement to/from dict helpers for PropertyInfo/MethodInfo by @Naros in #1443 Fix create instance func by @pupil1337 in #1431 Give compile-time error if register...