Posts

XTEA for Opensim

If you’ve tried using the XTEA encryption code I referenced in the “Let’s Make a Breedable” blog series on OpenSim, you may have noticed it failing inconsistently. The reason it fails is due to difference in the llBase64ToString in opensim and Second Life, and the fact that the XTEA code pads zeros to the Base64 string it is to decode. Sometimes, there will be extra junk characters at the end of the decoded string, which may throw off your breedable.
Read more

Xundras Little Grid 2

I’ve been working on setting up Xundra’s Little Grid - this time, locked down with no hypergrid. Why? Well, one of my main goals in Second Life is to make breedables affordable. They should be fun for everyone - but not everyone can afford land to put them on. A region in SL costs quiet a lot, and is out of reach for many (including myself). So, I thought I’d make an opensim grid that people could rent regions from me much cheaper, and could transfer breedables between them.
Read more

Lets Make a Breedable - Part 8

Update Cubes As time goes by, you will likely find bugs or make improvements to your breedable, so you need a way to update your pets to the latest version. To keep things simple, we’re just going to update live pets. Eggs can be updated when they are hatched. The basic flow of updating with an update cube is: Breeder clicks update on pet. Pet broadcasts looking for update cube, includes it’s version.
Read more

Lets Make a Breedable - Part 7

The Starter Egg The starter egg is similar to the ordinary egg script, except it doesn’t need to be birthed, so we can remove some code. We do need to decide how we will choose the starter trait, be it random or set. Often colour based breedables start with primary colours (Red, Green or Blue) however in this tutorial it will just be random. We will need to make two versions of this script, one for male and one for female.
Read more

Lets Make a Breedable - Part 6

In this part we are going to extend our brain script to support interaction with the owner of the pet to do things like freeze, set home, range, name and so on. These changes will be done in the running state. First we will need some additional global variables. integer dialog_channel; integer dialog_listener; integer range_channel; integer range_listener; integer name_channel; integer name_listener; integer is_frozen = TRUE; integer interbreed = FALSE; Now for our modified running state, which I will break up and add comments in between
Read more

Lets Make a Breedable - Part 5

The Egg The egg object will only have one script in it with four states, a default state, a full state, a hatching state and a dead state. We will also need some variables from our other scripts, namley the “EGG_CHANNEL”, the “SUPER_SECRET_KEY” from Part 1 and the SECRET_REZ_NUMBER from part 4. We will also need the XTEA encryption code from part 1 and your avatar’s UUID. (You could use llGetCreator(), but only if you are actually the creator of the object).
Read more

Lets Make a Breedable - Part 4

Breeding First, each pet must have a trait, or a series of traits. For our pet, to keep it simple will have one trait - it’s colour. We will assume this colour vector is set in linkset data as “colour-trait”, later on when we birth an egg we will actually assign the colour trait. The method for deciding which trait your baby will have is entirely up to you, but for this example using colours, we will make it a mixture of the two colours, with a small random deviation.
Read more

Lets Make a Breedable - Part 3

Movement Movement can vary, for example a pet that flies or hops would have different movement code than one that crawls along the ground. In this tutorial we are going to go with crawling along the ground as it is the simplest. We start the script the same as the ager and hunger script with a default state that waits for a signal to begin. The SPEED vairiable is how fast to walk in metres per second.
Read more

Lets Make a Breedable - Part 2

Aging In this part we will be working on three scripts, one for aging, one for eating and a food bowl. The first thing we need to do is create the default state, this default state will do nothing but wait for a signal from the main script that it’s time to start. The reason for this is that we don’t want the age or hunger timers to start before the pet is born.
Read more

Lets Make a Breedable - Part 1

Communication and encryption. Communication between pets and pets, pets and eggs, pets and foodbowls, update cubes etc is one of the most important parts of a breedable pet. It also must happen in public chat, which means, anyone can intercept and forge chat to mimic your pets. Chat between pets usually happens with lists of commands, for example a food consuming session might look like this: Pet (broadcast): I’m looking for a food bowl.
Read more