@Options is an effective method for restricting parameters. How can I create my own OptionList?
For an extension, I tried to create a list of possible directions (forward, backward, etc.) with the name MoveDirections. To do this, I adapted a copy of the ScreenAnimation class.
This is the extension code:
@SimpleFunction(description = "Move the robot.")
public void Move(@Options(MoveDirection.class) String Direction) {
...
}
When compiling, I get this error message:
java.lang.IllegalArgumentException: OptionList Class: de.ullisroboterseite.ursblerobot.MoveDirection is not available. Make sure that it is available to the compiler.
at com.google.appinventor.components.scripts.ComponentProcessor.tryAddOptionList(ComponentProcessor.java:2117)
Trying @SimpleProperty instead of @SimpleFunction gives the same error.
