While I certainly prefer the engine callback, it would be best to have some mechanism so that a scenario could tell the engine what difficulty levels it supports, not all authors will be wanting to support all levels.
Example of my proposal method in proper XML:
<difficulty-selectable value="true"/>(Note from the first post, difficult -> difficulty)
This would mean we'd have the 0, 3, and 5 difficulties available (aka: "Very easy", "Hard", and "Insane" in the default english translation). As well, the difficulty-selectable tag would replace the difficulty tag, and if both occur, it will take priority. As well, for displaying the "chooseable" difficulty levels, it would probably display it as GAE currently does, with a table showing information about the scenario, but the difficulty value would have arrows around its value. The default value of the difficulty field would be whichever "difficulty" tag appears first, so if the tag is:
Then the default difficulty will be 3 (Hard), that way if a scenario has support for a far easier than intended difficulty level, a player who doesn't realize they can choose won't end up playing in a way easier than intended; though more-over it's just to give modders an extra element of choice.
This graphical method of using arrows around the value (similar to how maps used to work, before the new GUI allowed drop-down boxes) could later be expanded to allow choices for different factions or tilesets (though different factions would be far more complex and would also need some method of checking what faction the player chose; in order to create the correct units, etc). A whole world of possibilities exist, though, should only be taken one step at a time, and I would say it's a higher priority to finish what is planned already and get 0.4 released (it's been more than 9 months since the last GAE release). Unless it ends up being harder than expected, perhaps something for 0.5?