Move to vs AEMoveTo?

Create fast, sprite powered games with Animation Engine, co-developed with DerBrill Software!

Moderators: heatherlaine, kevinmiller, robinmiller, malte

Post Reply
jpatten
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 45
Joined: Tue May 06, 2008 11:24 pm

Move to vs AEMoveTo?

Post by jpatten » Sat Oct 05, 2013 5:13 pm

Attempting to get AE to work in the iOS simulator with these two scripts:

move group "notepad" from 568,451 to 568,783

and

aeMoveTo group "notepad",568,783,1000,"inOut"

The top one works fine. The bottom one (aeMoveTo) does not. I have the box checked on the AE stack to use it. What am I missing here? Does AE have to be added in standalone settings for iOS? Or...?

Thank you!

malte
Posts: 1098
Joined: Thu Feb 23, 2006 8:34 pm
Location: Ostenfeld germany
Contact:

Re: Move to vs AEMoveTo?

Post by malte » Sat Oct 05, 2013 10:13 pm

Hi John,

AE needs to be present. So Either add it as a substack to your mainstack, or put it in copy files. In your mainstack, at some point you will need to

Code: Select all

start using stack "animationEngine"
Savest bet is to have AE as a substack. Open the messagebox and type:

Code: Select all

set the mainStack of stack "animationEngine" to "nameOfYourStackGoesHere"
And have the start using part in the openStack handler of your stack.

To check if it is really there, have a button with this script:

Code: Select all

on mouseUp
  answer the stacksInUse
end mouseUp
Hope this helps,

Malte

jpatten
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 45
Joined: Tue May 06, 2008 11:24 pm

Re: Move to vs AEMoveTo?

Post by jpatten » Sun Oct 06, 2013 5:05 am

Thanks Malte...

Still having some trouble getting this to work. It seems it should be pretty straight forward but I must be missing something.

I went ahead and changed the script to match as close to the examples in the doc as I could:

aeMoveTo group "notepad", the loc of grc id 1020, 1000, "inOut"

This does not work from a button on the card. This will not work in the simulator. I have a button that checks to see if AnimationEngine is running (as you suggested.) It reports that it is running.

The only way it works is if I put the script in the message box. Then it works as it should and the "notepad" group moves.

Thanks for any ideas!

Oh...the error it reports in the button activated attempt is:
button "Button": execution error at line 2 (Chunk: source is not a container), char 2

jpatten
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 45
Joined: Tue May 06, 2008 11:24 pm

Re: Move to vs AEMoveTo?

Post by jpatten » Sun Oct 06, 2013 5:59 am

SOLVED...

Discovered going through the lists I needed to reference the group with its long ID. So instead of writing this:

aeMoveTo group "notepad", the loc of grc id 1020, 1000, "inOut"

I had to write this:

aeMoveTo the long id of group "notepad", the loc of grc id 1020, 1000, "inOut"

Cheers!

Post Reply

Return to “Animation Engine”