Archive for October, 2007

LSL Snippet: Generate Sized List

Sunday, October 28th, 2007

Heya, everybody. I wrote a somewhat useful LSL function, and I wanted to stash it somewhere that I wouldn’t forget it. Then I thought, “I’ll just make a blog post, and everybody can benefit. Maybe I’ll get some suggestions on how to improve it, too.”

So, here you go: it’s a function to create a new list of a certain size, filled with zeroes. This is such a small and rather obvious function, so I hereby release it to the public domain. Yay!

// Create a new list which is filled with +length+ 0's.
list generate_filled_list( integer length )
{
	list new_list;
	integer counter = 0;

	// Fill it up 10 at a time, until we have at least enough.
	for( ; counter < length; counter += 10 )
	{
		new_list += [0,0,0,0,0,0,0,0,0,0];
	}

	// Return only the needed amount.
	return llList2List( new_list, 0, length - 1 );
}

Thoughts on the CSI: NY Episode

Thursday, October 25th, 2007

Like a lot of US-based Resis I know, I turned on my television last night for the much-hyped CSI: NY episode featuring Second Life, and it was pretty much what I expected—in a mostly-good way. The action was intense, the plot was plausible enough (for a TV crime drama show) that I could suspend my disbelief, the SL tie-in was halfway clever, and they threw enough bones to the Resis in the audience to earn some chuckles.

In short, it was rather entertaining.

Was it a 100% accurate portrayal of SL? Not a chance.

Was their portrayal of SL more accurate than their portrayal of forensics, the criminal justice system, computer technology, and the world in general? Oh, yes.

But none of that matters; it’s a crime drama, not a documentary. Somehow, they make even lifting fingerprints look sexy, cool, and action-packed. Likewise, they did their best to make SL look sexier, cooler, and more action-packed than it really is. (Heck, with the right background music and some quick camera cuts, even a scene of Gary Sinise sitting down to eat a bowl of pea soup could make your heart pound in suspense.)

But enough about the show; let’s talk about the SL side of things.

You might be wondering if the in-world crime mystery games were half as entertaining as the show was. Well, I really couldn’t tell you; the whole thing was so dependent on streaming media with Quicktime playback—a feature which we Linux users are hard to come by yet—that I didn’t even get past the introductory briefing. There was a bit of action, though: my client died trying to play back an MP3 from an apparently-nonresponsive Electric Sheep Company server. (By the way, SL crashes aren’t as sexy in real life as they look on TV, either.)

As for the growing fears of the Grid imploding under the pressure of an anticipated 10,000+ new users in one night… well, from what I’ve seen, it didn’t happen. I had no trouble logging in yesterday evening or today, and teleports and other grid services have been as well-behaved as can be expected these days. Apparently, some technical difficulties (perhaps overloaded file servers?) stopped a quite a few would-be-newbies from actually downloading the viewer and getting in-world, so we’ll likely see more of a steady dribble for a few weeks than the flood-of-Biblical-proportions that people were gnashing their teeth about beforehand.

On The Case

Thursday, October 25th, 2007

On The Case

Just another day in the life of Jacek Antonelli, Bug Detective.

Here I’m snooping out some bounding box issues related to VWR-1852.

P.S. This is my first ever Flickr. Crazy.

Drag My Avatar

Sunday, October 7th, 2007

No, no. This isn’t about dressing my avatar in drag. It’s about moving my avatar around by clicking and dragging on it!

Today, I was messing around with the llDetectedGrab() function, which returns a vector telling which way someone is pushing or pulling on an object. I’m planning on using it for controls in some upcoming projects, so I wanted to get a grip on it (pun intended).

So, I put a script in a box, and tried using the vector in various different ways. The first, way was simply to move the box around; that was enough to confirm my suspicions about how the numbers worked. Then I went on to try changing the color of the object, based on the vector. When you drag it along the X axis, it turns red; along the Y axis, green; along the Z axis, blue. If you drag it along multiple axes, it turns some combination.

Then, I was showing it to Chrysocolla and hya. The land was no-rez, so I improvised by wearing the box on my head! Then I got the idea that I could allow other people to drag my avatar around, by pushing myself based on the vector. So, some scripting later, Chrysocolla was dragging my avatar and throwing her against walls and other hard things. Ouch!

Here’s a composite time-lapse snapshot of the brutality:

Drag My Avatar

Overall, it was very silly.

UPDATE: hya passed out poking sticks, so I got my revenge.

Revenge

Femme Noir

Friday, October 5th, 2007

Femme Noir