gaokaihaha / myunityframework Goto Github PK
View Code? Open in Web Editor NEW我的Unity框架,包含资源加载,配置加载,数据加载,UI管理,日志管理,动画系统,特效系统
我的Unity框架,包含资源加载,配置加载,数据加载,UI管理,日志管理,动画系统,特效系统
Hi!
In the demo, I see some class extend from IApplicationStatus. How to use it and what does it for?
What is it role in MVC model or it does not belong to MVC model?
Is every UIWindow need an IApplicationStatus?
Thank in advance!
PathUitls JsonUitls相关实现文件作者是否是忘提交了?
Hi @GaoKaiHaHa
Recently when update new code we have this error on the demo scene (Scene/main):
Exception: UICameraList is null !
UILayerManager.GetUICameraDataByKey (System.String key) (at Assets/Script/Core/UI/Control/UILayerManager.cs:104)
UILayerManager.SetLayer (.UIWindowBase ui, System.String cameraKey) (at Assets/Script/Core/UI/Control/UILayerManager.cs:56)
UIManager.CreateUIWindow (System.String UIName) (at Assets/Script/Core/UI/Control/UIManager.cs:256)
UIManager.OpenUIWindow (System.String UIName, .UICallBack callback, System.Object[] objs) (at Assets/Script/Core/UI/Control/UIManager.cs:274)
UIManager.OpenUIWindow[testWindow] () (at Assets/Script/Core/UI/Control/UIManager.cs:301)
FirstStatus.OnEnterStatus () (at Assets/Script/GameStatus/FirstStatus.cs:20)
ApplicationStatusManager.EnterStatus (System.String statusName, Boolean isFade) (at Assets/Script/Core/Application/ApplicationStatusManager.cs:99)
ApplicationManager.AppLaunch () (at Assets/Script/Core/Application/ApplicationManager.cs:121)
ApplicationManager.Awake () (at Assets/Script/Core/Application/ApplicationManager.cs:73)
Hi @GaoKaiHaHa !
Please update the wiki and Global Event!
Many thank for this!
Hi!
I just found this is an awesome framework to start with!
I need a small tutorial or sample to understand how UIWindowBase works.
Would you please quick note how to make a screen with:
Button Setting: Open Popup Setting
Button Shop: Open Popup Shop
Button Start Game - > Open New Game Scene
In Scene Game, it will be great if you can demo the use of
GameUI,
Fixed,
Normal,
TopBar,
PopUp
Big thankyou to you!
Hi @GaoKaiHaHa !
Please update session "SDK Manager". I want to learn how to use SDK Manager to perform ads show, hide
Thank so much!
Hi @GaoKaiHaHa
This code version has some error like:
Assets/Script/SDK/GoogleLogin.cs(14,26): error CS0115: `GoogleLogin.Login()' is marked as an override but no suitable method found to override
Assets/Script/UI/ShopWindow/ShopWindow.cs(14,20): error CS1502: The best overloaded method match for `ScrollRectInput.Init(string, int)' has some invalid arguments
Duplicate class declares: TableConfigFieldInfo
-- And many more
Could you please check and update the code?
Thank so much!
Hi @GaoKaiHaHa
Please add some new tutorial to wiki session!
I like to learn how "Data, configuration, and persistent data" works - how multi-language is applied,
how to use "SDK Manager" to config s_logServiceList...
Thank so much for your support!
Hi @GaoKaiHaHa !
I think we can add a menu item on the window to just export what is needed (base code) to a .unitypackage (like plugins)
This will exclude example assets and other things that do not need for the framework to works well
So when we create a new game or update game, we only need to import MyUnityFrameWork unity package.
Thank so much!
端游中经常见到角色、背包、商城、技能等面板是可以同时显示的,只不过有个谁在上层谁在下层的问题,通常激活的窗口处于最顶层,最先打开的窗口在最低层,而且这些窗口还可以拖拽,我就想知道咱们现在这个UI管理器的设计能不能支持这种情况呢?
Hi @GaoKaiHaHa !
Please update quick note and simple about
Beginner's guide
Lua
Game Object Manager
Audio Manager
Animation system
...
Thank so much!
Hi @GaoKaiHaHa
I just follow 2 steps in https://github.com/GaoKaiHaHa/MyUnityFrameWork/wiki/Beginner's-guide
Tools -> 新手引导(Beginner's guide) -> 初始化(initialization)
Tools -> 新手引导(Beginner's guide) -> 创建新手引导预设(Create Beginner's guide Perfab)
But now we have the error when adding RectTransform into the mask and then error when assign value here:
//1
Can't add component 'RectTransform' to mask because such a component is already added to the game object!
UnityEngine.GameObject:AddComponent()
UICreateService:CreateGuideWindow() (at Assets/Script/Core/Editor/UI/UICreateService.cs:330)
GuideSystemEditor:CreateGuideSystemWidnow() (at Assets/Script/Core/Editor/GuideSystem/GuideSystemEditor.cs:53)
///2
NullReferenceException: Object reference not set to an instance of an object
UICreateService.CreateGuideWindow () (at Assets/Script/Core/Editor/UI/UICreateService.cs:331)
GuideSystemEditor.CreateGuideSystemWidnow () (at Assets/Script/Core/Editor/GuideSystem/GuideSystemEditor.cs:53)
Thanks!
PrecompiledAssemblyException: Multiple precompiled assemblies with the same name CString.dll included for the current platform. Only one assembly with the same name is allowed per platform. Assembly path: {0}
UnityEditor.Scripting.ScriptCompilation.EditorBuildRules.CreateTargetAssemblies (IEnumerable1 customScriptAssemblies, IEnumerable
1 precompiledAssemblies) (at C:/buildslave/unity/build/Editor/Mono/Scripting/ScriptCompilation/EditorBuildRules.cs:249)
UnityEditor.Scripting.ScriptCompilation.EditorCompilation.UpdateCustomTargetAssemblies () (at C:/buildslave/unity/build/Editor/Mono/Scripting/ScriptCompilation/EditorCompilation.cs:625)
UnityEditor.Scripting.ScriptCompilation.EditorCompilation.SetAllCustomScriptAssemblyJsons (System.String[] paths) (at C:/buildslave/unity/build/Editor/Mono/Scripting/ScriptCompilation/EditorCompilation.cs:735)
UnityEditor.Scripting.ScriptCompilation.EditorCompilationInterface.SetAllCustomScriptAssemblyJsons (System.String[] allAssemblyJsons) (at C:/buildslave/unity/build/Editor/Mono/Scripting/ScriptCompilation/EditorCompilationInterface.cs:217)
第一次打开什么都没改
Hi @GaoKaiHaHa !
Inside "Resource Management" there is "Hot update" feature that is missing.
Please update or create a new wiki page, thank you so much!
UnityEngine.UnassignedReferenceException: The variable m_TipTransfrom of GuideWindow has not been assigned.
You probably need to assign the m_TipTransfrom variable of the GuideWindow script in the inspector.
Timer Update 中一次性RemoveAll完结的Timer,避免多次Array.Copy
请问server需要配置什么?
Readme中有提到该框架提供3D模型投射到UI上的工具,请问入口在哪里,菜单里都找了,没有找到。 @GaoKaiHaHa
5.X的版本 有报错
Assets/Script/Core/SDKManager/PayImplements/Android/Weixin/WXPayClass.cs(32,27): error CS0246: The type or namespace name `PrePay2Client' could not be found. Are you missing an assembly reference?
Hi!
After update to Unity 2017.3 I have error when open 打包设置管理器(Package Settings Manager) window:
(Unity 2017.2 works well) Thank so much!
IndexOutOfRangeException: Array index is out of range.
UnityEditor.MaskFieldGUI.GetMenuOptions (Int32 mask, System.String[] flagNames, System.Int32[] flagValues, System.String& buttonText, System.String[]& optionNames, System.Int32[]& optionMaskValues, System.Int32[]& selectedOptions) (at /Users/builduser/buildslave/unity/build/Editor/Mono/GUI/MaskFieldGUI.cs:157)
UnityEditor.MaskFieldGUI.DoMaskField (Rect position, Int32 controlID, Int32 mask, System.String[] flagNames, System.Int32[] flagValues, UnityEngine.GUIStyle style, System.Int32& changedFlags, System.Boolean& changedToValue) (at /Users/builduser/buildslave/unity/build/Editor/Mono/GUI/MaskFieldGUI.cs:114)
UnityEditor.MaskFieldGUI.DoMaskField (Rect position, Int32 controlID, Int32 mask, System.String[] flagNames, UnityEngine.GUIStyle style, System.Int32& changedFlags, System.Boolean& changedToValue) (at /Users/builduser/buildslave/unity/build/Editor/Mono/GUI/MaskFieldGUI.cs:100)
UnityEditor.MaskFieldGUI.DoMaskField (Rect position, Int32 controlID, Int32 mask, System.String[] flagNames, UnityEngine.GUIStyle style) (at /Users/builduser/buildslave/unity/build/Editor/Mono/GUI/MaskFieldGUI.cs:84)
UnityEditor.EditorGUI.MaskFieldInternal (Rect position, Int32 mask, System.String[] displayedOptions, UnityEngine.GUIStyle style) (at /Users/builduser/buildslave/unity/build/Editor/Mono/EditorGUI.cs:3119)
UnityEditor.EditorGUI.MaskField (Rect position, Int32 mask, System.String[] displayedOptions, UnityEngine.GUIStyle style) (at /Users/builduser/buildslave/unity/build/artifacts/generated/common/editor/EditorGUIBindings.gen.cs:782)
UnityEditor.EditorGUILayout.MaskField (Int32 mask, System.String[] displayedOptions, UnityEngine.GUILayoutOption[] options) (at /Users/builduser/buildslave/unity/build/Editor/Mono/EditorGUI.cs:7196)
BundleConfigEditorWindow.OnGUI () (at Assets/Script/Core/Editor/Package/PackageConfigEditorWindow.cs:81)
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)
Rethrow as TargetInvocationException: Exception has been thrown by the target of an invocation.
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MonoMethod.cs:232)
System.Reflection.MethodBase.Invoke (System.Object obj, System.Object[] parameters) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MethodBase.cs:115)
UnityEditor.HostView.Invoke (System.String methodName, System.Object obj) (at /Users/builduser/buildslave/unity/build/Editor/Mono/HostView.cs:295)
UnityEditor.HostView.Invoke (System.String methodName) (at /Users/builduser/buildslave/unity/build/Editor/Mono/HostView.cs:288)
UnityEditor.HostView.InvokeOnGUI (Rect onGUIPosition) (at /Users/builduser/buildslave/unity/build/Editor/Mono/HostView.cs:255)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)
我自己的理解是,配置是key,value串,数据更像是表格
但是数据如果需要使用嵌套类型,需要怎么操作呀
还有在配置里看到了可将类序列化保存到配置中,保存之后是可以自动生成类的吗,要怎么生成呢。
JsonUtils等相关的实现文件还是没有
Hi @GaoKaiHaHa
We should add into framework feature that when show popup window that not fullscreen, then a translucent with fading effect will appear. It will block touch to other windows under the background. When user close popup, it is simple to disable.
Thank so much!
Hi @GaoKaiHaHa
The error on Guide system now gone, I follow the wiki to create simple guide system but actually it quite hard for me to start.
Would you please add to GUI example (that have a menu, setting, shop and main game window so far) this tutorial:
Thank so much for supporting me!
Hi @GaoKaiHaHa !
What should you comment on storing image, sprite of a game?
Should we include inside Resources folder and then later in production we make it Streaming Assets (Asset Bundle).
Or should we create Sprites folder inside Assets folder and put those images into this?
Thank so much!
Hi @GaoKaiHaHa Do you have any experience with build ios?
For now, I am having this error below.
Could you please take a note how to config LUA to export build for ios?
Thank so much!
Undefined symbols for architecture arm64:
"_tolua_lateupdate", referenced from:
_LuaDLL_tolua_lateupdate_m178229348 in Bulk_Assembly-CSharp_3.o
_LuaStatePtr_LuaLateUpdate_m3971650425 in Bulk_Assembly-CSharp_3.o
(maybe you meant: _LuaDLL_tolua_lateupdate_m178229348)
"_tolua_update", referenced from:
_LuaDLL_tolua_update_m351421198 in Bulk_Assembly-CSharp_3.o
_LuaStatePtr_LuaUpdate_m921402014 in Bulk_Assembly-CSharp_3.o
(maybe you meant: _LuaDLL_tolua_update_m351421198)
"_tolua_pushresult", referenced from:
_LuaDLL_tolua_pushresult_m2778333851 in Bulk_Assembly-CSharp_3.o
(maybe you meant: _LuaDLL_tolua_pushresult_m2778333851)
"_tolua_addstring", referenced from:
_LuaDLL_tolua_addstring_m3017661005 in Bulk_Assembly-CSharp_3.o
(maybe you meant: _LuaDLL_tolua_addstring_m3017661005)
"_tolua_pushcfunction", referenced from:
_LuaDLL_tolua_pushcfunction_m656370259 in Bulk_Assembly-CSharp_3.o
_LuaDLL_tolua_pushcfunction_m3366310567 in Bulk_Assembly-CSharp_3.o
(maybe you meant: _LuaDLL_tolua_pushcfunction_m656370259, _LuaDLL_tolua_pushcfunction_m3366310567 , _LuaDLL_tolua_pushcfunction_m3366310567_MetadataUsageId )
"_tolua_setflag", referenced from:
_LuaDLL_tolua_setflag_m1772645268 in Bulk_Assembly-CSharp_3.o
Hi!
Our GUI manager works great with single unity scene.
For multi-scene is there any difference in architect?
Would you please support code to change between scene and loading scene effect for that?
Thank so much!
初始化lua后 对应的测试lua文件没有生出来
Hi @GaoKaiHaHa!
I am getting stuck in organize GUI (UIWindow) and Unity Game Object (Transform with Sprite Component,..)
I am using one Unity Scene for all Windows (MainMenu, Setting, MainGame, PauseGame ...),
so should I put the game object into MainGame GUI Prefab or separate it at new Game Object on Hierarchy and enable it when we Open the MainGame Window?
What is the best practice of organizing in-game object if we using One Unity Scene for the game
Thank so much!
PathUtils、JsonUtils等相关的实现文件作者是否忘记提交了?
Hi!
I can see we have a lot of function to write the logic each window UI, it is really awesome! Can you tell more about the lifecycle of those methods and common usage pattern?
OnInit()
OnOpen()
OnClose()
OnHide()
OnShow()
OnRefresh() . -- This usage pattern example? What kind of UI event will active this method?
Why we usually using OnOpen and OnClose but not OnShow and OnHide?
And one more thing I am very confused is why we using AddOnClickListener on OnOpen but do not have to remove it on OnClose (and why don't use it in OnInit ), So maybe we have an issue that duplicated events somewhere?
Thank you so much! I am learning it day by day!
Hi @GaoKaiHaHa
When Anim GUI, I need chain (sequence like DoTween) some AnimData. For now, as I know we only can do this by delay and choose right timing between AnimData.
Please support that feature!
FileUtils.cs文件作者是否忘记提交了
TableConfigFieldInfo中的ShowGUIName特性不存在 是否忘记提交
帧同步服务端dome 差一些配置文件
Hi!
After reading wiki and viewing example code, i still have some confuse about Data, Configuration and Persistent data.
Thank so much!
Hi!
When using with UI system, I think we should keep a list of the open window in a stack so we can push and pop the latest window.
With that support, we can easily implement default back behavior on Android by call CloseLastOpenedUI(), we can easily close the latest open popup ... without knowing the name of the window
What do you think about that?
Thank so much!
RT,在本项目中没有见到类似的DEMO,网络的那块代码有点复杂,不知从何入手,如果项目中有支持的话,希望作者能在百忙之中给与指点,感激不尽!
项目中没有LuaBinder类
请问ResourcesManifest.json
是如何生成的?
Hi @GaoKaiHaHa
Today when build and run game on ios (Unity 2018), using Asset Bundle system
Everything works fine on Android and Editor
I have this error on iPhone - xCode log
Could not open file archive:/CAB-MainMenuWindow/CAB-MainMenuWindow.resS for read
(Filename: Line: 56)
async texture load: failed to load Btn_Play_1 from archive:/CAB-MainMenuWindow/CAB-MainMenuWindow.resS
After Google, I see it is unity bugs:
https://forum.unity.com/threads/opening-file-failed-opening-file-archive-cab-ca6e2cdc278a53641b19581a975bffc5-cab-ca6e2cdc278a53641.488402/
https://issuetracker.unity3d.com/issues/cancelling-displaydialog-dot-error-is-being-thrown-when-entering-the-play-mode-after-assetbundle-dot-unload-false
Just open this issue to track the bugs
Meanwhile, if you can have a way to workaround, please update
Thanks
例如游戏内数据变动了,需要刷新UI,是怎么从数据那边推送到UI上的啊
Hi again!
I want to understand what is common and best way to pass data between UIWindowBase (window)
For example:
Thank so much!
请问作者有Demo没
Hi!
I see in readme we have "Networked system" session!
Please add some info to wiki
What is server we use with our client?
It is awesome if you have a simple demo about server and client!
Thank so much!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.