10-06-2022, 12:25 AM
Some would have it that meditation is medication.
Code: (Select All)
_Title "3-6-9 Tesla Breathing Sit up straight relaxed alertness" ' B+ 2020-05-19
Screen _NewImage(600, 300, 32)
_Delay .25
_ScreenMove _Middle
'_FULLSCREEN
cText 300, 150, 32, &HFFFFFF00, "Prep: quick exhale"
_Delay 4
lim = 1
l = -1
l2 = 1
Do
Cls
If l <= 2 Then
cText 300, 150, 32, &HFFFF3633, "To 3, Quick Deep Inhale" + Str$(l + 1)
ElseIf l > 2 And l <= 8 Then
cText 300, 150, 32, &HFF006900, "To 6, H o l d . . ." + Str$(l - 2)
ElseIf l > 8 Then
cText 300, 150, 32, &HFF440066, "To 9, S l o w E x h a l e " + Str$(l - 8)
End If
_Display
_Limit lim
l = (l + 1) Mod 18
If l2 Mod 162 = 0 Then lim = lim - .02
l2 = l2 + 1
Loop
Sub cText (x, y, textHeight, K As _Unsigned Long, txt$)
Dim fg As _Unsigned Long, cur&, I&, mult, xlen
fg = _DefaultColor
'screen snapshot
cur& = _Dest
I& = _NewImage(8 * Len(txt$), 16, 32)
_Dest I&
Color K, _RGBA32(0, 0, 0, 0)
_PrintString (0, 0), txt$
mult = textHeight / 16
xlen = Len(txt$) * 8 * mult
_PutImage (x - .5 * xlen, y - .5 * textHeight)-Step(xlen, textHeight), I&, cur&
Color fg
_FreeImage I&
End Sub
b = b + ...