jessaskey/mhedit

Add a 'Validate' to the Maze/Collection right click in the tree.

jessaskey opened this issue · 2 comments

It would be handy for a builder to be able to right click on a maze OR collection in the tree and select 'Validate' and get a nice report of any issues. If in a collection, it would need to also say which maze it is for.

Validation errors need to identify the object that is failing to help the user locate and correct the problem. In this light I need to come up with a better AutoNaming scheme for MazeObjects so that validation errors can be more easily tracked.

One option is to Prefix the Object's AutoName with the Maze it's in. Such as Level13.Arrow3. Another option is to simply print the name stack out in the error message: MazeCollection1:Maze3:Perkoid11.

I'm also thinking of giving a red background to any object that has a validation error in the visual trees. So the TreeView will have a highlight and the object in the ComboBox as well.

I think that the [MazeName].[ObjectName] should be fine for now... and the only thing to take into consideration is there probably does need to have maybe two aspects to this... ERRORs and WARNINGs? So a Validation Error would be something that would not even run in MAME or be allowed for upload... example: no reactoid in a level. That should be an ERROR. While something like an object being defined outside of maze area (which would mostly include position 0,0 objects for now) might just be a Validation WARNING. The example you brought up of having a lock of a certain color but not a key, that might be a WARNING too, but not an error because at a certain point in the game, Im going to allow carrying keys across multiple levels. :-)