[GUIDE][INFO]Concurrency and Threads - Java for Android App Development

Mod Edit: You can find this guide in it's entirety here:
http://docs.oracle.com/javase/tutorial/essential/concurrency/index.html
There is no need to copy/paste the entire thing.

sak-venom1997 said:
thank you !
but is there someone really in need of this ?
Sent from my GT-S5302 using Tapatalk 2
Click to expand...
Click to collapse
Very nice guide.
Judging by the amount of laggy apps that block the UI thread, I'd say a lot of people are in need of this

All info is COPIED almost word for word from Oricle (Java) website.
http://docs.oracle.com/javase/tutorial/essential/concurrency/sleep.html
from above:
Thread.sleep causes the current thread to suspend execution for a specified period. This is an efficient means of making processor time available to the other threads of an application or other applications that might be running on a computer system. The sleep method can also be used for pacing, as shown in the example that follows, and waiting for another thread with duties that are understood to have time requirements, as with the example below.
Two overloaded versions of sleep are provided: one that specifies the sleep time to the millisecond and one that specifies the sleep time to the nanosecond. However, these sleep times are not guaranteed to be precise, because they are limited by the facilities provided by the underlying OS. Also, the sleep period can be terminated by interrupts. In any case, you cannot assume that invoking sleep will suspend the thread for precisely the time period specified.
Click to expand...
Click to collapse
from Java site:
Thread.sleep causes the current thread to suspend execution for a specified period. This is an efficient means of making processor time available to the other threads of an application or other applications that might be running on a computer system. The sleep method can also be used for pacing, as shown in the example that follows, and waiting for another thread with duties that are understood to have time requirements, as with the SimpleThreads example in a later section.
Two overloaded versions of sleep are provided: one that specifies the sleep time to the millisecond and one that specifies the sleep time to the nanosecond. However, these sleep times are not guaranteed to be precise, because they are limited by the facilities provided by the underlying OS. Also, the sleep period can be terminated by interrupts, as we'll see in a later section. In any case, you cannot assume that invoking sleep will suspend the thread for precisely the time period specified.
Click to expand...
Click to collapse

sak-venom1997 said:
thank you !
but is there someone really in need of this ?
Sent from my GT-S5302 using Tapatalk 2
Click to expand...
Click to collapse
I am in the second quarter of an applications developer program and I will be taking a class on android programming next year. This is very interesting and at the point that I am at in my C# studies this makes some sense even though I don't know a lick of java yet. These are the most valuable stories on XDA in my opinion, it is not a walk through, it is actual factual information on a specific subject from the standpoint of an android developer. It is write ups like this that may not be wow topics, but in the end serve very useful in a forum that is dominated by overly simplistic topics. Keep it up

sak-venom1997 said:
Mod Edit: You can find this guide in it's entirety here:
http://docs.oracle.com/javase/tutorial/essential/concurrency/index.html
There is no need to copy/paste the entire thing.
Click to expand...
Click to collapse
:good: Thread closed.

Related

[REF] ICS User Experience Graphs (sentiment analysis)

