Building AT on Android

Discussions of the development process of the game.
User avatar
Zukero
Lead Developer
Posts: 1735
Joined: Thu Jul 21, 2011 9:56 am
android_version: 8.0

Re: Building AT on Android

Post by Zukero » Mon Jan 15, 2018 11:34 am

You should have some error log (logcat) somewhere in AIDE. Look for some messages tagged Fatal or Error, and potentially a stack trace (many lines beginning with com.gpl.rpg.andorstrail....).
When found, paste it here.
Lvl: 78, XP: 8622632, Gold: 271542, RoLS: 1, ElyR: -, RoL: -, ChaR: 1, GoLF: 1, ShaF: 1, SRoV: 1, VSH: 1, WMC: 1, GoW: 1
HP: 71, AC: 301%, AD: 38-47, AP: 3, ECC: 50%, CM: 3.75, BC: 101%, DR: 2

User avatar
Shadow Slayer
Posts: 56
Joined: Fri Jan 05, 2018 10:22 am
android_version: 4.4 - Kitkat
Location: Vacor's Hideout (Temporarily Retired)(Real Life Location, I WILL NOT TELL YOU:))

Re: Building AT on Android

Post by Shadow Slayer » Tue Jan 16, 2018 2:41 pm

Yeah, Unfortunately I can't paste it out or wright it down for one reason, I get up to 7116 errors, I did write down most of the errors that repeated for thousands of times, I tried building AT as an Android App, Mobile game and Java App. I have written what happened for each in sections to make it easier to see what happened...

1: Android App) When creating an android app I got No errors when turning on AIDE and my project, when I pressed the play button, when compiling the apt I got 3 errors upon 0% saying something about icon not being found in resource or something with @ at some point and some stuff written that I do not understand, (references to appt and resource) when the compiling went up to 10% or higher until stopping upon 1115 errors, but they all seemed similar, they said unknown entity or package "R", or Invalid package declaration, when I pressed the first error I was taken to some points of the code saying stuff like, <preset.skill>"R" or sometimes random Rs in the code, the second error was at the top of the code simply saying package com.gpl.rpg.AndorsTrail... The rest was mainactivity.java or other activites like heroinfo.java or any other activity I know of, this seemed alright because I moved the gpl folder into every single place possible in the project, I even created a folder called package com, and I tried starting a new project placing gpl in different places but no other copies in the project...

2: Mobile Game) I did the same things as in android app including the same resolutions but this time I wasn't getting the odd 3 errors at start of compiling but 7116 errors about unknown entities, packages and invalid package declarations...

3: Java Application) Strangely enough Everything worked (No errors on load and running of the app) but when I pressed the button to run it it still displayed hello world... But I suppose that's because AT is not a Java app.

And thank you for trying to help :D :D :D

Edit: Is it possible I have these errors because some of my items or conditions I created in ATCS don't have a category?(I read a post about someone having similar problems viewtopic.php?f=6&t=5649 (But that was after the game loaded so I don't think so,))
They called it the Shadow, and started creating a small cult around it, Only the smallest core of the cult actually knows that this power comes from the Kazaul-era dark arts...

User avatar
Zukero
Lead Developer
Posts: 1735
Joined: Thu Jul 21, 2011 9:56 am
android_version: 8.0

Re: Building AT on Android

Post by Zukero » Tue Jan 16, 2018 5:21 pm

Option 1 sounds like it is what you need to use.
You REALLY should try to run the game as it can be found on github first (master branch).
The "R" file is generated by the android toolkit to generate numeric IDs for all resources under the "res/" folder to reference them from Java code. For example, in the android java code, you would use something like:

Code: Select all

findResource(R.xml.home);
to access the home.tmx map file.

"aapt" is the android toolkit binary that generates the R.java file. It is (one of) the first step(s) in compiling an android app.
The "R" class is referenced many times in many places in the Java code, so if aapt fails to create it, the compiler will throw many similar errors about it missing.

I never managed to use one of the free Android app compilers because their aapt binary would fail to launch on Android 5+ (a new security requirement for binaries enforced in 5+). AIDE should have it done right though.

It is very likely that something you changed makes aapt fail.
It is also possible that there's something new in the recent versions of the android toolkit that choke on the existing code.
I have to look something up about new versions failing to compile because all contents of the res/xml/ directory must be XML files, with filenames ending in .xml, and our maps are XML files ending in .tmx, forcing me to move it all under res/raw/, and updating the res/values/loadresources*.xml files accordingly.
Lvl: 78, XP: 8622632, Gold: 271542, RoLS: 1, ElyR: -, RoL: -, ChaR: 1, GoLF: 1, ShaF: 1, SRoV: 1, VSH: 1, WMC: 1, GoW: 1
HP: 71, AC: 301%, AD: 38-47, AP: 3, ECC: 50%, CM: 3.75, BC: 101%, DR: 2

User avatar
rijackson741
Posts: 2173
Joined: Tue Aug 20, 2013 2:04 am
android_version: 9.0 - Pie
Location: Somewhere in Dhayavar

Re: Building AT on Android

Post by rijackson741 » Wed Jan 17, 2018 12:37 pm

Zukero wrote:
Tue Jan 16, 2018 5:21 pm
You REALLY should try to run the game as it can be found on github first (master branch).
I just want to emphasize that point. You are confounding two problems: getting AIDE to build AT correctly, and incorporating your content. Solve one first, then the other.

