floatToInteger method

Object? floatToInteger(
  1. Object? key
)

Implementation

Object? floatToInteger(Object? key) {
  if (key is double) {
    double f = key;
    if (LuaNumber.isInteger(f)) {
      return f.toInt();
    }
  }
  return key;
}