Solved

LINGO in Mac Director6.5

Posted on 1998-10-06
6
617 Views
Last Modified: 2012-06-21
Hello,
I am hoping to have someone help me with lingo scripting.

What I have is a director movie containing two digital videos (Quicktime3) in which the first video starts playing while other animation is running at the same time and on my command(by a keypress) the second video will start to play in place of the first.

My problem is this: I have my lingo written in the frame script like this:

on exitframe
   go to the frame
    -- which will keep my first video looping
  if the keypressed = RETURN then go loop
    -- in using keypress, it will let me keep looping in
       the first video until I press a
       key function (RETURN) which then goes to my next
       marker(2nd video)
end

All I want to do is change the keypressed = RETURN to keypressed = SPACEBAR. Instead of pressing the return key to activate my second video, I would prefer to press the spacebar. I have tried KeyCode(49), I have tried the numToChar(32), I have tried KeyDown, keyUp, etc.

If anyone has any suggestions in how to write this lingo script, it would be greatly appreciated.
Thank you very much
Julie
             
0
Comment
Question by:juliuscrassus
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
6 Comments
 
LVL 1

Expert Comment

by:yaelie
ID: 1540074
The KeyCode shoudl work...are you sure the number is 49 though?! according to a book I have that is the wrong number...I might be mistaken, but I would double check it if I were you.
0
 
LVL 3

Accepted Solution

by:
Raydot earned 70 total points
ID: 1540075


Try: "if the keyPressed = SPACE then," and not SPACEBAR.

Also, you shouldn't have all of this code crammed in AFTER the "go to the frame" command.  What you could end up doing is creating a situation where this code is still executing even though the playback head has moved on.

Last, but not least, I'd suggest you look into using the "KeyDownScript."

Something like this:

on enterframe
   set the KEYDOWNSCRIPT = "movieControl"
end

on exitFrame
   go to the frame
end

Then in another movie script somewhere:

on movieControl
  if the key = SPACE then
     go frame "loop"   -- go to frame where second movie is
     set the keydownscript = EMPTY  -- e.g. condition has been fulfilled, we don't need this script any more
  end if
end movieControl

Good luck!  Let me know if I can help you with anything else...

Raydot.
0
 

Author Comment

by:juliuscrassus
ID: 1540076
The keyCode is in fact, 49. Please check your book, again I am working on the Mac, maybe for Windows it is different.
Definitely keyCode = 49
Thanks anyways
0
Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 

Author Comment

by:juliuscrassus
ID: 1540077
Raydot,

I have found an easier solution while waiting for your answer.Thanks for all your help. Just to let you know: "If the keyPressed = SPACE" doesn't work either.Thanks!
0
 
LVL 3

Expert Comment

by:Raydot
ID: 1540078
I actually tested "if the keyPressed = SPACE" before I sent it to you.  You found another solution, you said...it's not really easy handling Digital Video in Director.  I know what the manuals say, but I've been working with this application for 3 years, and it's never just something simple...

Have you ever checked out the Direct-L or Lingo-L mailing lists?  They're great resources for people with director questions...

Raydot.
0
 

Author Comment

by:juliuscrassus
ID: 1540079
How do I get in contact with these mailing lists? Thanks for this reference. Also, I really did try "if the keyPressed = SPACE" again and still doesn't work. But, "keyCode = 49" does work anyways. Thanks for all you help.

Julie.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
First crummy OS for the iPhone 3 65
Save Excel documents to PDF and RETAIN color 16 542
Apple licensing for business 3 83
apple id without bloatware 4 96
Hi Folks, This article is intended to throw some light or basically give an idea towards taking the first step in the world of Systems Administration. This would in the real context of the word "Systems Administration" which would mean right from…
Steve Jobs once said that Blu-ray is "a bag of hurt". As Macs users well known, things haven’t settled down (at least not from Apple’s perspective). Several years after that comment, Mac OS X still doesn’t support Blu-ray playback, nor has any Mac s…
Users will learn how to set proper sequence settings, scale images, paste attributes, add transitions, fades, and music. Open up Final Cut Pro 7 and Create a new Project: Set the Sequence Settings. a) Click File > Easy Setup > Format > Apple ProRe…
CodeTwo Sync for iCloud (http://www.codetwo.com/sync-for-icloud?sts=6554) automatically synchronizes your Outlook 2016, 2013, 2010 or 2007 folders with iCloud folders available via iCloud Control Panel. This lets you automatically sync them with…

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question