code: def generate_py_abilities(data):
      """Generate the list of functions in actions.py."""
  
      def print_action(func_id, name, func, ab_id, general_id):
          args = [func_id, '"%s"' % name, func, ab_id]
          if general_id:
              args.append(general_id)
          print(
              "    Function.ability(%s),"
              % ", ".join(str(v) for v in args)
          )
  
      func_ids = itertools.count(12)  # Leave room for the ui funcs.
      for ability in sorted(
          data.abilities.values(), key=lambda a: sort_key(data, a)
      ):
          ab_id = ability.ability_id
          if ab_id in skip_abilities or (
              ab_id not in data.general_abilities
              and ab_id not in used_abilities
          ):
              continue
  
          name = generate_name(ability).replace(" ", "_")
  
          if ability.target in (
              sc_data.AbilityData.Target.Value("None"),
              sc_data.AbilityData.PointOrNone,
          ):
              print_action(
                  next(func_ids),
                  name + "_quick",
                  "cmd_quick",
                  ab_id,
                  ability.remaps_to_ability_id,
              )
          if ability.target != sc_data.AbilityData.Target.Value("None"):
              print_action(
                  next(func_ids),
                  name + "_screen",
                  "cmd_screen",
                  ab_id,
                  ability.remaps_to_ability_id,
              )
              if ability.allow_minimap:
                  print_action(
                      next(func_ids),
                      name + "_minimap",
                      "cmd_minimap",
                      ab_id,
                      ability.remaps_to_ability_id,
                  )
          if ability.allow_autocast:
              print_action(
                  next(func_ids),
                  name + "_autocast",
                  "autocast",
                  ab_id,
                  ability.remaps_to_ability_id,
              )
  
file_path: pysc2/pysc2/bin/gen_actions.py
imports: import itertools
  from absl import app
  from absl import flags
  from pysc2 import maps
  from pysc2 import run_configs
  from pysc2.lib import static_data
  from s2clientprotocol import common_pb2
  from s2clientprotocol import data_pb2
  from s2clientprotocol import sc2api_pb2
label_desc: Use image node_id 5 for calling a global function with example usage: generate_py_abilities(data) without return types