setInitOffset method
Implementation
void setInitOffset(VoltronMap map) {
if (isHorizontal) {
var offset = map.get<double>("x") ?? map.get<int>("x")?.toDouble() ?? 0;
_initOffset = offset;
} else {
var offset = map.get<double>("y") ?? map.get<int>("y")?.toDouble() ?? 0;
_initOffset = offset;
}
}