Results 1 to 5 of 5

Thread: intermediate modding questions

  1. #1

    Default intermediate modding questions

    1. I appreciate the help that experienced modders may provide on this forum. A number of the threads here are questions, which nobody ever answered. Is there another forum or another site, which people may recommend as an additional place to try getting help?

    2. Where is the place where base game missions are customized? For example, a mission to assassinate some particular agent, or to recruit a unit in some particular province. The mission db files contain some basic text for the mission; but some part of the game code must "fill in" values like the name of the province, based on the current game situation. I am trying to write some new missions, and it would be helpful to see the existing game code for this. As an example, export_ancillaries.lua contains all the code for determining which ancillaries are available; but export_missions.lua does not contain anything to "fill in" missions and most of it appears to apply to ETW anyway since it has European city names.

    3. Is there any way to tell which effects can be used by which types of object? In the db table for effects we can see many interesting effects, such as "campaign_map_stealth" (enables army to lay ambush in any terrain). Can this be added to an ancillary, or a building? For some other effects, the name has a prefix such as "clan_trait_shimazu_superior_katana_hero" and we could "assume" this can only be applied to a clan, not to a general, or building, or tech. But, I can't find any way to see which effects will actually work when applied to a certain object. See this post for one failed experiment.

    Any help would be greatly appreciated.

  2. #2

    Default Re: intermediate modding questions

    hey,

    both of your questions should have answers in the tools, tutorials, resources page. For 2., check out the guides to cheating/all clan traits. Some of them include information about the page that deals with missions. For 3, check out the PFM discussions, and the PFM itself. You have to figure some things out for yourself, but once you've been doing it for a while it begins to make sense. Also, you can learn a lot from the ETW tools, tutorials, resources page too, since the engine and especially the data format is very similar

  3. #3

    Default Re: intermediate modding questions

    Thanks. For (2), I have read all the tools and tutorial pages for Shogun, and I did not find anything that answers this question. It is possible that there are tutorials for NTW or ETW which describe this; but a lot of the material there specifically does not apply to Shogun. Are there specific references in NTW or ETW which you feel would answer this? Or do you see a reference in the Shogun tutorial material which describes "filling in" the values for missions?

    For (3), I do not agree that the information is available in PFM. I have used PFM and its data to find many interesting things; but there is nothing which says what objects an effect can be applied to. In the linked post with my failed experiment, I have given some details of what I tried. For example, in that post I have shown that the game simply ignores the building_mod_income_farms effect when applied to an ancillary. I do not want to try hundreds of playtests to figure out which effects will work on ancillaries. I am hoping somebody can point out a specific place where this is either (a) documented, or (b) given as data in some table which I have overlooked.

  4. #4

    Default Re: intermediate modding questions

    Bump. Where is the code that fills in the variables for missions? For example, in the db\missions table, we see one of the initial missions jap_chosokabe_intro_three has type CAPTURE_REGIONS, but there is nothing in the table which says the names of the valid regions. This must be in a lua file somewhere. Does anybody know where?

  5. #5

    Default Re: intermediate modding questions

    Answering my own question. I suppose that means I have "leveled up" in modding :-). The key file for this is db/cdir_events_mission_option_junctions_tables. I do not have all the details. But the fields in this file appear to give (a) the conditions under which a mission can be given, and (b) statements which "generate" the particulars of the mission. For example, the following lines are defined for the Agrarian Matters mission:

    VAR_CHANCE True 5
    VAR_MISSION_LENGTH_MIN True 2
    VAR_MISSION_LENGTH_MAX True 6
    VAR_MISSION_LENGTH_ADDITIONAL_MIN True 0
    VAR_MISSION_LENGTH_ADDITIONAL_MAX True 4
    VAR_MISSION_LENGTH_MOD_EASY True 1.5
    VAR_MISSION_LENGTH_MOD_NORMAL True 1.2
    VAR_MISSION_LENGTH_MOD_HARD True 1.0
    VAR_MISSION_LENGTH_MOD_VERY_HARD True 0.9
    CND_CAMPAIGN True jap_shogun
    CND_MISSION_TYPE_ROUNDS_UNTIL_NEXT True 12
    GEN_TARGET_REGION False
    GEN_CND_REGION_BUILDING_CHAIN_AVAILABLE True SHO_Farming
    CND_CONSTRUCTING_NOT_BUILDING_CHAIN True SHO_Farming

    This appears to say that the chance of the mission is 5%. The length is 2-6 turns, plus an additional 0-4 turns modified by the campaign difficulty. At least 12 turns must elapse between when the game offers the mission and when it offers it again. When the mission occurs, generate a target region, where there is an available building in the farm chain and the player is not building it. I suppose if no valid target region is found then the mission cannot be given.

Posting Permissions

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