Ai following script path in mission

Discussion in 'Programming' started by Murokmakto, Sep 28, 2024.

  1. Murokmakto

    Murokmakto
    Expand Collapse

    Joined:
    Dec 24, 2023
    Messages:
    281
    How do I make a ai car follow a script path in a mission?

    I created a "arrive" mission with the setting "ai vehicle" active to "ai mode" "script". I created a script path and file (the file has a green mark so it is being recognized).
    When I test the mission the ai car won´t follow the path but just sit at the start.

    How do I make it follow the script path? I know that the script path is not assigned to any vehicle. I suppose that is the issue? But the vehicle I want to assign it to is not represented in the scene tree since it is being spawned in only at the start of the mission. So I can´t assign it prior...?

    The screenshot should make things clear.. Thank you if anyone can help!
     

    Attached Files:

    • 20240928114533_1.jpg
    #1 Murokmakto, Sep 28, 2024
    Last edited: Sep 28, 2024
  2. Murokmakto

    Murokmakto
    Expand Collapse

    Joined:
    Dec 24, 2023
    Messages:
    281
    Does anyone has an idea how that works? I tried following this guide but either I am doing something wrong or it does not work the same for an arrive mission.

    My goal is to create a mission where the player has to follow another car to a set location. The problem is that the ai will drive at top speed if I set the mode to "arrive" or anything else and the only mode it won´t drive top speed is "traffic" but then it will not go to my location but randomly anywhere.
     
  3. Murokmakto

    Murokmakto
    Expand Collapse

    Joined:
    Dec 24, 2023
    Messages:
    281
    Any help is greatly appreciated!
     
  4. Murokmakto

    Murokmakto
    Expand Collapse

    Joined:
    Dec 24, 2023
    Messages:
    281
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice