[AB-89] adding templates for weather command feature

This commit is contained in:
Sheldan
2023-03-17 01:53:52 +01:00
parent b6a2dd2da7
commit e05f774500
13 changed files with 54 additions and 0 deletions

View File

@@ -0,0 +1,41 @@
{
"embeds": [
{
"color" : {
"r": ${embedColor.red},
"g": ${embedColor.green},
"b": ${embedColor.blue}
},
<#assign weatherMap = { "Rain": "🌧️", "Clouds": "☁️", "Mist": "🌁", "Fog": "🌫️", "Sand": "⏳", "Dust": "⏳", "Thunderstorm": "⛈️", "Snow": "🌨️", "Clear": "☀️"}>
<#assign locationName=locationName>
<#assign countryKey=countryKey>
<#assign weatherIcon>${weatherMap[mainWeather]!""}</#assign>
<#assign weatherKey=mainWeather!"">
<#assign weatherDescription=description!"">
"description": "<@safe_include "openWeatherMap_command_response_description"/>",
"fields": [
<#if temperature??>
{
<#assign displayTemperaturRange=maxTemperature!=minTemperature>
"name": "<@safe_include "openWeatherMap_command_response_field_temperature_field_title"/>",
"value": "<@safe_include "openWeatherMap_command_response_field_temperature_field_value"/>",
"inline": "true"
},
{
"name": "<@safe_include "openWeatherMap_command_response_field_temperature_feels_like_field_title"/>",
"value": "${feelsLikeTemperature}°C",
"inline": "true"
}
</#if>
<#if humidity??>
<#if temperature??>,</#if>
{
"name": "<@safe_include "openWeatherMap_command_response_field_humidity_field_title"/>",
"value": "${humidity}%",
"inline": "true"
}
</#if>
]
}
]
}

View File

@@ -0,0 +1 @@
<#include "no_weather_location_found_exception_text">