SL Cert - Basic Scripting

From Second Life Wiki
Revision as of 11:40, 12 February 2009 by Louise Rumpler (Talk | contribs)

Jump to: navigation, search

Rationale for scripting Demonstrate an understanding of what scripts are, their limitations and why they are used in second life.

Script creation Show ability to create scripts in both primitives and inventory. Be able to transfer one to the other, set them to running or not and set relevant permissions for them.

Commenting and Clarity Understand the benefits of keeping code legible, using the same style of writing throughout and commenting code where necessary.

Variables, Types and Constants Be able to recognise differant types of variable and how they can be used to store different types of information. Understand that constants are in essence a "fixed" variable.

Functions and Parameters Recognise functions from their 'll' format and be able to explain why there is a necessity for so many different functions. Understand what a parameter is and why some functions do not need them yet still require brackets.

States Understand what a state is and be able to explain why the default state is compulsory. Recognise that a script program essentially has no ending.

Events Understand what events are and how they can be used to capture input. Demonstrate this by scripting an object that says "I was clicked by (avatars name)" in public chat when touched.

Global and Local Variables Recognise the difference between the two and why using a naming system can be helpful to avoid confusion as script complexity grows.

Typecasting Understand the need to be able to convert one variable type into another by typecasting.

Operators Understand how these can be used to manipulate variables and demonstrate this by creating an object that displays the number of times it has been touched in public chat.

Conditionals Show an understanding of the if(condition) and use this understanding to create an object that counts the number of times it has been touched by its owner and display this information in public chat.

Task 1 Create a primitive cube that when touched will change to a random colour on the face that was touched. This must work for only the owner of the cube and it should also announce which face was touched in public chat.

Task 2 Create an object that when touched will move 2m above its original position and move back again on the next touch.

Task 3 Create an object that responds to owner using the words "up" and "down" to move the object 2m above its original position and back down again.