Import Deck for Android...

All suggestions and feature requests to improve wagic.
Sub forums Card Coding & Parser ,Game Mode ,Deck Editor
kevlahnota
Posts: 619
Joined: Tue Feb 08, 2011 3:00 pm
Location: Philippines
Contact:

Import Deck for Android...

Post by kevlahnota »

I really don't know about java but I hope we can have an Import button for decks downloaded from deckstats...

Just playing around from SDLActivity.java and I hope I can understand it..

Image
Djardin
Posts: 129
Joined: Sat Sep 04, 2010 11:40 am

Re: Import Deck for Android...

Post by Djardin »

I think the best way would be to declare that Wagic can be used to open a specific file format matching the one of deckstats, if I remember correctly this can be done easily in Android, but also on iOS or Windows.
Then, we need to add in Wagic that if the app was started to open a specific file, then it saves it into the user directory.
When we have all that, we could actually use Google Drive or Microsoft OneDrive Android apps to simply load a new deck into a Wagic Android app...
Zethfox
Posts: 3029
Joined: Thu Jun 10, 2010 11:28 pm

Re: Import Deck for Android...

Post by Zethfox »

this is great and all but wagic currently cant even load external sd card images on android 4 or higher. baby steps?
kevlahnota
Posts: 619
Joined: Tue Feb 08, 2011 3:00 pm
Location: Philippines
Contact:

Re: Import Deck for Android...

Post by kevlahnota »

Zethfox wrote:this is great and all but wagic currently cant even load external sd card images on android 4 or higher. baby steps?
Can you try this if this works: https://mega.nz/#!9kRiWYpB!fHMdsLeOhCpl ... SOmp51_T6I

On my device (Android 5.0.2) it doesn't work but on my cousins phone with Android 4.2 it works...

edit: I think I've got it:

Image
Zethfox
Posts: 3029
Joined: Thu Jun 10, 2010 11:28 pm

Re: Import Deck for Android...

Post by Zethfox »

Didnt work for me.
kevlahnota
Posts: 619
Joined: Tue Feb 08, 2011 3:00 pm
Location: Philippines
Contact:

Re: Import Deck for Android...

Post by kevlahnota »

Zethfox wrote:Didnt work for me.
Here's my last attempt, please try:
https://mega.nz/#!htAn0KYa!MZxncZjrcBMV ... A626bawFlI

I forced the path if the mountpoints are null and the android version is kitkat and above...
Zethfox
Posts: 3029
Joined: Thu Jun 10, 2010 11:28 pm

Re: Import Deck for Android...

Post by Zethfox »

That was closer yes, it didnt work but atleast it mounted. Error not allowed to write to that card.
Did any of the info i posted on this bug help? It said used that function i pointed and aet the sd card as somearray [0] or something cause that will be the location we are allowed to save and read.
kevlahnota
Posts: 619
Joined: Tue Feb 08, 2011 3:00 pm
Location: Philippines
Contact:

Re: Import Deck for Android...

Post by kevlahnota »

Zethfox wrote:That was closer yes, it didnt work but atleast it mounted. Error not allowed to write to that card.
Did any of the info i posted on this bug help? It said used that function i pointed and aet the sd card as somearray [0] or something cause that will be the location we are allowed to save and read.
Yeah, I read somewhere that As of Android 4.4 KitKat, applications can no longer write * to the "secondary storage" of a device. Write operations using the java.io.File API will thus fail. There is a workaround I think using Media Content Provider, but I don't know how to implement it. Anyway my device is using Android 5.0.2 and It's has a read and write access to SDCard since I'm using a Custom Firmware.

Anyway Just an Update :)
Image

The bug above is the path points to the same location...
kevlahnota
Posts: 619
Joined: Tue Feb 08, 2011 3:00 pm
Location: Philippines
Contact:

Re: Import Deck for Android...

Post by kevlahnota »

Update: I think I'm close... :) Using Droid4x as my emulator for Android :)

Image
kevlahnota
Posts: 619
Joined: Tue Feb 08, 2011 3:00 pm
Location: Philippines
Contact:

Re: Import Deck for Android...

Post by kevlahnota »

Another update: parsed the same file .dec or .txt success. just find a way to count existing deck and name it, then save :) :mrgreen: :mrgreen:

Image
Locked