There's an AIDE community here: https://plus.google.com/communities/104 ... 900d6f6158 that may be able to help. If you point them to the github sources (minus your content) someone can probably give you instructions on what to do.
Level: 64, XP: 4734786, HP: 196, AC: 246%, AD: 49-59, AP: 3, ECC: 25%, CM: 3, BC: 127%, DR: 2
Gold: 232355 | RoLS: 1, RoL: 1, GoW: 1
HH: 1, CS: 2, IF: 4, Ev: 3, Re: 2, WP:DA: 1, WP:1S: 1, AP:L: 1, FS:DW: 2, S:DW: 1
SR

User avatar
Shadow Slayer
Posts: 56
Joined: Fri Jan 05, 2018 10:22 am
android_version: 4.4 - Kitkat
Location: Vacor's Hideout (Temporarily Retired)(Real Life Location, I WILL NOT TELL YOU:))

Re: Building AT on Android

Post by Shadow Slayer » Wed Jan 17, 2018 2:49 pm

Zukero wrote:
Tue Jan 16, 2018 5:21 pm
Option 1 sounds like it is what you need to use.
You REALLY should try to run the game as it can be found on github first (master branch).
So I should download AT from github or something, sorry but what do you mean by running the game, you mean playing AT???
They called it the Shadow, and started creating a small cult around it, Only the smallest core of the cult actually knows that this power comes from the Kazaul-era dark arts...

sdevaney
Site Admin
Posts: 1073
Joined: Fri Jan 28, 2011 10:17 pm
android_version: 9.0 - Pie
Contact:

Re: Building AT on Android

Post by sdevaney » Wed Jan 17, 2018 3:07 pm

Shadow Slayer wrote:
Wed Jan 17, 2018 2:49 pm
Zukero wrote:
Tue Jan 16, 2018 5:21 pm
Option 1 sounds like it is what you need to use.
You REALLY should try to run the game as it can be found on github first (master branch).
So I should download AT from github or something, sorry but what do you mean by running the game, you mean playing AT???
I believe what they mean is for you to try compiling from the github source using your phone method without your new content. We know the github source is good to compile an apk as it's been used in previous content testing. Then once you are able to do that, look into adding in your new content and compiling an apk with it included.

User avatar
Zukero
Lead Developer
Posts: 1735
Joined: Thu Jul 21, 2011 9:56 am
android_version: 8.0

Re: Building AT on Android

Post by Zukero » Wed Jan 17, 2018 4:15 pm

Exactly.
Lvl: 78, XP: 8622632, Gold: 271542, RoLS: 1, ElyR: -, RoL: -, ChaR: 1, GoLF: 1, ShaF: 1, SRoV: 1, VSH: 1, WMC: 1, GoW: 1
HP: 71, AC: 301%, AD: 38-47, AP: 3, ECC: 50%, CM: 3.75, BC: 101%, DR: 2

User avatar
Shadow Slayer
Posts: 56
Joined: Fri Jan 05, 2018 10:22 am
android_version: 4.4 - Kitkat
Location: Vacor's Hideout (Temporarily Retired)(Real Life Location, I WILL NOT TELL YOU:))

Re: Building AT on Android

Post by Shadow Slayer » Thu Jan 18, 2018 5:56 pm

Ok, so I finally did it, but...After creating AT, I added my ATCS content to the resaurces folder, json files into raw and maps into xml, I reinstalled AT with my content after recompiling apk, but nothing was there, I uninstalled the AT I created and deleted the apk and created a new one with my content included, I run it and still nothing there :o

Does somebody know whats wrong???
They called it the Shadow, and started creating a small cult around it, Only the smallest core of the cult actually knows that this power comes from the Kazaul-era dark arts...

User avatar
rijackson741
Posts: 2173
Joined: Tue Aug 20, 2013 2:04 am
android_version: 9.0 - Pie
Location: Somewhere in Dhayavar

Re: Building AT on Android

Post by rijackson741 » Thu Jan 18, 2018 6:12 pm

Did you get any errors when compiling?

Can you put the apk somewhere and PM me with a link to download it?
Level: 64, XP: 4734786, HP: 196, AC: 246%, AD: 49-59, AP: 3, ECC: 25%, CM: 3, BC: 127%, DR: 2
Gold: 232355 | RoLS: 1, RoL: 1, GoW: 1
HH: 1, CS: 2, IF: 4, Ev: 3, Re: 2, WP:DA: 1, WP:1S: 1, AP:L: 1, FS:DW: 2, S:DW: 1
SR

User avatar
Shadow Slayer
Posts: 56
Joined: Fri Jan 05, 2018 10:22 am
android_version: 4.4 - Kitkat
Location: Vacor's Hideout (Temporarily Retired)(Real Life Location, I WILL NOT TELL YOU:))

Re: Building AT on Android

Post by Shadow Slayer » Thu Jan 18, 2018 6:39 pm

rijackson741 wrote:
Thu Jan 18, 2018 6:12 pm
Did you get any errors when compiling?

Can you put the apk somewhere and PM me with a link to download it?
No errors and I dont know how to link a download from my phone and I dont think it would help, there are no errors when compiling, it is just as if aide is ignoring my content when compiling, I opened R.java file and saw all the files from the resaurce folder (public static final name_of_file=numbers) apart from my content.
They called it the Shadow, and started creating a small cult around it, Only the smallest core of the cult actually knows that this power comes from the Kazaul-era dark arts...

Post Reply