does anyone know if a set_"fleet_order" exists?

  • We have updated our Community Code of Conduct. Please read through the new rules for the forum that are an integral part of Paradox Interactive’s User Agreement.

Pancakelord

Lord of Pancakes
43 Badges
Apr 7, 2018
3.374
12.268
  • Cities: Skylines - Green Cities
  • Stellaris: Leviathans Story Pack
  • Cities: Skylines - Natural Disasters
  • Hearts of Iron IV: Together for Victory
  • Stellaris: Ancient Relics
  • Cities: Skylines - Mass Transit
  • Surviving Mars
  • Hearts of Iron IV: Death or Dishonor
  • Imperator: Rome
  • Stellaris: Digital Anniversary Edition
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Cities: Skylines - Parklife
  • Stellaris: Distant Stars
  • Shadowrun Returns
  • Cities: Skylines Industries
  • Imperator: Rome Deluxe Edition
  • Cities: Skylines - After Dark
  • Stellaris: Nemesis
  • Europa Universalis IV
  • Stellaris: Necroids
  • Crusader Kings III
  • War of the Roses
  • Cities: Skylines
  • Stellaris: Federations
  • Magicka: Wizard Wars Founder Wizard
  • Cities: Skylines - Snowfall
  • Stellaris: Lithoids
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • Hearts of Iron IV: Cadet
  • Hearts of Iron IV: Colonel
  • Stellaris - Path to Destruction bundle
  • Stellaris: Megacorp
  • Stellaris: Synthetic Dawn
  • Crusader Kings II
  • Stellaris
  • Cities: Skylines Deluxe Edition
  • Sword of the Stars II
  • March of the Eagles
  • Darkest Hour
Cant seem to find a way to do this one., I know there is a way to check orders,
1626528471653.png


But, beyond move_to and a few other (mostly combat related) things, I cannot find a general set X order on Y ship to Z location (if applicable)

Whilst I've got a work-around going for building mining stations automatically, by just spawning them in [cant issue an actual build order], I also wanted to do
  • Automatic construction of observation stations (doesn't seem to be any way to spawn these in script??)
  • Auto-move science ships to the worlds with highest sci-output and set them to "assist research" (as I always forget to do this)
    • A sub-set would be to auto-buy scientists for ships that are assisting research when their leaders die (which is doable - I think? Depends how quickly the "assist research" order is cleared on old-leader death)
 
For the first one. Didn't set the wait time to match build speed, but seems to work fine.
Code:
namespace = test_natpres

#Locate any primitive worlds in borders without observation post, go to them, build. Probably breaks if there's a hostile fleet in the way.
country_event = {
    id = test_natpres.1
    hide_window = yes
    is_triggered_only = yes

    trigger = {
        resource_stockpile_compare = { resource = minerals value >= 100 }
        any_planet_within_border = {
            AND = {
                has_observation_outpost = no
                exists = owner
                owner = {
                    is_primitive = yes
                }
            }
        }
        any_owned_fleet = {
            AND = {
                NOR = {
                    has_fleet_order = move_to_system_point_order
                    has_fleet_order = build_orbital_station_order
                    has_fleet_order = build_space_station_order
                    has_fleet_order = return_fleet_order
                    has_fleet_order = repair_fleet_order
                    has_fleet_order = evade_hostiles_order
                    has_fleet_order = follow_order
                    has_fleet_order = build_megastructure_fleet_order
                    has_fleet_order = use_bypass_order
                    has_fleet_order = jumpdrive_order
                    has_fleet_order = jumpdrive_windup
                }
                any_owned_ship = {
                    is_ship_size = constructor
                }
            }
        }
    }

    immediate = {
        random_owned_fleet = {
            limit = {
                AND = {
                    NOR = {
                        has_fleet_order = move_to_system_point_order
                        has_fleet_order = build_orbital_station_order
                        has_fleet_order = build_space_station_order
                        has_fleet_order = return_fleet_order
                        has_fleet_order = repair_fleet_order
                        has_fleet_order = evade_hostiles_order
                        has_fleet_order = follow_order
                        has_fleet_order = build_megastructure_fleet_order
                        has_fleet_order = use_bypass_order
                        has_fleet_order = jumpdrive_order
                        has_fleet_order = jumpdrive_windup
                    }
                    any_owned_ship = {
                        is_ship_size = constructor
                    }
                }
            }
            queue_actions = {
                find_closest_system = {
                    trigger = {
                        id = test.1.buildobservation
                        any_system_planet = {
                            AND = {
                                has_observation_outpost = no
                                exists = owner
                                owner = {
                                    is_primitive = yes
                                }
                            }
                        }
                    }
                    found_system = {
                        move_to = this
                        find_closest_planet = {
                            trigger = {
                                id = test.2.buildobservation
                                AND = {
                                    has_observation_outpost = no
                                    exists = owner
                                    owner = {
                                        is_primitive = yes
                                    }
                                }
                            }
                            found_planet = {
                                move_to = this
                                wait = {
                                    duration = 60
                                }
                                effect = {
                                    id = test.3.buildobservation
                                    create_fleet = {
                                        effect = {
                                            set_owner = root

                                            create_ship = {
                                                name = random
                                                random_existing_design = observation_station
                                            }

                                            set_location = prev
                                        }
                                    }           
                                    root = {
                                        owner = {
                                            add_resource = { minerals = -100 }
                                        }
                                        clear_fleet_actions = this
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
 
Cant seem to find a way to do this one., I know there is a way to check orders,
View attachment 740928

But, beyond move_to and a few other (mostly combat related) things, I cannot find a general set X order on Y ship to Z location (if applicable)

Whilst I've got a work-around going for building mining stations automatically, by just spawning them in [cant issue an actual build order], I also wanted to do
  • Automatic construction of observation stations (doesn't seem to be any way to spawn these in script??)
  • Auto-move science ships to the worlds with highest sci-output and set them to "assist research" (as I always forget to do this)
    • A sub-set would be to auto-buy scientists for ships that are assisting research when their leaders die (which is doable - I think? Depends how quickly the "assist research" order is cleared on old-leader death)
Most of fleet orders are issued by queue_actions effect (exceptions are ie aforementioned auto_move_to_planet effect, auto_follow_fleet (option = attack) etc.).

Some things you cannot do with queue_actions:
* land armies
* colonise planet
* orbit starbase/juggernaut
* upgrade fleet
* issue build order
* use jumpdrive
* use bypass

Some things you can do with queue_actions:
* merge fleets
* attack fleet
* orbit planet
* use planet killer on a planet
* find closest/random fleet, planet, system (although closest- seems to crash the game as of 3.0)
* wait
* repeat
* move to
* change stance
* queue effect
* queue event

Useful effects:
clear_orders = yes
clear_fleet_actions = this

I never saw survey and assist on a list of valid queue_actions.

You can find almost complete list of valid Stellaris script inputs in CWTools when writing in VSCode.
 
Last edited:
  • 1Like
  • 1
Reactions:
It might be interest of you @Pancakelord that I am working on a library adding missing queue_actions functionalities - Stellaris Fleet EXtender (SFEX). It will allow modders to have any fleet order normally not possible to issue. Below is a live jumpdrive example: