initial testing

Hi guys,

Great work on getting the tvOS alpha out for people to look at.

Just thought I’d let you know my findings so far.

The following code causes a crash with no error in the logs:

os.execute( “clear” )

The controls for ALONE work straight away, with no alteration.

Also, it seems that any data saved to the documents directory isn’t being stored (no highscores being saved).

Thanks!

Also, I can’t seem to get key events to work at this moment, making navigation impossible.

What sort of key events are you having issues with? It should work with controllers, but not keyboards.

Are you testing on an actual device or the tvOS simulator? At present, the virtual remote in the tvOS simulator does not support key/axes events.

Is the documents data just not writing, or not saving between sessions? Does this happen to the other directories?

Hi Michael,

I’m testing on both. I’ve been reading through to see if I’ve misread, but unsure.

I’m I meant to expect a “key” event to happen when I do swipes on the controller? I get no “key” events at all.

The only input I get is from a touch (not a tap) and that originates in the center of the screen. You can then move the touch point and release somewhere else. Does that make sense at all?

Thanks for the reply btw - We’re really pleased that tvOS is being worked on.  This is ALONE working natively:

https://www.instagram.com/p/98yJp3tglO

I’m getting the key events successfully on device (not in the simulator), however not really sure why but the directions are not that reliable. I mean, sometimes I swipe in a direction and I get a different direction key event. Maybe the key listener is trying to determine the direction doings some maths from the touch events of the trackpad? May it be that in some case (long/short swipe etc) the listener get confused and we need some filtering?

I got the PewPew example running on the tvOS device without a problem using the Coronalabs SDK (not Enterprise), so great job with the alpha version! 

Now I’ll start to port “Freeze! 2 - Brothers” to tvOS, but it will be quite an effort because the original game is in portrait mode.

And I use an intuitive control scheme where you rotate the levels on screen directly with your fingers, so I will have to play around a bit with e.g. using the touchpad x-axis values for rotation. 

On my first try I stripped the game a little bit, removed Game Center etc. but I only got a black screen so far on the device.

But all problems will be solved, all obstacles left behind if I just invest a little time. And that’s what I’m doing now. :slight_smile:

Thanks for supporting tvOS so fast! I know your hands are quite full!
 

Best

Andreas

Also, it seems that any data saved to the documents directory isn’t being stored (no highscores being saved).

I believe this is due to Apple TV not allowing local storage. You must use iCloud to store data the way you would have locally on iOS devices. We’ll need a solution to this before we can have IAP in our apps since there is no way to store whether they unlocked content or not.

There is a little unanswered thread about it here: https://forums.coronalabs.com/topic/60137-file-storage/?p=311636

Can you guys go into more detail about how the remote works? My approach (once I get the equipment) is going to be:

  • Get the MFi controller working in the simulator
  • Build and test on device to see what the heck the remote does with that code (if anything)

Is this how you did it? Does the remote work for you? Can you target the remote specifically or is it just working as a side effect of MFi controller support? Are you using some other (non MFi) controller code?

Honestly, I just took code from one of the controller tutorial’s I did back in the “When Ouya was hot” days. Those tutorials (keys and axis) have the basic code to capture up, down, left, right, etc. I put a few print statements in the event handler to see what keys I got. I pressed all the buttons to see what codes I was getting.

Once I had my menu basically working, I moved on to getting the axis stuff working for the play level. The menu code was pretty much what I used in the Tutorial on Tuesday.

Thanks Rob! I got an Apple TV on Friday and we’re going to start prototyping asap.

Anyone tried to use the accelerometer yet? Like pointing the Apple remote towards the screen to select buttons etc?

Thanks!

I have not. Perhaps I can give it a go this weekend. It might be a good movement model for the game I’m building.

Rob

Also, I can’t seem to get key events to work at this moment, making navigation impossible.

What sort of key events are you having issues with? It should work with controllers, but not keyboards.

Are you testing on an actual device or the tvOS simulator? At present, the virtual remote in the tvOS simulator does not support key/axes events.

Is the documents data just not writing, or not saving between sessions? Does this happen to the other directories?

Hi Michael,

I’m testing on both. I’ve been reading through to see if I’ve misread, but unsure.

I’m I meant to expect a “key” event to happen when I do swipes on the controller? I get no “key” events at all.

The only input I get is from a touch (not a tap) and that originates in the center of the screen. You can then move the touch point and release somewhere else. Does that make sense at all?

Thanks for the reply btw - We’re really pleased that tvOS is being worked on.  This is ALONE working natively:

https://www.instagram.com/p/98yJp3tglO

I’m getting the key events successfully on device (not in the simulator), however not really sure why but the directions are not that reliable. I mean, sometimes I swipe in a direction and I get a different direction key event. Maybe the key listener is trying to determine the direction doings some maths from the touch events of the trackpad? May it be that in some case (long/short swipe etc) the listener get confused and we need some filtering?

I got the PewPew example running on the tvOS device without a problem using the Coronalabs SDK (not Enterprise), so great job with the alpha version! 

Now I’ll start to port “Freeze! 2 - Brothers” to tvOS, but it will be quite an effort because the original game is in portrait mode.

And I use an intuitive control scheme where you rotate the levels on screen directly with your fingers, so I will have to play around a bit with e.g. using the touchpad x-axis values for rotation. 

On my first try I stripped the game a little bit, removed Game Center etc. but I only got a black screen so far on the device.

But all problems will be solved, all obstacles left behind if I just invest a little time. And that’s what I’m doing now. :slight_smile:

Thanks for supporting tvOS so fast! I know your hands are quite full!
 

Best

Andreas

Also, it seems that any data saved to the documents directory isn’t being stored (no highscores being saved).

I believe this is due to Apple TV not allowing local storage. You must use iCloud to store data the way you would have locally on iOS devices. We’ll need a solution to this before we can have IAP in our apps since there is no way to store whether they unlocked content or not.

There is a little unanswered thread about it here: https://forums.coronalabs.com/topic/60137-file-storage/?p=311636