Author Topic: Animations  (Read 9807 times)

0 Members and 1 Guest are viewing this topic.

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Animations
« on: October 29, 2010, 02:45:50 pm »
I've been playing around with animations and I've done a few interesting things, for now, I'll post a simple animation.

I've made a few more complex and fun, but can't upload them at the moment.

The GIF made in WabbitEmu doesn't look very fast, but it is fast and optimized, is there any trick to save faster GIFs?

Close all problems? Change settings?

Thanks, please tell me what you think. I think these could be used somewhere in a program, but anyways it's for practice mostly.

Offline MRide

  • LV8 Addict (Next: 1000)
  • ********
  • Posts: 711
  • Rating: +14/-0
  • You can't see this.
    • View Profile
Re: Animations
« Reply #1 on: October 29, 2010, 02:55:47 pm »
Looks cool! Is it supposed to move up and down or just side to side?

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: Animations
« Reply #2 on: October 29, 2010, 03:12:05 pm »
Looks cool! Is it supposed to move up and down or just side to side?

It gives the idea it is moving down, but it isn't, check why:

Code: [Select]
:ClrHome
:For(A,1,100
:Disp ".
:Disp " .
:Disp "  .
:Disp "   .
:Disp "    .
:Disp "     .
:Disp "      .
:Disp "       .
:Disp "        .
:Disp "         .
:Disp "        .
:Disp "       .
:Disp "      .
:Disp "     .
:Disp "    .
:Disp "   .
:Disp "  .
:Disp " .
:End

Offline MRide

  • LV8 Addict (Next: 1000)
  • ********
  • Posts: 711
  • Rating: +14/-0
  • You can't see this.
    • View Profile
Re: Animations
« Reply #3 on: October 29, 2010, 03:13:20 pm »
Well, I mean, when it moves to the left, it drops down a sprite.  Is that intentional? 

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: Animations
« Reply #4 on: October 29, 2010, 03:16:23 pm »
Well, I mean, when it moves to the left, it drops down a sprite.  Is that intentional? 

Does it?

There are two:
Code: [Select]
:Disp ".
:Disp ".

That is intentional, is that what you mean?

Offline MRide

  • LV8 Addict (Next: 1000)
  • ********
  • Posts: 711
  • Rating: +14/-0
  • You can't see this.
    • View Profile
Re: Animations
« Reply #5 on: October 29, 2010, 03:18:26 pm »
Ah, yeah, that's just because of Disp.
Nice effect.  It's not easy to get good animations in BASIC.

Offline Deep Toaster

  • So much to do, so much time, so little motivation
  • Administrator
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 8217
  • Rating: +758/-15
    • View Profile
    • ClrHome
Re: Animations
« Reply #6 on: October 29, 2010, 03:31:59 pm »
The GIF made in WabbitEmu doesn't look very fast, but it is fast and optimized, is there any trick to save faster GIFs?

Close all problems? Change settings?

Yep, just change the Framerate setting to 9 or something. That way, it'll look better in certain browsers.
« Last Edit: October 29, 2010, 07:30:26 pm by Deep Thought »




Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: Animations
« Reply #7 on: October 29, 2010, 03:47:20 pm »
A wave animation, I'll do a sea wave animation right away hahah.

Then, I'm gonna do a virus-like animation, which will be quite hard.

How can I do something like this:

Output(1,1,".

Then, wait a second or two and

Output(1,2,".

A second or two and

Output(1,3,".

Have no idea, th0ugh. Thanks :)

Offline squidgetx

  • Food.
  • CoT Emeritus
  • LV10 31337 u53r (Next: 2000)
  • *
  • Posts: 1881
  • Rating: +503/-17
  • rawr.
    • View Profile
Re: Animations
« Reply #8 on: October 29, 2010, 03:53:03 pm »
Put a For(A,0, somenumber): End where you want to pause. For 1 or two seconds I think try like 100 or 200 for somenumber (I forget exactly)

Offline JosJuice

  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1344
  • Rating: +66/-14
    • View Profile
Re: Animations
« Reply #9 on: October 29, 2010, 03:53:29 pm »
How can I do something like this:

Output(1,1,".

Then, wait a second or two and

Output(1,2,".

A second or two and

Output(1,3,".
If you want to make the program wait a bit, use something like rand(100 to waste processing time.

Offline ztrumpet

  • The Rarely Active One
  • CoT Emeritus
  • LV13 Extreme Addict (Next: 9001)
  • *
  • Posts: 5712
  • Rating: +364/-4
  • If you see this, send me a PM. Just for fun.
    • View Profile
Re: Animations
« Reply #10 on: October 29, 2010, 03:56:38 pm »
It gives the idea it is moving down, but it isn't, check why:

Code: [Select]
:ClrHome
:For(A,1,100
:Disp ".
:Disp " .
:Disp "  .
:Disp "   .
:Disp "    .
:Disp "     .
:Disp "      .
:Disp "       .
:Disp "        .
:Disp "         .
:Disp "        .
:Disp "       .
:Disp "      .
:Disp "     .
:Disp "    .
:Disp "   .
:Disp "  .
:Disp " .
:End
Nice effect. :)

Here's my code for the same effect:
Code: [Select]
:ClrHome
:For(A,1,7
:Disp " // Nothing after the quote
:End
:1->A // Current X position
:1->B // Variable to track movement
:Repeat getKey
:Disp " // Again, nothing after the quote
:Output(8,A,".
:A+B->A
:If Ans=10 or Ans=1
:-B->B // That's the negative sign, not minus
:End

What do you think of my code? :)

Nice animation; great job for just starting basic! ;D
« Last Edit: October 29, 2010, 03:57:31 pm by ztrumpet »

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: Animations
« Reply #11 on: October 29, 2010, 03:59:25 pm »
That gave me a syntax error, though, can't tell which line for now, WabbitEmu.

Offline ztrumpet

  • The Rarely Active One
  • CoT Emeritus
  • LV13 Extreme Addict (Next: 9001)
  • *
  • Posts: 5712
  • Rating: +364/-4
  • If you see this, send me a PM. Just for fun.
    • View Profile
Re: Animations
« Reply #12 on: October 29, 2010, 04:00:58 pm »
Hmm, I just typed it to makes sure it would work.  Did you type the "//" and everything after them?  Those are comments and they're not meant to be typed in the code. :)

Offline squidgetx

  • Food.
  • CoT Emeritus
  • LV10 31337 u53r (Next: 2000)
  • *
  • Posts: 1881
  • Rating: +503/-17
  • rawr.
    • View Profile
Re: Animations
« Reply #13 on: October 29, 2010, 04:01:28 pm »
Don't type in the // and the stuff after it; those are his comments

...ninja'd
« Last Edit: October 29, 2010, 04:01:48 pm by squidgetx »

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: Animations
« Reply #14 on: October 29, 2010, 04:02:08 pm »
Hmm, I just typed it to makes sure it would work.  Did you type the "//" and everything after them?  Those are comments and they're not meant to be typed in the code. :)

Of course I removed the //, I'm not that stupid :S