Splash Screen Plugin

Hi, I have been having lots of trouble putting a plug in for the splash screen this is how my build.setting look.


settings =

{

    orientation =

{

– Supported values for orientation:

– portrait, portraitUpsideDown, landscapeLeft, landscapeRight

default = “portrait”,

supported = { “portrait”, },

},

   splashScreen =

    {

        enable = true,

        image = “velocity.png”

    },

– Android section

android =

{

usesPermissions =

{

“android.permission.INTERNET”,

},

},

– iOS section

iphone =

{

plist =

{

UIStatusBarHidden = false,

UILaunchStoryboardName = “LaunchScreen”,

CFBundleIconFiles =

{

“Icon-40.png”,

“Icon-58.png”,

“Icon-76.png”,

“Icon-80.png”,

“Icon-87.png”,

“Icon-120.png”,

“Icon-152.png”,

“Icon-167.png”,

“Icon-180.png”,

},

},

},

– Plugins section

plugins =

{

},

– Project section

excludeFiles =

{

– Exclude unnecessary files for each platform

ios = { “Icon.png”, “Icon-*dpi.png”, },

android = { “Icon.png”, “Icon-??.png”, “Icon-???.png”, “LaunchScreen.storyboardc”, },

},

}

Does velocity.png exist in the same folder as main.lua or is it in an “images” folder?

For the community benefit, this is a continuation of a support email. The poster is currently getting just a black screen after adding the splashScreen block to the build.settings.

What’s in your console log? (the text window behind the simulator)

Rob

velocity.png is in a seperate folder of images. I did not put main.lua in a folder, should I. This is the console log.

15:11:42.793 15:11:42.793 Windows simulator build date: Mar 31 2017 @ 14:34:46 15:11:42.793 15:11:54.074 15:11:54.074 Copyright (C) 2009-2017 C o r o n a L a b s I n c . 15:11:54.074 Version: 3.0.0 15:11:54.074 Build: 2017.3068 15:11:54.074 Platform: SM-G900S / x64 / 10.0 / Intel(R) HD Graphics 630 / 4.4.0 - Build 21.20.16.4541 / 2017.3068 / en\_US | US | en\_US | en 15:11:54.074 Loading project from: C:\Users\bathw\OneDrive\Documents\Corona Projects\Balloon Chaos 15:11:54.074 Project sandbox folder: C:\Users\bathw\AppData\Local\Corona Labs\Corona Simulator\Sandbox\balloon chaos-39C7784870EF88519FAF5298CB69BEE5\Documents

You need to point to the image by its actual location. If you put it inside a subfolder, you need to specify that to the plugin.

Brent

I changed that what you said, before so th log console is what it is. i put images = “images/velocity.png”

I also have another question it is when I bought the $99 splash control plugin how does my text editor sublime text editor 3 know I have bought  the splash control because I didn’t put any password in my app to let it know or anything.

It has no impact on Sublime Text 3. The Splash Screen plugin is special. Normally for plugins you have to put them in your “plugins” table in build.settings, however for the splash screen you just need the splashScreen table that you’ve added.  The Corona simulator reads your build.settings file and downloads any required plugins like the splash screen. You at one point logged into the simulator with your password.

Rob

OK , then do you have any recommendations of what text editor to use. Something that professionals and maybe you would use.

That would also fit the plugin, of course.

Here are some options we recommend:

https://docs.coronalabs.com/guide/programming/01/index.html#text-editors

Would the ones that work be the add on packages.

which one would you choose because I’m just a beginner and i don’t know much.

It’s really up to you. If you’re on Windows (I believe you are), many people like Sublime… but it’s not free. A lot of people are turning to Atom because it’s highly customizable. You should check out a few options and decide which one “feels” good to you.

Brent

Would atom work with the SplashScreen control plug in.

Your text editor is a completely separate tool that Corona. You can use any text editor that you like and Sublime Text is a great editor. It’s what I use. But at the end of the day, all Sublime Text (or any other text editor) is a way for you to write and edit code and save it. After that the Corona simulator reads those text files and runs your app for you.

Any editor will work. Atom is a good editor too.  But your problem isn’t with the editor, something else is going on with your code. That’s happening in the Simulator.  

What are you expecting to see?  

What does your main.lua file do? Or are you trying to see the splash screen before you write the rest of your app?
 

Rob

Yes I am trying to see the splash Screen before I start the app, and to make sure the text work I put some text in the main.lua to make sure it changes. So I can see. This is how my main.lua looks.

local options = { text = "Hello World", x = 140, y = 220, width = 128, font = native.systemFont, fontSize = 18, align = "right" -- Alignment parameter } local myText = display.newText( options ) myText:setFillColor( 1, 0, 0 )

Are you seeing the text in the simulator?  If so everything is working as expected. You won’t see the splash screen until build for a device and install it and run it on that device.

Rob

I do see the text. So everything should be fine, and is everything in my build.settings fine for the splash.

OK, another question can you know if it works beforehand before you post the app that the splash works, and is the build.settings good for the splash screen to work.

You should always build your app and test it on real devices before submitting it to a store. It’s the only way you can know that your app will work as expected. There are several items like the splash screen, ads, in-app purchases and more that can only be tested on a real device and not in the Corona Simulator.

I don’t see anything wrong in your build.settings that would lead me to believe there is a problem. But you won’t know until you test it.

Rob