[DEPRECATED] Experimental iOS port (LÖVE 0.9.2)

Discuss any ports of LÖVE to different platforms.
Locked
User avatar
slime
Solid Snayke
Posts: 3132
Joined: Mon Aug 23, 2010 6:45 am
Location: Nova Scotia, Canada
Contact:

Re: Experimental iOS port (LÖVE 0.9.x)

Post by slime »

kneeko wrote:I just got a game on the App Store using this port, so it's production-ready enough!
And the game is fun and polished too! A double-success. :D
kneeko wrote:Fonts don't seem to get loaded into memory until they are first drawn or evaluated with getWidth/getHeight. For large fonts this can cause a hiccup during runtime. My workaround was to call getWidth on all of the characters I would be using right after loading them.
Yeah, that's an annoyance. LÖVE can't really preload the glyphs since it doesn't know which glyphs will be used (and the font file might have hundreds.) First-time runtime hitches like that are also a problem at a lower level (inside the graphics driver) when drawing things using different states (blend modes, shaders, etc.) as well on mobile, but it's less of an issue than the image uploading that LÖVE does I think.

Also, did you use the new iOS 8 Storyboard/xib Launch Screen file, or just the static launch images? The app's description in the App Store says it's "Optimized for iPhone 6 and 6 plus" which I thought only appeared if the Launch Screen was used, but it would be good to know if the regular device-specific Launch Images trigger that as well.
User avatar
kneeko
Prole
Posts: 2
Joined: Sun Aug 04, 2013 8:54 pm
Location: Seattle, WA
Contact:

Re: Experimental iOS port (LÖVE 0.9.x)

Post by kneeko »

undef wrote:That does look like a lot of fun, why don't you present it in the Projects & Demos section :)
I'll do that very soon! Thanks for the suggestion. ^^
slime wrote:Also, did you use the new iOS 8 Storyboard/xib Launch Screen file, or just the static launch images? The app's description in the App Store says it's "Optimized for iPhone 6 and 6 plus" which I thought only appeared if the Launch Screen was used, but it would be good to know if the regular device-specific Launch Images trigger that as well.
I used regular (black) Launch Images, but I was also under the impression that you had to use a Storyboard to get that label. I suppose not! Which reminds me, I also had to use black Launch Images because there's a moment of black while LÖVE loads the game.

By the way, starting Feb 1st, Apple will be requiring everything submitted to be 64-bit. I fiddled with trying to get it to build with arm64, but I have absolutely zero experience with iOS development so I didn't make very much progress. Do you know if there are any major roadblocks in making that change? If so, I'll have to get my updates out before then! ;)
User avatar
slime
Solid Snayke
Posts: 3132
Joined: Mon Aug 23, 2010 6:45 am
Location: Nova Scotia, Canada
Contact:

Re: Experimental iOS port (LÖVE 0.9.x)

Post by slime »

kneeko wrote:I also had to use black Launch Images because there's a moment of black while LÖVE loads the game.
I'll see if there's anything I can do to fix that issue.
kneeko wrote:By the way, starting Feb 1st, Apple will be requiring everything submitted to be 64-bit. I fiddled with trying to get it to build with arm64, but I have absolutely zero experience with iOS development so I didn't make very much progress. Do you know if there are any major roadblocks in making that change? If so, I'll have to get my updates out before then! ;)
The big thing preventing LÖVE from supporting 64 bit ARM right now is LuaJIT. It doesn't have the code necessary to work on that architecture yet, although someone is working on it. If that's not done by February then LÖVE for iOS will have to use regular Lua 5.1 in the meantime, since that works on 64 bit ARM out of the box.
User avatar
xpol
Prole
Posts: 14
Joined: Tue May 13, 2014 2:00 am

Re: Experimental iOS port (LÖVE 0.9.x)

Post by xpol »

Smooth points are not supported - rough points will always be used.
I do needs smooth lines in my app.

Is it possible to make smooth lines?
User avatar
slime
Solid Snayke
Posts: 3132
Joined: Mon Aug 23, 2010 6:45 am
Location: Nova Scotia, Canada
Contact:

Re: Experimental iOS port (LÖVE 0.9.x)

Post by slime »

They should be supported, yeah – smooth points are a feature of older desktop OpenGL versions and they aren't available on OpenGL ES (mobile), whereas LÖVE has its own code for smooth lines so they should work everywhere.


EDIT:
kneeko wrote:I also had to use black Launch Images because there's a moment of black while LÖVE loads the game.
I made a little test, and I believe the moment of black will occur while things in love.load are executed, as long as takes enough time to notice. I don't think there's much that can be done inside LÖVE – it's up to your game's code.

You could draw some quick placeholder stuff before loading the majority of the game's content, maybe. You can use [wiki]love.graphics.clear[/wiki] / love.graphics.draw / etc. and [wiki]love.graphics.present[/wiki] inside love.load to do that.

Something as simple as this might be a bit of help:

Code: Select all

function love.load()
    local initialcolor = {0, 64, 192} -- or whatever the main color of your game's initial screen is.
    love.graphics.setBackgroundColor(initialcolor)
    love.graphics.clear()
    love.graphics.present()

    -- Load the game as normal.
end
EDIT 2: I have a (somewhat hacky) idea for keeping the launch image/screen around for longer. I'll see if it works out tomorrow, maybe.
User avatar
bartbes
Sex machine
Posts: 4946
Joined: Fri Aug 29, 2008 10:35 am
Location: The Netherlands
Contact:

Re: Experimental iOS port (LÖVE 0.9.x)

Post by bartbes »

kneeko wrote: • Fonts don't seem to get loaded into memory until they are first drawn or evaluated with getWidth/getHeight. For large fonts this can cause a hiccup during runtime. My workaround was to call getWidth on all of the characters I would be using right after loading them.
That is correct (and the behaviour of the "normal" love as well), this is mostly to deal with unicode and the large amounts of probably unused glyphs that might entail.
It is of course an option to render the ASCII characters on load, but this would still have performance dips when you happen to load a character not already loaded, I'm not sure there's a clean solution.
gianmichele
Citizen
Posts: 63
Joined: Tue Jan 14, 2014 11:03 pm

Re: Experimental iOS port (LÖVE 0.9.x)

Post by gianmichele »

This really has come a long way. I guess it's time for me to test properly!

Any chance you'll integrate iAds or Game Center Leaderboards? Or a guide that shows how to do it?
User avatar
slime
Solid Snayke
Posts: 3132
Joined: Mon Aug 23, 2010 6:45 am
Location: Nova Scotia, Canada
Contact:

Re: Experimental iOS port (LÖVE 0.9.x)

Post by slime »

gianmichele wrote:Any chance you'll integrate iAds or Game Center Leaderboards? Or a guide that shows how to do it?
I haven't looked into either one of those yet, but there might be existing Lua bindings out there that you'd be able to use with LÖVE. If not, I could probably create something like that – for Game Center at least. I'm not really interested in working with iAds myself.
gianmichele
Citizen
Posts: 63
Joined: Tue Jan 14, 2014 11:03 pm

Re: Experimental iOS port (LÖVE 0.9.x)

Post by gianmichele »

I guess that probably a small guide on how to integrate those services could open the door to people integrating a few :D
gianmichele
Citizen
Posts: 63
Joined: Tue Jan 14, 2014 11:03 pm

Re: Experimental iOS port (LÖVE 0.9.x)

Post by gianmichele »

Another small question: how do you guys handle multi resolution and loading of retina assets?

Thanks,
Gianmichele
Locked

Who is online

Users browsing this forum: No registered users and 32 guests