Jump to content

[TOPIC: topicViewTemplate]
[GLOBAL: userSmallPhoto]
Photo

Getting Started
Started by Rob Miracle Dec 05 2017 08:32 AM

12 replies to this topic
[TOPIC CONTROLS]
This topic is locked This topic is locked
[/TOPIC CONTROLS]
[modOptionsDropdown]
[/modOptionsDropdown]
[reputationFilter]
[TOPIC: post.html]
#1

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 25,790 posts
  • Enterprise

New here? Where should you start?

 

Check out our getting started guide:

 

https://docs.coronalabs.com/guide/programming/index.html

 

This set of tutorials will guide you through getting Corona installed and making two games. It will help you learn Lua and the Corona API system.

 

Rob

 


  • Rou.shaheen likes this

[TOPIC: post.html]
#2

Rou.shaheen

[GLOBAL: userInfoPane.html]
Rou.shaheen
  • Observer

  • 1 posts
  • Corona SDK

Hello

I am new to all of this and apprecaite any help that I can get. (I am no developer, i just deal with one so bear with me for not understanding the technical terms)

I am having a third party developer make me a simple app for iOS and Android and we are in different countries

The developer is saying that it is a Corona based iTunes app.

In order for me to test this app he is saying that I need to purchase an Enterprise Developer Account and to send him the account details so he can deploy it and I can play on my devices.

He says to make sure to create a CORONA based iTunes and gives me the following steps :

login
then click on developer account
then packages
then cocoa
select
corona
and then click on platform
select iphone and android
then select languages
lua
objective C
android SDK
java platform
then click on soft
in that select supported files
then click on yes buttion
then click on packages
select packages


The problem the link he gave me to follow these steps is apple developer and those steps are not there at all


Does any of this make sense to anyone?

I have tried to enroll in an Enterprise Developer Account but it only allows me to sign up for the Individual Developer account.

The developer is saying that I cannot use an Individual Developer Account.

Thanks!

[TOPIC: post.html]
#3

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 25,790 posts
  • Enterprise

To develop for iOS, you do have to have an Apple developer account which gives you access to iTunes Connect, the web-based interface that lets you upload your app to Apple to get approved and deployed.  There aren't any "Corona" specific settings in your Apple setup and there isn't any Android setup there as well.  I suspect the requirement for an Enterprise developer vs. An individual developer is so that you can add his developer account to your Enterprise account so he can manage it.

 

The steps above don't make a lot of sense to me. Some of it looks like you're setting up a Xcode project.  The steps Android steps also don't make a lot of sense in any Google-based setup.

 

Rob



[TOPIC: post.html]
#4

sadeshjo123

[GLOBAL: userInfoPane.html]
sadeshjo123
  • Observer

  • 3 posts
  • Corona SDK

thanks for this



[TOPIC: post.html]
#5

aliaymaneltantawy

[GLOBAL: userInfoPane.html]
aliaymaneltantawy
  • Observer

  • 12 posts
  • Corona SDK

Hi ,
I have a problem. Now I'm in the "Upward & Inward" tutorial and I have downloaded its source. When I open the Build dot Settings file visual studio sends me an error message which is "Data at the root level is invalid. Line 1, position 1.", how to solve this problem?
Thanks.


[TOPIC: post.html]
#6

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 25,790 posts
  • Enterprise

How did you get the files for the project? Did you create a build.settings file and hand type in the contents? Did you do a New Project from the menu or welcome Window? Did you download the source from GitHub?

 

Can you open it in another editor like Notepad?

 

Thanks

Rob



[TOPIC: post.html]
#7

aljaafrehjamal

[GLOBAL: userInfoPane.html]
aljaafrehjamal
  • Observer

  • 1 posts
  • Corona SDK

Hi, I'm very new to everything, but I've mainly been having a ton of trouble with tables and having enemies (in my case, fighter jets) appear on screen. I'm not exactly sure what I've done wrong, but I'm sure my code is a mess because I've been trying many different things to make it work. I really need help to understand what it is I'm doing wrong, and what method should I be using. Thank you for any help!

 

