Complete newbie

Im wanting a iPad hobbie and I came across codify (or codea as its to be known). I have downloaded the app but admit I’m a complete novice, no coding experience what so ever BUT I really want to have a stab at this. I’m a good learner when I set my sights on something and am looking forward to getting my teeth into a project.

my question is what are the tips on starting? Is there step by step guide for complete novices? any web links would be appreciated that would help me get started with a project.

It’s all words and numbers to me BUT I WANT TO LEARN :slight_smile:

Help would be much appreciated.

I like your enthusiasm :slight_smile:

It might be good to get familiar with the programming language used by Codea, it’s called Lua and you can find some basic tutorials here:

You can also find a web-based Lua interpreter (a thing you can type commands into, and see output) here: (You’ll have to select Lua as the language you want to use)

And finally a quick overview of Codea

When you start a new project you’re greeted by a file called “Main” which contains two sections of code called functions. One is called setup, and one is called draw.

Setup is run once, as soon as you press the play button.

Draw is then called 60 times per second, and you can put commands inside here to put things on the screen.

So, for example, the following program will draw a circle underneath your finger when you touch the screen (note that lines prefixed with “–” are comments and are ignored, they are just there to make notes for yourself inside your code):

-- Touch example
function setup()
    -- This line is a comment, it is ignored

function draw()
    -- First we clear the background color to black
    -- 0, 0, 0 indicates that we want zero amount of red, green, and blue
    background( 0, 0, 0 )

    -- We will set the fill color to red, all shapes will be this color
    -- the three parameters to "fill" below indicate the amount of red, 
    -- green and blue we want in our fill color 
    fill( 255, 0, 0 ) 
    -- The next line draws a circle, it takes four parameters, they are:
    -- x and y location (we are setting this to the CurrentTouch position)
    -- width and height (we are setting these both to 100, making it a circle)
    ellipse( CurrentTouch.x, CurrentTouch.y, 100, 100 )

I’m sure others here will be able to suggest better starting resources

One of THE BEST starting resources is right at the top of the main Codea screen - the example apps. You can look at those, tweak them to see how things change or break, and do so with confidence, because you can’t overwrite the originals. Once you have a vague understanding of how each of the examples work, you’ll be well on your way. And if you don’t understand how a particular one works - Bingo! You’ve found what you need to read about - google for it, there’s a ton of info out there (or ask here. better to google first.).

You don’t mention if you have any other languages under your belt. If you have some familiarity with other languages, I suggest - or even if you don’t, the curve will just be a bit steeper. I’m Mr. Computer Dude for… egads, 30+ years now, and I’m working my way thru the PIL - my biggest problem is unlearning things from other languages.

I am also a complete newbe at this stuff. But I’ve found these tutorials to be great. I’ve learned a lot of the basics. It’s both video and text tutorials.

Also, I’ve used an app called iLuaBox Lite when I did the tutorials. It’s fun to just play around with and see what you can do with it.

Hope this tutorials help you as much as they’ve helped me! :smiley:

Hi guys sorry for grave digging but since my original post I have been too busy to indulge myself into the app…

I’m now ready and im just wondering if there is any new complete novice material so i can enter this wonderful world of programming :slight_smile:


So, have you looked at the FAQ and Wiki (some links are broken) yet? I find the Wiki very helpful.

Just downloaded Codea and started playing with it myself. Am a complete newbie to coding too (except some BASIC stuff 30 years ago!) but am finding using Codea a real dream. As mentioned above, check out -
Some links are broken but they mentioned yesterday they are aware of this and attempting to fix. So far these tutorials have helped me get my feet wet…

Good. Can’t wait to see what you roll out!

Guys, I am also starting, very excited! I have a decent programming background, and started coding and struggling with bodies and physics.
I am a bit lost with the Codea documentation, I can’t seem to find the definite API documentation, as I keep on coming across functions that I cannot find anywhere in the in-app docs or wiki. Can somebody help to point to the complete API docs?
And if anybody knows, I am drawing Polygons as bodies, now trying to figure out out to paint them??

@raidersan - For physics - The body’s dont automatically draw their shape like most programming languages. Many functions are not in the in-app docs or wiki. Some of them can be found here: I have issues drawing the polygonal body’s too. If TLL could add basic functionality for that, that would be awesome. You’ll have to draw a line from point to point.

Thanks Zoyt, I have just realised that by looking at the PhysicsDebugDraw Class… Ok, now I am starting to see what is going on, Physics only simulate and you need to paint yourself what is being modelled… Makes sense. But Filling a POLYGON, can’t see that right now, or you would need some very fancy shape analysis to break it down to primitive shapes… mmh…
The link you give is lua only it seems, I was hoping to get the Codea implementation API for Love2D, as code completion doesn’t do it, it is all a bit of a guess, or am I missing something?

For filling the polygon, I’m guessing the key is mesh. I don’t know much about mesh though. The link I gave you was to list the rest of the undocumented Lua-only functions. I’m assuming you know about the in all documentation that shows when you press the eye. There’s a web version on wiki that’s the exact same thing, but in to versions - a web kit needy versions that’s found in the app and an old, no webkit needed version. Hope that helps a little. I agree, the docs aren’t too well documented.