Android development and its real world apps

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
User avatar
Atic Atac
Prole
Posts: 16
Joined: Tue Oct 11, 2016 11:10 am

Android development and its real world apps

Post by Atic Atac » Thu Dec 01, 2016 1:37 pm

I searched through the forum but I guess the questionto be too Generic. What is the best way to port to Android and how many apps have succesfully been ported. I mean, not an exact statistic, only if there is any thread or web where you can see it more or less.

What is the perspective of a succesful pc app if you must port to Android?

User avatar
Positive07
Party member
Posts: 1005
Joined: Sun Aug 12, 2012 4:34 pm
Location: Argentina

Re: Android development and its real world apps

Post by Positive07 » Thu Dec 01, 2016 2:48 pm

Well Android is a really new thing, it was officially released this year, although it has been in development for at least another year so in the beginning of 2015.

This means that there aren't many apps made with LÖVE targeted to Android just yet. Anyway, there are some. Porting from the desktop is not easy if you require complex controls. Most of the games that were ported used just the mouse on PC and that translates really well to touch in Android. The ones that did use the keyboard just used for movement, and there are a few libraries that give you an on screen touch joystick so this too is easy.

You shouldn't need to rewrite your code. It just works. But remember that screen sizes are different. Your game should be able to adapt to the size of the screen, and using PixelScale is a good idea, since some phones may report really big screen but a pixel is 1/4 the size of a pixel on a PC (Here PixelScale would be 4).

As I mentioned you don't have keyboard all the time (you can ask for it but it takes half the screen) so you need to think how you are gonna handle input.

If you don't care about multitouch then handling touch is the same as handling the mouse on a PC.

I will post with some more time and include links to games and libraries so that you can see them. But there surely are, give it a search in the forums and you'll find them
for i, person in ipairs(everybody) do
[tab]if not person.obey then person:setObey(true) end
end
love.system.openURL(Github.com/Positive07)

User avatar
Atic Atac
Prole
Posts: 16
Joined: Tue Oct 11, 2016 11:10 am

Re: Android development and its real world apps

Post by Atic Atac » Sun Dec 04, 2016 5:50 pm

So the worst problems are screen res. and control?
Well. Is there any lib specifically to adress these issues or simply the standard love2d?

About original question I not only mean finished games, but also tests of the viability of love2d for Android

User avatar
raidho36
Party member
Posts: 1951
Joined: Mon Jun 17, 2013 12:00 pm

Re: Android development and its real world apps

Post by raidho36 » Sun Dec 04, 2016 7:50 pm

There is a multitouch library that basically maps touches to virtual buttons of arbitrary shape and provides gesture information on the fly. As for resolution, pretty sure any generic camera library will do.

User avatar
Atic Atac
Prole
Posts: 16
Joined: Tue Oct 11, 2016 11:10 am

Re: Android development and its real world apps

Post by Atic Atac » Mon Dec 05, 2016 4:30 pm

And those libraries are successfully used when implemented in very simple or minimal projects?

Or in another, more generic words, has a project more chances to be developed if you try to limit its scope?

User avatar
raidho36
Party member
Posts: 1951
Joined: Mon Jun 17, 2013 12:00 pm

Re: Android development and its real world apps

Post by raidho36 » Mon Dec 05, 2016 4:59 pm

That really has nothing to do with neither framework nor its libraries. But yes, simpler projects get done easier. That's kind of a no-brainer.

User avatar
Atic Atac
Prole
Posts: 16
Joined: Tue Oct 11, 2016 11:10 am

Re: Android development and its real world apps

Post by Atic Atac » Wed Dec 07, 2016 10:34 am

I'm always referring to the Android port . If it's so inmature that you better care to not be so ambitious. I think "Turtle: Invaders" could be a good example about I said. Any good example?

User avatar
Positive07
Party member
Posts: 1005
Joined: Sun Aug 12, 2012 4:34 pm
Location: Argentina

Re: Android development and its real world apps

Post by Positive07 » Wed Dec 07, 2016 4:37 pm

Anything you can do with LÖVE can be done with the Android port, the Android port is not immature because it uses the same code base as LÖVE itself, there are none crashes that I know of (except for really specific reported crashes that no one else knows why and not enough information was provided)

Even then there aren't many people working with it so not many apps has been made. This is because of the lack of common input (keyboard, joystick). Using touch as a mouse only allows you to get a single touch point and handling multiple touch events and gestures is not that easy.

As we mentioned, there are a few libraries like Gooi or AnalogJoystick (I think that was it's name) that allow you to use touch as more complicated input like a joystick, or simple buttons.

I think that we need more people developing for Android and writing more libraries. That is what the Android port is missing
for i, person in ipairs(everybody) do
[tab]if not person.obey then person:setObey(true) end
end
love.system.openURL(Github.com/Positive07)

User avatar
Atic Atac
Prole
Posts: 16
Joined: Tue Oct 11, 2016 11:10 am

Re: Android development and its real world apps

Post by Atic Atac » Thu Dec 08, 2016 3:40 pm

Yeah, so the Moving of the old Androidsubforum was for finishing at last its devekopment? Good work :awesome: . I learned that if its readiness was not so well polished there would be no reason to treat it like the rest of the Love2d API. So the only problem so far is the lack of programmers ready to Take advantage of it. ??? That' s ok. Because I will try it. In fact that's what I wanted from the beginning. Any advice for the very start, like making before 2 or 3 little PC apps before venturing into Android??

User avatar
Positive07
Party member
Posts: 1005
Joined: Sun Aug 12, 2012 4:34 pm
Location: Argentina

Re: Android development and its real world apps

Post by Positive07 » Thu Dec 08, 2016 4:45 pm

Ummm get familiar with the multitouch API, if you are gonna target mobile I recommend you don't use mouse events but the touch ones.

Get your environment ready, setting up everything to build LÖVE for Android APKs is somewhat of a pain, you need:
JDK+Android SDK+Android NDK+Ant
Note that this is only necessary when releasing an APK, you can use the LÖVE app in development

So get the LÖVE for Android app on your phone and I recommend you get Dropbox, you can upload your stuff to your Dropbox folder from your development PC and you can then click the .love file from Dropbox and it will open it with LÖVE!

And of course you need to get familiar with LÖVE.

Also there are some limitations in the current Android port, like static screen orientation and some other minor stuff
for i, person in ipairs(everybody) do
[tab]if not person.obey then person:setObey(true) end
end
love.system.openURL(Github.com/Positive07)

Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 6 guests