Results 1 to 5 of 5

Thread: scripting.lua commands

  1. #1

    Default scripting.lua commands

    Is there a list of commands that you can make for conditions?

    Im looking for something more like "destroy faction " as a condition, not just take a province from said faction. Then a reward of a unit which is "scripting.game_interface:grant_unit(Settlement, Unit)"

    Any ideas on how this destroy faction type reference could be done? maybe capture their capital but no garuntee they wont have any other territories left, uk?
    Last edited by Havie; January 30, 2016 at 12:44 AM.

  2. #2

    Default Re: scripting.lua commands

    In Napoleon:Total War there's a condition if britain is destroyed:
    local BOOL_britain_destroyed = false
    I think you should set false to true and then add the reward.
    Good luck!
    "You can ask me for anything you like, except time."
    Napoleon Bonaparte
    "If you want a thing done well, do it yourself."
    Napoleon Bonaparte
    "You don't reason with intellectuals. You shoot them."
    Napoleon Bonaparte

  3. #3

    Default Re: scripting.lua commands

    Thanks, i will!

  4. #4

    Default Re: scripting.lua commands

    So this works btw

    --[TARGET]--
    "local BOOL_Mori_destroyed = true",
    --[REWARD]--
    "grant_unit:sh_lubu#jap_mino")
    end


    just thought id post an update

  5. #5

    Default Re: scripting.lua commands

    Just kidding..... Actually I was wrong, the mission somehow still has the conditions for "capture any province" once in game...

    Im trying to edit the starting shimazu mission,
    Which Ive changed to :

    Spoiler Alert, click show to read: 
    -- SHIMAZU ----
    -- MISSIONS --

    -- Shimazu Mission 1: Capture Osumi Province
    local function shimazu_intro_mission_one()
    out.ting("Shimazu Mission: Capture Osumi Province")
    scripting.game_interface:trigger_custom_mission(--[MISSION KEY]--
    "jap_shimazu_intro_mission_one",
    --[MISSION ISSUER]--
    "CLAN_ELDERS",
    --[FACTION KEY]--
    "shimazu",
    --[TURN LIMIT]--
    10,
    --[TARGET]--
    "local BOOL_Mori_destroyed = true",
    --[REWARD]--
    "grant_unit:sh_lubu#jap_mino")
    end




    any idea why the condition is still to capture any province?

    Edit:
    I think its because that command isnt a valid string. If I change it to "region:jap_mino" the condition successfully changes In game :-/
    Last edited by Havie; February 14, 2016 at 09:44 PM.

Posting Permissions

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