[Features] The position and state of touch panel where it was touched are returned.
The position and state of touch panel where it was touched are returned.
n=0 The number of the present touches. on=1 or more. off=0.
n=1 Movement of flick X. (No.1)
n=2 Movement of flick Y. (No.1)
n=3 Touch No.1 ID.
n=4 No.1 X coordinate.
n=5 No.1 Y coordinate.
Below, each 3 are increasing with the number of the multi-touch.
n=6 Touch No.2 ID.
n=7 No.2 X coordinate.
n=8 No.2 Y coordinate.
Normal single touch can be got with this.
Coordinate: x=touch(4) y=touch(5)
[Movement of flick] support only for No.1.
'n' correspondence table was changed from version275.
The table by the old version are as follows.
n: 0.X 1.Y 2.Number of touches 3.X-Movement 4.Y-Movement
Since each touch is assigned ID number, by getting 'touch(3+tn*3)',
please write the program which each touch is distinguished by those ID.
The correspondence between touch-ID and 'n',
when multiple on/off touching are repeated, it change at any time.
For example of using multi-touch, please refer to the included sample program.
[e.g.] Sample program.
2 points multiple touch that distinguish by left and right separation.(ID unused)
4 points more multiple touch that distinguish by touch-ID.
[Features] It will be in a waiting state until be inputted by a tap.
[Format] TAP [n]
If 'n' is specified, it will become the waiting for input for n seconds.
If omitted, waiting time will become infinite.
[e.g.] It wait for input for two minutes, and display a tapped coordinate.
10 tap 120
20 print touch(0);touch(1)
[Features] The input state of Hardware keyboard of a 'keycode' is read.
Return value. on:-1 off:0
[Features] To read the direction of the virtual pad.
n=0 Horizontal direction.
n=1 Vertical direction.
Virtual pad can be selected by menu[Softkey].
In Virtual pad, by command [ init"kb:n" ], change is possible [n=3 8way-input] [n=4 4way-input].
The sensitivity of a touch may differ depending on the model.
Bluetooth, NVIDIA-Shield, Xperia-Play, the controllers are supported. (c.f. item-Operation)
It corresponds also to the arrow key of a hardware keyboard.
x = stick(0)
[Features] To read the state of the button on the virtual pad.
n: Button number.
When pressed in the state of the first, '2' returns.
Once '2' is read, it will be set to '1',
and subsequent 'on-state' will return '1'.
And Bluetooth, NVIDIA-Shield, Xperia-Play, the controllers are supported. (c.f. item-Operation)
It corresponds also to the [X],[Z] key of a hardware keyboard.
bt = strig(0)
[Features] With input from the UI.dialog, and returns the input string.
The peculiar character of each country can be inputted.
Determined by the input and [OK].
Because when back button is pushed, dialog disappears,
it is necessary to push and cancel by back button once again then.
[Features] A selection number is returned by the item selection from UI dialog.
[Format] UI_SELECT("One-dimensional character array name","Message")
It have to declare 'One-dimensional character array' beforehand.
And it substitutes the item name in order from number '0'.
To specify the declared array name and the message,
and call then, List-style dialog will appear.
The list is displayed until it hits empty data.
Touch and select then the number will be returned.
When Cancel is pushed, -1 is returned.
100 dim item$(6)
160 print num,item$(num)
[Features] Arbitrary message sentence are displayed several seconds by UI(toast).
[Format] UI_MSG "message"
[Features] Arbitrary sentence are displayed by dialog.
[Format] UI_TEXT "String|TextFilename" [,TextColor] [,BackColor] [,FontSize]
When string is specified, directly display it,
when the end of the string is extension".txt", it is distinguished from a text file,
and the text file is loaded and displayed.
It can be display a long sentence by scrolling.
The text display is affected by encoding specified by [init"enc:"].
It can specify TextColor, BackColor and FontSize.