Frage zu door.osc

Das Forum befindet sich im reduzierten Betrieb. Die Addon- und Supportforen bleiben weiterhin verfügbar.
Bitte beachte, dass OMSI nicht mehr weiterentwickelt wird. Ein Teil der Entwickler widmet sich inzwischen der Entwicklung eines neuen Simulators. Weitere Informationen zum LOTUS-Simulator findest Du hier.
  • Hallo,


    Ich versuche derzeit das System in der door.osc bzgl. des Ein -und Ausstiegsverhaltens zu verstehen.


    Ich habe jetzt eine Frage am Beispiel des Facelifts 2 Türer mit Morphi Soundpack:


    (L.L.door_0) 0.9 > (S.L.PAX_Entry0_Open)

    (L.L.door_1) 0.9 > (S.L.PAX_Entry1_Open)

    (L.L.door_3) 0.9 > (S.L.PAX_Exit0_Open) (S.L.PAX_Exit1_Open)

    (L.L.door_5) 0.9 > (S.L.PAX_Exit2_Open) (S.L.PAX_Exit3_Open)


    Woher weiß ich, welche Zahl hinter dem L.L.door stehen muss?

    Was hat es mit der 5 auf sich? Es gibt doch gar keinen 5.Türflügel.... (eigentlich doch nur 0,1,2 und 3)

    Wo ist L.L.door_4?


    Der dritte Eintrag heißt ja meines Wissens, dass die 1.Tür zum Ausstieg freigegeben ist, wenn der 3.Türflügel (2.Tür also) zu 0.9 offen ist.

    Wenn ich diesen Eintrag rausgelöscht habe, sind die Fahrgäste nicht mehr hinten ausgestiegen. Dabei ist in der passengercabin.cfg gar kein Ausstieg an der ersten Tür vermerkt und dieser dritte Eintrag doch eigentlich überflüssig?


    Zudem habe ich versucht die Fahrgäste auch an der 2.Tür einsteigen zu lassen. Dazu habe ich in der passengercabin.cfg [entry] 2 und [entry] 3 eingetragen und habe in der door.osc noch folgendes hinzugefügt: (L.L.door_2) 0.9 > (S.L.PAX_Entry2_Open) und (L.L.door_3) 0.9 > (S.L.PAX_Entry3_Open) und zwar nach dem 2.Eintrag.


    Dennoch sind die Leute nur an der 2.Tür eingestiegen, wenn Tür 1 auch geöffnet ist. Wieso ist das so?


    LG Max

  • Der dritte Eintrag ist für die 2. Tür, nicht für die erste und dort wollen Passagiere nunmal aussteigen. Ohne den Eintrag wissen diese aber nicht wann die Tür offen ist. Wozu willst du die ganze Geschichte überhaupt bearbeiten?

  • Hello,

    Woher weiß ich, welche Zahl hinter dem L.L.door stehen muss?

    In every* door_X variable, X stands for the real door wing index, as we perceive it by looking at the physical ordering of doors, beginning from 0, from front to rear. So door_0 reflects the opening state of the first wing, door_1 of the second wing, ..., door_7 of the eighth wing.


    Was hat es mit der 5 auf sich? Es gibt doch gar keinen 5.Türflügel.... (eigentlich doch nur 0,1,2 und 3)

    Indeed, if all doors combined only yield 4 wings total, then the door_4, door_5 variables are useless. But perhaps the author intended to reuse the same code with 3-door vehicle variants. Or they just didn't bother cleaning up the redundant code.


    Wo ist L.L.door_4?

    This is likely a shortcut because the author thinks that both wings will be opening/closing (almost) synchronously, and hence deems it appropriate to just check whether one wing, likely the slowest one, is sufficiently open to allow boarding/disembarking. But of course that will fail if one decides to manually (e.g. via the emergency opening valves) open just these individual wings (door_3, door_5) while leaving the other two (door_2, door_4) closed, in which case passengers will magically be able to walk through the closed latter ones as well.


    So the proper expression would be:

    Code
    1. (L.L.door_2) 0.9 > (L.L.door_3) 0.9 > && (S.L.PAX_Exit0_Open) (S.L.PAX_Exit1_Open)
    2. (L.L.door_4) 0.9 > (L.L.door_5) 0.9 > && (S.L.PAX_Exit2_Open) (S.L.PAX_Exit3_Open)

    ...or better yet, for individual control:

    Code
    1. (L.L.door_2) 0.9 > (S.L.PAX_Exit0_Open)
    2. (L.L.door_3) 0.9 > (S.L.PAX_Exit1_Open)
    3. (L.L.door_4) 0.9 > (S.L.PAX_Exit2_Open)
    4. (L.L.door_5) 0.9 > (S.L.PAX_Exit3_Open)


    Der dritte Eintrag heißt ja meines Wissens, dass die 1.Tür zum Ausstieg freigegeben ist, wenn der 3.Türflügel (2.Tür also) zu 0.9 offen ist.

    Wenn ich diesen Eintrag rausgelöscht habe, sind die Fahrgäste nicht mehr hinten ausgestiegen. Dabei ist in der passengercabin.cfg gar kein Ausstieg an der ersten Tür vermerkt und dieser dritte Eintrag doch eigentlich überflüssig?

    No, the index X in the PAX_[Entry|Exit]X_[Open|Req] variable names is not necessarily equivalent to the X in door_X. Here X means strictly according to the ordering of the passengercabin.cfg. And the ordering in the .cfg represents priority, and not (necessarily) physical door wing order.


    For example, suppose that we have a bus with 5 doors (let's forget about door wings for a moment, for clarity's sake). Suppose also that we want our passengers to be able to board the vehicle from doors 3, 1, and 5, in that exact priority. And we would also want them to be able to disembark from doors 1 and 4 (here there's no notion of priority -- passengers in OMSI always choose the nearest exit). As for the spare 2nd door, we want it to be purely cosmetic, i.e., to neither serve as an entry nor as an exit to passengers.


    Here's how the .cfg would look like:

    And here's how the .osc would look like:

    Note that there's no door_1 above. This doesn't mean that the variable is useless though, since it would still be used to animate the 2nd physical door, in another part of the script. It just hasn't been mapped to any entry or exit used by passengers, since we don't want passengers to ever use it.


    * * *


    * Strictly technically speaking, that's not true. door_X are non-standard variables, and as such they can represent anything the script/bus author wants them to represent. But in practice X indeed virtually always follows the physical door (wing) ordering, as do the actual values assigned to those variables.