Canviades certes opcions a parametres i afegides noves opcions

This commit is contained in:
2024-10-11 09:03:57 +02:00
parent 117b80bdfc
commit e1fa1d2102
8 changed files with 113 additions and 115 deletions

View File

@@ -328,6 +328,48 @@ bool setParams(std::string var, std::string value)
param.balloon_4.grav = std::stof(value);
}
// NOTIFICACIONES
else if (var == "notification.pos_h")
{
if (value == "LEFT")
{
param.notification.pos_h = NotifyPosition::LEFT;
}
else if (value == "MIDDLE")
{
param.notification.pos_h = NotifyPosition::MIDDLE;
}
else
{
param.notification.pos_h = NotifyPosition::RIGHT;
}
}
else if (var == "notification.pos_v")
{
param.notification.pos_v = value == "TOP" ? NotifyPosition::TOP : NotifyPosition::BOTTOM;
}
else if (var == "notification.sound")
{
param.notification.sound = stringToBool(value);
}
else if (var == "notification.color.r")
{
param.notification.color.r = std::stoi(value);
}
else if (var == "notification.color.g")
{
param.notification.color.g = std::stoi(value);
}
else if (var == "notification.color.b")
{
param.notification.color.b = std::stoi(value);
}
// RESTO
else
{