sbox-issues
sbox-issues copied to clipboard
Reset button for a Component in the Inspector window does nothing
Describe the bug
reset button for a component in the inspector does nothing
To Reproduce
- Create a component with a property initialized to a value
- Attach the component to a GameObject and modify the Property's value
- Click the ellipsis on the component in the inspector and select "Reset"
Expected behavior
the Reset button should set the properties to their default values
Media/Files
Additional context
No response
Added this now
@DevulTj since your last change
public override void Reset()
{
base.Reset();
}
is now breaking the Component behavior. I had to remove the base function call in order to restore the previous behavior.
I'm not sure if this is expected.
Yeah, fair enough, I'll fix that properly.
Calling Sandbox.MapInstance.Reset() is now throwing error:
Object reference not set to an instance of an object.
System.NullReferenceException: Object reference not set to an instance of an object.
at Sandbox.MapInstance.LoadMapAsync(String mapName)
This breaks my Reset logic for my project :/ (i will find a temporary fix)
This isn't happening anymore