Help on scripting languages

Sean Wilson snw at paradise.net.nz
Thu Oct 7 14:27:44 CDT 2004


>I'm still not certain that we are discussing the same concept.

More and more I'm thinking we are :-)

>In Revolution one inserts a front script into the message heirachy using the
>command  "insert script of <objectSpecification> into front". The inserted
>script has its own keyDownScript which can stop/pass the event.
>
>The point is that all messages are sent to the inserted object *before* they
>are passed to the normal target and then up the message heirachy if passed.
>
>I cannot see any equivalent to the insert command. I am very new to Director
>and wonder if you could detail exactly how one goes about setting up a front
>object that varies the normal event entry point and so gets first crack at
>all events.

I would tend to use a prepareMovie handler to set up a key filter. 
Something like:
on prepareMovie
   the keyDownScript = "mFilterKeys"
end


on mFilterKeys
   case(the key) of
     -- example filtered key
     -- perhaps safer to use the keyCode here, but:
     "a": stopEvent
     otherwise: pass
   end case
end

I'm quite happy to discuss Director's methods etc. but as this is 
potentially not of interest to anyone else we should perhaps take it off-list.

Cheers,
-Sean. 




More information about the Valentina mailing list