I've decided to pull this project as it doesn't seem useful, or accurate! Feel free to pm if you have any ideas for me.
Where did the other benchmarks go?
All ICS ROM Benchmarks: this thread
Battery Drain Benchmarks: this thread
Kernel Features and Benchmarks: this thread
CPU Governors and I/O Schedulers: this thread
Power Saving Governors: this thread
Does SuperCharging work?: this thread
Methodology
I wrote a program in C++ with several routines:
1) copy all the thread's html all into one file
2) throw away all the html code
3) throw away anything from a quote
4) throw away any one letter words
5) throw away all punctuation except apostrophes/exclamation marks/question marks/periods/full-stops (also add a full-stop if it was missing at the end of a post)
Then the entire thread is uploaded in chunks of 400 words to an API http://www.alchemyapi.com/api/sentiment/
This returns a sentiment score for each 400 word chunk. It can be either positive or negative. Since most users are polite when they have a criticism, the scores tend to range from slightly negative to very positive.
[Q] What is 'sentiment analysis'?
[A] Find out more here: http://en.wikipedia.org/wiki/Sentiment_analysis
- - - quote "Computers can perform automated sentiment analysis of digital texts, using elements from machine learning such as latent semantic analysis, support vector machines, "bag of words" and Semantic Orientation — Pointwise Mutual Information..." sourced from the above link.
Each 400 word block gets a score usually ranging somewhere between slightly negative and very positive. Each score forms the basis of my raw data.
I currently show this data as several graphs, but I may strip away some. The most useful graph (remember, my background is mathematics education...) is a combination of the entire thread's average score plus the average for the most recent 10%. This helps to highlight threads that have a history of good sentiment as well as continuing good sentiment.
Notes
Initial attempt (for posterity): http://forum.xda-developers.com/showpost.php?p=24451874&postcount=712
I couldn't have done this without the support of a few people in particular: tchaari (who first informed me of this marvellous field of sentiment analysis); harbb for joking around with me (which got me thinking about doing it for real); and glennkaonang for feedback and moral support. Special thanks to original21 who inspired me to provide the most recent data separately.
Thanks to the XDA community in general, the developers, and a special shout out to others who have been supportive in my previous works: CyberGR, simms22, morfic, krarvind, wildestpixel, kong, Oodie, steve.garon, brainmaster, mathkid95, DaXmax, AndroidUser00110001, hope I didn't I forget anyone
Thanks to anyone past, present and future who has any constructive criticism, or just hits my thanks button! It keeps me going! Thanks to the moderators for keeping me in check... and to google/samsung for the toys
another bedalus special treat in store
I have been thinking, you should actually join the Recognized Contributor as you contributed alot...
Sent from my Nexus S using Tapatalk 2 Beta-5
DaXmax said:
I have been thinking, you should actually join the Recognized Contributor as you contributed alot...
Sent from my Nexus S using Tapatalk 2 Beta-5
Click to expand...
Click to collapse
+1
Nice to see that bedalus benchmarks are back
Very interesting work bedalus. The results in the spreadsheet are not always significant but it's a very good start that deserves many encouragements. I am thinking about if taking two words before and two words after each term can improve the readability of the results...
I have also another UX idea: coding some program that can evaluate (approximately) if a post is a positive feedback, negative feedback, a simple question or a simple answer. Then, a final average score is computed.
DaXmax said:
I have been thinking, you should actually join the Recognized Contributor as you contributed alot...
Click to expand...
Click to collapse
Thanks! I think I'm the most pleased with this one because it made me learn C++. I'm just wrapping my head around custom structs.
I've applied for the RC status. Don't know what the criteria are particularly, but I think I've produced some useful stuff. If I get it, I might order an XDA t-shirt, then my wife will be really concerned...
tchaari said:
+1
Nice to see that bedalus benchmarks are back
Very interesting work bedalus. The results in the spreadsheet are not always significant but it's a very good start that deserves many encouragements. I am thinking about if taking two words before and two words after each term can improve the readability of the results...
Click to expand...
Click to collapse
I'm one step ahead of you this time tchaari, the code for two words before and after is halfway there...
tchaari said:
I have also another UX idea: coding some program that can evaluate (approximately) if a post is a positive feedback, negative feedback, a simple question or a simple answer. Then, a final average score is computed.
Click to expand...
Click to collapse
Isn't that what your brain is for?
EDIT: I'm just adding the link you PM'd me so I can find it more easily: http://stackoverflow.com/questions/...-how-positive-or-negative-a-statement-text-is
UPDATE: Found the bug in my program that caused it to crash if there was only one page (with 50 posts per page) i.e. any young thread with less than 51 posts would fit on one page, and my program will only download the total number of pages -1 (it saves the last page for a new start page for when I update a thread). Fixed... now trying to get all the other threads.
bedalus said:
I'm one step ahead of you this time tchaari, the code for two words before and after is halfway there...
Click to expand...
Click to collapse
Not really surprised. You are the top benchmark specialist here
bedalus said:
Isn't that what your brain is for
Click to expand...
Click to collapse
Lol, that's true but we will all feel better if the machine can handle a little more computing and analysis from what our brains are cooking every day
You should really take a look on what's going on in the "natural language processing (NLP)" domain. If your program can be connected to some existing tools like [1] and [2], the results can be so interesting
[1] http://khassanali-nlp-research.blogspot.com/2008/01/nltk.html
[2] http://kmandcomputing.blogspot.com/2008/06/opinion-mining-with-rapidminer-quick.html
These are other refs on sentiment analysis and opinion mining from the NLP domain if someone is interested:
- http://en.wikipedia.org/wiki/Sentiment_analysis
- http://eprints.qut.edu.au/29301/1/c29301.pdf
Bedalus, you made us addicted to your benchmarks. If you close one more of your thread, I'll go on a hunger strike with Oodie
Wow ! This looks Promising
Let's see wht this gives us & yeah ! It was boring in NS forums without you . lol .
Welcome back sir
Sent from my Nexus S using XDA
Good to be back? At least I'm happy you are back!
Greetzz, jojoost.
Sent from my Nexus S using Tapatalk 2
Thanks for the kind words everyone! It's nice to be working on a thread again.
I got my program more stable. I found a more up to date version of wget for windows here by a guy called Oliver Krystal. It had the drivers built in.
I've removed the my program in the second post until I can locate the source of the instability. Last night I ran it and it managed to download most of the ROM threads, but crashed halfway through a long thread.
I'm going to tidy up the code and try and break it up into more manageable routines (most of the work is done in one long procedure at the moment, not very good practice... ) Then perhaps it'll be easier to debug.
When it's more stable I'll re-upload it.
@tchaari, maybe I do need to include some scoring algorithm, otherwise it's not really a benchmark is it! haha
Glad to see you back, bedalus.
This time you bring more headache to us having no experience at all in information technology with your testing methodology
Regarding improvements it needed, I think it's good enough already.
But the idea of that algorithm thing would make it more interesting, although it would bring more headache to me I guess
Sent from my Nexus S using xda premium
I changed a couple of things in the build, now it runs without crashing, so I re-uploaded the program to the second post (along with the spreadsheet).
The included 0threads.txt file currently includes all the 4.0.4 ROMs that were on my ROMs spreadsheet (didn't bother with 4.0.3s).
Any new ROMs I don't know about?
Does anyone want me to stick in any kernel threads? Theme threads? Threads from other phones?
STILL TO DO:
-Modify the program to update by starting to downloading threads at the point I last read
-See if I can implement a five word phrase
-See if I can find or create any language analysis program to score the phrases
bedalus said:
Thanks! I think I'm the most pleased with this one because it made me learn C++. I'm just wrapping my head around custom structs.
I've applied for the RC status. Don't know what the criteria are particularly, but I think I've produced some useful stuff. If I get it, I might order an XDA t-shirt, then my wife will be really concerned...
Click to expand...
Click to collapse
Lol. You contributed alot for the Nexus S development. Im sure the Senior Mod, will nominate you, if not, i will do it....
DaXmax said:
Lol. You contributed alot for the Nexus S development. Im sure the Senior Mod, will nominate you, if not, i will do it....
Click to expand...
Click to collapse
Cool! Thanks!
UPDATE: All 4.0.4 ROMs (that I currently know of) now in the spreadsheet. Just working on the index.
Another quality thread in the making I think!
Good to see you back I was getting worried when all your threads were closing.

XDATV Noter

Introduction
Hey guys. I'm working on an Android application for XDATV. We've never really featured a fully functional application on XDATV before. I thought it was high time we did that.
Noter is a note taking application. It is a good representation of several basic Anrdoid APIs.
source & download
Subversion Repository: http://xda-adk.googlecode.com
Project Checkout: svn checkout http://xda-adk.googlecode.com/svn/trunk/EclipseProjects/xdatv-noter
Image of app: http://i50.tinypic.com/qs8ro8.png
App download: https://code.google.com/p/xda-adk/downloads/detail?name=XDATVNoter.apk
goals
Demonstrate proper coding style and development.
Introduce n00bs to app development.
Make an expandable single-class app which will have the ability to integrate into future projects.
Questions and Contributions
If you have a question, please ask. I am in no way, shape, or form an Android app development expert. I do java more than anything else, not so much with Android. If you've got something to contribute, please do! If you spot a problem in the code, then let me know and I'll give you credit on the SVN Commit.
I think this is an awesome idea. Many of the developers here don't know the Android framework but have worked with lots of C based languages, so picking up Java (if we need to) is not that big a deal. Hopefully this will be the kind of thing that we can follow and learn the OS and framework as we go along. I know it's ideal for me, being a 20 years Windows developer.
Archer said:
I think this is an awesome idea. Many of the developers here don't know the Android framework but have worked with lots of C based languages, so picking up Java (if we need to) is not that big a deal. Hopefully this will be the kind of thing that we can follow and learn the OS and framework as we go along. I know it's ideal for me, being a 20 years Windows developer.
Click to expand...
Click to collapse
Yeah! That's the idea. Once the video is released I will publish it in the OP as well. I hope its understandable. If not, that's why we have this thread available.
The onclick view thing is handy:good:
hi adam! In the title of the video you mentioned testing, which i missed a little in the video. what methods or tools do you use for unit testing and stuff?
I'm sorry to clog up this thread with a post about help, but I couldn't find a thread for the series for tutorials Adam released about a year ago.
At around 8:34 in part one (http://www.youtube.com/watch?list=P...=31cxmLN09ss&feature=player_detailpage#t=513s), Adam adds a button to his test-app thing. It will not let me do this. It shows a no symbol over my cursor when I drag it over the display. I selected the .xml through res and layout just like he did. Only different thing I can tell I am doing is using 4.0 API instead of 2.3.
I have no experience with coding or doing work with Android so I apologize for any common mistakes.
klownk said:
hi adam! In the title of the video you mentioned testing, which i missed a little in the video. what methods or tools do you use for unit testing and stuff?
Click to expand...
Click to collapse
Just the standard tools. A device and a device emulator.
hi der!
is their any file named "notes.txt" is created.? if yes where can i find it?
and yeah thank you!.. am just a beginner and this helped me a lot!
Edit :
i also added "WRITE_EXTERNAL_STORAGE" permission in android manifest!
but still cant find noter.txt file anywhere as mentions in MainActivity.java file!
please help!
1031Vulcan said:
I'm sorry to clog up this thread with a post about help, but I couldn't find a thread for the series for tutorials Adam released about a year ago.
At around 8:34 in part one (http://www.youtube.com/watch?list=P...=31cxmLN09ss&feature=player_detailpage#t=513s), Adam adds a button to his test-app thing. It will not let me do this. It shows a no symbol over my cursor when I drag it over the display. I selected the .xml through res and layout just like he did. Only different thing I can tell I am doing is using 4.0 API instead of 2.3.
I have no experience with coding or doing work with Android so I apologize for any common mistakes.
Click to expand...
Click to collapse
You have to drag it from the bar on the left. There are a set of controls over there which you can select and drag/drop.
ateeq72 said:
hi der!
is their any file named "notes.txt" is created.? if yes where can i find it?
and yeah thank you!.. am just a beginner and this helped me a lot!
Edit :
i also added "WRITE_EXTERNAL_STORAGE" permission in android manifest!
but still cant find noter.txt file anywhere as mentions in MainActivity.java file!
please help!
Click to expand...
Click to collapse
Its in /data/data/tv.xda.noter/files/notes.txt You need to be "Noter" or root to access this file.
Nice video, thanks!
Don't forget to close your output stream; probably more dangerous than forgetting to close an input stream if anything's buffered. Also it's maybe stylistic, but I much prefer Reader/Writer for textual data. If you like System.out style, you can do:
PrintWriter out = new PrintWriter(new OutputStreamWriter(openFileOutput(FILENAME, Context.MODE_APPEND)));
Really great job Adam. I'm going to watch a second time tint and build the app along with the video, you have some points that are helpful that I hadn't thought of before.
Edit:
Adam, I just watched and built along with the video. What action did you do at 15:24, I can see you did something called Refactor, but I'm not familiar with it. Can you explain what it does and why you did it? Thank you!!!
Sent from my Nexus 7 using xda premium
marty331 said:
Really great job Adam. I'm going to watch a second time tint and build the app along with the video, you have some points that are helpful that I hadn't thought of before.
Edit:
Adam, I just watched and built along with the video. What action did you do at 15:24, I can see you did something called Refactor, but I'm not familiar with it. Can you explain what it does and why you did it? Thank you!!!
Sent from my Nexus 7 using xda premium
Click to expand...
Click to collapse
I just moved some code into methods and changed some names. Refactoring means renaming or moving or a number of other operations. Basically, you clean things up with a refactoring. Refactoring is an operation the IDE does safely so when methods or variables move, all the calls point at the newly refactored method or variable.
AdamOutler said:
I just moved some code into methods and changed some names. Refactoring means renaming or moving or a number of other operations. Basically, you clean things up with a refactoring. Refactoring is an operation the IDE does safely so when methods or variables move, all the calls point at the newly refactored method or variable.
Click to expand...
Click to collapse
Awesome, great to know. I'll try using this in the future!
Sweet tutorial! Will be using this as starting point for the app I want to develop. Quick issue though. When I first implement the OnClickListener, it has an error with 56 fixes available, the top two being imports. Which one of these do I pick? I see you chose something from a dropdown, but the video sped up and I can't see which one it was.
A random package said:
Sweet tutorial! Will be using this as starting point for the app I want to develop. Quick issue though. When I first implement the OnClickListener, it has an error with 56 fixes available, the top two being imports. Which one of these do I pick? I see you chose something from a dropdown, but the video sped up and I can't see which one it was.
Click to expand...
Click to collapse
There are 2 common OnClickListener classes like you say, one of them is probably View.OnClickListener and the other DialogInterface.OnClickListener. Use the View.OnClickListener any time that you are attaching it to a widget in your normal layout. Use the DialogInterface.OnClickListnener any time you have created an AlertDialog and are listening to one of its buttons.
Sweet, thank you! :good:
File Location
Hey Adam
In the video you haven't mentioned how to choose the file location.
Please guide me on this.
Thanks
pawan.dewani said:
Hey Adam
In the video you haven't mentioned how to choose the file location.
Please guide me on this.
Thanks
Click to expand...
Click to collapse
that's done in the fileinputstream portion. new FileInputStream("filename"), or you can do new FileInputStream(new File("filename", "/path/tofile"));

Dear devs: What are your thoughts on security while developing?

Hello! I'm doing my bachelor thesis on Android security issues and I'd love to hear what you guys think about it, mainly on how you work with security issues when you develop your apps!
I threw together a quick 10 question multiple answer google docs form, should take 2-3 min max to fill out and it would really help me and hopefully lead to something that will benefit the android dev community when it's finished!
It's totally anonymous and requires no registration and i don't need any contact info to you :fingers-crossed:
LINK: https://docs.google.com/forms/d/1fvs166K4C9lcv7bHeNnOLfeaHK3LQNmc1qGffWWYjO4/viewform
(While i'm aware that this is technically a question I felt it goes under discussion rather than being a simple Q&A post, so that's why i posted here instead of the Q&A forum, hope you agree!)
Hi!
I read your questions but I don't think it's as easy as that.
The time spent on security varies very much with the kind the of app. For example, you don't need to spend much time on security if there's no network interaction and no sensitive data which needs to be stored.
So I would have entered that I spend no time on security. That, however, doesn't mean that I wouldn't spend time on security if an app would require that.
Do you get my point?
QuestionAsker said:
Hello! I'm doing my bachelor thesis on Android security issues and I'd love to hear what you guys think about it, mainly on how you work with security issues when you develop your apps!
I threw together a quick 10 question multiple answer google docs form, should take 2-3 min max to fill out and it would really help me and hopefully lead to something that will benefit the android dev community when it's finished!
It's totally anonymous and requires no registration and i don't need any contact info to you :fingers-crossed:
LINK: https://docs.google.com/forms/d/1fvs166K4C9lcv7bHeNnOLfeaHK3LQNmc1qGffWWYjO4/viewform
(While i'm aware that this is technically a question I felt it goes under discussion rather than being a simple Q&A post, so that's why i posted here instead of the Q&A forum, hope you agree!)
Click to expand...
Click to collapse
I completed it but I think there are maybe 2 quite different questions here...
1) Security from a user's perspective (i.e. their personal data)
2) Security from a developer's perspective (i.e. their IP / product)
I guess they overlap a bit but as a developer you need to consider both separately.
PicomatStudios said:
I completed it but I think there are maybe 2 quite different questions here...
1) Security from a user's perspective (i.e. their personal data)
2) Security from a developer's perspective (i.e. their IP / product)
I guess they overlap a bit but as a developer you need to consider both separately.
Click to expand...
Click to collapse
Thanks for the input, i was hoping to discuss the relationship between the user and the developer by examining how the developer handles the users data and to what extent the user can take control over the data s/he has inputted if for some reason s/he would like to make sure that the data never will end up somewhere it shouldn't. Because this data can be obtained in different ways, the survey has questions that could be perceived to relate to different questions perhaps? I should probably have written about the end goal more in detail
Anyways, thanks for participating!
QuestionAsker said:
Thanks for the input, i was hoping to discuss the relationship between the user and the developer by examining how the developer handles the users data and to what extent the user can take control over the data s/he has inputted if for some reason s/he would like to make sure that the data never will end up somewhere it shouldn't. Because this data can be obtained in different ways, the survey has questions that could be perceived to relate to different questions perhaps? I should probably have written about the end goal more in detail
Anyways, thanks for participating!
Click to expand...
Click to collapse
OK, I see.
I work on a Keyboard app.
There's an interesting phenomenon you might be interested in regarding 3rd party keyboards... almost all of them require internet permission.
When we started out we figured that nobody would download a keyboard with internet permission, as that's all you need for a keylogger.. we were wrong about that though ! In the end, the usability issues with having to download multiple language pack apps troubled more people than the potential security issues in downloading an internet-aware keyboard.
There's another one, which is that our app (and others) is quite heavily pirated and distributed on blogs etc (we know that, because we can measure how many apps are downloaded vs the number of language installations there have been). That's despite the fact that an unofficial copy could very easily be a keylogger - it still doesn't put people off !
PicomatStudios said:
OK, I see.
I work on a Keyboard app.
There's an interesting phenomenon you might be interested in regarding 3rd party keyboards... almost all of them require internet permission.
When we started out we figured that nobody would download a keyboard with internet permission, as that's all you need for a keylogger.. we were wrong about that though ! In the end, the usability issues with having to download multiple language pack apps troubled more people than the potential security issues in downloading an internet-aware keyboard.
There's another one, which is that our app (and others) is quite heavily pirated and distributed on blogs etc (we know that, because we can measure how many apps are downloaded vs the number of language installations there have been). That's despite the fact that an unofficial copy could very easily be a keylogger - it still doesn't put people off !
Click to expand...
Click to collapse
Hehe that's indeed pretty interesting. I know lots of people who don't even bother reading the permissions of apps, even knowing that Play is full of malicious content.

