Search Unity

Power Inspector | Complete Inspector Rewrite

Discussion in 'Assets and Asset Store' started by SisusCo, Aug 28, 2019.

?

What Are Your Favorite Features?

  1. Back and Forward Buttons

  2. Search Box

  3. Split View

  4. Copy-Paste

  5. Debug Mode+

  6. Quick Invoke Menu

  7. Create Script Wizard

  8. Keyboard Friendly

  9. Improved Tooltips

  10. Target Window

Multiple votes are allowed.
Results are only viewable after voting.
  1. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    Been using the asset quite a bit lately and I though I'd let you know about some things that I've found.

    - Attempting to use the Ground option, found by right clicking an object's Transform position, results in an exception and resets the object to position 0,0,0.
    - C# Script Wizard exceptions when invoked from the root (Assets) folder.
    - C# Script Wizard adds an unnecessary "Assets/" at the beginning of the "Save Path" which leads to creating an incorrect folder structure.

    - C# Script Wizard uses the default "MonoBehaviour" Template on invoke, regardless if it was changed in a prior invoke of the tool.
    - It would be nice if those component divisor arrows remembered their position on a per component basis if possible.
    - Material Inspector is a bit crammed. Adding a divisor arrow to control that, like in other components, would be nice if at all possible.


    Unity 2020.2.0b1
    Windows Build Support (IL2CPP)
    is the only platform module installed
    HDRP is the project template
    API Compatibility Level is set by default as .NET Standard 2.0
    Scripting Backend
    is set by default as IL2CPP
    Power Inspector 1.4.5
    is the only asset imported

    Hope this all made sense :confused:
     
    Last edited: Sep 9, 2020
  2. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    @Bezoro Great ideas and bug findings, cheers!

    I think I should be able to add/fix all of these for the next version, with the exception of adding a prefix column resizer to the material drawer. I think that the prefix column width is somehow hard-coded for the MaterialEditor, as I have been unable to adjust it at all yet no matter what tricks I have tried.
     
    Bezoro likes this.
  3. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    A bit of a shame about the material thing, but understandable, I can live with it.
     
    Last edited: Sep 11, 2020
  4. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    - Is Power Inspector supposed to support editing Layers/Tags? Because it doesn't seem to be able to. You need to open a default inspector to do it.

    - The generated C# class from the Input Action Asset (in my case called MainInputActions), one of the new types introduced with the new Input System, locks up the editor with the following message when trying to inspect it's values.

    That counter has gone upwards of 20 minutes btw.
    For context the object is a ScriptableObject with a public property with a private setter and I am trying to see it in the inspector using Debug+ mode
    Code (CSharp):
    1.  
    2. using UnityEngine;
    3.  
    4. namespace Bezoro
    5. {
    6.     [CreateAssetMenu(fileName = "MAN_InputManager", menuName = "Managers/Input Manager")]
    7.     public class InputManager : ScriptableObject
    8.     {
    9.         public MainInputActions InputActions { get; private set; }
    10.  
    11.         private void OnEnable() => InputActions = new MainInputActions();
    12.     }
    13. }
    14.  
    Example of a C# class generated by an Input Actions Asset, in case you are unfamiliar and in case it's relevant.
    Code (CSharp):
    1.  
    2. // GENERATED AUTOMATICALLY FROM 'Assets/_Project/Input Settings/IA_Main.inputactions'
    3.  
    4. using System;
    5. using System.Collections;
    6. using System.Collections.Generic;
    7. using UnityEngine.InputSystem;
    8. using UnityEngine.InputSystem.Utilities;
    9.  
    10. namespace Bezoro
    11. {
    12.     public class @MainInputActions : IInputActionCollection, IDisposable
    13.     {
    14.         public InputActionAsset asset { get; }
    15.         public @MainInputActions()
    16.         {
    17.             asset = InputActionAsset.FromJson(@"{
    18.    ""name"": ""IA_Main"",
    19.    ""maps"": [
    20.        {
    21.            ""name"": ""Player"",
    22.            ""id"": ""2f627c00-f638-4767-8c5f-dc6efbb638dc"",
    23.            ""actions"": [
    24.                {
    25.                    ""name"": ""Move"",
    26.                    ""type"": ""Value"",
    27.                    ""id"": ""c67a0499-1077-45ff-8336-487f8f77a890"",
    28.                    ""expectedControlType"": ""Vector2"",
    29.                    ""processors"": """",
    30.                    ""interactions"": """"
    31.                },
    32.                {
    33.                    ""name"": ""Look"",
    34.                    ""type"": ""Value"",
    35.                    ""id"": ""b236c7de-ddec-4c09-9854-7816e1db51d2"",
    36.                    ""expectedControlType"": ""Vector2"",
    37.                    ""processors"": """",
    38.                    ""interactions"": """"
    39.                },
    40.                {
    41.                    ""name"": ""Fire"",
    42.                    ""type"": ""Button"",
    43.                    ""id"": ""1bc6fa65-0c77-4648-9594-a10ea6ce297e"",
    44.                    ""expectedControlType"": ""Button"",
    45.                    ""processors"": """",
    46.                    ""interactions"": """"
    47.                },
    48.                {
    49.                    ""name"": ""Jump"",
    50.                    ""type"": ""Button"",
    51.                    ""id"": ""98ac1cfb-5227-4797-b35d-8fbf1d8a32a0"",
    52.                    ""expectedControlType"": ""Button"",
    53.                    ""processors"": """",
    54.                    ""interactions"": """"
    55.                }
    56.            ],
    57.            ""bindings"": [
    58.                {
    59.                    ""name"": """",
    60.                    ""id"": ""978bfe49-cc26-4a3d-ab7b-7d7a29327403"",
    61.                    ""path"": ""<Gamepad>/leftStick"",
    62.                    ""interactions"": """",
    63.                    ""processors"": """",
    64.                    ""groups"": "";Gamepad"",
    65.                    ""action"": ""Move"",
    66.                    ""isComposite"": false,
    67.                    ""isPartOfComposite"": false
    68.                },
    69.                {
    70.                    ""name"": ""WASD"",
    71.                    ""id"": ""00ca640b-d935-4593-8157-c05846ea39b3"",
    72.                    ""path"": ""Dpad"",
    73.                    ""interactions"": """",
    74.                    ""processors"": """",
    75.                    ""groups"": """",
    76.                    ""action"": ""Move"",
    77.                    ""isComposite"": true,
    78.                    ""isPartOfComposite"": false
    79.                },
    80.                {
    81.                    ""name"": ""up"",
    82.                    ""id"": ""e2062cb9-1b15-46a2-838c-2f8d72a0bdd9"",
    83.                    ""path"": ""<Keyboard>/w"",
    84.                    ""interactions"": """",
    85.                    ""processors"": """",
    86.                    ""groups"": "";Keyboard&Mouse"",
    87.                    ""action"": ""Move"",
    88.                    ""isComposite"": false,
    89.                    ""isPartOfComposite"": true
    90.                },
    91.                {
    92.                    ""name"": ""up"",
    93.                    ""id"": ""8180e8bd-4097-4f4e-ab88-4523101a6ce9"",
    94.                    ""path"": ""<Keyboard>/upArrow"",
    95.                    ""interactions"": """",
    96.                    ""processors"": """",
    97.                    ""groups"": "";Keyboard&Mouse"",
    98.                    ""action"": ""Move"",
    99.                    ""isComposite"": false,
    100.                    ""isPartOfComposite"": true
    101.                },
    102.                {
    103.                    ""name"": ""down"",
    104.                    ""id"": ""320bffee-a40b-4347-ac70-c210eb8bc73a"",
    105.                    ""path"": ""<Keyboard>/s"",
    106.                    ""interactions"": """",
    107.                    ""processors"": """",
    108.                    ""groups"": "";Keyboard&Mouse"",
    109.                    ""action"": ""Move"",
    110.                    ""isComposite"": false,
    111.                    ""isPartOfComposite"": true
    112.                },
    113.                {
    114.                    ""name"": ""down"",
    115.                    ""id"": ""1c5327b5-f71c-4f60-99c7-4e737386f1d1"",
    116.                    ""path"": ""<Keyboard>/downArrow"",
    117.                    ""interactions"": """",
    118.                    ""processors"": """",
    119.                    ""groups"": "";Keyboard&Mouse"",
    120.                    ""action"": ""Move"",
    121.                    ""isComposite"": false,
    122.                    ""isPartOfComposite"": true
    123.                },
    124.                {
    125.                    ""name"": ""left"",
    126.                    ""id"": ""d2581a9b-1d11-4566-b27d-b92aff5fabbc"",
    127.                    ""path"": ""<Keyboard>/a"",
    128.                    ""interactions"": """",
    129.                    ""processors"": """",
    130.                    ""groups"": "";Keyboard&Mouse"",
    131.                    ""action"": ""Move"",
    132.                    ""isComposite"": false,
    133.                    ""isPartOfComposite"": true
    134.                },
    135.                {
    136.                    ""name"": ""left"",
    137.                    ""id"": ""2e46982e-44cc-431b-9f0b-c11910bf467a"",
    138.                    ""path"": ""<Keyboard>/leftArrow"",
    139.                    ""interactions"": """",
    140.                    ""processors"": """",
    141.                    ""groups"": "";Keyboard&Mouse"",
    142.                    ""action"": ""Move"",
    143.                    ""isComposite"": false,
    144.                    ""isPartOfComposite"": true
    145.                },
    146.                {
    147.                    ""name"": ""right"",
    148.                    ""id"": ""fcfe95b8-67b9-4526-84b5-5d0bc98d6400"",
    149.                    ""path"": ""<Keyboard>/d"",
    150.                    ""interactions"": """",
    151.                    ""processors"": """",
    152.                    ""groups"": "";Keyboard&Mouse"",
    153.                    ""action"": ""Move"",
    154.                    ""isComposite"": false,
    155.                    ""isPartOfComposite"": true
    156.                },
    157.                {
    158.                    ""name"": ""right"",
    159.                    ""id"": ""77bff152-3580-4b21-b6de-dcd0c7e41164"",
    160.                    ""path"": ""<Keyboard>/rightArrow"",
    161.                    ""interactions"": """",
    162.                    ""processors"": """",
    163.                    ""groups"": "";Keyboard&Mouse"",
    164.                    ""action"": ""Move"",
    165.                    ""isComposite"": false,
    166.                    ""isPartOfComposite"": true
    167.                },
    168.                {
    169.                    ""name"": """",
    170.                    ""id"": ""1635d3fe-58b6-4ba9-a4e2-f4b964f6b5c8"",
    171.                    ""path"": ""<XRController>/{Primary2DAxis}"",
    172.                    ""interactions"": """",
    173.                    ""processors"": """",
    174.                    ""groups"": ""XR"",
    175.                    ""action"": ""Move"",
    176.                    ""isComposite"": false,
    177.                    ""isPartOfComposite"": false
    178.                },
    179.                {
    180.                    ""name"": """",
    181.                    ""id"": ""3ea4d645-4504-4529-b061-ab81934c3752"",
    182.                    ""path"": ""<Joystick>/stick"",
    183.                    ""interactions"": """",
    184.                    ""processors"": """",
    185.                    ""groups"": ""Joystick"",
    186.                    ""action"": ""Move"",
    187.                    ""isComposite"": false,
    188.                    ""isPartOfComposite"": false
    189.                },
    190.                {
    191.                    ""name"": """",
    192.                    ""id"": ""c1f7a91b-d0fd-4a62-997e-7fb9b69bf235"",
    193.                    ""path"": ""<Gamepad>/rightStick"",
    194.                    ""interactions"": """",
    195.                    ""processors"": """",
    196.                    ""groups"": "";Gamepad"",
    197.                    ""action"": ""Look"",
    198.                    ""isComposite"": false,
    199.                    ""isPartOfComposite"": false
    200.                },
    201.                {
    202.                    ""name"": """",
    203.                    ""id"": ""c8c58786-9ae0-4efa-aa0a-9dbc478fb94a"",
    204.                    ""path"": ""<Pointer>/delta"",
    205.                    ""interactions"": """",
    206.                    ""processors"": ""NormalizeVector2"",
    207.                    ""groups"": "";Keyboard&Mouse;Touch"",
    208.                    ""action"": ""Look"",
    209.                    ""isComposite"": false,
    210.                    ""isPartOfComposite"": false
    211.                },
    212.                {
    213.                    ""name"": """",
    214.                    ""id"": ""3e5f5442-8668-4b27-a940-df99bad7e831"",
    215.                    ""path"": ""<Joystick>/{Hatswitch}"",
    216.                    ""interactions"": """",
    217.                    ""processors"": """",
    218.                    ""groups"": ""Joystick"",
    219.                    ""action"": ""Look"",
    220.                    ""isComposite"": false,
    221.                    ""isPartOfComposite"": false
    222.                },
    223.                {
    224.                    ""name"": """",
    225.                    ""id"": ""143bb1cd-cc10-4eca-a2f0-a3664166fe91"",
    226.                    ""path"": ""<Gamepad>/rightTrigger"",
    227.                    ""interactions"": """",
    228.                    ""processors"": """",
    229.                    ""groups"": "";Gamepad"",
    230.                    ""action"": ""Fire"",
    231.                    ""isComposite"": false,
    232.                    ""isPartOfComposite"": false
    233.                },
    234.                {
    235.                    ""name"": """",
    236.                    ""id"": ""05f6913d-c316-48b2-a6bb-e225f14c7960"",
    237.                    ""path"": ""<Mouse>/leftButton"",
    238.                    ""interactions"": """",
    239.                    ""processors"": """",
    240.                    ""groups"": "";Keyboard&Mouse"",
    241.                    ""action"": ""Fire"",
    242.                    ""isComposite"": false,
    243.                    ""isPartOfComposite"": false
    244.                },
    245.                {
    246.                    ""name"": """",
    247.                    ""id"": ""886e731e-7071-4ae4-95c0-e61739dad6fd"",
    248.                    ""path"": ""<Touchscreen>/primaryTouch/tap"",
    249.                    ""interactions"": """",
    250.                    ""processors"": """",
    251.                    ""groups"": "";Touch"",
    252.                    ""action"": ""Fire"",
    253.                    ""isComposite"": false,
    254.                    ""isPartOfComposite"": false
    255.                },
    256.                {
    257.                    ""name"": """",
    258.                    ""id"": ""ee3d0cd2-254e-47a7-a8cb-bc94d9658c54"",
    259.                    ""path"": ""<Joystick>/trigger"",
    260.                    ""interactions"": """",
    261.                    ""processors"": """",
    262.                    ""groups"": ""Joystick"",
    263.                    ""action"": ""Fire"",
    264.                    ""isComposite"": false,
    265.                    ""isPartOfComposite"": false
    266.                },
    267.                {
    268.                    ""name"": """",
    269.                    ""id"": ""8255d333-5683-4943-a58a-ccb207ff1dce"",
    270.                    ""path"": ""<XRController>/{PrimaryAction}"",
    271.                    ""interactions"": """",
    272.                    ""processors"": """",
    273.                    ""groups"": ""XR"",
    274.                    ""action"": ""Fire"",
    275.                    ""isComposite"": false,
    276.                    ""isPartOfComposite"": false
    277.                },
    278.                {
    279.                    ""name"": """",
    280.                    ""id"": ""d6ae66a7-0582-43bd-a6c9-1e67c928d509"",
    281.                    ""path"": ""<Keyboard>/space"",
    282.                    ""interactions"": ""Press(behavior=2)"",
    283.                    ""processors"": """",
    284.                    ""groups"": ""Keyboard&Mouse"",
    285.                    ""action"": ""Jump"",
    286.                    ""isComposite"": false,
    287.                    ""isPartOfComposite"": false
    288.                }
    289.            ]
    290.        },
    291.        {
    292.            ""name"": ""UI"",
    293.            ""id"": ""4ae4415b-aacb-4fe5-8214-916e18c195f7"",
    294.            ""actions"": [
    295.                {
    296.                    ""name"": ""Navigate"",
    297.                    ""type"": ""Value"",
    298.                    ""id"": ""da10ccaa-10fe-4ae2-9632-e5c2c1f39c0d"",
    299.                    ""expectedControlType"": ""Vector2"",
    300.                    ""processors"": """",
    301.                    ""interactions"": """"
    302.                },
    303.                {
    304.                    ""name"": ""Submit"",
    305.                    ""type"": ""Button"",
    306.                    ""id"": ""43ef8d59-164f-4045-a2ec-9addfbb5861c"",
    307.                    ""expectedControlType"": ""Button"",
    308.                    ""processors"": """",
    309.                    ""interactions"": """"
    310.                },
    311.                {
    312.                    ""name"": ""Cancel"",
    313.                    ""type"": ""Button"",
    314.                    ""id"": ""fed263b1-57e2-4a37-b1c5-d30d6d303367"",
    315.                    ""expectedControlType"": ""Button"",
    316.                    ""processors"": """",
    317.                    ""interactions"": """"
    318.                },
    319.                {
    320.                    ""name"": ""Point"",
    321.                    ""type"": ""PassThrough"",
    322.                    ""id"": ""2ad96eda-0554-49a0-9043-8b6c0ec42c6b"",
    323.                    ""expectedControlType"": ""Vector2"",
    324.                    ""processors"": """",
    325.                    ""interactions"": """"
    326.                },
    327.                {
    328.                    ""name"": ""Click"",
    329.                    ""type"": ""PassThrough"",
    330.                    ""id"": ""d927d3c4-99d2-4b7e-a8a0-9464a62f2b6f"",
    331.                    ""expectedControlType"": ""Button"",
    332.                    ""processors"": """",
    333.                    ""interactions"": """"
    334.                },
    335.                {
    336.                    ""name"": ""ScrollWheel"",
    337.                    ""type"": ""PassThrough"",
    338.                    ""id"": ""73f930aa-c1d1-4c16-acd8-60ec0da588b7"",
    339.                    ""expectedControlType"": ""Vector2"",
    340.                    ""processors"": """",
    341.                    ""interactions"": """"
    342.                },
    343.                {
    344.                    ""name"": ""MiddleClick"",
    345.                    ""type"": ""PassThrough"",
    346.                    ""id"": ""7fcdf15d-3e85-4499-81eb-106d64f0d158"",
    347.                    ""expectedControlType"": """",
    348.                    ""processors"": """",
    349.                    ""interactions"": """"
    350.                },
    351.                {
    352.                    ""name"": ""RightClick"",
    353.                    ""type"": ""PassThrough"",
    354.                    ""id"": ""ac079359-d13f-4577-a096-5d910cdcdc2c"",
    355.                    ""expectedControlType"": """",
    356.                    ""processors"": """",
    357.                    ""interactions"": """"
    358.                },
    359.                {
    360.                    ""name"": ""TrackedDevicePosition"",
    361.                    ""type"": ""PassThrough"",
    362.                    ""id"": ""e76d986d-6620-453a-b454-2cbc1e2394e3"",
    363.                    ""expectedControlType"": ""Vector3"",
    364.                    ""processors"": """",
    365.                    ""interactions"": """"
    366.                },
    367.                {
    368.                    ""name"": ""TrackedDeviceOrientation"",
    369.                    ""type"": ""PassThrough"",
    370.                    ""id"": ""4bd70b95-3811-429e-ad61-528514b2ec82"",
    371.                    ""expectedControlType"": ""Quaternion"",
    372.                    ""processors"": """",
    373.                    ""interactions"": """"
    374.                }
    375.            ],
    376.            ""bindings"": [
    377.                {
    378.                    ""name"": ""Gamepad"",
    379.                    ""id"": ""809f371f-c5e2-4e7a-83a1-d867598f40dd"",
    380.                    ""path"": ""2DVector"",
    381.                    ""interactions"": """",
    382.                    ""processors"": """",
    383.                    ""groups"": """",
    384.                    ""action"": ""Navigate"",
    385.                    ""isComposite"": true,
    386.                    ""isPartOfComposite"": false
    387.                },
    388.                {
    389.                    ""name"": ""up"",
    390.                    ""id"": ""14a5d6e8-4aaf-4119-a9ef-34b8c2c548bf"",
    391.                    ""path"": ""<Gamepad>/leftStick/up"",
    392.                    ""interactions"": """",
    393.                    ""processors"": """",
    394.                    ""groups"": "";Gamepad"",
    395.                    ""action"": ""Navigate"",
    396.                    ""isComposite"": false,
    397.                    ""isPartOfComposite"": true
    398.                },
    399.                {
    400.                    ""name"": ""up"",
    401.                    ""id"": ""9144cbe6-05e1-4687-a6d7-24f99d23dd81"",
    402.                    ""path"": ""<Gamepad>/rightStick/up"",
    403.                    ""interactions"": """",
    404.                    ""processors"": """",
    405.                    ""groups"": "";Gamepad"",
    406.                    ""action"": ""Navigate"",
    407.                    ""isComposite"": false,
    408.                    ""isPartOfComposite"": true
    409.                },
    410.                {
    411.                    ""name"": ""down"",
    412.                    ""id"": ""2db08d65-c5fb-421b-983f-c71163608d67"",
    413.                    ""path"": ""<Gamepad>/leftStick/down"",
    414.                    ""interactions"": """",
    415.                    ""processors"": """",
    416.                    ""groups"": "";Gamepad"",
    417.                    ""action"": ""Navigate"",
    418.                    ""isComposite"": false,
    419.                    ""isPartOfComposite"": true
    420.                },
    421.                {
    422.                    ""name"": ""down"",
    423.                    ""id"": ""58748904-2ea9-4a80-8579-b500e6a76df8"",
    424.                    ""path"": ""<Gamepad>/rightStick/down"",
    425.                    ""interactions"": """",
    426.                    ""processors"": """",
    427.                    ""groups"": "";Gamepad"",
    428.                    ""action"": ""Navigate"",
    429.                    ""isComposite"": false,
    430.                    ""isPartOfComposite"": true
    431.                },
    432.                {
    433.                    ""name"": ""left"",
    434.                    ""id"": ""8ba04515-75aa-45de-966d-393d9bbd1c14"",
    435.                    ""path"": ""<Gamepad>/leftStick/left"",
    436.                    ""interactions"": """",
    437.                    ""processors"": """",
    438.                    ""groups"": "";Gamepad"",
    439.                    ""action"": ""Navigate"",
    440.                    ""isComposite"": false,
    441.                    ""isPartOfComposite"": true
    442.                },
    443.                {
    444.                    ""name"": ""left"",
    445.                    ""id"": ""712e721c-bdfb-4b23-a86c-a0d9fcfea921"",
    446.                    ""path"": ""<Gamepad>/rightStick/left"",
    447.                    ""interactions"": """",
    448.                    ""processors"": """",
    449.                    ""groups"": "";Gamepad"",
    450.                    ""action"": ""Navigate"",
    451.                    ""isComposite"": false,
    452.                    ""isPartOfComposite"": true
    453.                },
    454.                {
    455.                    ""name"": ""right"",
    456.                    ""id"": ""fcd248ae-a788-4676-a12e-f4d81205600b"",
    457.                    ""path"": ""<Gamepad>/leftStick/right"",
    458.                    ""interactions"": """",
    459.                    ""processors"": """",
    460.                    ""groups"": "";Gamepad"",
    461.                    ""action"": ""Navigate"",
    462.                    ""isComposite"": false,
    463.                    ""isPartOfComposite"": true
    464.                },
    465.                {
    466.                    ""name"": ""right"",
    467.                    ""id"": ""1f04d9bc-c50b-41a1-bfcc-afb75475ec20"",
    468.                    ""path"": ""<Gamepad>/rightStick/right"",
    469.                    ""interactions"": """",
    470.                    ""processors"": """",
    471.                    ""groups"": "";Gamepad"",
    472.                    ""action"": ""Navigate"",
    473.                    ""isComposite"": false,
    474.                    ""isPartOfComposite"": true
    475.                },
    476.                {
    477.                    ""name"": """",
    478.                    ""id"": ""fb8277d4-c5cd-4663-9dc7-ee3f0b506d90"",
    479.                    ""path"": ""<Gamepad>/dpad"",
    480.                    ""interactions"": """",
    481.                    ""processors"": """",
    482.                    ""groups"": "";Gamepad"",
    483.                    ""action"": ""Navigate"",
    484.                    ""isComposite"": false,
    485.                    ""isPartOfComposite"": false
    486.                },
    487.                {
    488.                    ""name"": ""Joystick"",
    489.                    ""id"": ""e25d9774-381c-4a61-b47c-7b6b299ad9f9"",
    490.                    ""path"": ""2DVector"",
    491.                    ""interactions"": """",
    492.                    ""processors"": """",
    493.                    ""groups"": """",
    494.                    ""action"": ""Navigate"",
    495.                    ""isComposite"": true,
    496.                    ""isPartOfComposite"": false
    497.                },
    498.                {
    499.                    ""name"": ""up"",
    500.                    ""id"": ""3db53b26-6601-41be-9887-63ac74e79d19"",
    501.                    ""path"": ""<Joystick>/stick/up"",
    502.                    ""interactions"": """",
    503.                    ""processors"": """",
    504.                    ""groups"": ""Joystick"",
    505.                    ""action"": ""Navigate"",
    506.                    ""isComposite"": false,
    507.                    ""isPartOfComposite"": true
    508.                },
    509.                {
    510.                    ""name"": ""down"",
    511.                    ""id"": ""0cb3e13e-3d90-4178-8ae6-d9c5501d653f"",
    512.                    ""path"": ""<Joystick>/stick/down"",
    513.                    ""interactions"": """",
    514.                    ""processors"": """",
    515.                    ""groups"": ""Joystick"",
    516.                    ""action"": ""Navigate"",
    517.                    ""isComposite"": false,
    518.                    ""isPartOfComposite"": true
    519.                },
    520.                {
    521.                    ""name"": ""left"",
    522.                    ""id"": ""0392d399-f6dd-4c82-8062-c1e9c0d34835"",
    523.                    ""path"": ""<Joystick>/stick/left"",
    524.                    ""interactions"": """",
    525.                    ""processors"": """",
    526.                    ""groups"": ""Joystick"",
    527.                    ""action"": ""Navigate"",
    528.                    ""isComposite"": false,
    529.                    ""isPartOfComposite"": true
    530.                },
    531.                {
    532.                    ""name"": ""right"",
    533.                    ""id"": ""942a66d9-d42f-43d6-8d70-ecb4ba5363bc"",
    534.                    ""path"": ""<Joystick>/stick/right"",
    535.                    ""interactions"": """",
    536.                    ""processors"": """",
    537.                    ""groups"": ""Joystick"",
    538.                    ""action"": ""Navigate"",
    539.                    ""isComposite"": false,
    540.                    ""isPartOfComposite"": true
    541.                },
    542.                {
    543.                    ""name"": ""Keyboard"",
    544.                    ""id"": ""ff527021-f211-4c02-933e-5976594c46ed"",
    545.                    ""path"": ""2DVector"",
    546.                    ""interactions"": """",
    547.                    ""processors"": """",
    548.                    ""groups"": """",
    549.                    ""action"": ""Navigate"",
    550.                    ""isComposite"": true,
    551.                    ""isPartOfComposite"": false
    552.                },
    553.                {
    554.                    ""name"": ""up"",
    555.                    ""id"": ""563fbfdd-0f09-408d-aa75-8642c4f08ef0"",
    556.                    ""path"": ""<Keyboard>/w"",
    557.                    ""interactions"": """",
    558.                    ""processors"": """",
    559.                    ""groups"": ""Keyboard&Mouse"",
    560.                    ""action"": ""Navigate"",
    561.                    ""isComposite"": false,
    562.                    ""isPartOfComposite"": true
    563.                },
    564.                {
    565.                    ""name"": ""up"",
    566.                    ""id"": ""eb480147-c587-4a33-85ed-eb0ab9942c43"",
    567.                    ""path"": ""<Keyboard>/upArrow"",
    568.                    ""interactions"": """",
    569.                    ""processors"": """",
    570.                    ""groups"": ""Keyboard&Mouse"",
    571.                    ""action"": ""Navigate"",
    572.                    ""isComposite"": false,
    573.                    ""isPartOfComposite"": true
    574.                },
    575.                {
    576.                    ""name"": ""down"",
    577.                    ""id"": ""2bf42165-60bc-42ca-8072-8c13ab40239b"",
    578.                    ""path"": ""<Keyboard>/s"",
    579.                    ""interactions"": """",
    580.                    ""processors"": """",
    581.                    ""groups"": ""Keyboard&Mouse"",
    582.                    ""action"": ""Navigate"",
    583.                    ""isComposite"": false,
    584.                    ""isPartOfComposite"": true
    585.                },
    586.                {
    587.                    ""name"": ""down"",
    588.                    ""id"": ""85d264ad-e0a0-4565-b7ff-1a37edde51ac"",
    589.                    ""path"": ""<Keyboard>/downArrow"",
    590.                    ""interactions"": """",
    591.                    ""processors"": """",
    592.                    ""groups"": ""Keyboard&Mouse"",
    593.                    ""action"": ""Navigate"",
    594.                    ""isComposite"": false,
    595.                    ""isPartOfComposite"": true
    596.                },
    597.                {
    598.                    ""name"": ""left"",
    599.                    ""id"": ""74214943-c580-44e4-98eb-ad7eebe17902"",
    600.                    ""path"": ""<Keyboard>/a"",
    601.                    ""interactions"": """",
    602.                    ""processors"": """",
    603.                    ""groups"": ""Keyboard&Mouse"",
    604.                    ""action"": ""Navigate"",
    605.                    ""isComposite"": false,
    606.                    ""isPartOfComposite"": true
    607.                },
    608.                {
    609.                    ""name"": ""left"",
    610.                    ""id"": ""cea9b045-a000-445b-95b8-0c171af70a3b"",
    611.                    ""path"": ""<Keyboard>/leftArrow"",
    612.                    ""interactions"": """",
    613.                    ""processors"": """",
    614.                    ""groups"": ""Keyboard&Mouse"",
    615.                    ""action"": ""Navigate"",
    616.                    ""isComposite"": false,
    617.                    ""isPartOfComposite"": true
    618.                },
    619.                {
    620.                    ""name"": ""right"",
    621.                    ""id"": ""8607c725-d935-4808-84b1-8354e29bab63"",
    622.                    ""path"": ""<Keyboard>/d"",
    623.                    ""interactions"": """",
    624.                    ""processors"": """",
    625.                    ""groups"": ""Keyboard&Mouse"",
    626.                    ""action"": ""Navigate"",
    627.                    ""isComposite"": false,
    628.                    ""isPartOfComposite"": true
    629.                },
    630.                {
    631.                    ""name"": ""right"",
    632.                    ""id"": ""4cda81dc-9edd-4e03-9d7c-a71a14345d0b"",
    633.                    ""path"": ""<Keyboard>/rightArrow"",
    634.                    ""interactions"": """",
    635.                    ""processors"": """",
    636.                    ""groups"": ""Keyboard&Mouse"",
    637.                    ""action"": ""Navigate"",
    638.                    ""isComposite"": false,
    639.                    ""isPartOfComposite"": true
    640.                },
    641.                {
    642.                    ""name"": """",
    643.                    ""id"": ""9e92bb26-7e3b-4ec4-b06b-3c8f8e498ddc"",
    644.                    ""path"": ""*/{Submit}"",
    645.                    ""interactions"": """",
    646.                    ""processors"": """",
    647.                    ""groups"": """",
    648.                    ""action"": ""Submit"",
    649.                    ""isComposite"": false,
    650.                    ""isPartOfComposite"": false
    651.                },
    652.                {
    653.                    ""name"": """",
    654.                    ""id"": ""82627dcc-3b13-4ba9-841d-e4b746d6553e"",
    655.                    ""path"": ""*/{Cancel}"",
    656.                    ""interactions"": """",
    657.                    ""processors"": """",
    658.                    ""groups"": """",
    659.                    ""action"": ""Cancel"",
    660.                    ""isComposite"": false,
    661.                    ""isPartOfComposite"": false
    662.                },
    663.                {
    664.                    ""name"": """",
    665.                    ""id"": ""c52c8e0b-8179-41d3-b8a1-d149033bbe86"",
    666.                    ""path"": ""<Mouse>/position"",
    667.                    ""interactions"": """",
    668.                    ""processors"": """",
    669.                    ""groups"": ""Keyboard&Mouse"",
    670.                    ""action"": ""Point"",
    671.                    ""isComposite"": false,
    672.                    ""isPartOfComposite"": false
    673.                },
    674.                {
    675.                    ""name"": """",
    676.                    ""id"": ""e1394cbc-336e-44ce-9ea8-6007ed6193f7"",
    677.                    ""path"": ""<Pen>/position"",
    678.                    ""interactions"": """",
    679.                    ""processors"": """",
    680.                    ""groups"": ""Keyboard&Mouse"",
    681.                    ""action"": ""Point"",
    682.                    ""isComposite"": false,
    683.                    ""isPartOfComposite"": false
    684.                },
    685.                {
    686.                    ""name"": """",
    687.                    ""id"": ""5693e57a-238a-46ed-b5ae-e64e6e574302"",
    688.                    ""path"": ""<Touchscreen>/touch*/position"",
    689.                    ""interactions"": """",
    690.                    ""processors"": """",
    691.                    ""groups"": ""Touch"",
    692.                    ""action"": ""Point"",
    693.                    ""isComposite"": false,
    694.                    ""isPartOfComposite"": false
    695.                },
    696.                {
    697.                    ""name"": """",
    698.                    ""id"": ""4faf7dc9-b979-4210-aa8c-e808e1ef89f5"",
    699.                    ""path"": ""<Mouse>/leftButton"",
    700.                    ""interactions"": """",
    701.                    ""processors"": """",
    702.                    ""groups"": "";Keyboard&Mouse"",
    703.                    ""action"": ""Click"",
    704.                    ""isComposite"": false,
    705.                    ""isPartOfComposite"": false
    706.                },
    707.                {
    708.                    ""name"": """",
    709.                    ""id"": ""8d66d5ba-88d7-48e6-b1cd-198bbfef7ace"",
    710.                    ""path"": ""<Pen>/tip"",
    711.                    ""interactions"": """",
    712.                    ""processors"": """",
    713.                    ""groups"": "";Keyboard&Mouse"",
    714.                    ""action"": ""Click"",
    715.                    ""isComposite"": false,
    716.                    ""isPartOfComposite"": false
    717.                },
    718.                {
    719.                    ""name"": """",
    720.                    ""id"": ""47c2a644-3ebc-4dae-a106-589b7ca75b59"",
    721.                    ""path"": ""<Touchscreen>/touch*/press"",
    722.                    ""interactions"": """",
    723.                    ""processors"": """",
    724.                    ""groups"": ""Touch"",
    725.                    ""action"": ""Click"",
    726.                    ""isComposite"": false,
    727.                    ""isPartOfComposite"": false
    728.                },
    729.                {
    730.                    ""name"": """",
    731.                    ""id"": ""bb9e6b34-44bf-4381-ac63-5aa15d19f677"",
    732.                    ""path"": ""<XRController>/trigger"",
    733.                    ""interactions"": """",
    734.                    ""processors"": """",
    735.                    ""groups"": ""XR"",
    736.                    ""action"": ""Click"",
    737.                    ""isComposite"": false,
    738.                    ""isPartOfComposite"": false
    739.                },
    740.                {
    741.                    ""name"": """",
    742.                    ""id"": ""38c99815-14ea-4617-8627-164d27641299"",
    743.                    ""path"": ""<Mouse>/scroll"",
    744.                    ""interactions"": """",
    745.                    ""processors"": """",
    746.                    ""groups"": "";Keyboard&Mouse"",
    747.                    ""action"": ""ScrollWheel"",
    748.                    ""isComposite"": false,
    749.                    ""isPartOfComposite"": false
    750.                },
    751.                {
    752.                    ""name"": """",
    753.                    ""id"": ""24066f69-da47-44f3-a07e-0015fb02eb2e"",
    754.                    ""path"": ""<Mouse>/middleButton"",
    755.                    ""interactions"": """",
    756.                    ""processors"": """",
    757.                    ""groups"": "";Keyboard&Mouse"",
    758.                    ""action"": ""MiddleClick"",
    759.                    ""isComposite"": false,
    760.                    ""isPartOfComposite"": false
    761.                },
    762.                {
    763.                    ""name"": """",
    764.                    ""id"": ""4c191405-5738-4d4b-a523-c6a301dbf754"",
    765.                    ""path"": ""<Mouse>/rightButton"",
    766.                    ""interactions"": """",
    767.                    ""processors"": """",
    768.                    ""groups"": "";Keyboard&Mouse"",
    769.                    ""action"": ""RightClick"",
    770.                    ""isComposite"": false,
    771.                    ""isPartOfComposite"": false
    772.                },
    773.                {
    774.                    ""name"": """",
    775.                    ""id"": ""7236c0d9-6ca3-47cf-a6ee-a97f5b59ea77"",
    776.                    ""path"": ""<XRController>/devicePosition"",
    777.                    ""interactions"": """",
    778.                    ""processors"": """",
    779.                    ""groups"": ""XR"",
    780.                    ""action"": ""TrackedDevicePosition"",
    781.                    ""isComposite"": false,
    782.                    ""isPartOfComposite"": false
    783.                },
    784.                {
    785.                    ""name"": """",
    786.                    ""id"": ""23e01e3a-f935-4948-8d8b-9bcac77714fb"",
    787.                    ""path"": ""<XRController>/deviceRotation"",
    788.                    ""interactions"": """",
    789.                    ""processors"": """",
    790.                    ""groups"": ""XR"",
    791.                    ""action"": ""TrackedDeviceOrientation"",
    792.                    ""isComposite"": false,
    793.                    ""isPartOfComposite"": false
    794.                }
    795.            ]
    796.        }
    797.    ],
    798.    ""controlSchemes"": [
    799.        {
    800.            ""name"": ""Keyboard&Mouse"",
    801.            ""bindingGroup"": ""Keyboard&Mouse"",
    802.            ""devices"": [
    803.                {
    804.                    ""devicePath"": ""<Keyboard>"",
    805.                    ""isOptional"": false,
    806.                    ""isOR"": false
    807.                },
    808.                {
    809.                    ""devicePath"": ""<Mouse>"",
    810.                    ""isOptional"": false,
    811.                    ""isOR"": false
    812.                }
    813.            ]
    814.        },
    815.        {
    816.            ""name"": ""Gamepad"",
    817.            ""bindingGroup"": ""Gamepad"",
    818.            ""devices"": [
    819.                {
    820.                    ""devicePath"": ""<Gamepad>"",
    821.                    ""isOptional"": false,
    822.                    ""isOR"": false
    823.                }
    824.            ]
    825.        },
    826.        {
    827.            ""name"": ""Touch"",
    828.            ""bindingGroup"": ""Touch"",
    829.            ""devices"": [
    830.                {
    831.                    ""devicePath"": ""<Touchscreen>"",
    832.                    ""isOptional"": false,
    833.                    ""isOR"": false
    834.                }
    835.            ]
    836.        },
    837.        {
    838.            ""name"": ""Joystick"",
    839.            ""bindingGroup"": ""Joystick"",
    840.            ""devices"": [
    841.                {
    842.                    ""devicePath"": ""<Joystick>"",
    843.                    ""isOptional"": false,
    844.                    ""isOR"": false
    845.                }
    846.            ]
    847.        },
    848.        {
    849.            ""name"": ""XR"",
    850.            ""bindingGroup"": ""XR"",
    851.            ""devices"": [
    852.                {
    853.                    ""devicePath"": ""<XRController>"",
    854.                    ""isOptional"": false,
    855.                    ""isOR"": false
    856.                }
    857.            ]
    858.        }
    859.    ]
    860. }");
    861.             // Player
    862.             m_Player = asset.FindActionMap("Player", throwIfNotFound: true);
    863.             m_Player_Move = m_Player.FindAction("Move", throwIfNotFound: true);
    864.             m_Player_Look = m_Player.FindAction("Look", throwIfNotFound: true);
    865.             m_Player_Fire = m_Player.FindAction("Fire", throwIfNotFound: true);
    866.             m_Player_Jump = m_Player.FindAction("Jump", throwIfNotFound: true);
    867.             // UI
    868.             m_UI = asset.FindActionMap("UI", throwIfNotFound: true);
    869.             m_UI_Navigate = m_UI.FindAction("Navigate", throwIfNotFound: true);
    870.             m_UI_Submit = m_UI.FindAction("Submit", throwIfNotFound: true);
    871.             m_UI_Cancel = m_UI.FindAction("Cancel", throwIfNotFound: true);
    872.             m_UI_Point = m_UI.FindAction("Point", throwIfNotFound: true);
    873.             m_UI_Click = m_UI.FindAction("Click", throwIfNotFound: true);
    874.             m_UI_ScrollWheel = m_UI.FindAction("ScrollWheel", throwIfNotFound: true);
    875.             m_UI_MiddleClick = m_UI.FindAction("MiddleClick", throwIfNotFound: true);
    876.             m_UI_RightClick = m_UI.FindAction("RightClick", throwIfNotFound: true);
    877.             m_UI_TrackedDevicePosition = m_UI.FindAction("TrackedDevicePosition", throwIfNotFound: true);
    878.             m_UI_TrackedDeviceOrientation = m_UI.FindAction("TrackedDeviceOrientation", throwIfNotFound: true);
    879.         }
    880.  
    881.         public void Dispose()
    882.         {
    883.             UnityEngine.Object.Destroy(asset);
    884.         }
    885.  
    886.         public InputBinding? bindingMask
    887.         {
    888.             get => asset.bindingMask;
    889.             set => asset.bindingMask = value;
    890.         }
    891.  
    892.         public ReadOnlyArray<InputDevice>? devices
    893.         {
    894.             get => asset.devices;
    895.             set => asset.devices = value;
    896.         }
    897.  
    898.         public ReadOnlyArray<InputControlScheme> controlSchemes => asset.controlSchemes;
    899.  
    900.         public bool Contains(InputAction action)
    901.         {
    902.             return asset.Contains(action);
    903.         }
    904.  
    905.         public IEnumerator<InputAction> GetEnumerator()
    906.         {
    907.             return asset.GetEnumerator();
    908.         }
    909.  
    910.         IEnumerator IEnumerable.GetEnumerator()
    911.         {
    912.             return GetEnumerator();
    913.         }
    914.  
    915.         public void Enable()
    916.         {
    917.             asset.Enable();
    918.         }
    919.  
    920.         public void Disable()
    921.         {
    922.             asset.Disable();
    923.         }
    924.  
    925.         // Player
    926.         private readonly InputActionMap m_Player;
    927.         private IPlayerActions m_PlayerActionsCallbackInterface;
    928.         private readonly InputAction m_Player_Move;
    929.         private readonly InputAction m_Player_Look;
    930.         private readonly InputAction m_Player_Fire;
    931.         private readonly InputAction m_Player_Jump;
    932.         public struct PlayerActions
    933.         {
    934.             private @MainInputActions m_Wrapper;
    935.             public PlayerActions(@MainInputActions wrapper) { m_Wrapper = wrapper; }
    936.             public InputAction @Move => m_Wrapper.m_Player_Move;
    937.             public InputAction @Look => m_Wrapper.m_Player_Look;
    938.             public InputAction @Fire => m_Wrapper.m_Player_Fire;
    939.             public InputAction @Jump => m_Wrapper.m_Player_Jump;
    940.             public InputActionMap Get() { return m_Wrapper.m_Player; }
    941.             public void Enable() { Get().Enable(); }
    942.             public void Disable() { Get().Disable(); }
    943.             public bool enabled => Get().enabled;
    944.             public static implicit operator InputActionMap(PlayerActions set) { return set.Get(); }
    945.             public void SetCallbacks(IPlayerActions instance)
    946.             {
    947.                 if (m_Wrapper.m_PlayerActionsCallbackInterface != null)
    948.                 {
    949.                     @Move.started -= m_Wrapper.m_PlayerActionsCallbackInterface.OnMove;
    950.                     @Move.performed -= m_Wrapper.m_PlayerActionsCallbackInterface.OnMove;
    951.                     @Move.canceled -= m_Wrapper.m_PlayerActionsCallbackInterface.OnMove;
    952.                     @Look.started -= m_Wrapper.m_PlayerActionsCallbackInterface.OnLook;
    953.                     @Look.performed -= m_Wrapper.m_PlayerActionsCallbackInterface.OnLook;
    954.                     @Look.canceled -= m_Wrapper.m_PlayerActionsCallbackInterface.OnLook;
    955.                     @Fire.started -= m_Wrapper.m_PlayerActionsCallbackInterface.OnFire;
    956.                     @Fire.performed -= m_Wrapper.m_PlayerActionsCallbackInterface.OnFire;
    957.                     @Fire.canceled -= m_Wrapper.m_PlayerActionsCallbackInterface.OnFire;
    958.                     @Jump.started -= m_Wrapper.m_PlayerActionsCallbackInterface.OnJump;
    959.                     @Jump.performed -= m_Wrapper.m_PlayerActionsCallbackInterface.OnJump;
    960.                     @Jump.canceled -= m_Wrapper.m_PlayerActionsCallbackInterface.OnJump;
    961.                 }
    962.                 m_Wrapper.m_PlayerActionsCallbackInterface = instance;
    963.                 if (instance != null)
    964.                 {
    965.                     @Move.started += instance.OnMove;
    966.                     @Move.performed += instance.OnMove;
    967.                     @Move.canceled += instance.OnMove;
    968.                     @Look.started += instance.OnLook;
    969.                     @Look.performed += instance.OnLook;
    970.                     @Look.canceled += instance.OnLook;
    971.                     @Fire.started += instance.OnFire;
    972.                     @Fire.performed += instance.OnFire;
    973.                     @Fire.canceled += instance.OnFire;
    974.                     @Jump.started += instance.OnJump;
    975.                     @Jump.performed += instance.OnJump;
    976.                     @Jump.canceled += instance.OnJump;
    977.                 }
    978.             }
    979.         }
    980.         public PlayerActions @Player => new PlayerActions(this);
    981.  
    982.         // UI
    983.         private readonly InputActionMap m_UI;
    984.         private IUIActions m_UIActionsCallbackInterface;
    985.         private readonly InputAction m_UI_Navigate;
    986.         private readonly InputAction m_UI_Submit;
    987.         private readonly InputAction m_UI_Cancel;
    988.         private readonly InputAction m_UI_Point;
    989.         private readonly InputAction m_UI_Click;
    990.         private readonly InputAction m_UI_ScrollWheel;
    991.         private readonly InputAction m_UI_MiddleClick;
    992.         private readonly InputAction m_UI_RightClick;
    993.         private readonly InputAction m_UI_TrackedDevicePosition;
    994.         private readonly InputAction m_UI_TrackedDeviceOrientation;
    995.         public struct UIActions
    996.         {
    997.             private @MainInputActions m_Wrapper;
    998.             public UIActions(@MainInputActions wrapper) { m_Wrapper = wrapper; }
    999.             public InputAction @Navigate => m_Wrapper.m_UI_Navigate;
    1000.             public InputAction @Submit => m_Wrapper.m_UI_Submit;
    1001.             public InputAction @Cancel => m_Wrapper.m_UI_Cancel;
    1002.             public InputAction @Point => m_Wrapper.m_UI_Point;
    1003.             public InputAction @Click => m_Wrapper.m_UI_Click;
    1004.             public InputAction @ScrollWheel => m_Wrapper.m_UI_ScrollWheel;
    1005.             public InputAction @MiddleClick => m_Wrapper.m_UI_MiddleClick;
    1006.             public InputAction @RightClick => m_Wrapper.m_UI_RightClick;
    1007.             public InputAction @TrackedDevicePosition => m_Wrapper.m_UI_TrackedDevicePosition;
    1008.             public InputAction @TrackedDeviceOrientation => m_Wrapper.m_UI_TrackedDeviceOrientation;
    1009.             public InputActionMap Get() { return m_Wrapper.m_UI; }
    1010.             public void Enable() { Get().Enable(); }
    1011.             public void Disable() { Get().Disable(); }
    1012.             public bool enabled => Get().enabled;
    1013.             public static implicit operator InputActionMap(UIActions set) { return set.Get(); }
    1014.             public void SetCallbacks(IUIActions instance)
    1015.             {
    1016.                 if (m_Wrapper.m_UIActionsCallbackInterface != null)
    1017.                 {
    1018.                     @Navigate.started -= m_Wrapper.m_UIActionsCallbackInterface.OnNavigate;
    1019.                     @Navigate.performed -= m_Wrapper.m_UIActionsCallbackInterface.OnNavigate;
    1020.                     @Navigate.canceled -= m_Wrapper.m_UIActionsCallbackInterface.OnNavigate;
    1021.                     @Submit.started -= m_Wrapper.m_UIActionsCallbackInterface.OnSubmit;
    1022.                     @Submit.performed -= m_Wrapper.m_UIActionsCallbackInterface.OnSubmit;
    1023.                     @Submit.canceled -= m_Wrapper.m_UIActionsCallbackInterface.OnSubmit;
    1024.                     @Cancel.started -= m_Wrapper.m_UIActionsCallbackInterface.OnCancel;
    1025.                     @Cancel.performed -= m_Wrapper.m_UIActionsCallbackInterface.OnCancel;
    1026.                     @Cancel.canceled -= m_Wrapper.m_UIActionsCallbackInterface.OnCancel;
    1027.                     @Point.started -= m_Wrapper.m_UIActionsCallbackInterface.OnPoint;
    1028.                     @Point.performed -= m_Wrapper.m_UIActionsCallbackInterface.OnPoint;
    1029.                     @Point.canceled -= m_Wrapper.m_UIActionsCallbackInterface.OnPoint;
    1030.                     @Click.started -= m_Wrapper.m_UIActionsCallbackInterface.OnClick;
    1031.                     @Click.performed -= m_Wrapper.m_UIActionsCallbackInterface.OnClick;
    1032.                     @Click.canceled -= m_Wrapper.m_UIActionsCallbackInterface.OnClick;
    1033.                     @ScrollWheel.started -= m_Wrapper.m_UIActionsCallbackInterface.OnScrollWheel;
    1034.                     @ScrollWheel.performed -= m_Wrapper.m_UIActionsCallbackInterface.OnScrollWheel;
    1035.                     @ScrollWheel.canceled -= m_Wrapper.m_UIActionsCallbackInterface.OnScrollWheel;
    1036.                     @MiddleClick.started -= m_Wrapper.m_UIActionsCallbackInterface.OnMiddleClick;
    1037.                     @MiddleClick.performed -= m_Wrapper.m_UIActionsCallbackInterface.OnMiddleClick;
    1038.                     @MiddleClick.canceled -= m_Wrapper.m_UIActionsCallbackInterface.OnMiddleClick;
    1039.                     @RightClick.started -= m_Wrapper.m_UIActionsCallbackInterface.OnRightClick;
    1040.                     @RightClick.performed -= m_Wrapper.m_UIActionsCallbackInterface.OnRightClick;
    1041.                     @RightClick.canceled -= m_Wrapper.m_UIActionsCallbackInterface.OnRightClick;
    1042.                     @TrackedDevicePosition.started -= m_Wrapper.m_UIActionsCallbackInterface.OnTrackedDevicePosition;
    1043.                     @TrackedDevicePosition.performed -= m_Wrapper.m_UIActionsCallbackInterface.OnTrackedDevicePosition;
    1044.                     @TrackedDevicePosition.canceled -= m_Wrapper.m_UIActionsCallbackInterface.OnTrackedDevicePosition;
    1045.                     @TrackedDeviceOrientation.started -= m_Wrapper.m_UIActionsCallbackInterface.OnTrackedDeviceOrientation;
    1046.                     @TrackedDeviceOrientation.performed -= m_Wrapper.m_UIActionsCallbackInterface.OnTrackedDeviceOrientation;
    1047.                     @TrackedDeviceOrientation.canceled -= m_Wrapper.m_UIActionsCallbackInterface.OnTrackedDeviceOrientation;
    1048.                 }
    1049.                 m_Wrapper.m_UIActionsCallbackInterface = instance;
    1050.                 if (instance != null)
    1051.                 {
    1052.                     @Navigate.started += instance.OnNavigate;
    1053.                     @Navigate.performed += instance.OnNavigate;
    1054.                     @Navigate.canceled += instance.OnNavigate;
    1055.                     @Submit.started += instance.OnSubmit;
    1056.                     @Submit.performed += instance.OnSubmit;
    1057.                     @Submit.canceled += instance.OnSubmit;
    1058.                     @Cancel.started += instance.OnCancel;
    1059.                     @Cancel.performed += instance.OnCancel;
    1060.                     @Cancel.canceled += instance.OnCancel;
    1061.                     @Point.started += instance.OnPoint;
    1062.                     @Point.performed += instance.OnPoint;
    1063.                     @Point.canceled += instance.OnPoint;
    1064.                     @Click.started += instance.OnClick;
    1065.                     @Click.performed += instance.OnClick;
    1066.                     @Click.canceled += instance.OnClick;
    1067.                     @ScrollWheel.started += instance.OnScrollWheel;
    1068.                     @ScrollWheel.performed += instance.OnScrollWheel;
    1069.                     @ScrollWheel.canceled += instance.OnScrollWheel;
    1070.                     @MiddleClick.started += instance.OnMiddleClick;
    1071.                     @MiddleClick.performed += instance.OnMiddleClick;
    1072.                     @MiddleClick.canceled += instance.OnMiddleClick;
    1073.                     @RightClick.started += instance.OnRightClick;
    1074.                     @RightClick.performed += instance.OnRightClick;
    1075.                     @RightClick.canceled += instance.OnRightClick;
    1076.                     @TrackedDevicePosition.started += instance.OnTrackedDevicePosition;
    1077.                     @TrackedDevicePosition.performed += instance.OnTrackedDevicePosition;
    1078.                     @TrackedDevicePosition.canceled += instance.OnTrackedDevicePosition;
    1079.                     @TrackedDeviceOrientation.started += instance.OnTrackedDeviceOrientation;
    1080.                     @TrackedDeviceOrientation.performed += instance.OnTrackedDeviceOrientation;
    1081.                     @TrackedDeviceOrientation.canceled += instance.OnTrackedDeviceOrientation;
    1082.                 }
    1083.             }
    1084.         }
    1085.         public UIActions @UI => new UIActions(this);
    1086.         private int m_KeyboardMouseSchemeIndex = -1;
    1087.         public InputControlScheme KeyboardMouseScheme
    1088.         {
    1089.             get
    1090.             {
    1091.                 if (m_KeyboardMouseSchemeIndex == -1) m_KeyboardMouseSchemeIndex = asset.FindControlSchemeIndex("Keyboard&Mouse");
    1092.                 return asset.controlSchemes[m_KeyboardMouseSchemeIndex];
    1093.             }
    1094.         }
    1095.         private int m_GamepadSchemeIndex = -1;
    1096.         public InputControlScheme GamepadScheme
    1097.         {
    1098.             get
    1099.             {
    1100.                 if (m_GamepadSchemeIndex == -1) m_GamepadSchemeIndex = asset.FindControlSchemeIndex("Gamepad");
    1101.                 return asset.controlSchemes[m_GamepadSchemeIndex];
    1102.             }
    1103.         }
    1104.         private int m_TouchSchemeIndex = -1;
    1105.         public InputControlScheme TouchScheme
    1106.         {
    1107.             get
    1108.             {
    1109.                 if (m_TouchSchemeIndex == -1) m_TouchSchemeIndex = asset.FindControlSchemeIndex("Touch");
    1110.                 return asset.controlSchemes[m_TouchSchemeIndex];
    1111.             }
    1112.         }
    1113.         private int m_JoystickSchemeIndex = -1;
    1114.         public InputControlScheme JoystickScheme
    1115.         {
    1116.             get
    1117.             {
    1118.                 if (m_JoystickSchemeIndex == -1) m_JoystickSchemeIndex = asset.FindControlSchemeIndex("Joystick");
    1119.                 return asset.controlSchemes[m_JoystickSchemeIndex];
    1120.             }
    1121.         }
    1122.         private int m_XRSchemeIndex = -1;
    1123.         public InputControlScheme XRScheme
    1124.         {
    1125.             get
    1126.             {
    1127.                 if (m_XRSchemeIndex == -1) m_XRSchemeIndex = asset.FindControlSchemeIndex("XR");
    1128.                 return asset.controlSchemes[m_XRSchemeIndex];
    1129.             }
    1130.         }
    1131.         public interface IPlayerActions
    1132.         {
    1133.             void OnMove(InputAction.CallbackContext context);
    1134.             void OnLook(InputAction.CallbackContext context);
    1135.             void OnFire(InputAction.CallbackContext context);
    1136.             void OnJump(InputAction.CallbackContext context);
    1137.         }
    1138.         public interface IUIActions
    1139.         {
    1140.             void OnNavigate(InputAction.CallbackContext context);
    1141.             void OnSubmit(InputAction.CallbackContext context);
    1142.             void OnCancel(InputAction.CallbackContext context);
    1143.             void OnPoint(InputAction.CallbackContext context);
    1144.             void OnClick(InputAction.CallbackContext context);
    1145.             void OnScrollWheel(InputAction.CallbackContext context);
    1146.             void OnMiddleClick(InputAction.CallbackContext context);
    1147.             void OnRightClick(InputAction.CallbackContext context);
    1148.             void OnTrackedDevicePosition(InputAction.CallbackContext context);
    1149.             void OnTrackedDeviceOrientation(InputAction.CallbackContext context);
    1150.         }
    1151.     }
    1152. }
    1153.  

    - Missing script has no option to remove it, forcing you to use the default inspector, I assume that is no intentional.

    Unity 2020.2.0b1.
    Windows Build Support (IL2CPP) is the only platform module installed.
    HDRP is the project template.
    API Compatibility Level is set by default as .NET Standard 2.0.
    Scripting Backend is set by default as IL2CPP.
    Power Inspector 1.4.6 is the only asset imported, Located in the Plugins folder.
     
    Last edited: Sep 16, 2020
  5. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    Hey @Bezoro and thanks again for making such clear and informative bug reports :)

    Layers and Tags editing is definitely supposed to work. Maybe a unity update has broken this, I'll have to investigate.

    The ability to remove missing scripts via the context menu should also be there, especially in version 2019.1 and later where unity introduced some new useful functions in the GameObjectUtility class. I'll investigate this regression too.

    I don't think I have tested Power Inspector with Input Action Assets yet, so I'll do this and try to get to the bottom of the issue you've described.

    I'm having quite a busy week right now so it could take me a bit longer than usual to get to these, but I'll try to find the time for it as soon as I can.
     
  6. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    I know how much of a pain it is to fix bugs based on unclear reports, so I am trying my best.

    Perfectly Understandable.
     
    SisusCo likes this.
  7. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    - Issue inspecting an instance of CancellationTokenSource.

    This is all the code in TestScript.cs
    Code (CSharp):
    1.  
    2. using UnityEngine;
    3. using System.Threading;
    4.  
    5. public class TestScript : MonoBehaviour
    6. {
    7.     private CancellationTokenSource _cancellationTokenSource = new CancellationTokenSource();
    8. }
    9.  

    Unity 2020.2.0b2.
    Windows Build Support (IL2CPP) is the only platform module installed.
    HDRP is the project template.
    API Compatibility Level is set by default as .NET Standard 2.0.
    Scripting Backend is set by default as IL2CPP.
    Power Inspector 1.4.6 is the only asset imported, Located in the Plugins folder.
     
  8. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    @Bezoro Version 1.4.7 is out now and should fix issues with viewing data such as CancellationTokenSource and Input Actions in Debug Mode+ as well as restore the ability to remove missing scripts.

    Fixes for the "Add Tag..." and "Add Layer..." buttons aren't included in this one, but they'll be at the top of my to do list for the next update for sure :)
     
  9. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    Thanks for taking the time.
     
  10. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    Version 1.4.8 is now out and it includes a fix to make the "Add tag..." and "Add layer..." buttons work inside Power Inspector.
     
  11. AGregori

    AGregori

    Joined:
    Dec 11, 2014
    Posts:
    527
    Hi there, the asset stopped working for me:

    EndLayoutGroup: BeginLayoutGroup must be called first.
    UnityEngine.GUILayout:EndHorizontal()
    Sisus.CustomEditorBaseDrawer`2:DrawMembers(Rect) (at Assets/Sisus/Power Inspector/Code/Editor/Drawers/UnityObject/CustomEditorBaseDrawer.cs:879)
    Sisus.CustomEditorBaseDrawer`2:DrawBody(Rect) (at Assets/Sisus/Power Inspector/Code/Editor/Drawers/UnityObject/CustomEditorBaseDrawer.cs:778)
    Sisus.CustomEditorAssetDrawer:DrawBody(Rect) (at Assets/Sisus/Power Inspector/Code/Editor/Drawers/UnityObject/Asset/CustomEditor/CustomEditorAssetDrawer.cs:663)
    Sisus.CustomEditorBaseDrawer`2:Draw(Rect) (at Assets/Sisus/Power Inspector/Code/Editor/Drawers/UnityObject/CustomEditorBaseDrawer.cs:700)
    Sisus.Inspector`2:DrawViewport() (at Assets/Sisus/Power Inspector/Code/Editor/Inspector/Core/Inspector.cs:1881)
    Sisus.Inspector`2:DrawViewport(Rect) (at Assets/Sisus/Power Inspector/Code/Editor/Inspector/Core/Inspector.cs:1806)
    Sisus.PowerInspector:OnGUI(Rect, Boolean) (at Assets/Sisus/Power Inspector/Code/Editor/Inspector/Power Inspector/PowerInspector.cs:139)
    Sisus.InspectorDrawerWindow`2:OnGUI() (at Assets/Sisus/Power Inspector/Code/Editor/EditorWindow/InspectorDrawerWindow.cs:1800)
    UnityEngine.GUIUtility:processEvent(Int32, IntPtr, Boolean&)

    (Smilies are obviously not my doing. :) )
     
  12. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    Hey again @AGregori :)

    That's strange, there's definitely a BeginHorizontal preceding the EndHorizontal call in there. I also did some testing and was able to inspect an asset with a custom editor without problems.

    Could it be that the custom editor that you were inspecting contains one too many EndHorizontal calls inside its OnInspectorGUI function? o_O Did the issue only occur when inspecting a specific type of asset?
     
    AGregori likes this.
  13. AGregori

    AGregori

    Joined:
    Dec 11, 2014
    Posts:
    527
    Thanks for the reply.
    The issue occurs in 2020.1.7 when I inspect anything in the scene view. It also messed up my custom editor layouts which I had to re-create upon restart. So it's clearly some major conflict -- but if you cannot reproduce it, then it's a local conflict on my end.

    That said, Power Inspector is amazing and I love its features. But it's probably in conflict with other editor extensions: I have Peek and Hierarchy Pro installed, I'll investigate.
     
    SisusCo likes this.
  14. ArkyonVeil

    ArkyonVeil

    Joined:
    Dec 20, 2013
    Posts:
    14
    Greetings, so I gave Power Inspector a shot and noticed something that for me while amazing, it isn't quite working as expected.

    So... To make my life easier, I'm attempting to use an abstract class to help swap in and out inhereting classes with complex behavior in an uniform system.

    Unity normally only allows this with a custom editor, but I noticed that Power Inspector enables this by default. As such:



    So it can be used like so.



    Unfortunately. I discovered that when I do this, the moment I press play and/or close Unity. These values are lost, which kind of loses the point of it.

    I may be doing something wrong, so the code is as such.

    The Monobehavior script:

    Code (CSharp):
    1. [SerializeField]  
    2. public List<BulletSettings> BulletSettingsTest;
    The classes themselves:

    Code (CSharp):
    1. [System.Serializable]
    2. public abstract class BulletSettings
    3. {
    4.     public bool VariableBoolGlobal;
    5. }
    6. [System.Serializable]
    7.  
    8. public class BulletSetting_A : BulletSettings
    9. {
    10.     public float VariableFloatTest;
    11. }
    12. [System.Serializable]
    13.  
    14. public class BulletSetting_B : BulletSettings
    15. {
    16.     public string VariableStringTest;
    17. }
    I'd really appreciate if this worked, because it would make my project far more organized and easier to play around in for what I'm currently doing. If it isn't functional for whatever reason, I'd appreciate an alternative way to approach htis problem.

    I'm really enjoying the rest of the features. But I'd also really appreciate if you could have a look too, it would make my life much easier. :)

    Edit: Unity Version 2019.4.8f1 Personal
     
    Last edited: Oct 18, 2020
  15. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    Hi @ArkyonVeil !

    You can use the new SerializeReference attribute instead of the SerializeField one and your field values should get saved properly :)

    While Power Inspector can handle displaying just about anything you throw at it, it doesn't actually affect serialization in anyway, so the same rules that you usually have to work with in Unity still apply here.
     
    ArkyonVeil likes this.
  16. ArkyonVeil

    ArkyonVeil

    Joined:
    Dec 20, 2013
    Posts:
    14
    You're a savior. Thank you so much :D
     
    SisusCo likes this.
  17. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    Was playing with the new UI Builder to create custom inspectors and noticed that it doesn't seem to work at all with PI.
    Makes sense I suppose since it has not even had it's first stable release yet.
    But are there plans to support it eventually?
     
  18. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    @Bezoro The UI Toolkit is something I've been keeping an eye on for a long time and waiting for it to mature. I don't want to lose backwards compatibility with older versions of Unity that don't support it, and this makes introducing support even more complicated than it would otherwise be :eek:

    Nonetheless I have started working on slowly rewriting the top level structures of Power Inspector with the new UI Toolkit. The plan at first is to rewrite everything down to the component level, so that I can introduce support for UI based custom editors. This I think should be doable within a reasonable timeframe if there aren't any unforeseen complications.

    Fully supporting UI based property drawers and decorator drawers requires quite a bit more work, because they could be nested inside any datasets from arrays to custom classes, which means that I'll also have to rewrite a large number of quite complex parent drawers in Power Inspector. But once the generic ComponentDrawer and DataSetDrawer have been rewritten I think that 95% of situations should be covered at least.

    tl;dr: the plan is to support it eventually but it could take a while before full-blown support is in.
     
  19. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    Understandable. I don't envy the amount of work that that'll probably take.

    On another note, something that I just noticed is that it would be really nice if we could invoke methods from classes marked as [System.Serializable], like we can for MonoBehaviours, if that makes sense. Don't know if that is at all possible, but it would be pretty awesome.

    Thanks for all your work on this asset by the way. It has completely replaced the default inspector for me for a while now.
     
  20. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    @Bezoro Great to hear that PI is being put to good use!

    That is definitely doable. In fact, if you add the ContextMenuItem attribute to a method inside a plain old class object it will currently show up in the context menu.

    Code (CSharp):
    1. using System;
    2. using UnityEngine;
    3.  
    4. public class TestClassWithMethod : MonoBehaviour
    5. {
    6.     public ClassWithMethod rightClickMe = new ClassWithMethod();
    7.  
    8.     [Serializable]
    9.     public class ClassWithMethod
    10.     {
    11.         [ContextMenu("Method")]
    12.         public void Method()
    13.         {
    14.             Debug.Log("Hello from method!");
    15.         }
    16.     }
    17. }
    context-menu-attribute-with-pocos.png

    But yeah, I could also add an "Invoke" menu item in the expanded context menu which always contains all the methods of the target. It's a great idea, thanks for the suggestion! :)
     
  21. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    That is what I meant yeah, some sort of list of all the methods of a serialized class without the need for a [ContextMenu] attribute.
     
    SisusCo likes this.
  22. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    @Bezoro I had a big eureka moment last weekend when I was working on adding support for UI based custom editors. I wasn't making good progress with my initial top-down rewrite approach, so I ended up starting from scratch with a new idea I had of simply overlaying the VisualElements on top of my existing IMGUI based UI - and it actually seems to be working like a charm :)

    So as a result Power Inspector 1.5.0 now has support for UI based custom editors and property drawers. I haven't done super extensive testing with this yet, but my simple test editors at least seemed to be working just as expected.

    Version 1.5.0 also adds the ability to invoke methods on any class members via the expanded context menu.

    It lists even methods with return values, and selecting them results in the return value being copied to the clipboard and logged to the console.

    invoke-submenu.png
     
    Last edited: Oct 29, 2020
  23. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    Made a quick test and got this:
    PI UIBuilder Custom Inspector Issue.png

    Custom editor code:
    Code (CSharp):
    1. using UnityEditor;
    2. using UnityEngine.UIElements;
    3.  
    4. namespace Bezoro.Editor
    5. {
    6.     [CustomEditor(typeof(Player))]
    7.     public class UIBuilderPlayerEditor : UnityEditor.Editor
    8.     {
    9.         private Player _player = null;
    10.         private VisualElement _rootElement = null;
    11.         private VisualTreeAsset _visualTreeAsset = null;
    12.      
    13.         private void OnEnable()
    14.         {
    15.             _player = (Player)target;
    16.             _rootElement = new VisualElement();
    17.  
    18.             _visualTreeAsset =
    19.                 AssetDatabase
    20.                    .LoadAssetAtPath<VisualTreeAsset
    21.                         >("Assets/_Project/Scripts/Editor/CustomInspectors/UI Builder/PlayerInspector.uxml");
    22.         }
    23.  
    24.         public override VisualElement CreateInspectorGUI()
    25.         {
    26.             var root = _rootElement;
    27.             root.Clear();
    28.      
    29.             _visualTreeAsset.CloneTree(root);
    30.      
    31.             return root;
    32.         }
    33.     }
    34. }
    35.  

    PlayerInspector.uxml is just a button with a label test (as you can see from the first image), there is no functionality whatsoever.

    Hope this makes sense.

    Unity 2020.2.0b8.
    Windows Build Support (IL2CPP) is the only platform module installed.
    URP is the project template.
    API Compatibility Level is set by default as .NET 4.x.
    Scripting Backend is IL2CPP.
    Power Inspector 1.5.0.
    UI Builder 1.0.0-preview.9

    As a sidenote, in 1.4.9(?), the previous version, it simply wouldn't do anything to PI.

    As far as I'm concerned there is no need to rush, the new UI system is still very new, it hasn't even had it's 1.0 yet. It would just be nice to have, because I really don't like the current workflow for making custom editors, and even though I have Odin Inspector, I am also not a huge fan of littering my code with tons of attributes just to make my inspector nicer. But that is besides the point.

    Edit.: Another detail, this is not a 100% clean project, so that may have something to do with it.
     
  24. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    @Bezoro Ah, my bad...I forgot to actually turn on UI support inside the inspector by default :rolleyes:

    If you add PI_ENABLE_UI_SUPPORT to the Scripting Define Symbols in Player settings the editor should start working. I'll make an update soon to enable the feature by default.
     
  25. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    Beautiful :p
    PI UIBuilder CustomInspector Working.png

    Edit.: Collapsing the component isn't working correctly for me. It keeps drawing the fields regardless.
     
    Last edited: Oct 30, 2020
    SisusCo likes this.
  26. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    Oh, collapsing is working locally on my machine, but I must have pushed out the update before I fixed that issue. So this should also get fixed with the next update.
     
  27. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    So... It's me again :p

    Feature Requests:

    [Material Inspector] Remember its last state. (Per Game Object?)

    [Script Wizard] Ability to resize the window for long Namespaces/Save Paths.

    [Script Wizard] Add "fileName" and "menuName" fields for ScriptableObjects.

    [Script Wizard] Use the same script inspector that PI uses

    Bugs:

    ScriptableObjects Inspector not drawing Odin Inspector Attributes.
    Unity 2020.2.0b13
    Odin 3.0.2.0
    PI 1.5.3


    Code (CSharp):
    1.  
    2. using System.Collections.Generic;
    3. using Sirenix.OdinInspector;
    4. using UnityEngine;
    5. using UnityEngine.InputSystem;
    6.  
    7. namespace Bezoro.Editor
    8. {
    9.     [CreateAssetMenu(fileName = "MAN_Input", menuName = "Bezoro/Managers/Input Manager")]
    10.     public class InputManager : ScriptableObject
    11.     {
    12.         [BoxGroup("Dependencies"), PropertyOrder(0)] [Required]
    13.         [SerializeField] private InputActionAsset _inputActionAsset = null;
    14.         [BoxGroup("Debug"), PropertyOrder(2)] [ReadOnly] [DisplayAsString]
    15.         [SerializeField] private List<string> _actionMaps = new List<string>();
    16.  
    17.         private void Awake() => Debug.Log("Awake");
    18.  
    19.         private void OnEnable() => Debug.Log("Enable");
    20.  
    21.         private void OnDisable() => Debug.Log("Disable");
    22.  
    23.         private void OnDestroy() => Debug.Log("Destroy");
    24.  
    25.         private void OnValidate()
    26.         {
    27.             _actionMaps.Clear();
    28.             foreach (var map in _inputActionAsset.actionMaps)
    29.                 _actionMaps.Add(map.name);
    30.         }
    31.     }
    32. }
    33.  

    Scriptable Wizard ignores "Editor" folder. (Haven't tested it but I'd assume it ignores all Unity special folders)

    ? Documentation button takes you to the wrong page for seemingly all components.

    Ground function bug with offset child mesh.
    (The capsule collider is also offset by 1 unit on the Y as you can see in the first image [Center: 0,1,0])
    Hopefully this one makes sense, it's a little convoluted.
     
  28. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    Great ideas and bug discoveries as usual @Bezoro :) I'll try to get all of these implemented for to the next version.
     
  29. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    Not sure if I should edit my previous post or write a new one, but here goes.

    Bug:

    This one has been bugging me for a while. I finally found a way to reproduce it 100% of the time.
    Custom scripts (non-Unity scripts) disappear when entering Play Mode (Reload domain = false) if Inspector Gadgets Pro is installed along with PI.
    PI 1.5.3
    IGP 6.5





    Code (CSharp):
    1.  
    2. using UnityEngine;
    3.  
    4. public class PIBugTest : MonoBehaviour
    5. {
    6. }
    7.  

    I'm considering it a PI bug because it does not affect the default inspector when Inspector Gadgets is installed, only PI.
    A workaround is to simply deselect the GO and select it again btw.
     
    Last edited: Nov 30, 2020
  30. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    @Bezoro What an interesting bug :D I'll look into it.
     
  31. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    Sorry to lay even more stuff on you but I just noticed 1 more thing...

    Bug:

    Node Canvas FSM/BT Assets do not draw correctly in PI.

    Funnily enough it does draw Dialogue Tree Assets fine...

    PI: 1.5.3
    Node Canvas: 3.1.6
    Unity: 2020.2.0b14
     
  32. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    @Bezoro Just when I had gotten all the previous issues fixed you do this to me dammit :p

    I'm just kidding, the more the merrier - I'll try to get this one fixed too next week.
     
  33. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    Not gonna lie, I did feel bad :oops:
    Thanks for being a good sport though.
     
    SisusCo likes this.
  34. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    The new version has some really cool stuff, thank you for taking the time.
    I was surprised to see that in the new version Inspector Gadgets Pro was drawing the transform even in PI.
    I wonder if you can tell PI to override something like that? Although I don't think I will even if you can. I think IGP covers all the features of PI for the transform component and even has a couple extra things. Although I do prefer how PI draws the transform component.
    I did find a bug while testing though.

    Bug:

    "Freeze Child Transforms" does not work in the scene view while using the transform gizmos to manipulate a parent object. It does work in PI by dragging the individual position and rotation field though.
    LCTSideBySide.png

    Sorry about reporting these very asset specific bugs...
    I just want PI to be the best it can be, because it's awesome.
     
    Last edited: Dec 7, 2020
  35. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    Glad you like them; thank you again for all the great ideas for improvements you've given :)

    Yeah, custom editors from third party packages were always supposed to be prioritized over Power Inspector's component drawers, but there was a flaw in the prioritization system which resulted in this not happening consistently before the latest update.

    The prioritization system is not something that can currently be configured in the preferences, but there are ways to take control of this process with a bit of code. One way to achieve this would be with the use of a custom drawer provider. For example this drawer provider would ensure that PI's TransformDrawer gets used for Transform targets:
    Code (CSharp):
    1. using UnityEngine;
    2. using Sisus.Attributes;
    3. namespace Sisus
    4. {
    5.     [DrawerProviderFor(typeof(PowerInspector))]
    6.     public sealed class MyDrawerProvider : DrawerProviderModifier
    7.     {
    8.         public MyDrawerProvider() : base(new DefaultDrawerProvider()) { }
    9.         public override IComponentDrawer GetForComponent(IInspector inspector, Component target, IParentDrawer parent)
    10.         {
    11.             if(target is Transform)
    12.             {
    13.                 return TransformDrawer.Create(new Component[]{ target }, parent, inspector);
    14.             }
    15.             return base.GetForComponent(inspector, target, parent);
    16.         }
    17.         public override IComponentDrawer GetForComponents(IInspector inspector, Component[] targets, IParentDrawer parent)
    18.         {
    19.             if(targets.Length > 0 && targets[0] is Transform)
    20.             {
    21.                 return TransformDrawer.Create(targets, parent, inspector);
    22.             }
    23.             return base.GetForComponents(inspector, targets, parent);
    24.         }
    25.     }
    26. }
    Interesting...I'll make sure to look into this too.

    It's all good, I feel the same way ;) Even if an issue is completely asset specific, resolving it can still help all PI users using that asset, so fixing it is still important to me.
     
    Bezoro likes this.
  36. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    @Bezoro I submitted a new update for review that should fix the issue of some features in Inspector Gadgets Pro not functioning properly inside PI.
     
  37. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    Super cool, seems to be working nicely.
    Hopefully I won't need to bother you anymore anytime soon.
    Thank you for your hard work.
     
    SisusCo likes this.
  38. OnePlusOneNS

    OnePlusOneNS

    Joined:
    Nov 18, 2013
    Posts:
    7
    Hey,

    great asset! Really enjoy using it! :)

    A minor issue a co-worker of mine has found is that when previewing a material in power inspector it does not change the mesh used for previewing. It always displays the material on a sphere instead of the selected mesh (i.e. cube or cylinder). This behaviour was seen using Unity 2021.1.5.

    Thanks for this nice asset!
     
  39. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    Hi @OnePlusOneNS I'm happy to hear you've been enjoying using PI :)

    I'll look into the material preview issue, thanks for letting me know about it!
     
  40. Bezoro

    Bezoro

    Joined:
    Mar 16, 2015
    Posts:
    133
    Would just like to report this warning:

    Unity_OTPbgyPSny.png

    Also, trying to open PI gives me this exception:

    Unity_hZn9LEcSHI.png

    PI: 1.6.2
    Unity 2020.3.12f1
     
    Last edited: Jun 26, 2021
  41. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    @Bezoro Thanks for reporting these, I'll look into them.
     
  42. JuniorLongfellow

    JuniorLongfellow

    Joined:
    Feb 27, 2013
    Posts:
    19
    I'm getting the same null pointer exception error. Just bought this asset, is there a working version?

    2021.1.13
     
  43. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    Hi there @pcthehuman

    A fix has been submitted to the asset store, but it can take a couple of days for it to pass verification. I sent you a PM so you can get your hands on it sooner if you like.
     
  44. esteban16108

    esteban16108

    Joined:
    Jan 23, 2014
    Posts:
    159
    @SisusCo when a script is selected in the project window power inspector only shows the source code I also need to see to which assembly definition it belongs like the default inspector, is there a way to enable that or it's not a feature?

    upload_2021-9-6_17-37-36.png
     
  45. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    Hey @esteban16108

    There is currently no feature in Power Inspector's script drawer to do this I'm afraid.

    If it's enough to just see the name of the assembly, I could easily add that information in the tooltip that is shown when mouseovering the header.

    I could also maybe add something like "Select Assembly Definition" to the context menu for easily selecting the file in the Project view - not really sure how difficult it would be for me to locate that file programmatically though.

    Adding a reference field for the assembly definition file might be a bit more involved, and I'm not sure where I'd want to place that, as optimally I'd like to keep the header size minimal to fit as much visible code in the first page as possible. Maybe I could tuck that information behind a foldout, or a new header button or something...but I'll have to think about that some more :)
     
  46. esteban16108

    esteban16108

    Joined:
    Jan 23, 2014
    Posts:
    159
    My use case was that I needed to work with a test case, so when you create a test case in Unity it creates a new assembly with no reference to anything in the project, so I needed to know to which assembly def the class I wanted to test belonged to...

    I think a readonly field above the code showing to which assembly it belongs it's enough... I mean, I like power inspector enough so I don't need to open the old one ;)
     
    SisusCo likes this.
  47. esteban16108

    esteban16108

    Joined:
    Jan 23, 2014
    Posts:
    159
    @SisusCo this means we can expect this change in the next release? Thanks
     
  48. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    @esteban16108 I will investigate this and see what is doable, but yeah I'm hoping I'll have a solution for this in one form or another in the next release.

    I'll see first if I can conjure up a reference to the assembly definition file programmatically, in which case I could perhaps add that custom read-only reference field as you've suggested.

    If that can't be done my plan B is to add the ability to view the default script editor inside Power Inspector, so one can at least access the information at will that way.
     
    esteban16108 likes this.
  49. AGregori

    AGregori

    Joined:
    Dec 11, 2014
    Posts:
    527
    Got this issue, it breaks everything:

    NullReferenceException: Object reference not set to an instance of an object
    UnityEditor.ModelImporterClipEditor.OnInteractivePreviewGUI (UnityEngine.Rect r, UnityEngine.GUIStyle background) (at <d04deee419f24e8faf312b86e53e3f07>:0)
    UnityEditor.AssetImporterTabbedEditor.OnInteractivePreviewGUI (UnityEngine.Rect r, UnityEngine.GUIStyle background) (at <d04deee419f24e8faf312b86e53e3f07>:0)
    UnityEditor.ObjectPreview.DrawPreview (UnityEditor.IPreviewable defaultPreview, UnityEngine.Rect previewArea, UnityEngine.Object[] targets) (at <d04deee419f24e8faf312b86e53e3f07>:0)
    UnityEditor.AssetImporters.AssetImporterEditor.DrawPreview (UnityEngine.Rect previewArea) (at <d04deee419f24e8faf312b86e53e3f07>:0)
    Sisus.EditorWrapper.DrawPreview (UnityEngine.Rect previewArea) (at Assets/Sisus/Power Inspector/Code/Editor/Inspector/Core/PreviewDrawer/EditorWrapper.cs:162)
    Sisus.PreviewDrawer.Draw (UnityEngine.Rect position) (at Assets/Sisus/Power Inspector/Code/Editor/Inspector/Core/PreviewDrawer/PreviewDrawer.cs:1126)
    Sisus.PowerInspector.OnGUI (UnityEngine.Rect inspectorDimensions, System.Boolean anyInspectorPartMouseovered) (at Assets/Sisus/Power Inspector/Code/Editor/Inspector/Power Inspector/PowerInspector.cs:204)
    Sisus.InspectorDrawerWindow`2[TInspectorDrawer,TInspector].OnGUI () (at Assets/Sisus/Power Inspector/Code/Editor/EditorWindow/InspectorDrawerWindow.cs:2261)
    UnityEditor.HostView.InvokeOnGUI (UnityEngine.Rect onGUIPosition, UnityEngine.Rect viewRect) (at <d04deee419f24e8faf312b86e53e3f07>:0)
    UnityEditor.DockArea.DrawView (UnityEngine.Rect viewRect, UnityEngine.Rect dockAreaRect) (at <d04deee419f24e8faf312b86e53e3f07>:0)
    UnityEditor.DockArea.OldOnGUI () (at <d04deee419f24e8faf312b86e53e3f07>:0)
    UnityEngine.UIElements.IMGUIContainer.DoOnGUI (UnityEngine.Event evt, UnityEngine.Matrix4x4 parentTransform, UnityEngine.Rect clippingRect, System.Boolean isComputingLayout, UnityEngine.Rect layoutSize, System.Action onGUIHandler, System.Boolean canAffectFocus) (at <3d389beb8fbc4cc99098812a324df20c>:0)
    UnityEngine.GUIUtility:processEvent(Int32, IntPtr, Boolean&)

    Unity_JKxgTRlGFB.png
     
  50. SisusCo

    SisusCo

    Joined:
    Jan 29, 2019
    Posts:
    1,331
    @AGregori I'll investigate the cause of this - thanks for letting me know about it.
     
    AGregori likes this.