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 / why doesnt my \android app work?

Author
Message
novaapz
11
Years of Service
User Offline
Joined: 28th Jun 2012
Location: seat
Posted: 18th Aug 2012 14:44
ive made a few android apps and they awere all working nicely until i bought the samsung galaxy note where i downlaoded the apps and instead of images i got black and white boxes with a red cross over them... why is this? if its a fault how can it be fixed please
Digital Awakening
AGK Developer
21
Years of Service
User Offline
Joined: 27th Aug 2002
Location: Sweden
Posted: 18th Aug 2012 17:21
That's because AppGameKit can't find your images.

Cliff Mellangard 3DEGS
Developer
18
Years of Service
User Offline
Joined: 20th Feb 2006
Location: Sweden
Posted: 18th Aug 2012 17:47
First of all is it with the player or you are making an apk file that you install?

Android 2.3 Gingerbread , ZTE Skate , 480x800 , 800 mhz cpu , Samsung Galaxy Y , 240x320 , 832 mhz cpu
Android 4.0 Sandwich , Dmtech 3g 9738B , 1024x768 , 9.7 inches , cortex A8 1.2 cpu , 1 gb ram.
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 18th Aug 2012 19:01
and what version of Android? It would be good to know whether Ice Cream Sandwich works okay with AGK

Tone Dialer
Valued Member
18
Years of Service
User Offline
Joined: 17th Oct 2005
Location: England, well a town in it !
Posted: 18th Aug 2012 22:34
@ novaapz

Make sure you use only lower case directory and file names (with no spaces), image file names are case sensitive.

Digital Awakening
AGK Developer
21
Years of Service
User Offline
Joined: 27th Aug 2002
Location: Sweden
Posted: 19th Aug 2012 09:20
Quote: " Make sure you use only lower case directory and file names (with no spaces), image file names are case sensitive."

That would have been a good suggestion, had he not used Android before.

Cliff Mellangard 3DEGS
Developer
18
Years of Service
User Offline
Joined: 20th Feb 2006
Location: Sweden
Posted: 19th Aug 2012 11:27
Quote: "and what version of Android? It would be good to know whether Ice Cream Sandwich works okay with AGK"

It works on sandwich! But only at half the speed compared to the older versions of android.

They made a change in sandwich that agk dont seam to like?
I belive it have to be the gpu accelerated 2d function that is a standard since 3.0 i belive?

It also make your apps double the memory usage.

Android 2.3 Gingerbread , ZTE Skate , 480x800 , 800 mhz cpu , Samsung Galaxy Y , 240x320 , 832 mhz cpu
Android 4.0 Sandwich , Dmtech 3g 9738B , 1024x768 , 9.7 inches , cortex A8 1.2 cpu , 1 gb ram.
Mobiius
Valued Member
21
Years of Service
User Offline
Joined: 27th Feb 2003
Location: The Cold North
Posted: 19th Aug 2012 16:12
GPU acceleration actually slows AppGameKit apps down. Dunno why, but it does.

I live for video games! (And beers, and football, and cars!)
See what I live for here: [url]http:\\www.TeamDefiant.co.uk[/url]
novaapz
11
Years of Service
User Offline
Joined: 28th Jun 2012
Location: seat
Posted: 21st Aug 2012 22:06
all images were space less and in lower case. its an apk file and i dont know the current software type it runs on because my wife seems to think it is hers and i cant seem to get it to look.

should i just recompile the apk file and see if it builds properly?
Mobiius
Valued Member
21
Years of Service
User Offline
Joined: 27th Feb 2003
Location: The Cold North
Posted: 22nd Aug 2012 18:25
Does your game work in windows? If it does, then you've probably placed your media in the wrong locations.

In Windows, my folder structure is like this:

In Android, the folder structure is:


I live for video games! (And beers, and football, and cars!)
See what I live for here: [url]http:\\www.TeamDefiant.co.uk[/url]
Ancient Lady
Valued Member
20
Years of Service
User Offline
Joined: 17th Mar 2004
Location: Anchorage, Alaska, USA
Posted: 22nd Aug 2012 19:18
@Mobiius, first, for Android the path is '<projdir>/assets/media', not just 'assets'. The byte code file goes in the '<projdir>/assets/media' directory. All AppGameKit platforms since v107 assume that the default directory is named 'media'.

Also the media assets (images, sounds, text files) can go in the same directory as the byte code file.

In fact, unless you specify a subdirectory, the 'media' directory is the default location.

Cheers,
Ancient Lady
AGK Community Tester
The Zoq2
14
Years of Service
User Offline
Joined: 4th Nov 2009
Location: Linköping, Sweden
Posted: 22nd Aug 2012 22:03
My apps work fine on my galaxy note with ICS...
Mobiius
Valued Member
21
Years of Service
User Offline
Joined: 27th Feb 2003
Location: The Cold North
Posted: 23rd Aug 2012 18:10
@Ancient Lady, Guess I need to update my android templates! lol I haven't built an android app for many months! lol

I live for video games! (And beers, and football, and cars!)
See what I live for here: [url]http:\\www.TeamDefiant.co.uk[/url]
Ancient Lady
Valued Member
20
Years of Service
User Offline
Joined: 17th Mar 2004
Location: Anchorage, Alaska, USA
Posted: 23rd Aug 2012 18:16
@Mobius, be careful about the android Tier2 template. Make sure to download the Android_1076_Tier2_Template from the 'Your Products' download page on TGC.

Paul did everyone a great favor and provided one that compiles, links and actually runs on an Android device.

As for your Tier1 ones, just add a media directory under assets and move everything there.

I've posted this elsewhere, but have updated it to NOT copy over the template_android directory.....

These are commands I execute every time I update/change my AppGameKit version. I have my Windows AppGameKit installed in C:\TGC\AGK (I never use the Program Files directories if given the choice, I hate spaces in paths/file names). And I used simply 'android-ndk' for the Android NDK path (I used the most recent version). And I just created from IDE down in the android set, since I didn't need anything else in the AppGameKit tree.

A good command to use before anything else, to make sure directory/file permissions are set well:


To update the core AppGameKit stuff:


To update my own projects after updating core AppGameKit (this is important to make sure that your project uses any new stuff):


After doing the above to make sure the permissions are correct and that Eclipse will be able to run the app on the Android device:


Now, just so you have a working player, build the player:


Edit /cygdrive/c/Android/IDE/apps/interpreter/interpreter.cpp to uncomment the correct line so that your app will run instead of the player. In v1075 and v1076 it is at line #255:


Copy from your AppGameKit Tier1 directory, clean and compile your app:


Good luck!

Cheers,
Ancient Lady
AGK Community Tester

Login to post a reply

Server time is: 2024-05-02 07:55:41
Your offset time is: 2024-05-02 07:55:41