Skip to main content

MetricUtils

Provides ways to convert studs to metric and back.

Functions

getSoundDelaySeconds

MetricUtils.getSoundDelaySeconds(studsnumber) → number--

seconds

Computes sound delay for the given studs

studsToKilometers

MetricUtils.studsToKilometers(studsnumber) → number--

kilometers

Converts studs to kilometers

studsToMeters

MetricUtils.studsToMeters(studsnumber) → number--

meters

Converts studs to meters

studsPerSecondToKph

MetricUtils.studsPerSecondToKph(studsPerSecondnumber) → number--

kph

Convert from studs per a second (Roblox in-game units) to kph

studsPerSecondToMetersPerSecond

MetricUtils.studsPerSecondToMetersPerSecond(studsPerSecondnumber) → number--

kph

Convert from studs per a second to meters per a second

studsPerSecondToMph

MetricUtils.studsPerSecondToMph(studsPerSecondnumber) → number--

mph

Convert from studs per a second (Roblox in-game units) to mph

kphToStudsPerSecond

MetricUtils.kphToStudsPerSecond(kphnumber) → number--

studs per a second

Convert mph to studs per a second

mphToStudsPerSecond

MetricUtils.mphToStudsPerSecond(mphnumber) → number--

studs per a second

Convert mph to studs per a second

Show raw api
{
    "functions": [
        {
            "name": "getSoundDelaySeconds",
            "desc": "Computes sound delay for the given studs",
            "params": [
                {
                    "name": "studs",
                    "desc": "",
                    "lua_type": "number"
                }
            ],
            "returns": [
                {
                    "desc": "seconds",
                    "lua_type": "number"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 18,
                "path": "src/metricutils/src/Shared/MetricUtils.lua"
            }
        },
        {
            "name": "studsToKilometers",
            "desc": "Converts studs to kilometers",
            "params": [
                {
                    "name": "studs",
                    "desc": "",
                    "lua_type": "number"
                }
            ],
            "returns": [
                {
                    "desc": "kilometers",
                    "lua_type": "number"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 28,
                "path": "src/metricutils/src/Shared/MetricUtils.lua"
            }
        },
        {
            "name": "studsToMeters",
            "desc": "Converts studs to meters",
            "params": [
                {
                    "name": "studs",
                    "desc": "",
                    "lua_type": "number"
                }
            ],
            "returns": [
                {
                    "desc": "meters",
                    "lua_type": "number"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 37,
                "path": "src/metricutils/src/Shared/MetricUtils.lua"
            }
        },
        {
            "name": "studsPerSecondToKph",
            "desc": "Convert from studs per a second (Roblox in-game units) to kph",
            "params": [
                {
                    "name": "studsPerSecond",
                    "desc": "",
                    "lua_type": "number"
                }
            ],
            "returns": [
                {
                    "desc": "kph",
                    "lua_type": "number"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 46,
                "path": "src/metricutils/src/Shared/MetricUtils.lua"
            }
        },
        {
            "name": "studsPerSecondToMetersPerSecond",
            "desc": "Convert from studs per a second to meters per a second",
            "params": [
                {
                    "name": "studsPerSecond",
                    "desc": "",
                    "lua_type": "number"
                }
            ],
            "returns": [
                {
                    "desc": "kph",
                    "lua_type": "number"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 56,
                "path": "src/metricutils/src/Shared/MetricUtils.lua"
            }
        },
        {
            "name": "studsPerSecondToMph",
            "desc": "Convert from studs per a second (Roblox in-game units) to mph",
            "params": [
                {
                    "name": "studsPerSecond",
                    "desc": "",
                    "lua_type": "number"
                }
            ],
            "returns": [
                {
                    "desc": "mph",
                    "lua_type": "number"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 65,
                "path": "src/metricutils/src/Shared/MetricUtils.lua"
            }
        },
        {
            "name": "kphToStudsPerSecond",
            "desc": "Convert mph to studs per a second",
            "params": [
                {
                    "name": "kph",
                    "desc": "",
                    "lua_type": "number"
                }
            ],
            "returns": [
                {
                    "desc": "studs per a second",
                    "lua_type": "number"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 74,
                "path": "src/metricutils/src/Shared/MetricUtils.lua"
            }
        },
        {
            "name": "mphToStudsPerSecond",
            "desc": "Convert mph to studs per a second",
            "params": [
                {
                    "name": "mph",
                    "desc": "",
                    "lua_type": "number"
                }
            ],
            "returns": [
                {
                    "desc": "studs per a second",
                    "lua_type": "number"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 83,
                "path": "src/metricutils/src/Shared/MetricUtils.lua"
            }
        }
    ],
    "properties": [],
    "types": [],
    "name": "MetricUtils",
    "desc": "Provides ways to convert studs to metric and back.",
    "source": {
        "line": 5,
        "path": "src/metricutils/src/Shared/MetricUtils.lua"
    }
}