Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / GetDirectionX() and GetDirectionY()

Author
Message
polomint
12
Years of Service
User Offline
Joined: 3rd Apr 2012
Location: Lancashire, United Kingdom
Posted: 13th May 2012 14:19 Edited at: 13th May 2012 14:24
Ok, I wrote a quick test app in Tier1 to test left and right tilt on the PB.

Now, when I broadcast to the AGKPlayer on the PB, GetDirectionX() allows left and right tilting, yet if I convert to Tier2 I have to change it to GetDirectionY() to be able to tilt left and right. It's like GetDirectionX() and GetDirectionY() functions are reversed.
Has anyone come across this before?
I have SetOrientation(1,1,0,0) and g_bLandscape = true;

Tier 1 code:


Tier 2 code:


Both sets of code above have exactly the same effect...

I may have done something wrong, but I can't see what,

Blackberry App Development & ZX Spectrum Game Development.
bjadams
AGK Backer
16
Years of Service
User Offline
Joined: 29th Mar 2008
Location:
Posted: 13th May 2012 14:52
report it here

http://code.google.com/p/agk/issues/list

keep in mind that PB support is kind of a preview and not 100% official yet
polomint
12
Years of Service
User Offline
Joined: 3rd Apr 2012
Location: Lancashire, United Kingdom
Posted: 13th May 2012 16:14
Ok, will do.

Blackberry App Development & ZX Spectrum Game Development.
DVader
20
Years of Service
User Offline
Joined: 28th Jan 2004
Location:
Posted: 13th May 2012 23:27
I think it is because AppGameKit runs in portrait and fakes the landscape mode. I have had issues getting my android to register getdirectiony() when I lock it to landscape for instance. I have changed tack and used getdirectionangle() with more luck

polomint
12
Years of Service
User Offline
Joined: 3rd Apr 2012
Location: Lancashire, United Kingdom
Posted: 14th May 2012 09:06
@DVader: Yeah, I think I'll alter it to use GetDirectionAngle() once I get home,

Blackberry App Development & ZX Spectrum Game Development.

Login to post a reply

Server time is: 2024-05-04 07:21:40
Your offset time is: 2024-05-04 07:21:40