hertzole / advanced-level-editor Goto Github PK
View Code? Open in Web Editor NEWAdvanced, but simple to use, runtime level editor for Unity.
License: MIT License
Advanced, but simple to use, runtime level editor for Unity.
License: MIT License
for example , By using UniTask, you can simplify your asynchronous operation of this modal window.
as unitask can await button's onclick event , and can await more then one button .
so you can do like this (fake logic snippet):
public class Notifacation:MonoBehaviours
{
static Notifacation instance;
public async static int ShowNoticeAsync(string message)
{
instance.text.text = message;
await instanc.background.fadeinasync(); // by dotween maybe
var index= await Unitask.WhenAny(instance.bt0.onclick,instance.bt1.onclick);
instance.gameobject.setactive(false);
return index;
}
}
how to use?
public void OnCreateNewLevelRequred =>_=CreateLevelAsync(); // new level button's onclick callback list add this fuction
private async void CreateLevelAsync()
{
if(editor.IsDirty)
{
var index = await Notifacation.ShowNoticeAsync(“you message here”);
if(index==0)
{
// user say yes.
CreateNewLevel();
}
else if(index==1)
{
// user say no. do nothing maybe
}
}
}
Bug description:
keyboard can effect both Inputfiled and gizmos at the same time.
To reproduce:
Expected behavior:
do not effect gizmos when keyin some words.
Screenshots:
Desktop and versions:
Additional context:
can alse perform drag when save level modal is display.
Is your feature request related to a problem? Please describe.
Add keyboard shortcuts for certain actions, like duplicate, delete, copy, and paste.
Duplicate the selected objects with hotkey:CTRL + D
when select a leveleditorobject , no ways for us to delete it.
Bug description:
If an exposed value has no default value or is just null by default, the equals check in SetValue can fail and give a null reference exception.
To reproduce:
Make a new class type variable and don't give it a value, like a string.
Mark it as exposed.
Try to set the value.
Expected behavior:
The value should be set without any issues.
Bug description:
If you have an object without any exposed properties and enter play mode, it will give you a null reference exception when trying to save all the exposed properties.
To reproduce:
Have one object without any exposed properties.
Enter runtime play mode.
Witness error.
Expected behavior:
It should not give an error.
Is your feature request related to a problem? Please describe.
Installing ALE with the package manager isn't enough.
Aditionally message pack .NET needs to be downloaded from the github page 'actions' section (release unitypackage is broken)
and the Microsoft.NET.StringTools.dll and System.Runtime.CompilerServices.Unsafe.dll need to be extracted into the plugins folder.
Describe the solution you'd like
Including this extra info into the docs would be nice.
Bug description:
The sample scene has 86 of these warnings
As a result the sample scene doesn't work properly
To reproduce:
Import sample with package manager
Open "ALE Completed Sample" in Assets/Samples/Advanced Level Editor/0.1.0-preview/Completed Scene
Press Play
Observe warnings in console
Expected behavior:
No warnings
The sample Scene works as expected
Desktop and versions:
This level editor is awesome, it has very advanced things as script editing but still dosent have something as duplicate objects, hope this is added on future
basicly i get errors on build with the package, but when i delete the folders i can build again
any help?
Bug description:
Sometimes this exception is thrown
Processing assembly Library/Bee/artifacts/1900b0aEDbg.dag/Assembly-CSharp.dll, with 138 defines and 350 references
processors: FishNet.CodeGenerating.ILCore.FishNetILPP, Hertzole.ALE.CodeGen.LevelEditorILProcessor, Unity.Entities.CodeGen.EntitiesILPostProcessors, Unity.Jobs.CodeGen.JobsILPostProcessor, zzzUnity.Burst.CodeGen.BurstILPostProcessor
running FishNet.CodeGenerating.ILCore.FishNetILPP
running Hertzole.ALE.CodeGen.LevelEditorILProcessor
Hertzole.ALE.CodeGen.LevelEditorILProcessor: ILPostProcessor has thrown an exception: System.ArgumentException: An item with the same key has already been added. Key: (Hertzole.ALE.ALEProcessedAttribute, .ctor, System.Type[])
at System.Collections.Generic.Dictionary`2.TryInsert(TKey key, TValue value, InsertionBehavior behavior)
at System.Collections.Generic.Dictionary`2.Add(TKey key, TValue value)
at Hertzole.ALE.CodeGen.WeaverExtensions.GetConstructor(ModuleDefinition module, Type type, Type[] parameters)
at Hertzole.ALE.CodeGen.WeaverExtensions.GetConstructor[T](ModuleDefinition module, Type[] parameters)
at Hertzole.ALE.CodeGen.Weaver.ProcessAssembly(ModuleDefinition module, String[] defines)
at Hertzole.ALE.CodeGen.LevelEditorILProcessor.Process(ICompiledAssembly compiledAssembly)
at Unity.ILPP.Runner.PostProcessingPipeline.PostProcessAssemblyAsync(PostProcessAssemblyRequest request, Action`2 progressSink)
PostProcessing failed: System.ArgumentException: An item with the same key has already been added. Key: (Hertzole.ALE.ALEProcessedAttribute, .ctor, System.Type[])
at System.Collections.Generic.Dictionary`2.TryInsert(TKey key, TValue value, InsertionBehavior behavior)
at System.Collections.Generic.Dictionary`2.Add(TKey key, TValue value)
at Hertzole.ALE.CodeGen.WeaverExtensions.GetConstructor(ModuleDefinition module, Type type, Type[] parameters)
at Hertzole.ALE.CodeGen.WeaverExtensions.GetConstructor[T](ModuleDefinition module, Type[] parameters)
at Hertzole.ALE.CodeGen.Weaver.ProcessAssembly(ModuleDefinition module, String[] defines)
at Hertzole.ALE.CodeGen.LevelEditorILProcessor.Process(ICompiledAssembly compiledAssembly)
at Unity.ILPP.Runner.PostProcessingPipeline.PostProcessAssemblyAsync(PostProcessAssemblyRequest request, Action`2 progressSink)
at Unity.ILPP.Runner.PostProcessingService.PostProcessAssembly(PostProcessAssemblyRequest request, IServerStreamWriter`1 responseStream, ServerCallContext context)
Unhandled Exception: System.InvalidOperationException: Post processing failed
at Unity.ILPP.Trigger.TriggerApp.<ProcessArgumentsAsync>d__1.MoveNext() + 0xf74
--- End of stack trace from previous location ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20
at Unity.ILPP.Trigger.TriggerApp.<ProcessArgumentsAsync>d__1.MoveNext() + 0x1149
--- End of stack trace from previous location ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb6
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task) + 0x42
at Unity.ILPP.Trigger.TriggerApp.<RunAsync>d__0.MoveNext() + 0xc7
--- End of stack trace from previous location ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb6
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task) + 0x42
at Program.<<Main>$>d__0.MoveNext() + 0x1a3
--- End of stack trace from previous location ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb6
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task) + 0x42
at Program.<Main>(String[]) + 0x20
at Unity.ILPP.Trigger!<BaseAddress>+0x47890b
I believe that in ModuleExtensions the method on line 194 is the culprit.
public static MethodReference GetConstructor(this ModuleDefinition module, Type type, params Type[] parameters)
{
if (cachedParameterMethods.TryGetValue((type, ".ctor", parameters), out var cachedMethod))
{
return cachedMethod;
}
MethodReference result = module.ImportReference(type.GetConstructor(parameters));
if (result == null)
{
throw new ArgumentException($"There's no constructor with those parameters in type {type.FullName}");
}
cachedParameterMethods.Add((type, ".ctor", parameters), result);
return result;
}
As far as I understand, when cachedParamterMethods.Add is called, the key is already present in the dictionary, even though that should be impossible in normal circumstances. Could this have something to do with multithreading?
I pushed a fix to my fork of ALE. If it works as intended I'll make a PR.
Desktop and versions:
Ive tried lots of things, but didnt work, whenever i try to set something with decimals in the inspector it eliminates the commas and makes seting position very complicated
Bug description:
When doing customData.AddCustomData, the type of said data is not registered as a valid type. This results in the type not being able to be serialized at all unless you manually add it.
To reproduce:
Make a new type and don't use it anywhere else but in custom data.
Try to serialize.
It should now say it hasn't been registered.
Expected behavior:
It should be registered and can be saved without issues.
What I want to do:
I would like to know what level is currently loaded.
What I've tried:
Looked through the code but couldn't find anything.
How it could be improved:
A field that has a reference to the currently loaded level.
Is your feature request related to a problem? Please describe.
As far as I can tell this method's common implementation is the generation of new LevelEdtorSaveData and it doesn't actually get an already existing instance of LevelEditorSaveData.
Describe the solution you'd like
Rename to GenerateLevelDataFromScenery
Describe alternatives you've considered
Idk, I'm sure there are better names than "[...]FromScenery"
Additional context
At first, I was incorrectly using this method, because I assumed that it would return already present LevelEditorSaveData.
Fully implement a undo/redo system.
Todo list:
maybe you should change the OnDestory Callback to OnApplicationQuit callback as Object Instance may destory before LevelEditorObjectManager .
Bug description:
When changing the name of an object in the inspector, the name doesn't update in the hierarchy.
To reproduce:
Rename an object and observe how it wasn't updated in the hierarchy.
Expected behavior:
The name should be updated to the new name in the hierarchy.
Is your feature request related to a problem? Please describe.
When clicking on empty space in the Hierarchy nothing happens and selection stays. Which feels like a bad user experiance.
Describe the solution you'd like
When clicking on empty space in the Hierarchy it should unselect whatever is currently selected.
Is your feature request related to a problem? Please describe.
As the title says, allow the user to delete levels from the load level dialog. There should be a confirmation before deleting the level.
Bug description:
Some types, like arrays and enums, can not be serialized when building to IL2CPP.
Expected behavior:
It should serialize.
Additional context:
Can be solved by implementing a resolver that points the types to an ArrayFormatter, GenericEnumFormatter, etc.
Is your feature request related to a problem? Please describe.
If you want an object to not have the ability to have children or be a child. That is not possible.
Describe the solution you'd like
Ability to disable reparent/children for an object.
Bug description:
change one level from another ,when there has same type model ,say "cube" maybe,then after level changed the cube can not select from free space.
To reproduce:
Expected behavior:
no matter how many times change the level. contents inside the level should be selected.
but the gameobject appeared before will not be select in the other level.
Screenshots:
Desktop and versions:
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.