Page 1 of 2 12 LastLast
Results 1 to 10 of 11

Thread: Animation HELP

                  
   
  1. #1

    Default Animation HELP

    Im trying to make like a animation.
    Pretty much like
    Trying to send
    A L across the screen
    then a U across the screen
    then a A across the screen
    and have them all meet to form
    LUA
    What code would I use

  2. #2
    GP2X Coder/Moderator
    Join Date
    Jan 2006
    Posts
    1,678
    Rep Power
    87

    Default

    Clue: a series of 3 while loops

  3. #3
    PS3 User Gizmo356's Avatar
    Join Date
    Feb 2006
    Age
    33
    Posts
    1,756
    Rep Power
    124

    Default

    O_o

  4. #4
    DCEmu Coder MasterChafed's Avatar
    Join Date
    Jul 2005
    Location
    Colorado
    Age
    34
    Posts
    832
    Rep Power
    94

    Default

    or a series of if statements
    http://one.revver.com/watch/170516
    http://one.revver.com/watch/167200

    Please click the links above to watch my stick figure animations,
    and please, if you have the time, click the ads at the end to earn me some money.

  5. #5
    PS3 User Gizmo356's Avatar
    Join Date
    Feb 2006
    Age
    33
    Posts
    1,756
    Rep Power
    124

    Default

    double O_o

  6. #6

  7. #7
    PS3 User Gizmo356's Avatar
    Join Date
    Feb 2006
    Age
    33
    Posts
    1,756
    Rep Power
    124

    Default

    lol

  8. #8
    GP2X Coder/Moderator
    Join Date
    Jan 2006
    Posts
    1,678
    Rep Power
    87

    Default

    Quote Originally Posted by MasterChafed
    or a series of if statements
    Ouch.. that will be one REALLY long script if you did it that way.

  9. #9
    DCEmu Pro jman420's Avatar
    Join Date
    Oct 2005
    Location
    Colorado, USA
    Posts
    756
    Rep Power
    76

    Default

    here's the simplest way I can think to do it..

    white = Color.new(255,255,255)

    -- L starting placement --

    lx = 0

    -- U starting placement --

    uy = 0

    -- A starting placement --

    ax = 480

    -- main loop --

    while true do

    -- if L's X placement is less then 236, raise untill 236 --

    if lx <= 236 then
    lx = lx +1 end

    -- if U's Y placement is less then 130 raise untill 130 --

    if uy <=130 then
    uy = uy +1 end

    -- if A's X placement is greater then 260, decrese untill 260 --

    if ax >= 260 then
    ax = ax -1 end

    -- print L using the lx placement to assign its X render to use the variable --

    screenrint(lx,130,"L",white)

    -- U used a Y axis assignment forcing the final track to be from the top of the screen down --

    screenrint(240,uy,"U",white)

    -- and A came from the left side of the screen, so use A's X placement --

    screenrint(ax,130,"A",white

    flip.screen()
    screen.waitVblankStart()

    -- if animation complete. wait 30 frames and break program --

    if ax >=260 then
    screen.waitVblankStart(30)
    break end

    -- also you could change from break to

    screen:clear()
    do file("other program.lua")

    afterwards to change to another program after the animation --

    end

    that would basicly tell the whole thing how to animate to the given positions

    P.S. used If statements, and its accualy realy short code

  10. #10
    DCEmu Coder MasterChafed's Avatar
    Join Date
    Jul 2005
    Location
    Colorado
    Age
    34
    Posts
    832
    Rep Power
    94

    Default

    Quote Originally Posted by yaustar
    Ouch.. that will be one REALLY long script if you did it that way.
    lol, i know, but i eat and breathe if statements. :P
    http://one.revver.com/watch/170516
    http://one.revver.com/watch/167200

    Please click the links above to watch my stick figure animations,
    and please, if you have the time, click the ads at the end to earn me some money.

Page 1 of 2 12 LastLast

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
  •