Source [MuEmu] Fix Notice System to work with Slider - kayito

Publicado por Dakosmu, Jul 10, 2023, 08:52 AM

Tema anterior - Siguiente tema

Dakosmu

Source [MuEmu] Fix Notice System to work with Slider - kayito


CitarBuenas gente, en este caso les traigo el fix para que puedan utilizar el notice system con el slider del main.
Para aquellos que no lo sepan, el sistema de noticias de muemu (que se ubica en "MuServer/Data/Util/Notice.txt") tiene la posibilidad de trabajar con el slider del main.
Sin más, les dejo el fix para que funcione.



Los visitantes no pueden visualizar imágenes en los mensajes, por favor Regístrate o Inicia Sesión



CitarGameServer -> Notice.cpp
Buscar la función "void CNotice::Load(char* path)" y donde dice

info.Color = RGB(lpMemScript->GetAsNumber(),lpMemScript->GetAsNumber(),lpMemScript->GetAsNumber());
Reemplazar por lo siguiente:

info.Color = 0;
info.Color |= lpMemScript->GetAsNumber();
info.Color |= (lpMemScript->GetAsNumber() << 8);
info.Color |= (lpMemScript->GetAsNumber() << 16);
info.Color |= (info.Opacity << 24);

De esta forma podrán usar el RGB + el Opacity para definir el color del texto.

Acá les describo los tipos de mensaje que pueden enviar:

CitarTYPE   VALUE
0   Global center yellow message
1   Global system blue message
2   Global center green message
HELP SLIDER
10   Normal message (lowest importance): Appears according to the announcement time, but is deleted if the appearance time is delayed
11   Must-read message (low importance): Appears according to the notice time
12   Urgent message (important): Appears next time ignoring other notices
NOTICE SLIDER
13   General Notice (Severe Importance): Appears according to the notice time, but is deleted if the appearance time is delayed
14   Must-Read Notice (High importance): Appears according to the notice time
15   Urgent Announcement (Highest Importance): Appears next time ignoring other announcements
Acá les dejo un archivo configurado de ejemplo:


//Message Type Count Opacity Delay Red Green Blue Speed RepeatTime
"Mensaje global amarillo" 0 1 0 0 0 0 0 0 60
"Mensaje global azul" 1 1 0 0 0 0 0 0 60
"Mensaje global verde" 2 1 0 0 0 0 0 0 60
"Slider tipo 10" 10 1 255 0 255 0 0 5 60
"Slider tipo 11" 11 1 255 0 0 255 0 5 60
"Slider tipo 12" 12 1 255 0 0 0 255 5 60
"Slider tipo 13" 13 1 255 0 255 255 0 5 60
"Slider tipo 14" 14 1 255 0 255 0 255 5 60
"Slider tipo 15" 15 1 255 0 0 255 255 5 60
end











Bon Dia

🡱 🡳