'LUA psvita TOUCH boton

I'm learning Lua, but I don't understand how to create a button? http://onelua.x10.mx/vita/docs/es/group__touch.html my reference

    if touch.front.count(1).x(100).y(100).pressed then  screen.print(400,400,"ok",1,color.white,color.green)end

did not get a button in exact coordinates

the whole screen works with a single button with this code

if touch.back[1].held if touch.fron[1].held



Solution 1:[1]

It should look something like this:

if touch.front.count(1).x(100).y(100).pressed then

    screen.print(400,400,"ok",1,color.white,color.green)
    
end

If that isn't the solution then you gave the wrong variable to touch or screen.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 pppery