神岛 API 文档 - ArenaPro版
    Preparing search index...
    • Converts a string to an integer.

      Parameters

      • string: string

        A string to convert into a number.

      • Optionalradix: number

        A value between 2 and 36 that specifies the base of the number in string. If this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal. All other strings are considered decimal.

      Returns number

    • Parameters

      • s: string
      • Optionalradix: number

      Returns number

      将字符串转换为整数。

      Converts a string to an integer.

      要转换为数字的字符串。

      A string to convert into a number.

      一个介于 2 和 36 之间的值,指定 s 中数字的基数。如果未提供此参数,则前缀为“0x”的字符串被视为十六进制。所有其他字符串都被视为十进制。

      A value between 2 and 36 that specifies the base of the number in s. If this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal. All other strings are considered decimal.