How to put a image in your app/game? - help

People say to draw do this coding… variablename:draw(). But nothing shows up between the () do I have to put the image coding in between this () if you know what I mean please help

Sorry to confuse you. This is much more complicated coding stuff. Let me reexplain myself:

  1. Create a class.
  2. Inside you will see a className:init() (get rid of the x inside the parenthesis), className:draw(), and className:touch().
  3. Imaging this as its own program. It has a draw loop, initial setup loop, and a touched loop, but they have to manually be called.
  4. If you want a lot of these classes, set a variable to them, therefore duplicating them. So if you say variablename = className:init() you create a duplicate of the class. Then you can tell the class duplicate to draw like this: variablename:draw()
  5. You don’t need to pass in functions to these classes, but it’s best if you do.
  6. To draw an image, it’s as simple as saying sprite(spritename). Tap on the blue part to choose from the built in sprite packs. In 1.4, we’re getting sprite pack management, so we’ll get custom images without hacking.
    Hope that helps! That might be more info than needed or possibly too complicated with beginners. If the link wasn’t broken, I’d send you to the classes tutorial on Wiki.
    Thanks!

Look at the example projects - it should make more sense with working code.

If i have a photo in my iPad,is it possible draw it in a program?

Just wait for 1.4… Something big awaits us all… There is a custom sprite pack hack you can use for now… If you want more info, LMK.

In 1.4 beta, you can simply import photos from your photo roll to a spritepack. You can also cut/paste them in, say from Safari. I don’t know when Apple will approve it, or if it’s even been submitted yet, but this is coming.