Action map asset bug

I think this is actually a Unity bug (attached).

I've encountered it in my own tool efforts, but this is particularly bizarre.

I've had to edit some script to be able to find out what all those assets actually are :P

2598968--182038--InputBug.JPG

I have run into the same issue. If you name a subasset something that comes alphanumerically before the name of the parent/main asset, visually the subasset will show up as the same name as the parent/main asset, and might even be positioned where you would except the parent/main asset to be.

If you force text on asset files and examine the asset, you can see that the names in the files are all correct.

I believe that this issue is at least partly due to the fact that there is no real hierarchy system for nested assets, and they will be ordered by name regardless of whether an object is a parent or a child. If the child is first in the ordering, it will be displayed with the name of the parent/main asset because the engine makes sure that first asset in that list is always displayed as the parent/main asset.

This is almost certainly a general Unity bug because I was able to replicate the issue in a separate project, one that does not include the New Input System. I will post repro steps in my next comment.

Repro Steps (method from scratch):
1. Open a Unity project.
2. Create an empty GameObject.
3. Download the script attachment from this message.
4. Attach the 'Tester' script to your empty GameObject.
5. Hit 'Play' in the editor.
6. Look in the assets folder for the generated assets. You will see that the sub-asset named "AGiraffe" actually is displayed as "Giraffe" because of the reasons in the previous post.

Repro Steps(method from Unity's input-prototype-demo project):
1. Download Unity's demo project from here.
2. Extract the zip file and open the Unity project contained within.
3. Navigate to /Assets/Demo/Assets/.
4. Expand the file 'FirstPersonControls.asset'.
5. Notice that there are two assets in the hierarchy named 'FirstPersonControls'.
6. Open the asset file in a text editor, and node that there is actual only one object in the asset hierarchy named 'FirstPersonControls', even though there are two displayed in the editor.

2603262--182391--Tester.cs (902 Bytes)

Same issue here, very annoying, even though this new feature is experimental. I now have to selected the last subasset with the main asset's name and put that in the Player Input component. Also have to redo this with every change I make in the actionmap, since it will generate a new subasset with the changes..

I take it you've filed bug reports on this? We'd like to chime in and say "fixit!" 'cause we are running into it too.