Jump to content


lordtez

Member Since 13 Nov 2003
Offline Last Active Today, 10:36 AM

Topics I've Started

touch controls iphone5

19 January 2013 - 03:22 AM

Hi,

I am having some unexpected results with touch controls and the iphone 5.

I've been using the code below to control my ships movement in a space shooter i'm making. The code works perfectly on the iphone4 and ipad but not on the iphone 5.
If I'm moving left ie: device_mouse_x(device)<=120, and i press the fire button, the ship sometimes  stops moving. After some investigating, it turns out that a small portion in the bottom left corner of my iphone5 will register as a release event, even though my finger is still  down. Only happens on iphone 5. Any ideas on what may be causing this error. I even tried virtual keys -same result.

Cheers

// in step event of ship
for(device=0; device<2; device+=1){
if device_mouse_check_button_released(device, mb_left){if device_mouse_x(device)>=420 {rapid=true}}//fire button released

if device_mouse_check_button(device, mb_left){
if device_mouse_x(device)>=420 {if(rapid=true){ event_perform(ev_keypress,vk_space)};rapid=false;}// fire button area down
if device_mouse_x(device)>=170 and device_mouse_x(device)<420 {x+=5;}//right move area down
if device_mouse_x(device)<=120 {x-=5;}}//left move area down
}

Rs232 Dll Question

27 September 2009 - 02:04 PM

Hi all. I've tried using the rs232 dll  by andbna. I've created 2  virtual com ports com3 and com4 using a virtual serial emulator. The rs232example that comes with the gex works fine when receiving byte data, but always returns a single letter or number  when reading string data. Any ideas as to what may be causing this problem.
Thanks.