Edit: I'm creating a physics game very similar to flappy bird where I have a UFO moving along a Parallax background and dodging incoming fighter jets from the right side of the screen. I initially had everything operating correctly except for collision (I can't seem to make the collision function take the player to the "menu" screen). But I realized I should be utilizing tables to create the fighter jet enemies instead of creating each individual jet since they are all the same png file. I tried to do this, but I can't seem to figure out how to implement tables for my fighter jet enemies. They just don't appear at all when I try this method.

local composer = require( "composer" )

local scene = composer.newScene()


local physics = require "physics"
physics.start()


-- -----------------------------------------------------------------------------------
-- Code outside of the scene event functions below will only be executed ONCE unless
-- the scene is removed entirely (not recycled) via "composer.removeScene()"
-- -----------------------------------------------------------------------------------


 local background
 local city1
 local city2
 local city3
 local city4
 local ufo = display.newImage("ufo.png")
ufo.x = 100
ufo.y = 100
ufo:scale( .1, .1 )
physics.addBody(ufo, "dynamic", {density=1, bounce=0.1, friction=2, radius=12} )


local fighter = display.newImage("fighter.png")


local fightersTable = {}


local score = 0






-- -----------------------------------------------------------------------------------
-- Scene event functions
-- -----------------------------------------------------------------------------------
  function activateUfo(self,event)
self:applyForce(0, -10, self.x, self.y)
end




function touchScreen(event)
if event.phase == "began" then
  ufo.enterFrame = activateUfo
  Runtime:addEventListener("enterFrame", ufo)
end


if event.phase == "ended" then
Runtime:removeEventListener("enterFrame", ufo)
end
end


Runtime:addEventListener("touch", touchScreen)


 function activateUfo(self,event)
self:applyForce(0, -10, self.x, self.y)
end




function scrollCity(self,event)
if self.x < -800 then
self.x = 900
else
self.x = self.x - self.speed
end
end


local function createFighters()
local newFighter = display.newImage("fighter.png")
table.insert( fightersTable, newFighter)
physics.addBody(fighter, "static", {density=1, bounce=0.1, friction=2, radius=12} )
newFighter.myName = "fighter"


local whereFrom = math.random(3)


if ( whereFrom == 1 ) then
fighter.x = 500
newFighter.y = math.random(50, 300)
newFighter:scale( .08, .08 )
newFighter.speed = math.random(2,6)
newFighter.initY = fighter.y
newFighter.amp = math.random(20,100)
newFighter.angle = math.random(1,360)
newFighter:setLinearVelocity( math.random(500, 300))
elseif ( whereFrom == 2 ) then
fighter1.x = 500
newFighter.y = math.random(200, 300)
newFighter:scale( .08, .08 )
newFighter.speed = math.random(6,9)
newFighter.initY = fighter1.y
newFighter.amp = math.random(20,100)
newFighter.angle = math.random(1,360)
newFighter:setLinearVelocity( math.random(500, 100))
elseif ( whereFrom == 3 ) then
newFighter.x = 500
newFighter.y = math.random(100, 200)
newFighter:scale( .08, .08 )
newFighter.speed = math.random(3,7)
newFighter.initY = fighter.y
newFighter.amp = math.random(20,100)
newFighter.angle = math.random(1,360)
newFighter:setLinearVelocity( math.random(500, 200))
end
end




function onCollision(event)
if event.phase == "began" then




end
end


local function updateText()
scoreText.text = "Score: " .. score
 end
-- create()
function scene:create( event )


    local sceneGroup = self.view


scoreText = display.newText( "Score: " .. score, 200, 80, native.systemFont, 36 )


local background = display.newImageRect( "BG.png", 900, 480 )
background.x = display.contentCenterX
background.y = display.contentCenterY


local city1 = display.newImageRect( "city1.png", 900, 480 )
city1.x = display.contentCenterX
city1.y = display.contentCenterY + 110
city1.speed = 1


local city2 = display.newImageRect( "city1.png", 900, 480 )
city2.x = display.contentCenterX + 900
city2.y = display.contentCenterY + 110
city2.speed = 1


local city3 = display.newImageRect( "city2.png", 900, 480 )
city3.x = display.contentCenterX
city3.y = display.contentCenterY + 5
city3.speed = 2


local city4 = display.newImageRect( "city2.png", 900, 480 )
city4.x = display.contentCenterX + 900
city4.y = display.contentCenterY + 5
city4.speed = 2


