Showing different images when moving?

Creating Games? Developing something for fun?

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

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

Re: Showing different images when moving?

Post by bogs » Sun Nov 05, 2017 10:22 pm

ROACH !!!!
Image

qqchrono
Posts: 13
Joined: Tue Oct 24, 2017 3:27 am

Re: Showing different images when moving?

Post by qqchrono » Thu Nov 16, 2017 9:27 am

Hi all!

Thanks for the replies. There's definitely a lot of new valuable information posted here since the last time i checked. Unfortunately I'm still tied up with work and haven't gotten the time to work on this but i do check on this thread occasionally in hopes there might be suggestions for improvement which they are :D

qqchrono
Posts: 13
Joined: Tue Oct 24, 2017 3:27 am

Re: Showing different images when moving?

Post by qqchrono » Thu Nov 16, 2017 9:43 am

Slightly changed stack is attached.
Hi Jim,

The stack you attached works and looks way smoother than mine thanks :lol:
I tested it out and after i held down an arrow key for a period of time let's say around 2 seconds? It starts to flicker between the arrow and the circle and is stuck in the same spot. Was that supposed to happen or is it just me? Don't get me wrong, its a great help and is far superior to my coding. Just wondering if the flickering is an issue on my side.

Cheers
Chrono

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

Re: Showing different images when moving?

Post by bogs » Thu Nov 16, 2017 2:58 pm

qqchrono wrote:
Thu Nov 16, 2017 9:43 am
I tested it out and after i held down an arrow key for a period of time let's say around 2 seconds?...Just wondering if the flickering is an issue on my side.
It probably is not supposed to happen, and it is not just on your machine (happened on my machine as well, linux box).
Image

qqchrono
Posts: 13
Joined: Tue Oct 24, 2017 3:27 am

Re: Showing different images when moving?

Post by qqchrono » Fri Nov 17, 2017 3:03 am

bogs wrote:
Thu Nov 16, 2017 2:58 pm

It probably is not supposed to happen, and it is not just on your machine (happened on my machine as well, linux box).
Hmmm... Is anyone else having the same problem? I'm currently using version 9.0 livecode.

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

Re: Showing different images when moving?

Post by bogs » Fri Nov 17, 2017 4:39 am

Erm well, heh, I ah, don't really use anything newer than 6.5 regularly, and usually I am poking around in things much older than that :P
Image

jiml
Posts: 336
Joined: Sat Dec 09, 2006 1:27 am
Location: Los Angeles

Re: Showing different images when moving?

Post by jiml » Thu Dec 07, 2017 12:58 am

Hi Chrono,

No there is no flickering or sticking here on any version of LC on a Mac.
Perhaps your issues are not LC but OS related.

JimL

jiml
Posts: 336
Joined: Sat Dec 09, 2006 1:27 am
Location: Los Angeles

Re: Showing different images when moving?

Post by jiml » Mon Dec 18, 2017 11:56 pm

Hi All,

This thread has led me to create a behavior and example stack for making cel animation easy in LC.
Here it is:
http://livecodeshare.runrev.com/stack/857/Cel-Animation

Enjoy!

Jim Lambert

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

Re: Showing different images when moving?

Post by bogs » Tue Dec 19, 2017 12:02 am

All I can say is WOW :shock:
Image

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9801
Joined: Sat Apr 08, 2006 7:05 am
Location: Los Angeles
Contact:

Re: Showing different images when moving?

Post by FourthWorld » Tue Dec 19, 2017 12:05 am

Nicely done, Jim!
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

jiml
Posts: 336
Joined: Sat Dec 09, 2006 1:27 am
Location: Los Angeles

Re: Showing different images when moving?

Post by jiml » Tue Dec 19, 2017 1:42 am

Bogs & Richard,

Thanks :D

JimL

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

Re: Showing different images when moving?

Post by bogs » Tue Dec 19, 2017 6:09 am

To get a real treat as your watching Jim's work, after you set the last dispatch command ( I used 120 instead of 80 ), and hit [Start], you see the cat start a nice leisurely trot. Without changing anything, hit [Start] again, and after a few seconds again.

That is one cat that can really MOVE :twisted:
Image

jiml
Posts: 336
Joined: Sat Dec 09, 2006 1:27 am
Location: Los Angeles

Re: Showing different images when moving?

Post by jiml » Tue Dec 19, 2017 6:52 am

Bogs,

That's very cool. You've discovered a second way to speed up the animation.
Each time you click START you add additional animateMe's to pendingmessages. Neat!

But I think that speed won't survive leaving the card. The leisurely 120 speed will be restored on return to the card and INITing, since that value is stored by SETUP.
A more persistent way to speed up would be retimeMe which saves the changed timing value.

Code: Select all

dispatch "retimeme" to the selobj with 0
Is blistering too.

JimL

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

Re: Showing different images when moving?

Post by bogs » Tue Dec 19, 2017 7:29 am

Yuppers, noticed that on the first run through, just thought the effect of going from slower to faster hitting start was like releasing a power stroke. As I said initially, WOW :shock: really elegant way to handle it.
Image

Post Reply

Return to “Games”