A community extension I'm writing to improve D&D 5E combat in Fantasy Grounds Unity. Design Goal is a minimalist streamlined version of the original Combat Enhancer, written for Fantasy Grounds Unity.
Resizing tokens caused a debug error to pop up on the console. The simple solution here was to just return nil in that branch of the if statement and let the framework take over, as specified in the documentation of tokeninstance.onWheel()
Also corrected the version numbers and created a new .ext file.
onWheel
function onWheel(target, notches)
This function is called when the mouse wheel is spun over the token.
The token interface for wheel events is different than other objects in that a handler must be registered to intercept click events.
Parameters
target (tokeninstance)
The tokeninstance triggering the event
notches (number)
This number specifies the number of notches the wheel was spun. Typically one notch corresponds to one adjustment step on the wheel.
Return values
(boolean)
This function should return true if it handled the event and the processing of the event should be stopped. A value of false indicates that the default framework functionality for the this particular control should not be executed, but the processing should continue for the element below this control, if any. A return value of nil (or the absence of a return statement) indicates that the framework should continue handling the event normally.
Resizing tokens caused a debug error to pop up on the console. The simple solution here was to just return nil in that branch of the if statement and let the framework take over, as specified in the documentation of tokeninstance.onWheel() Also corrected the version numbers and created a new .ext file.