if text:match("%[FA%] .+ Family .+: .+") then
color = argb_to_rgba(join_argb(211, colors.fam.r, colors.fam.g, colors.fam.b))
return {color, text}
end
Туже процедуру что и выше делал с чатом фамы, все работает: чат изменяет цвет, который я укажу.
if text:match("%[A%] Администратор...
Что не так?
{E69A00}[A] Администратор Tom_Red [49]: {E6C600}Ну вот..
if text:match("%[A%] Администратор (%a+_%a+)%[(%d+)%]: (.+)") then
color = argb_to_rgba(join_argb(211, colors.fam.r, colors.fam.g, colors.fam.b))
return {color, text}
end
if text:match("%[FA%] .+ Family .+: .+") then
color = argb_to_rgba(join_argb(211, colors.fam.r, colors.fam.g, colors.fam.b))
return {color, text}
end
Есть такой код, помогите написать text:match, чтобы цвет менял ник: Jon_Tayler
{E69A00}[A] Администратор Jon_Tayler [39]: {E6C600}Ну вот..
help
чатлог: [FA] AnarchySons Family Pasha Gudkin: {ECECEB}Текст сообщения
ps Family не изменяема, в каждой семье статична
if text:match('[FA] .+% Family .+%: .+%') then color = argb_to_rgba(join_argb(255, colors.jail.r, colors.jail.g, colors.jail.b)) end