Difference between revisions of "Pathfinding Cookbook"

From Second Life Wiki
Jump to navigation Jump to search
(restructure)
Line 1: Line 1:
UNDER DEVELOPMENT - INCOMPLETE
UNDER DEVELOPMENT - INCOMPLETE


==Hunting Animal==
=Rezzer=
Wanders looking for specific prey and pursues when prey is spotted.
 
The code below is for a simple rezzer for the creatures. For a region scale rezzer system see...


<lsl>
<lsl>
default
 
{
state_entry()
{
    llCreateCharacter([CHARACTER_MAX_SPEED, 25, CHARACTER_DESIRED_SPEED, 15.0]);
    //script being tested/refined, coming soon
}
}
</lsl>
</lsl>
=Simple Creatures=


==Grazing Animal==
==Grazing Animal==
Line 19: Line 15:


<lsl>
<lsl>
default
 
{
state_entry()
{
    llCreateCharacter([CHARACTER_MAX_SPEED, 25, CHARACTER_DESIRED_SPEED, 15.0]);
    //script being tested/refined, coming soon
}
}
</lsl>
</lsl>


==Grazing Prey Animal==
==Sentient Treasure Chest==
Wanders and pauses to eat, run a short distance when approached (skittish), runs further and hides from specific predator.
Treasure chest with legs. Sleeps, but runs and hides if anyone approaches.
 
<lsl>
 
</lsl>
 
==Fairy==
Wanders about (flying) looking for flowers, lingers by flowers, runs and hides from agents.


<lsl>
<lsl>
default
 
{
state_entry()
{
    llCreateCharacter([CHARACTER_MAX_SPEED, 25, CHARACTER_DESIRED_SPEED, 15.0]);
    //script being tested/refined, coming soon
}
}
</lsl>
</lsl>


Line 47: Line 36:


<lsl>
<lsl>
default
 
{
state_entry()
{
    llCreateCharacter([CHARACTER_MAX_SPEED, 25, CHARACTER_DESIRED_SPEED, 15.0]);
    //script being tested/refined, coming soon
}
}
</lsl>
</lsl>


==Fairy==
==Snake==
Wanders about (flying) looking for flowers, lingers by flowers, runs and hides from agents.
Wanders about an area, includes special movement example.
 
<lsl>
 
</lsl>
 
==Treetop Birds==
Birds that move between treetops at random intervals.
 
<lsl>
 
</lsl>
 
==Vulture==
Birds that glide about on thermals


<lsl>
<lsl>
default
 
{
state_entry()
{
    llCreateCharacter([CHARACTER_MAX_SPEED, 25, CHARACTER_DESIRED_SPEED, 15.0]);
    //script being tested/refined, coming soon
}
}
</lsl>
</lsl>


==Sentient Treasure Chest==
=Ecosystem Creatures=
Treasure chest with legs. Sleeps, but runs and hides if anyone approaches.
 
==Hunting Animal==
Wanders looking for specific prey and pursues when prey is spotted.


<lsl>
<lsl>
default
 
{
state_entry()
{
    llCreateCharacter([CHARACTER_MAX_SPEED, 25, CHARACTER_DESIRED_SPEED, 15.0]);
    //script being tested/refined, coming soon
}
}
</lsl>
</lsl>


==Rat==
==Grazing Prey Animal==
Wanders about a specified area, flees and hides if an agent approaches.
Wanders and pauses to eat, run a short distance when approached (skittish), runs further and hides from specific predator.


<lsl>
<lsl>
default
 
{
state_entry()
{
    llCreateCharacter([CHARACTER_MAX_SPEED, 25, CHARACTER_DESIRED_SPEED, 15.0]);
    //script being tested/refined, coming soon
}
}
</lsl>
</lsl>


==Snake==
==Rat==
Wanders about an area, includes special movement example.
Wanders about a specified area, flees and hides if an agent approaches.


<lsl>
<lsl>
default
 
