Jump to content

[TOPIC: topicViewTemplate]
[GLOBAL: userSmallPhoto]
Photo

Windows Game Developer Contest and some beginner questions
Started by Nob Studio Feb 28 2015 03:28 AM

7 replies to this topic
[TOPIC CONTROLS]
This topic has been archived. This means that you cannot reply to this topic.
[/TOPIC CONTROLS]
[modOptionsDropdown]
[/modOptionsDropdown]
[reputationFilter]
[TOPIC: post.html]
#1

Nob Studio

[GLOBAL: userInfoPane.html]
Nob Studio
  • Contributor

  • 153 posts
  • Corona SDK

Hi guys,

Sharing a Windows Game Developer Contest in case some of you don't know about it.

http://www.wpdevcenteroffers.com/home/contest

 

Also, I have some silly newbie question and can't find the answers with know-it-all google, appreciate if anyone can help out, thanks in advance!

 

1. Do I need a windows phone or just test with the emulator will do?

2. How to make the rate it/review my app button? Use system.openURL()? (I read there is a rate-my-app Windows Phone component)

3. How long is the review process?

4. From the documents the audio doesn't support .mp3, so I have to convert to ogg?

5. Back button, do we need a "confirm you want to quit" pop out? Since the system.popup is not supported we have to make a scene on our own?



[TOPIC: post.html]
#2

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 25,460 posts
  • Enterprise

I can't answer all of these, but for #1, the emulator requires certain hardware features to run.  This setting isn't all that common to Windows machines.  If your CPU doesn't support this virtualization mode, then you will need a device to test on.

 

Here's the Window's system requirements for this:  https://msdn.microsoft.com/en-us/library/windows/apps/ff626524%28v=vs.105%29.aspx#hyperv

 

#2.  We don't support native.showPopUp() in CoronaCards, so you're left to your own means to accomplish this.  I don't know if system.OpenURL will work or not.  Since you're compiling in native space, if there are native SDK calls to rate your app, you should be able to call them.  See:  https://msdn.microsoft.com/en-us/library/windows/apps/hh394030%28v=vs.105%29.aspx

 

#4, yes, you will have to convert to .wav or .oog. 

#5, I opened several apps and backspaced my way out.  I was never prompted for a "Are you sure you want to quit" type box. 

 

Rob



[TOPIC: post.html]
#3

doubleslashdesign

[GLOBAL: userInfoPane.html]
doubleslashdesign
  • Contributor

  • 727 posts
  • Corona SDK

I have a sample windows phone app that adds the corona Hook to communicate with the lua code and a native popup message box.

 

You would do #2 the same way but call Microsoft's rate app component.

 

I can find the link so you can download it if you want it.

 

Larry



[TOPIC: post.html]
#4

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 25,460 posts
  • Enterprise

Actually I just did #2 using Microsoft's rate app component in an app I submitted.  It was pretty easy.  See:

 

https://msdn.microsoft.com/en-us/library/windows/apps/hh394030%28v=vs.105%29.aspx

 

Rob



[TOPIC: post.html]
#5

Nob Studio

[GLOBAL: userInfoPane.html]
Nob Studio
  • Contributor

  • 153 posts
  • Corona SDK

Thanks Rob & Larry

 

1. It requires windows 8.1 PRO which I don't have so I end up getting a nice new phone lumia 535 at sgd $199 abt S145 usd

2. I like to implement the Microsoft's rate app component, how do I communicate with c+ language? Sorry I have no experience outside lua. After reading this page I still have no idea how to proceed, like where to put the C file in visual studio etc 

http://docs.coronalabs.com/coronacards/wp8/communication.html#class-framework

Can Rob spoonfeed me the code please?  :P

 

4. converted to ogg, music works well on windows phone

 

I followed this wonderful guide by fellow corona user http://scottadelman.com/2014/12/01/lessons-learned-bringing-my-corona-apps-to-window-phone/ and successfully tested the game on lumia.

Now the text is indeed a big problem on windows, so I have spent the past two days learning how to make bitmap font's and implementing them with multi lines(I have a lot dialogue boxes in game).



[TOPIC: post.html]
#6

Nob Studio

[GLOBAL: userInfoPane.html]
Nob Studio
  • Contributor

  • 153 posts
  • Corona SDK

Update:

So the rate it is actually very simple to implement.

system.openURL("zune:reviewapp?appid=yourappid")

 

email is easy too:

system.openURL("mailto:testing@yourdomain.com") 
 
open native app twitter and facebook
system.openURL("fb://profile/yourfbID")
system.openURL("twitter://user?id=yourtwitterID")
 
Just found out how to edit the tiles and add splash screen. :rolleyes:  


[TOPIC: post.html]
#7

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 25,460 posts
  • Enterprise

If you want to do it the native way, its pretty easy.  Add this to your MainPage.cs file near the bottom as a child function of MainPage():

        /// <summary>Called by Lua when it is requesting a login popup to be shown.</summary>
        /// <param name="sender">The CoronaRuntimeEnvironment that dispatched this event.</param>
        /// <param name="e">Provides the Lua vent table's fields/properties.</param>
        /// <returns>Returns a boxed object to Lua.</returns>
        private CoronaLabs.Corona.WinRT.ICoronaBoxedData rateApp(
            CoronaLabs.Corona.WinRT.CoronaRuntimeEnvironment sender,
            CoronaLabs.Corona.WinRT.CoronaLuaEventArgs e)
        {
            MarketplaceReviewTask marketplaceReviewTask = new MarketplaceReviewTask();
            marketplaceReviewTask.Show();
            // This returns nil to Lua.
            return null;
        }

 

At the top, in the "using" area add this line:

 

using Microsoft.Phone.Tasks;

 

In the OnCoronaRuntimeLoaded function add:

        private void OnCoronaRuntimeLoaded(
            object sender, CoronaLabs.Corona.WinRT.CoronaRuntimeEventArgs e)
        {
            // Keep a reference to the Corona runtime environment.
            // It's needed so that your login window's results can be dispatched to Corona.
            fCoronaRuntimeEnvironment = e.CoronaRuntimeEnvironment;
            fCoronaRuntimeEnvironment.AddEventListener("rateApp", rateApp);
        }

 

Then in your Lua code for the touch/tap handler for your Rate button do:

                local requestRateApp =
                {
                    name = "rateApp",
                }
                Runtime:dispatchEvent(requestRateApp)

 

Rob



[TOPIC: post.html]
#8

Nob Studio

[GLOBAL: userInfoPane.html]
Nob Studio
  • Contributor

  • 153 posts
  • Corona SDK

Thanks Rob for the code! Very helpful as I plan to implement highscore charts and some other window native features, and I had no idea where to start.

 

For Rate It button I'll stick with system.openURL("zune:reviewapp?appid=yourappid") cause it shows up pretty much the same as native.




[topic_controls]
[/topic_controls]