In the first program (Console), the character is displayed even if you keep your finger pressed on the key.
Code: Select all
If OpenConsole()
PrintN("Appuyez sur [Echap] pour quitter")
Repeat
KeyPressed$ = Inkey()
PrintN(KeyPressed$)
Delay(100)
Until KeyPressed$ = Chr(27)
EndIf
Code: Select all
If InitSprite() And InitKeyboard() And OpenScreen(800,600,32,"")
Repeat
FlipBuffers()
ClearScreen(RGB(100,100,100))
ExamineKeyboard()
resultat$ + KeyboardInkey()
If StartDrawing(ScreenOutput())
DrawingMode(1)
FrontColor(RGB(200, 200, 200))
DrawText(20, 20, resultat$)
StopDrawing()
EndIf
Until KeyboardPushed(#PB_Key_Escape)
EndIf
I would like, in the second case, that the character is displayed even if I keep my finger pressed on the key.
Is there a solution ?
thank you