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 / Using images stored on Android Device in a game

Author
Message
kozma_11
20
Years of Service
User Offline
Joined: 17th Sep 2003
Location: Scotland
Posted: 24th Apr 2015 20:50
I was wondering if someone could advise on the best way to do what I'm trying to do or whether it's possible.

I want my game to use customisable images from the user. For example, once the user has installed the game on their phone, they can then put a folder in the app sandbox called "user files" and the game will check the folder to see if the file exists in the folder, if not use the default image. I think it may be possible on Android, assuming the user can access the app sandbox, but I'm struggling to find it on my phone (Samsung Galaxy S4 mini). I can navigate to Android/data/com.myapp/files but there's nothing in it? Is this where the user should put images to use in the game? How about setting the app to look at the DCIM folder for example?

Any ideas would be appreciated. Also wondering how this might work on an iPhone since I think the user would struggle to create a folder in the app sandbox.

I'm using AGK2, Tier 1.

Thanks!

El Presidente
CJB
Valued Member
20
Years of Service
User Offline
Joined: 10th Feb 2004
Location: Essex, UK
Posted: 25th Apr 2015 00:12 Edited at: 25th Apr 2015 00:13
Hi Kozma_11,

You could use: ShowChooseImageScreen, IsChoosingImage, and GetChosenImage to allow the user to select an image from their photo gallery which you could then manipulate in your app however you like - including saving the updated image back to their photo gallery (using printimage) or in the app-data sandbox (using saveimage).

V2 T1 (Mostly)
Uzmadesign
kozma_11
20
Years of Service
User Offline
Joined: 17th Sep 2003
Location: Scotland
Posted: 25th Apr 2015 09:44
Hi CJB,

Thanks for the info. Tried what you suggested and works great

Any suggestions if the user wanted to select multiple images to use in the game? This method would need to do one image at a time. I'm thinking possible 500-1000 images to be used in the game?

Also, is there a way for the user to select a text file? I'd like the user to be able to load in their own text file that will sit outside the app-data sandbox?

Thanks!

John

El Presidente

Login to post a reply

Server time is: 2024-04-24 23:29:24
Your offset time is: 2024-04-24 23:29:24