Adriano_ppaula
Member
Hello everybody!
I'm having trouble creating a virtual_key system with the keyboard keys on GMS2. I'm following the tutorials all and doing it the right way but it does not work on android.
CREATE
DRAW GUI
I'm having trouble creating a virtual_key system with the keyboard keys on GMS2. I'm following the tutorials all and doing it the right way but it does not work on android.
CREATE
Code:
var vx=camera_get_view_width(view_camera[0]);
var vy=camera_get_view_height(view_camera[0]);
display_set_gui_size(vx,vy);
Code:
if instance_exists(ob_bleft) { global.vb_left= virtual_key_add(30, 400, 70, 70, vk_left) }
if instance_exists(ob_bright) { global.vb_right= virtual_key_add(60, 400, 70, 70, vk_right) }
if instance_exists(ob_batack) { global.vb_atack= virtual_key_add(200, 400, 70, 70, ord("C")) }
if instance_exists(ob_bjump) { global.vb_jump= virtual_key_add(300, 400, 70, 70, ord("X")) }