Skip to content

Repository files navigation

markline

markline is a lightweight, in-mission ME CLI for DCS, converting F10 map markers into live AI behaviour.

Inspired by slmod and other tooling, markline is designed to be a plug-and-play CLI1 for marker-based AI commands in single- or multi-player environments.

Think of it as your portable command shell for the mission: drop a map marker, type a command, and the AI does the rest.

Features

      Simple to adopt.
      markline is built to minimize setup and let you focus on commands. It maps F10 markers to parsed CLI input so you can start writing AI behaviour quickly.
      Learn more →
      Predictable behaviour.
      The CLI includes a parser, flag schema, and marker event bindings so commands are handled consistently across create/update/delete events.
      Easily modifiable.
      Commands are defined by schema and callbacks, making it simple to add new behaviour or extend the parser without changing engine code.

Getting Started

Create a mission_script.lua file to handle your CLI instance, and add a basic command:

-- mission_script.lua

local cli = mark.cli()

-- Handle a simple marker command.
cli:on("test", function(ctx)
    print("received!") -- dcs.log
end)

mark.cli() will register the handler with DCS automatically when the environment provides world.addEventHandler, so you generally do not need a manual event handler for the CLI itself.

Warning

If you're updating your script or the source, you must re-add the file first and then save the mission.

In your runtime mission, create an ON MISSION START trigger with two DO SCRIPT FILE actions. When a script is added, it is cached into the .miz file:

Mission Editor Trigger GUI menu with 1 ONCE ON MISSION START, 1 DO SCRIPT FILE "snwfke_markline.lua" 1 DO SCRIPT FILE "mission_script.lua"

You must load the markline CLI script first before your mission script, or the mark namespace won't be found.

Contributing

If you have any issues or concerns with this project, please forward the details to us so we can make it better. ❤️

Advanced

To learn more about command schema, event handlers, and parser behavior, please read our usage documentation.

Footnotes

  1. This is the abbreviation for a command-line interface, majorly responsible for allowing developers to execute commands on any given system.

About

A lightweight, in-mission ME CLI for DCS, converting F10 map markers into live AI behaviour.

Topics

Resources

Stars

2 stars

Watchers

0 watching

Forks

Releases

Contributors

Languages