ufo = display.newImage("ufo.png")
ufo.x = 50
ufo.y = 50
ufo:scale( .1, .1 )
physics.addBody(ufo, "dynamic", {density=1, bounce=0.1, friction=2, radius=12} )
ufo.collision = onCollision


city1.enterFrame = scrollCity
Runtime:addEventListener("enterFrame", city1)


city2.enterFrame = scrollCity
Runtime:addEventListener("enterFrame", city2)


city3.enterFrame = scrollCity
Runtime:addEventListener("enterFrame", city3)


city4.enterFrame = scrollCity
Runtime:addEventListener("enterFrame", city4)


fighter.enterFrame = moveFighters
Runtime:addEventListener("enterFrame", fighter)


Runtime:addEventListener("collision", onCollision)
    -- Code here runs when the scene is first created but has not yet appeared on screen


local function gameLoop()


createFighters()
end


end




-- show()
function scene:show( event )


    local sceneGroup = self.view
    local phase = event.phase


    if ( phase == "will" ) then


        -- Code here runs when the scene is still off screen (but is about to come on screen)


    elseif ( phase == "did" ) then




        -- Code here runs when the scene is entirely on screen


    end




-- hide()
function scene:hide( event )


    local sceneGroup = self.view
    local phase = event.phase


    if ( phase == "will" ) then
        -- Code here runs when the scene is on screen (but is about to go off screen)


    elseif ( phase == "did" ) then
        -- Code here runs immediately after the scene goes entirely off screen


    end
end
end




-- destroy()
function scene:destroy( event )


    local sceneGroup = self.view
    -- Code here runs prior to the removal of scene's view


end




-- -----------------------------------------------------------------------------------
-- Scene event function listeners
-- -----------------------------------------------------------------------------------
scene:addEventListener( "create", scene )
scene:addEventListener( "show", scene )
scene:addEventListener( "hide", scene )
scene:addEventListener( "destroy", scene )
-- -----------------------------------------------------------------------------------


return scene
[lua=auto:0]


[TOPIC: post.html]
#8

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 25,790 posts
  • Enterprise

It looks like your code did not format properly, making it hard to read and understand what's going on.

 

Can you edit it, and copy/paste your text into the popup window when you click the blue <> button in the edit bar along with Bold, Italics, etc.

 

You should also post a better description of what you're trying to accomplish, what you're seeing and what your expectations are. Screenshots or video captures of the what you're seeing are also helpful.

 

Rob


  • aljaafrehjamal likes this

[TOPIC: post.html]
#9

jason.etim.bassey

[GLOBAL: userInfoPane.html]
jason.etim.bassey
  • Observer

  • 1 posts
  • Corona SDK

Hello,

 

I'm following the tutorial but I can't seem to get past the background step without getting an error. I've tried copying the code for word but the following error pops up: https://imgur.com/a/vUFDMzR

I'm new to coding in general and would appreciate any help I could get.



[TOPIC: post.html]
#10

sheikhameen123

[GLOBAL: userInfoPane.html]
sheikhameen123
  • Observer

  • 23 posts
  • Corona SDK

I have just completed the Corona Getting Started Guides, and I realized I only used one asteroid from the sprite sheet. Did I miss out anywhere or the lesson was built that way?



[TOPIC: post.html]
#11

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 25,790 posts
  • Enterprise

Welcome to the Corona community...

 

The tutorial only uses one of the two asteroids. We left it as a way for you to improve upon the game by adding in multiple asteroids.

 

Rob



[TOPIC: post.html]
#12

boombox.extra

[GLOBAL: userInfoPane.html]
boombox.extra
  • Observer

  • 2 posts
  • Corona SDK

Hi! 

settings =
{
  orientation =
  {
    default = "landscapeLeft",
    supported = { "landscapeLeft", },
},
 unexpected symbol near '<eof>'
WTF? Help please


[TOPIC: post.html]
#13

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 25,790 posts
  • Enterprise

You already have a thread asking this question and getting help on:

 

https://forums.coronalabs.com/topic/75788-unexpected-symbol-near-eof/

 

Please only use one thread for your question.

 

Rob




[topic_controls]
[/topic_controls]