mirror of
https://github.com/luanti-org/luanti.git
synced 2025-11-21 08:55:21 +01:00
Add inventory image animation API (#16538)
This commit is contained in:
@@ -500,6 +500,16 @@ inline void str_formspec_escape(std::string &str)
|
||||
str_replace(str, "$", "\\$");
|
||||
}
|
||||
|
||||
/**
|
||||
* Escapes characters to nest texture modifiers
|
||||
*/
|
||||
inline void str_texture_modifiers_escape(std::string &str)
|
||||
{
|
||||
str_replace(str, "\\", "\\\\");
|
||||
str_replace(str, "^", "\\^");
|
||||
str_replace(str, ":", "\\:");
|
||||
}
|
||||
|
||||
/**
|
||||
* Replace all occurrences of the character \p from in \p str with \p to.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user