Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Better error message when console-requesting ambiguous items #2174

Closed
Cervator opened this issue Feb 22, 2016 · 0 comments
Closed

Better error message when console-requesting ambiguous items #2174

Cervator opened this issue Feb 22, 2016 · 0 comments
Labels
Topic: UI/UX Requests, Issues and Changes related to screens, artwork, sound and overall user experience

Comments

@Cervator
Copy link
Member

At present if you giveitem axe while running JoshariasSurvival you get:

org.terasology.logic.console.commandSystem.exceptions.CommandExecutionException: java.lang.IllegalArgumentException: No block found for 'axe'

Plus a big stacktrace in the game log. Works fine with plain Core. The issue is that both "Core:axe" and "ManualLabor:axe" exist, as easily visible with search axe - so really the problem isn't that axe doesn't exist, it is that the reference is too vague.

We should present a user a better error message and ideally offer the available suggestions ("It looks like you're trying to request an 'axe' - did you perhaps mean 'Core:axe' or 'ManualLabor:axe'?" - with Clippy mascot optional..)

The stacktrace in the log also isn't very useful since yes we know what the issue is. Probably a simpler warning should be logged instead (and if it is giveItem maybe it should say item instead of block)

@Limeth do you think this is similar to some of the auto-completion we've done in the past or maybe something the search command or some other method could achieve easily? I also wonder if there's a way to make search axe return only whole words or something ..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Topic: UI/UX Requests, Issues and Changes related to screens, artwork, sound and overall user experience
Projects
None yet
Development

No branches or pull requests

1 participant