Play All 3 - just three scripts to play all!
A new tutorial has been added to the site which looks at how you can use just three scripts to cover any number of tracks and stories in your project and make sure you get a reliable ‘play all’ situation.
This is very different from the earlier scripted example, which uses a script for every track to sort out the end jump and allows you to use the exact track names in your project. This is excellent for when you want a simple system that is easy to follow and does what you expect. However, if you are ready to move on with your scripting, this tutorial introduces you to using item values from your project. The advantage is that you don’t need to worry about track names, you can add as many tracks as you like and it will still work with no additional lines of code needed. You *do* need to edit a line in each script, but that’s a very small job!
Have a look here:
Advanced Scripting Techniques, Random Playback Scripts
A new tutorial exploring the use of advanced scripting techniques has been created, which uses bit based techniques to generate a random number and jump to a track or story. It checks to see if the track or story has been played before and if so generates a new random number.
The tutorial is theoretical, and doesn’t have a set of files to download yet, but looks at how to track up to 40 tracks/stories. This means that the tracking has to use 40 bit slots, or two and a half registers, leaving the remainder for calculations. This is more than enough, and in fact twice the number of clips could be tracked using this technique.
As it is only theoretical, there may be some flaws in the scripts, but it is offered as a starting point for experimentation and discussion. It uses fairly basic maths for the most part, but makes use of the ‘AND’ operator to compare two GPRMs. Previously, the ‘and’ has been used almost exclusively on this site to mask off different sets of bits.
The tutorial can be found here:
http://www.dvdstudiopro.co.uk/scripting-advanced-random-playback/
Simple Non-Repeat Quiz
More and more frequently we are being asked to help with making quizzes and other features to complement the DVD material. Sometimes this is a simple quiz where a number of questions arrive on screen and can be answered by any viewer, and sometimes they are far more complex with all kinds of game-play aspects to include.
Our advice is that you need to keep in mind the limitations of DVDs for this kind of thing. Whilst you can make superb quizzes, you are restricted by the number of memory slots as to how extensive the question selection and scoring can be. Trying to recreate a four player or team quiz complete with scoring and taking turns is a pretty complex task. Equally, having loads of questions in the quiz makes tracking what has been asked all the more difficult.
However, plenty of very simple quiz games can be made and the following link will download an ultra simple non-repeating quiz with just five questions. The idea is that you see what is involved in making the quiz rather than take it and use it as a template for a bigger game. Random question selection and tracking can be done in several ways, not only the way it is done here, for example. You may need more scripts of better structures if your quiz is reasonably complex.
Have a look at the project files in the zip archive here.
Item Values
In DVDSP the items that you create when authoring your project, such as tracks and menus, all have an in-built numerical value. This can be useful if you are trying to create a framework for a project that will use different assets each time you use it. Using the values helps you keep scripts pointing at the right asset and end jumps relevant, even when you replace the tracks, etc. It isn’t foolproof, but it can be useful.
The tutorial page helps explain how the item values can be ’seen’ using a combination of scripts and then it is up to you how you use the information.
Simple Random Playback
Randomising playback is one of those things that really ought to be easier than it is in DVD Studio Pro. Often you want to provide a quick way to offer random playback capabilities to your client, but it involves all sorts of difficulties - not least of which is preventing repeats.
In the DVD Spec, and with spec level authoring systems, you can set PGCs to be non repeating and random. In DVDSP, you can’t. Shame!
Instead of spending hours writing scripts, you could instead use stories and a simple script if you only want to randomise a low number of clips. You can read all about that in this article.
