Animation & blendLevel

Teaching software development? Using LiveCode to build your curriculum? This is the forum for you.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9251
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Animation & blendLevel

Post by richmond62 » Thu Apr 12, 2018 10:28 pm

Well, you know how it goes: a glass of dark beer, a cup of coffee . . .
RUNNING.jpg
This is fairly simplistic stuff, but it might get some kids' digestive juices flowing. 8)

The code is in the cardScript: play with the Right and Left Arrow Keys to see the fun.

Updated version available below.
Last edited by richmond62 on Fri Apr 13, 2018 6:27 pm, edited 1 time in total.

bogs
Posts: 5435
Joined: Sat Feb 25, 2017 10:45 pm

Re: Animation & blendLevel

Post by bogs » Fri Apr 13, 2018 5:59 am

Nice, but I think the keyboard repeat build up needs to be limited a bit :)
Image

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9251
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: Animation & blendLevel

Post by richmond62 » Fri Apr 13, 2018 10:55 am

the keyboard repeat build up
There IS a way to limit that, but, for the life of me, I can't remember how to do that.

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9251
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: Animation & blendLevel

Post by richmond62 » Fri Apr 13, 2018 6:28 pm

put flushEvents("keyDown") into temp
put flushEvents("keyUp") into temp
Version with flushEvents implemented.

https://www.dropbox.com/s/uyiagfq9peifo ... e.zip?dl=0
twitchy.png
twitchy.png (7.34 KiB) Viewed 8702 times
use flushEvents to prevent the animation going into overdrive,
because you are "going bonkers" and bashing the arrowKeys as if your life depends on that.
flush.png
Last edited by richmond62 on Fri Apr 13, 2018 7:33 pm, edited 1 time in total.

bogs
Posts: 5435
Joined: Sat Feb 25, 2017 10:45 pm

Re: Animation & blendLevel

Post by bogs » Fri Apr 13, 2018 7:23 pm

richmond62 wrote:
Fri Apr 13, 2018 6:28 pm
use flushEvents to prevent the animation going into overdrive,
Heh, should have thought of that one myself :twisted:
Selection_003.png
FlushEvents !!
Image

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9251
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: Animation & blendLevel

Post by richmond62 » Fri Apr 13, 2018 7:32 pm

Selection_003.png

bogs
Posts: 5435
Joined: Sat Feb 25, 2017 10:45 pm

Re: Animation & blendLevel

Post by bogs » Fri Apr 13, 2018 7:35 pm

Bwahahaha :mrgreen:
Image

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9251
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: Animation & blendLevel

Post by richmond62 » Fri Apr 13, 2018 7:43 pm

Lovely, lovely, FREE imagery for games here:

https://craftpix.net

bogs
Posts: 5435
Joined: Sat Feb 25, 2017 10:45 pm

Re: Animation & blendLevel

Post by bogs » Fri Apr 13, 2018 9:29 pm

That is pretty neat.
Image

Post Reply

Return to “Teaching with LiveCode”