Some protection against writing characters we don't have
This commit is contained in:
@@ -100,6 +100,11 @@ impl SpriteAtlas {
|
||||
let mut x = x;
|
||||
|
||||
for c in string.chars() {
|
||||
if (c as u8) < 32 {
|
||||
// don't support any ascii below ' ' (space)
|
||||
continue;
|
||||
}
|
||||
|
||||
if c == ' ' {
|
||||
x += 4;
|
||||
continue;
|
||||
|
||||
Reference in New Issue
Block a user