{
state_entry()
{
    llCreateCharacter([CHARACTER_MAX_SPEED, 25, CHARACTER_DESIRED_SPEED, 15.0]);
    //script being tested/refined, coming soon
}
}
</lsl>
</lsl>


Line 117: Line 87:


<lsl>
<lsl>
default
 
{
state_entry()
{
    llCreateCharacter([CHARACTER_MAX_SPEED, 25, CHARACTER_DESIRED_SPEED, 15.0]);
    //script being tested/refined, coming soon
}
}
</lsl>
</lsl>


Line 131: Line 94:


<lsl>
<lsl>
default
 
{
state_entry()
{
    llCreateCharacter([CHARACTER_MAX_SPEED, 25, CHARACTER_DESIRED_SPEED, 15.0]);
    //script being tested/refined, coming soon
}
}
</lsl>
</lsl>


Line 145: Line 101:


<lsl>
<lsl>
default
 
{
state_entry()
{
    llCreateCharacter([CHARACTER_MAX_SPEED, 25, CHARACTER_DESIRED_SPEED, 15.0]);
    //script being tested/refined, coming soon
}
}
</lsl>
</lsl>


Line 159: Line 108:


<lsl>
<lsl>
default
{
state_entry()
{
    llCreateCharacter([CHARACTER_MAX_SPEED, 25, CHARACTER_DESIRED_SPEED, 15.0]);
    //script being tested/refined, coming soon
}
}
</lsl>


==Treetop Birds==
Birds that move between treetops at random intervals.
<lsl>
default
{
state_entry()
{
    llCreateCharacter([CHARACTER_MAX_SPEED, 25, CHARACTER_DESIRED_SPEED, 15.0]);
    //script being tested/refined, coming soon
}
}
</lsl>
 
==Vulture==
Birds that glide about on thermals
<lsl>
default
{
state_entry()
{
    llCreateCharacter([CHARACTER_MAX_SPEED, 25, CHARACTER_DESIRED_SPEED, 15.0]);
    //script being tested/refined, coming soon
}
}
</lsl>
</lsl>


----
----
Return to [[Good_Building_Practices]]
Return to [[Good_Building_Practices]]

Revision as of 14:21, 2 August 2012

UNDER DEVELOPMENT - INCOMPLETE

Rezzer

The code below is for a simple rezzer for the creatures. For a region scale rezzer system see...

<lsl>

</lsl>

Simple Creatures

Grazing Animal

Wanders pauses and eat, wanders, repeat.

<lsl>

</lsl>

Sentient Treasure Chest

Treasure chest with legs. Sleeps, but runs and hides if anyone approaches.

<lsl>

</lsl>

Fairy

Wanders about (flying) looking for flowers, lingers by flowers, runs and hides from agents.

<lsl>

</lsl>

Dragonfly

Moves along designated path, lingers by designated waypoint and moves to next random waypoint.

<lsl>

</lsl>

Snake

Wanders about an area, includes special movement example.

<lsl>

</lsl>

Treetop Birds

Birds that move between treetops at random intervals.

<lsl>

</lsl>

Vulture

Birds that glide about on thermals

<lsl>

</lsl>

Ecosystem Creatures

Hunting Animal

Wanders looking for specific prey and pursues when prey is spotted.

<lsl>

</lsl>

Grazing Prey Animal

Wanders and pauses to eat, run a short distance when approached (skittish), runs further and hides from specific predator.

<lsl>

</lsl>

Rat

Wanders about a specified area, flees and hides if an agent approaches.

<lsl>

</lsl>

Mount

Build a character that can be ridden with race example.

<lsl>

</lsl>

Dog

Wanders about, chooses random agent, follows agent for a period, then wanders off, if no agents found sleeps.

<lsl>

</lsl>

Cat

Wanders about, chooses random agent, lingers by agent, then wanders again, if no agents found sleeps.

<lsl>

</lsl>

Hopping Scarecrow

Wanders about hopping and approaches random people, lingers and moves on.

<lsl>

</lsl>


Return to Good_Building_Practices