Path update

De DigiWiki.

(Différences entre les versions)
(Also)
 
Ligne 77 : Ligne 77 :
* [[llPursue]]
* [[llPursue]]
* [[llUpdateCharacter]]
* [[llUpdateCharacter]]
-
* [[llWanderWithin]]|
+
* [[llWanderWithin]]
 +
 
==Events==
==Events==
* [[path_update]]
* [[path_update]]

Version actuelle en date du 17 mars 2012 à 03:22

default
{
    state_entry()
    {
        llDeleteCharacter(); // Clear any previous character behaviors
        llCreateCharacter([CHARACTER_DESIRED_SPEED, 35.0]);
 
        llWanderWithin(llGetPos(), 10.0, []);
    }
 
    path_update(integer type, list reserved)
    {
        if (type == 0)
        {
            llOwnerSay("Near");
        }
        else if (type == 1)
        {
            llOwnerSay("Stopping");
        }
        else if (type == 2)
        {
            llOwnerSay("Cannot path find from current location! Attempting to go to the center of the region.");
 
            llNavigateTo(<128.0, 128.0, llGround(<128.0, 128.0, 0.0> - llGetPos())>, [FORCE_DIRECT_PATH, TRUE]);
        }
        else if (type == 3)
        {
            llOwnerSay("Goal not on navmesh!");
        }
        else if (type == 4)
        {
            llOwnerSay("Goal unreachable!");
        }
        else if (type == 5)
        {
            llOwnerSay("Target gone!");
        }
        else if (type == 6)
        {
            llOwnerSay("No place to go!");
        }
        else if (type == 7)
        {
            llOwnerSay("Hiding from pursuer...");
        }
        else if (type == 8)
        {
            llOwnerSay("Switched from hiding to running...");
        }
        else if (type == 9)
        {
            llOwnerSay("Region has no nav mesh..");
        }
        else if (type == 1000000)
        {
            llOwnerSay("Hit an unspecified failure");
        }
        else
        {
            llOwnerSay("Unknown failure");
        }
    }
}

Also

Events

  • path_update
Outils personnels
  • Cette page a été consultée 955 fois.
donate
Google Ads