Action Mod Scripts


The work on the action toolbar continues. This weekend in got the toolbar to load correctly within the simulation when a player picks  faction to 'guide' it. Clicking the red Stop button on the toolbar will not only disappear the toolbar but also will stop guidance on the selected faction.

I also started working on the action mod scripts. Specifically, I worked on the action that will allow players to choose a target neighbor region to migrate to. Here's the script (work in progress):

{
  "actions": [
    {
      "id": "expand_toward_region",
      "name": "Expand Toward Region",
      "target": "faction",
      "category": "territory",
      "properties": [
        { "id": "target_polity", "value": "target.polity" },
        { "id": "neighbor_region_set", "value": "target_polity.neighbor_regions" },
        { "id": "target_region", "value": "neighbor_region_set.request_controller_selection()" }
      ],
      "accessConditions": [
        "target == target_polity.dominant_faction",
        "target_polity.type == tribe"
      ],
      "effects": [
        "target.trigger_decision(tribe_decide_expand_toward_region, target_region)"
      ]
    }
  ]
}

I also added the code to load this script and add the respective action to the toolbar:


Next weekend I'm going to continue working on the toolbar and the action script. I need to make sure the actions are only accessible for factions that can use them (a non-dominant faction can't choose where the tribe should migrate, for example). I also need to work on the UI components that will allow a player to pick the target region. This particular task is going to be a very difficult one and it will, at minimum, take me three weeks to complete. So expect at least a couple of weeks of dull dev updates.

Get Worlds - History Simulator

Comments

Log in with itch.io to leave a comment.

very cool! not a "aesthetically pleasing" update but behind-the-hood updates like these are as important, if not more, than ones that make it appear better. im excited to see this develop, keep up the good work! 

(+2)

I'm impressed by the sheer amount of development you're putting into this simulation. It seems like you're working to expand/refine it on practically a weekly basis. It's such a measured approach to the development plan as well.

Thanks!