Setting paths to Externals
Sivakatirswami
katir at hindu.org
Fri Nov 23 22:31:37 EST 2007
OK I think I've wasted about 3 hours on this and
am finally throwing in the towel...(smile)
I'm trying to get Andre's Kiosk external loaded with my stand alone.
a) I don't see how to tell the Standalone builder to copy any externals
in use from the "My Revolution Enterprise" folder to the stand alone...
I want to select Rev Browser for possible later use, so I am unable to
check the box for the standalone builder to get the externals in use by
the stack automatically. If I
have the libkiosk.bundle in "My Revolution Enterprise/Externals/" it
works fine...
b) I tried everything "under the sun" to load an external by script. but
I'm doing something wrong
besides. I don't see how you can dynamically load an external anyway,
since the docs state you have stop and restart your application. But if
you are loading them by script in a preopenstack or open stack handler,
then how will you ever activate them?
c) then there is the issue of : you ask the stand alone builder to
set-copy some externals and then you are setting the externals by
script... how does that work?
A "Best Practices" video on "Working with Externals in Revolution" would
be most welcome!
I'm missing something fundamental, as all the paths look right now --
having solved the for movies
I know for sure the paths are correct for the location of the externals
--> all handlers
local tPath
ON preopenstack
set the rect of this stack to (the screenrect)
set the loc of this stack to the screenloc
END preopenstack
ON openstack
set the itemdel to "/"
put (the filename of this stack) into tPath
put environment() into tEnvirons
IF tEnvirons = "standalone application" THEN
answer "yes a standalone" WITH "OK"
delete item -4 to -1 of tPath #crawl back out of the OS X package
ELSE
delete item -1 of tPath
END IF
loadMovies tPath
loadExternals tPath
runMovies
send loadGuestRecords to this stack in 1 second
END openstack
ON loadMovies tPath # Hurray! this works now
set the filename of player 2 to url (tPath & "/media/tandava take
3.mov")
set the filename of player 1 to url (tPath &
"/media/aadheenam_2007-02-06_sm-vision-puja.mov")
END loadMovies
ON loadExternals tPath # Boo Hoo... this is not working
# where the external is in a folder adjacent to the standalone
# and not inside the standalone bundle
put "/plug-ins/libkiosk.bundle/Contents/MacOS/libkiosk" after tPath #
doesnt' work
--put "/plug-ins/libkiosk" after tPath # also doesn't work
answer tPath WITH "OK"
set the externals of this stack to tPath
END loadExternals
# Any attempt to call functions in the external give a script error
# And I wonder how things play out if you are tell Revolution to
# include externals when running the Standalone builder and the
# setting them yourself by script... won't they conflict?
ON runMovies
set the playloudness of player "Player1" to 0
start player "player1"
set the playrate of player "player2" to fld "tandavaRate"
start player "player2"
END runMovies
More information about the use-livecode
mailing list