DM2107: Scripting Interaction

Essential Readings


Recommended Books

Recommended Links

  • week 1
  • w 2
  • w 3
  • w 4
  • w 5
  • w 6
  • w 7
  • w 8
  • w 9
  • w 10
  • w 11
  • w 12

Introduction to the module. Clarifying the assignments.

 

A warm up:

Template

FlowerDemo

Inroduction to event-driven scripting: Events, Messages and Handlers:

Powerpoint Presentation

Demo1

Demo2

Demo3

w2-Template

Class tasks:

task1

task2

task3

 

This week we look at the use of variables.

w3_template

task1

task2

task3

task4

task5

task6

 

Today we look at how to use IF ... THEN... to make decisions. We also look at how to create new Properties for sprites.

 

W4_template

 

task1, task2, task3, task4, task5, task6, task7

 

 

In this session we work on your ideas and your designs. We try to find out how to put ideas into practice in Director.

 

The example below shows how you can use one graphic, with transparent background, for your walls and obstacles. Please download it and study it.

 

Transparent_wall_collision

 

Use this director movie to find the key codes

 

keyCode.dir

We work on the assignment in class and push it forward.

 

For some scripts that can help you with your project download and save this file.

try it and see if you can make it work for you.

 

You can see how it works in this director movie.

We improve the work you have done by further working on it in class. I sit with you individually and deal with any problems.

user defined handlers:

 

sample 1

sample 2

sample 3

 

Lists:

 

sample 1

sample 2

 

lingo list commands

Teacher guided workshop.

 

Looking at using MIAW

 

Put both movies in the same folder:

Main Movie

Message Movie

Projector

Teacher guided workshop.

 

Looking at using time and timer.

 

Sample Movie

Content 11

Here is an example of using Movie in a Window (MIAW) for giving messages to your users. You can create all your messages in a separate movie (here called "message") and then use MIAW to communicate with it. In the example I have given you here the message movie has 3 separate messages, each under a different marker.

 

Examine the script in the buttons, both in the main movie and in the message window to see how communication is controlled between the main movie and the MIAW. Message 3 communicates with the main movie.

 

Make sure both movies are in the same directory

 

mainMovie

message