Results 1 to 4 of 4

Thread: Simple down-scrolling code needed!

                  
   
  1. #1

  2. #2
    PSP Coder -Xandu-'s Avatar
    Join Date
    Jan 2007
    Posts
    1,036
    Rep Power
    79

    Default

    You can do:

    img = {}
    img = {x = 200, y = 20, img = YOURIMAGE }


    then,

    if Controls.read():down then
    img.y = img.y +2
    end

    if Controls.read():up then
    img.y = img.y -2
    end

    screen:blit(img.x,img.y,img.img)

  3. #3
    DCEmu Coder Freshmilk's Avatar
    Join Date
    Jul 2006
    Location
    Manchester, UK
    Age
    31
    Posts
    95
    Rep Power
    0

    Default

    Ummm, i'm gussing its a full screen image, xandu. Why blit it at 200 on the x axis...?
    Meh... either way, that would work.

  4. #4
    PSP Coder -Xandu-'s Avatar
    Join Date
    Jan 2007
    Posts
    1,036
    Rep Power
    79

    Default

    It was just an example plus, it's not hard to change the values you know .

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •