Configure door's variables

  • Hi all,


    Does anyone know how and where I can change the door's variables? In fact, it happens that passengers get on the bus with closed doors. I looked to the lexicon but I don't understand much about it. I tried scrolling through the scripts hoping to have some insight, but nothing.


    Thank you

  • Hi,


    You need to put the variable

    Code
    1. DoorOpen_#: boolean

    in the public vars section of your script. You need so many variables as the vehicle has door points. The # stands for the position of the door point in the list, beginning with 0. The points that not are door points are not counted. Then you can set that variable on true when the door opens (for example when the door position > 0.8 or something) and on false when it closes (when the door position < 0.8 or something).


    I hope that helps.

  • Thank you very much.

    this means I should create a specific Door's script or I can modify it from the existing one? In the second case I can try, in the first I really think I am not able to do it.

  • From yesterday to today I have tried everything, both in the "ND313_Doors.pas" and "ND313.pas" script. I can't get it to work, I've put variables all over the place. For example this is what I did on the "ND313.pas" script:


    DoorOpen_0: boolean;

    DoorOpen_1: boolean;

    DoorOpen_2: boolean;

    DoorOpen_3: boolean;

    DoorReqIn_0: false;

    DoorReqIn_1: false;

    DoorReqIn_2: false;

    DoorReqIn_3: false;

  • take a look at the "ND313_Doors.pas" in your OpenSource Folder.

    There is a part like this:


    DoorOpen_0 := Door_1_1_Pos > 0.8;

    DoorOpen_1 := Door_1_2_Pos > 0.8;

    DoorOpen_2 := Door_2_1_Pos > 0.8;

    DoorOpen_3 := Door_3_1_Pos > 0.8;


    But you need to declare this variables in "ND313.pas" like this:


    DoorOpen_0: boolean;

    DoorOpen_1: boolean;

    DoorOpen_2: boolean;

    DoorOpen_3: boolean;

    DoorReqIn_2: boolean;

    DoorReqIn_3: boolean;

  • Sorry, but I'm confused. I don't understand what I should write in ND313.pas since those variables are already there. I'm referring to:


    DoorOpen_0: boolean;

    DoorOpen_1: boolean;

    DoorOpen_2: boolean;

    DoorOpen_3: boolean;

    DoorReqIn_2: boolean;

    DoorReqIn_3: boolean;

  • Something in positive (maybe) has change. This is what my confusion has produced:


    DoorOpen_0: boolean;

    DoorOpen_1: boolean;

    DoorOpen_2: boolean;

    DoorOpen_3: boolean;

    DoorReqIn_0: boolean;

    DoorReqIn_1: boolean;

    DoorReqIn_2: boolean;

    DoorReqIn_3: boolean;

    DoorReqOut_0: boolean;

    DoorReqOut_1: boolean;

    DoorReqOut_2: boolean;

    DoorReqOut_3: boolean;


    In this way passengers wait for the doors opening but, they get off with the doors closed. For example they are in front of the middle door and they wait the opening; if I open the front door or the rear door, they begin to cross the middle (closed) to get off of the bus.

    I'm searching how to make these settings:


    Front door: get on

    Middle door: get off

    Rear door: get on

  • I'm searching how to make these settings:


    Front door: get on

    Middle door: get off

    Rear door: get on

    This is currently not possible.

    \|/⠀⠀⠀ ⠀⠀⠀⠀⠀⠀⠀(__)

    ⠀⠀⠀⠀`\-------------(oo)

    ⠀⠀⠀⠀⠀||⠀⠀⠀ ⠀⠀(__)

    ⠀⠀⠀⠀⠀||w------||⠀⠀⠀⠀\|/

    ⠀⠀⠀\|/

  • Neu erstellte Beiträge unterliegen der Moderation und werden erst sichtbar, wenn sie durch einen Moderator geprüft und freigeschaltet wurden.

    Die letzte Antwort auf dieses Thema liegt mehr als 60 Tage zurück. Das Thema ist womöglich bereits veraltet. Bitte erstellen Sie ggf. ein neues Thema.

    Maximale Anzahl an Dateianhängen: 5
    Maximale Dateigröße: 500 kB
    Erlaubte Dateiendungen: bmp, cfg, ini, jpeg, jpg, lct, ldl, llg, lob, log, lpmtl, lptmt, ltx, pas, pdf, png, railtrack, rar, txt, veh, wav