[APP][DEV][WIP] DemiGod RPG for android

Hello everyone,
This is my first thread on XDA, and also my first time using github. I have been learning java for android for ~3 years now, and feel there is still much to learn. As an all-time gamer, I would absolutely love to make one of my own.
I have recently started my 1st open-source project on github. I am still learning quite a bit, and am looking to create a retro-style, turn-based RPG for android. Any collaberators feel free to chime in, offer advice, bring new ideas to the table, etc...
This project is just beginning and the downloads may not be fully functional as of yet. Downloads serve mainly for testing purposes for now, but feel free to check it out. Please let me know what you think.
WORKING SO FAR:
* Stats and Inventory Databases
* Character creation (Choose name and class)
* Simple Battle mechanics
* Enemy Database
* Random enemy from database used in battles
* Level-ups
* Status Screen
* Viewing pre-populated Inventory (No using/exchanging items yet)
KNOWN ISSUES:
* Re-positioning Virual D-Pad when it's size is bigger than screen causes a force close
* D-Pad position gets skewed when re-sizing caused by it not accommodating for D-Pad Position setting
* Map's/Area's bounds are not set (Graphics still being worked on)
Storyline:
Unknowingly, you are a demigod. Half mortal, half god. Ever since your early teenage years, you have had "incidents" in which you never quite understood the nature of. Sudden outrages, blackouts, and waking up feeling completely exhausted.
The more the hero aged, the more frequent the uncontrollable events would occur. Finally the hero can't help but to believe it is some sort of witchcraft, cursed as a child. For this may not be completely false, the hero is soon to find out his true origins...
Github link: https://github.com/MattMatt0240/DemiGod
* Licensed under GNU GPL v3
Credits:
@nikwen (introducing the idea of open-source to me/ help in development threads)
@ADDICT.ANK (collaborator, helping hand)
@sak-venom1997 (collaborator, helping hand)
Please let me know if you're left out
FAQs/downloads/screenshots
Download:
* Alpha v0.02 (Preview/Testing)
* Alpha v0.01 (Preview/Testing)
MattMatt0240 said:
Credits:
@nikwen (introducing the idea of open-source to me/ help in development threads)
@ADDICT.ANK (collaberator, helping hand)
Please let me know if you're left out
Click to expand...
Click to collapse
Well great. Thanx bro you created the thread required
and pls reserve a couple of post row for later updating..
Lets go for it then.
As i developer i see firm reasons to join it
But few questions arise in my mind and it will be good for all if answered in the op
* What is the storyline for this game ?
* Under which lisense is this app available ? (Creative Commons ,GPL ..)
I suggests adding requests for things you want to add in the github repo
Sent from my GT-S5302 using Tapatalk 2
sak-venom1997 said:
As i developer i see firm reasons to join it
But few questions arise in my mind and it will be good for all if answered in the op
* What is the storyline for this game ?
* Under which lisense is this app available ? (Creative Commons ,GPL ..)
I suggests adding requests for things you want to add in the github repo
Sent from my GT-S5302 using Tapatalk 2
Click to expand...
Click to collapse
Thanks for the suggestion. This is my first thread here on XDA, also my 1st time using github(or any repo for that matter).
Pretty much my 1st time taking my code anywhere else from my personal computer and sharing my code/ideas with anyone besides my wife (who could care less about all of it). I have been learning java/android all by myself for a while, and could use some help and/or insight from someone more experienced.
Welcome aboard :thumbup:
Noted to self thrice via tapatalk
MattMatt0240 said:
Credits:
@nikwen (introducing the idea of open-source to me/ help in development threads)
@ADDICT.ANK (collaborator, helping hand)
@sak-venom1997 (collaborator, helping hand)
Please let me know if you're left out
Click to expand...
Click to collapse
Haha. Thanks.
MattMatt0240 said:
Reserved for FAQs/downloads/screenshots
Click to expand...
Click to collapse
Wow, looks good. Is that a mockup or do you already have this working?
nikwen said:
Haha. Thanks.
Wow, looks good. Is that a mockup or do you already have this working?
Click to expand...
Click to collapse
I started working on this a while back (in a different project to learn from). Realized many of my errors in doing so, so started fresh. The screenshot is just a basic idea of how I want the gameplay to look like, and is not quite functional yet. I do all of the art myself (so far) but there are many aspects in which I'm not quite sure how to make work, such as inventory/shops, and maps.
If there's anything you see that you feel can be improved, please feel free to let me know
Thanks nikwen!
Noted to self thrice via tapatalk
Would you mind pushing the merged code to new branched and deleting the bin folder
These non essential files make the repo huge and people like me with slow internet have problems synchronising
Sent from my GT-S5302 using Tapatalk 2
sak-venom1997 said:
Would you mind pushing the merged code to new branched and deleting the bin folder
These non essential files make the repo huge and people like me with slow internet have problems synchronising
Sent from my GT-S5302 using Tapatalk 2
Click to expand...
Click to collapse
Yeah, I meant to do it sooner. Been busy the last few days, will do it soon. Should be done by the time you get on. I don't have much of a base yet, this is really just the start of an idea.
Noted to self thrice via tapatalk
Should be good now sak. I have slow internet as well, very slow unless I manage to find 4g at my house. I downsized the repo quite a bit, so it should be better for us all
Noted to self thrice via tapatalk
@sak-venom1997 I added a PreferenceActivity (settings) and made the D-Pad repositionable via those settings
If you get a chance, check it out and let me know what you think.
Noted to self thrice via tapatalk
MattMatt0240 said:
@sak-venom1997 I added a PreferenceActivity (settings) and made the D-Pad repositionable via those settings
If you get a chance, check it out and let me know what you think.
Noted to self thrice via tapatalk
Click to expand...
Click to collapse
What's about posting apks here or on Github every now and then? I'd love to give it a try but I don't want to build it myself every time.
nikwen said:
What's about posting apks here or on Github every now and then? I'd love to give it a try but I don't want to build it myself every time.
Click to expand...
Click to collapse
Wow, still new to github, didn't know they had a release system I could do that and put a link in the O/P. Keep in mind that (at this point) it isn't necessarily playable, but at least everyone could get a feel for it and put up suggestions
Noted to self thrice via tapatalk
MattMatt0240 said:
Wow, still new to github, didn't know they had a release system I could do that and put a link in the O/P. Keep in mind that (at this point) it isn't necessarily playable, but at least everyone could get a feel for it and put up suggestions
Noted to self thrice via tapatalk
Click to expand...
Click to collapse
Exactly.
So do it and lets gather the suggestions.
Sent from my LT26i using xda premium
nikwen said:
What's about posting apks here or on Github every now and then? I'd love to give it a try but I don't want to build it myself every time.
Click to expand...
Click to collapse
ADDICT.ANK said:
Exactly.
So do it and lets gather the suggestions.
Sent from my LT26i using xda premium
Click to expand...
Click to collapse
Added download link to 3rd post. Constructive criticism is welcomed
Noted to self thrice via tapatalk
MattMatt0240 said:
Added download link to 3rd post. Constructive criticism is welcomed
Noted to self thrice via tapatalk
Click to expand...
Click to collapse
Thanks.
Looks good. Crashes very often but it's good considering that it's in its infancy. :good:
Will the character turn around when he's moved?
For sure I'll follow the development.
nikwen said:
Thanks.
Looks good. Crashes very often but it's good considering that it's in its infancy. :good:
Will the character turn around when he's moved?
For sure I'll follow the development.
Click to expand...
Click to collapse
Yes, I just need to crack down on drawing up some sprites Lol. Crashes may be caused by not creating a character first, and possibly a few other things that will be put in order in final production.
I was thinking of having the user being presented with a "setup" screen where they will have to adjust the D-Pad position and size. There's a few bugs in there I think. All of the activities are placed on the title screen temporarily simply for ease of access during development.
Regardless, thanks for the feedback, and yes it is still very early. I'm trying, and learning a whole lot quite fast
Noted to self thrice via tapatalk
Just a little update:
I have been working on trying to find an organized mapping system and think I found a satisfying solution. Before it was all hard-coded in java files leaving it a mess to read, and an activity for every "map" area.
Now, the maps will all be written in XML with a number identifier, which corresponds to the appropriate tile, translated by a separate java class. I tried using JSON, but @nikwen made a valid point... XML is more versatile and easier to read/use, thanks bud!
The inventory database has the path to the corresponding asset icon for each item, making it possible to match "xItem" with its relative icon. I was thinking I should do the same for enemies (once they are drawn). Enemy images are 100x100 pixels, used in battles, whereas item icons are the standard 32x32 px.
I also started playing around with animations, and obviously have much to learn on it.
I'll update the OP with another download, not much progress but still a lot of changes. Anybody feel free to chime in.
Noted to self thrice via tapatalk
MattMatt0240 said:
Just a little update:
I have been working on trying to find an organized mapping system and think I found a satisfying solution. Before it was all hard-coded in java files leaving it a mess to read, and an activity for every "map" area.
Now, the maps will all be written in XML with a number identifier, which corresponds to the appropriate tile, translated by a separate java class. I tried using JSON, but @nikwen made a valid point... XML is more versatile and easier to read/use, thanks bud!
The inventory database has the path to the corresponding asset icon for each item, making it possible to match "xItem" with its relative icon. I was thinking I should do the same for enemies (once they are drawn). Enemy images are 100x100 pixels, used in battles, whereas item icons are the standard 32x32 px.
I also started playing around with animations, and obviously have much to learn on it.
I'll update the OP with another download, not much progress but still a lot of changes. Anybody feel free to chime in.
Noted to self thrice via tapatalk
Click to expand...
Click to collapse
Good progress.
Looking forward to more improvements.

Q|How can I use UART connection to send commands

Hello,
I wanted to know how to connect to a device thorogh UART cable and send commands (wipe and so), also how can I learn the command set? (I think its AT commands )
..
fffft said:
Google
Read
Read some more
Try something
Repeat
Try something different. Confirm a missing piece. Have a beer
Repeat
Seriously. There are no step by step guides for this. The manufacturers do not provide any public documentation and the small number of people who have figured it out themselves are typically marketing programming tools based on that knowledge and reluctant to subvert that by disclosing a lot of detail to random strangers. An intelligent Google search will provide a wealth of information. But even so, you will need to do a substantial amount of first hand work to confirm information, fill in blanks, details and develop procedures.
As a bonus you will also gain experience in unbricking your test phones. The bottom line is that if you can't proactively search for the appropriate posts yourself and deduce the missing pieces empiracally, you simply aren't going to learn how to do this. Nevertheless a lot of people have at least a passing interest in this, so look here for details.
.
Click to expand...
Click to collapse
Thank you! You just gave me all the references I needed to start, btw great post (hope there is more to come).
Sent from my GT-I9300 using XDA Free mobile app

Categories

Resources