gamnit: fix actually using the attribute partial_line_skip
[nit.git] / lib / gamnit / bmfont.nit
index a4ab1fb..8ad2dce 100644 (file)
@@ -356,12 +356,11 @@ class BMFontAsset
                var dy = 0.0
 
                var line_height = desc.line_height
+               var partial_line_skip = line_height * partial_line_mod.to_f
 
                var prev_char = null
                for c in text do
 
-                       var partial_line_mod = 0.4
-
                        # Special characters
                        if c == '\n' then
                                dy -= line_height.to_f
@@ -369,11 +368,11 @@ class BMFontAsset
                                prev_char = null
                                continue
                        else if c == pld then
-                               dy -= line_height * partial_line_mod.to_f
+                               dy -= partial_line_skip
                                prev_char = null
                                continue
                        else if c == plu then
-                               dy += line_height * partial_line_mod.to_f
+                               dy += partial_line_skip
                                prev_char = null
                                continue
                        else if c.is_whitespace then