Monday, 12 December 2011

Week 5 - Datalists and notecards

For this weeks tasks, we looked at lists and notecards. In LSL there is no arrays, so list takes over... But not all the functions are the same.


The first task was to create a script that once a collision was detected, to store the avatar name, avatar KEY and speed at which the avatar/object collided with the prim containing the script. 


The second task was to display this data to the owner of the script on touch of the object. So I thought I would save some time and just put them together. When I tried this task, it wasnt that difficult at first but then I couldnt get the list organised well using the code I had got. Here it is and the output:



Output


I then researched some stuff about list organisation and ease of reading in second life. And re-coded the list and here is the final out: 




From this exercise so far, it has shown me some of the magical powers of loops and lists. These are a powerful tool when used together. 


I had a good bash at the third task but couldnt get it all working. I did manage to get the script to read from the notecard but then not really do much else after that. 





No comments:

Post a Comment