Results 1 to 7 of 7

Thread: Delay the next waypoint? - is it possible?

  1. #1
    Supporting Member
    Join Date
    Dec 2019
    Posts
    473
    Post Thanks / Like
    Total Downloaded
    22.61 MB

    Delay the next waypoint? - is it possible?

    As it says really. Is it possible to delay the next waypoint so that a flight stays in the area for a set time before the next waypoint becomes active and they head off.

    At the moment I'm just spamming waypoints in a circle to get the aircraft to fly around for however long I want, but a delay between arriving at one waypint and heading to the next would be really nice....
    I am Yo-Yo not YoYo (that's someone else)

  2. Likes von Graf liked this post
  3. #2
    Ace 1lokos's Avatar
    Join Date
    Jan 2012
    Posts
    5,323
    Post Thanks / Like
    Total Downloaded
    1.04 GB

    Re: Delay the next waypoint? - is it possible?

    If set for a flight just 2 waypoints, with the last without link for an airbase, plane start circling there until have fuel.

    You can't, after xx seconds add a new waypoint to this last?

    Or create a flight path in steeps?

  4. #3
    Supporting Member
    Join Date
    Dec 2019
    Posts
    473
    Post Thanks / Like
    Total Downloaded
    22.61 MB

    Re: Delay the next waypoint? - is it possible?

    Yes I'd seen that and it's that behaviour I was hoping to recreate, i.e. circling around, but only until the next waypoint is called up.

    But the use I am thinking of would be to include the player's fight, so go to a position, then patrol for 15 minutes for example, then fly home. Without having to set out 20 or so waypoints in a circle.

    I thought i had seen some form of code that seemed to relate to waypoints, I wondered if you could maybe loop back and fore between two waypoints for a set period of time.

    I was also wondering if it was possible to skip waypoints using code depending on events. This would be massively useful.
    I am Yo-Yo not YoYo (that's someone else)

  5. #4
    Supporting Member
    Join Date
    Dec 2019
    Posts
    473
    Post Thanks / Like
    Total Downloaded
    22.61 MB

    Re: Delay the next waypoint? - is it possible?

    Quote Originally Posted by 1lokos View Post
    ...

    You can't, after xx seconds add a new waypoint to this last?

    Or create a flight path in steeps?
    Ah sorry, I didn't pick these up as suggestions. If waypoints can be added that could be a solution.

    I see lots of intesting stuff in the obejct browser but until I learn the code preoprly I don't know what can be done or set from the script.

    There are intersting 'Tasks' for AiAirGroup.

    AiGroup has AiGroup.SetWay(maddox.game.world.AiWayPoint[]), also an 'Idle' Boolean.... I wonder what all these are for.
    I am Yo-Yo not YoYo (that's someone else)

  6. #5
    ATAG Member ATAG_Oskar's Avatar
    Join Date
    Nov 2017
    Location
    Canada
    Posts
    986
    Post Thanks / Like
    Total Downloaded
    908.31 MB

    Re: Delay the next waypoint? - is it possible?

    Quote Originally Posted by Yo-Yo View Post
    AiGroup has AiGroup.SetWay(maddox.game.world.AiWayPoint[])
    Yes, you can set waypoints using code.

    No, you can't have an airgroup linger around a waypoint. You have to make a bunch of points to use up the time.

  7. Likes Yo-Yo liked this post
  8. #6
    Supporting Member
    Join Date
    Dec 2019
    Posts
    473
    Post Thanks / Like
    Total Downloaded
    22.61 MB

    Re: Delay the next waypoint? - is it possible?

    Quote Originally Posted by ATAG_Oskar View Post
    Yes, you can set waypoints using code.

    ...
    Oh you tease.
    I am Yo-Yo not YoYo (that's someone else)

  9. #7
    Ace
    Join Date
    May 2015
    Location
    Kansas City, Missouri area
    Posts
    515
    Post Thanks / Like
    Total Downloaded
    130.02 MB

    Re: Delay the next waypoint? - is it possible?

    Quote Originally Posted by Yo-Yo View Post
    Oh you tease.
    Here is another example to look it:

    https://github.com/bhugh/TWC_Mission...tsubmission.cs

    This isn't a mission on its own, but you load it as a submission of any regular old mission with various fighter, bomber whatever flights built into it, and fly around, attack things, bomb things, whatever.

    What MoveBomb does is catches any AI airgroup as soon as it spawns in and reprograms its entire flight plan the way ***I*** want it to be.

    So, if you take a look at its various routines you can see both how it reads an airgroup's current flight plan and then how it changes it & re-writes/reloads it as the airgroup's new flight plan.

    (You can also see how a simple idea grows into like 3000 lines of code. The idea here was simple to read each airgroup's pre-programmed flight plan, change each waypoint to a different random but logical destination, change any attack or bomb points to a different nearby logical attack point, then send them back home to land--but at a different random airport than originally programmed. That plus eleventy-billion bugfixes and tweaks is what you see in the file.)
    System: Microsoft Windows 10 Pro 64 bit, 10.0.18362 N/A Build 18362, 20,437 MB |
    ASUS GeForce GTX 1060 3GB | Intel Core i5-2500 Quad-Core Processor 3.3 GHz 6 MB Cache LGA 1155 | Intel DB65AL motherboard | ARCTIC Freezer i11 CPU Cooler | SVGA 500 watt power supply | Microsoft Sidewinder 2 Force Feedback joystick

  10. Likes Yo-Yo liked this post

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •