This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

Beifahrer Sitzscript für Fahrzeuge
#3
ERGÄNZENDE INFO 11.10.2022

Mir ist aufgefallen das die Scripting Engine "X-Engine" den folgenden Bug hat:
Wenn man ein Sit Target definiert darf nie ein ZERO Vector <0.0,0.0,0.0> als Position angegeben werden, sonst wird das Sittarget nicht erstellt.

Folge ist das der AVA dann irgendwo rumhängt, anstelle gezielt an der gewünschten Position zu sitzen.

Ein kleiner Offset wie im folgenden Beispiel reicht aber schon für die Funktion:

vector  sitzposition = <0.0, 0.0, 0.01>;

    state_entry()
    {
        sitzanimation = llGetInventoryName( INVENTORY_ANIMATION, 0);
        llSetSitText("setzt dich");
        vector gSitTarget_Rot = llRot2Euler( llGetRootRotation() );  // SIT TARGET in Anhängigkeit von Boot Rotation
        llSitTarget(sitzposition, llEuler2Rot(DEG_TO_RAD * gSitTarget_Rot));     
    }

Festgestellt habe ich das auf der Opensim Version 0.9.0.1, aber es können auch neuere Versionen betroffen sein.
Zitieren


Nachrichten in diesem Thema
RE: Beifahrer Sitzscript für Fahrzeuge - von Tron Mcp - 11.10.2022, 11:41

Gehe zu:


Benutzer, die gerade dieses Thema anschauen: 1 Gast/Gäste