mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
vfmt: change all '$expr' to '${expr}' (#16428)
This commit is contained in:
@ -492,7 +492,7 @@ fn (mut app App) ai_move() {
|
||||
bestprediction = predictions[move_idx]
|
||||
}
|
||||
}
|
||||
eprintln('Simulation time: ${think_time:4}ms | best $bestprediction')
|
||||
eprintln('Simulation time: ${think_time:4}ms | best ${bestprediction}')
|
||||
app.move(bestprediction.move)
|
||||
}
|
||||
|
||||
@ -613,8 +613,8 @@ fn (app &App) draw() {
|
||||
app.gg.draw_text(ww / 2, (m * 8 / 10) + ypad, msg2, app.label_format(.score_end))
|
||||
}
|
||||
// Draw at the end, so that it's on top of the victory / game over overlays
|
||||
app.gg.draw_text(labelx, labely, 'Points: $app.board.points', app.label_format(.points))
|
||||
app.gg.draw_text(ww - labelx, labely, 'Moves: $app.moves', app.label_format(.moves))
|
||||
app.gg.draw_text(labelx, labely, 'Points: ${app.board.points}', app.label_format(.points))
|
||||
app.gg.draw_text(ww - labelx, labely, 'Moves: ${app.moves}', app.label_format(.moves))
|
||||
}
|
||||
|
||||
fn (app &App) draw_tiles() {
|
||||
@ -654,13 +654,13 @@ fn (app &App) draw_tiles() {
|
||||
app.gg.draw_text(xpos, ypos, '${1 << tidx}', fmt)
|
||||
}
|
||||
.log {
|
||||
app.gg.draw_text(xpos, ypos, '$tidx', fmt)
|
||||
app.gg.draw_text(xpos, ypos, '${tidx}', fmt)
|
||||
}
|
||||
.exponent {
|
||||
app.gg.draw_text(xpos, ypos, '2', fmt)
|
||||
fs2 := int(f32(fmt.size) * 0.67)
|
||||
app.gg.draw_text(xpos + app.ui.tile_size / 10, ypos - app.ui.tile_size / 8,
|
||||
'$tidx', gx.TextCfg{
|
||||
'${tidx}', gx.TextCfg{
|
||||
...fmt
|
||||
size: fs2
|
||||
align: gx.HorizontalAlign.left
|
||||
|
Reference in New Issue
Block a user