浏览代码

Try to fix MSVC build

rexim 4 年之前
父节点
当前提交
040ae6823c
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      main.c

+ 1 - 1
main.c

@@ -186,7 +186,7 @@ void buffer_delete(void)
 
 
 void render_cursor(SDL_Renderer *renderer, const Font *font)
 void render_cursor(SDL_Renderer *renderer, const Font *font)
 {
 {
-    const Vec2f pos = vec2f(buffer_cursor * FONT_CHAR_WIDTH * FONT_SCALE, 0.0f);
+    const Vec2f pos = vec2f((float) buffer_cursor * FONT_CHAR_WIDTH * FONT_SCALE, 0.0f);
 
 
     const SDL_Rect rect = {
     const SDL_Rect rect = {
         .x = (int) floorf(pos.x),
         .x = (int) floorf(pos.x),