Saltar al contenido principal

GetCurrentWind

aviso

Este export solo está disponible para lado del servidor!

Export Syntax
exports['dream_windturbines']:GetCurrentWind(WithCache) -- Returns Data

Parámetro

  1. WithCache (Bool) -> ¿Incluir el caché actual del viento? Sí o no!

Respuesta

Response Table
{
"speed": int, -- Velocidad del viento
"trend": string, -- [up, down]

-- SOLO CUANDO WithCache = true:
"cache": {
['TIMESTAMP'] = int -- Velocidad del viento
}
}
Example Export
local CurrentWind = exports['dream_windturbines']:GetCurrentWind()
print(CurrentWind.speed) -- 💨 Velocidad actual del viento
print(CurrentWind.trend) -- 📈 Tendencia actual del viento (Subiendo o bajando)