Modding Q&A [For Quick Questions and Answers]

Users who are viewing this thread

Status
Not open for further replies.
Fearg said:
there was an unexpected end to my troops.txt

it compiles fine so its not a syntax error

shows us the compilation output, or check your file to see if its not broken. The first line above contradicts the second.

other than that you may have found a engine limitation, which is independent of compilation.
 
Code:
Initializing...
variables.txt not found. Creating new variables.txt file
Compiling all global variables...
variables.txt not found. Creating new variables.txt file
variable_uses.txt not found. Creating new variable_uses.txt file
Exporting strings...
Exporting skills...
Exporting tracks...
Exporting animations...
Exporting meshes...
Exporting sounds...
Exporting skins...
Exporting faction data...
Exporting scene data...
Creating new tag_uses.txt file...
Creating new quick_strings.txt file...
Exporting particle data...
Exporting scene props...
Exporting quest data...
Exporting info_page data...
exporting simple triggers...
exporting triggers...
exporting dialogs...
Exporting postfx_params...
Exporting item data...
Exporting map icons...
Exporting troops data
Traceback (most recent call last):
  File "process_troops.py", line 111, in <module>
    save_troops()
  File "process_troops.py", line 38, in save_troops
    for inventory_item in inventory_list:
TypeError: 'int' object is not iterable
Exporting tableau materials data...
Exporting presentations...
Exporting scripts...
Exporting game menus data...
Exporting mission_template data...
WARNING: Usage of unassigned global variable: $g_wedding_bishop_troop
WARNING: Usage of unassigned global variable: $g_wedding_bride_troop
WARNING: Usage of unassigned global variable: $g_wedding_brides_dad_troop
WARNING: Usage of unassigned global variable: $g_wedding_groom_troop
WARNING: Usage of unassigned global variable: $g_wedding_groom_troop
WARNING: Usage of unassigned global variable: $g_wedding_bride_troop
WARNING: Usage of unassigned global variable: $g_wedding_brides_dad_troop
WARNING: Usage of unassigned global variable: $g_wedding_bishop_troop
WARNING: Usage of unassigned global variable: $g_wedding_bride_troop
WARNING: Usage of unassigned global variable: $g_wedding_brides_dad_troop
WARNING: Usage of unassigned global variable: $g_wedding_bride_troop
WARNING: Usage of unassigned global variable: $g_wedding_brides_dad_troop
WARNING: Usage of unassigned global variable: $g_wedding_bride_troop
WARNING: Usage of unassigned global variable: $g_wedding_brides_dad_troop
WARNING: Usage of unassigned global variable: $g_wedding_groom_troop
Exporting party_template data...
Exporting parties
Checking global variable usages...
WARNING: Global variable never used: g_last_archery_point_earned
WARNING: Global variable never used: g_number_of_map_ports
WARNING: Global variable never used: benefit_arguments_made
WARNING: Global variable never used: tutorial_time
WARNING: Global variable never used: animation_on
WARNING: Global variable never used: autosave_on
WARNING: Global variable never used: g_lord_long_term_count
WARNING: Global variable never used: g_multiplayer_team_1_first_spawn
WARNING: Global variable never used: g_multiplayer_team_2_first_spawn
WARNING: Global variable never used: g_start_arena_fight_at_nearest_town
WARNING: Global variable never used: $g_wedding_bishop_troop
WARNING: Global variable never used: $g_wedding_bride_troop
WARNING: Global variable never used: $g_wedding_brides_dad_troop
WARNING: Global variable never used: $g_wedding_groom_troop
WARNING: Global variable never used: $g_wedding_groom_troop
WARNING: Global variable never used: $g_wedding_bride_troop
WARNING: Global variable never used: $g_wedding_brides_dad_troop
WARNING: Global variable never used: $g_wedding_bishop_troop
WARNING: Global variable never used: $g_wedding_bride_troop
WARNING: Global variable never used: $g_wedding_brides_dad_troop
WARNING: Global variable never used: $g_wedding_bride_troop
WARNING: Global variable never used: $g_wedding_brides_dad_troop
WARNING: Global variable never used: $g_wedding_bride_troop
WARNING: Global variable never used: $g_wedding_brides_dad_troop
WARNING: Global variable never used: $g_wedding_groom_troop
echo ______________________________
echo Script processing has ended.
Press any key to exit. . .

And you were right, there's an error from the compiler

Exporting troops data
Traceback (most recent call last):
  File "process_troops.py", line 111, in <module>
    save_troops()
  File "process_troops.py", line 38, in save_troops
    for inventory_item in inventory_list:
TypeError: 'int' object is not iterable
 
Hey guys, I have a question. I've been trying to port a mod(the great 1866 mod) from Vanilla M&B to Warband, for personal joy, not public. I've done 95% of the work, mostly done with it, but there's this annoying thing that bothers me for some time now. Since I have ironed out all the other issues, pretty much, I'd appreciate some help. Here's the error message:

xivKo.png

Any ideas? I mean, I know the source, animations and I have the 'Native' Warband animations, plus others to fix whatever animation it is (a horse one, of course), but I am clueless as to what I do. Oh, also, how do I disable the error debug messages(red text). They are all idiotic warnings about pedestrians and such, all the important bits I have fixed, but the torrents of error messages kinda annoy me, they flood and don't show other useful stuff, like damage and such.

If anyone has an idea, I'd be really grateful. Thanks!
 
Edgar Allan Poe said:
xivKo.png

Any ideas?

module_animations.py is divided in two: human animations (first), horse animations (last). You can't use a human animation (with human skeleton) on a horse entry

Code:
#### Animations begin here

# All of the animations are hardcoded. You can edit the individual sequences, resources or times. But each
# animation must stay at the same position, otherwise the game won't run properly. If you want to add a new animation,
# you can change both the ids and values of the animations which are named as unused_human_anim_???
# and unused_horse_anim_??? (??? = any number). You must not change used animations' ids.

Code:
 ### Unused human animations start from here.

last human and first horse entry

Code:
 ["unused_human_anim_100", 0, 0, [1.0, "anim_human", 0, 1, 0]],

 ["horse_stand", 0, amf_client_prediction,

open your ID_animations.py to see which one is 406
 
kalarhan said:
maater66241 said:
Are the warnings anything I should be worried of or no?

The following errors were generated during compilation:
  try/end operations do not match in script.copy_troop: 1 try_end(s) missing

The following warnings were generated during compilation:
  duplicate entity found: itm.vaegir_army_coat

The following notifications were generated during compilation:
  local l.unused declared but never used in script.game_get_troop_wage

warning is something you should fix, as it may lead to bugs. It didn't break the compilation, but remember that compilation is just one step, as you have bugs that will only show up on runtime (when gaming is working).

read the warning messages and you should figure out what each one means. 1) find that script and review your blocks; 2) you have two items with the same name; 3) you have strings (module_strings.py) with the same name, delete one

I know that their are duplicates, but for the others: do they state which script and string is creating warnings/errors? Or must I find them myself?
 
i tried doing some stuff on my own but with no success what i'm trying to do is having some special units to recruit in villages i tried duplicating the old recruiting menu and making my own one but with no luck i saw that in the nobles recruiting from towns and castles we used tier 5 troops
Code:
slot_faction_tier_5_troop

so i thought if i can maybe create a new one  like this (if it is possible but i tried...)
Code:
slot_special_troop
but then i didn't know how to assign my own troops to this one and i got many ideas do i need to have them in all of the factions in module script below the tiers like this one here
Code:
......
	  # Cultures:
      (faction_set_slot, "fac_culture_1",  slot_faction_tier_1_troop, "trp_akamatsu_peasent"),
      (faction_set_slot, "fac_culture_1",  slot_faction_tier_2_troop, "trp_akamatsu_skrimisher"),
      (faction_set_slot, "fac_culture_1",  slot_faction_tier_3_troop, "trp_akamatsu_yari_ashigaru"),
      (faction_set_slot, "fac_culture_1",  slot_faction_tier_4_troop, "trp_akamatsu_experienced_yari_ashigaru"),
      (faction_set_slot, "fac_culture_1",  slot_faction_tier_5_troop, "trp_akamatsu_elite_yari_ashigaru"),
      (faction_set_slot, "fac_culture_1",  slot_faction_tier_6_troop, "trp_akamatsu_yari_cavalry"),

      (faction_set_slot, "fac_culture_1",  slot_special_troop, "trp_special_troop"),#### this here is an example

      (faction_set_slot, "fac_culture_1", slot_faction_town_walker_male_troop, "trp_town_walker_1"),
      (faction_set_slot, "fac_culture_1", slot_faction_town_walker_female_troop, "trp_town_walker_2"),
      (faction_set_slot, "fac_culture_1", slot_faction_village_walker_male_troop, "trp_village_walker_1"),
      (faction_set_slot, "fac_culture_1", slot_faction_village_walker_female_troop, "trp_village_walker_2"),
      (faction_set_slot, "fac_culture_1", slot_faction_town_spy_male_troop, "trp_spy_walker_1"),
      (faction_set_slot, "fac_culture_1", slot_faction_town_spy_female_troop, "trp_spy_walker_2"),

      (faction_set_slot, "fac_culture_2",  slot_faction_tier_1_troop, "trp_akizuki_peasent"),
      (faction_set_slot, "fac_culture_2",  slot_faction_tier_2_troop, "trp_akizuki_skrimisher"),
      (faction_set_slot, "fac_culture_2",  slot_faction_tier_3_troop, "trp_akizuki_yari_ashigaru"),
      (faction_set_slot, "fac_culture_2",  slot_faction_tier_4_troop, "trp_akizuki_experienced_yari_ashigaru"),
      (faction_set_slot, "fac_culture_2",  slot_faction_tier_5_troop, "trp_akizuki_elite_yari_ashigaru"),
      (faction_set_slot, "fac_culture_2",  slot_faction_tier_6_troop, "trp_akizuki_yari_cavalry"),
.........
but i'm not sure if it will work so i'm here asking how can i have it working or is there an OSC (open source code)
that have this feature of allowing to recruit special units in villages
and another question how can i make it only for certain villages (if there is something that i can take as an example please do tell me i'll appreciate thanks!)
 
So I was trying to make my own mod (NewNative) but when I clicked build_module.bat I got this problem.
Initializing...
variables.txt not found. Creating new variables.txt file
Compiling all global variables...
variables.txt not found. Creating new variables.txt file
variable_uses.txt not found. Creating new variable_uses.txt file
Traceback (most recent call last):
  File "process_global_variables.py", line 106, in <module>
    save_variables(export_dir, variables,variable_uses)
  File "C:\Users\You\Desktop\Module_system 1.171\process_operations.py", line 171, in save_variables
    file = open(export_dir + "variables.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/variables.txt'
Exporting strings...
Traceback (most recent call last):
  File "process_strings.py", line 26, in <module>
    save_strings(strings)
  File "process_strings.py", line 9, in save_strings
    ofile = open(export_dir + "strings.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/strings.txt'
Exporting skills...
Traceback (most recent call last):
  File "process_skills.py", line 32, in <module>
    save_skills()
  File "process_skills.py", line 15, in save_skills
    ofile = open(export_dir + "skills.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/skills.txt'
Exporting tracks...
Traceback (most recent call last):
  File "process_music.py", line 23, in <module>
    save_tracks()
  File "process_music.py", line 15, in save_tracks
    file = open(export_dir + "music.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/music.txt'
Exporting animations...
Traceback (most recent call last):
  File "process_animations.py", line 61, in <module>
    write_actions(animations,len(action_codes),action_codes,"actions.txt")
  File "process_animations.py", line 24, in write_actions
    file = open(export_dir + file_name,"w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/actions.txt'
Exporting meshes...
Traceback (most recent call last):
  File "process_meshes.py", line 25, in <module>
    save_meshes()
  File "process_meshes.py", line 9, in save_meshes
    ofile = open(export_dir + "meshes.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/meshes.txt'
Exporting sounds...
Traceback (most recent call last):
  File "process_sounds.py", line 51, in <module>
    write_sounds(sound_samples, sounds)
  File "process_sounds.py", line 13, in write_sounds
    ofile = open(export_dir + "sounds.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/sounds.txt'
Exporting skins...
Traceback (most recent call last):
  File "process_skins.py", line 105, in <module>
    export_skins(skins)
  File "process_skins.py", line 45, in export_skins
    ofile = open(export_dir + "skins.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/skins.txt'
Exporting map icons...
variables.txt not found. Creating new variables.txt file
variable_uses.txt not found. Creating new variable_uses.txt file
Creating new tag_uses.txt file...
Creating new quick_strings.txt file...
Traceback (most recent call last):
  File "process_map_icons.py", line 38, in <module>
    save_map_icons(variables,variable_uses,tag_uses,quick_strings)
  File "process_map_icons.py", line 9, in save_map_icons
    ofile = open(export_dir + "map_icons.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/map_icons.txt'
Exporting faction data...
Traceback (most recent call last):
  File "process_factions.py", line 70, in <module>
    save_factions(relations)
  File "process_factions.py", line 34, in save_factions
    file = open(export_dir + "factions.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/factions.txt'
Exporting item data...
variables.txt not found. Creating new variables.txt file
variable_uses.txt not found. Creating new variable_uses.txt file
Creating new tag_uses.txt file...
Creating new quick_strings.txt file...
Traceback (most recent call last):
  File "process_items.py", line 72, in <module>
    write_items(variables,variable_uses,tag_uses,quick_strings)
  File "process_items.py", line 19, in write_items
    ofile = open(itemkinds_file_name,"w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/item_kinds1.txt'
Exporting scene data...
variables.txt not found. Creating new variables.txt file
variable_uses.txt not found. Creating new variable_uses.txt file
Creating new tag_uses.txt file...
Creating new quick_strings.txt file...
Traceback (most recent call last):
  File "process_scenes.py", line 77, in <module>
    save_scenes(variables,variable_uses,tag_uses)
  File "process_scenes.py", line 46, in save_scenes
    ofile = open(export_dir + "scenes.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/scenes.txt'
Exporting troops data
Traceback (most recent call last):
  File "process_troops.py", line 107, in <module>
    save_troops()
  File "process_troops.py", line 13, in save_troops
    file = open(export_dir + "troops.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/troops.txt'
Exporting particle data...
Traceback (most recent call last):
  File "process_particle_sys.py", line 61, in <module>
    save_particle_systems()
  File "process_particle_sys.py", line 29, in save_particle_systems
    ofile = open(export_dir + "particle_systems.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/particle_systems.txt'
Exporting scene props...
variables.txt not found. Creating new variables.txt file
variable_uses.txt not found. Creating new variable_uses.txt file
Creating new tag_uses.txt file...
Creating new quick_strings.txt file...
Traceback (most recent call last):
  File "process_scene_props.py", line 32, in <module>
    save_scene_props(variables,variable_uses,tag_uses,quick_strings)
  File "process_scene_props.py", line 10, in save_scene_props
    ofile = open(export_dir + "scene_props.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/scene_props.txt'
Exporting tableau materials data...
variables.txt not found. Creating new variables.txt file
variable_uses.txt not found. Creating new variable_uses.txt file
Creating new tag_uses.txt file...
Creating new quick_strings.txt file...
Traceback (most recent call last):
  File "process_tableau_materials.py", line 31, in <module>
    save_tableau_materials(variables,variable_uses,tag_uses,quick_strings)
  File "process_tableau_materials.py", line 11, in save_tableau_materials
    ofile = open(export_dir + "tableau_materials.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/tableau_materials.txt'
Exporting presentations...
variables.txt not found. Creating new variables.txt file
variable_uses.txt not found. Creating new variable_uses.txt file
Creating new tag_uses.txt file...
Creating new quick_strings.txt file...
Traceback (most recent call last):
  File "process_presentations.py", line 33, in <module>
    save_presentations(variables,variable_uses,tag_uses,quick_strings)
  File "process_presentations.py", line 11, in save_presentations
    ofile = open(export_dir + "presentations.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/presentations.txt'
Exporting party_template data...
Traceback (most recent call last):
  File "process_party_tmps.py", line 46, in <module>
    save_party_templates()
  File "process_party_tmps.py", line 20, in save_party_templates
    file = open(export_dir + "party_templates.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/party_templates.txt'
Exporting parties
Creating new tag_uses.txt file...
Traceback (most recent call last):
  File "process_parties.py", line 69, in <module>
    save_parties(parties)
  File "process_parties.py", line 12, in save_parties
    file = open(export_dir + "parties.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/parties.txt'
Exporting quest data...
Traceback (most recent call last):
  File "process_quests.py", line 30, in <module>
    save_quests()
  File "process_quests.py", line 9, in save_quests
    ofile = open(export_dir + "quests.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/quests.txt'
Exporting info_page data...
Traceback (most recent call last):
  File "process_info_pages.py", line 26, in <module>
    save_info_pages()
  File "process_info_pages.py", line 9, in save_info_pages
    ofile = open(export_dir + "info_pages.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/info_pages.txt'
Exporting scripts...
variables.txt not found. Creating new variables.txt file
variable_uses.txt not found. Creating new variable_uses.txt file
Creating new tag_uses.txt file...
Creating new quick_strings.txt file...
Traceback (most recent call last):
  File "process_scripts.py", line 40, in <module>
    save_scripts(variables,variable_uses,scripts,tag_uses,quick_strings)
  File "process_scripts.py", line 10, in save_scripts
    file = open(export_dir + "scripts.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/scripts.txt'
Exporting mission_template data...
variables.txt not found. Creating new variables.txt file
variable_uses.txt not found. Creating new variable_uses.txt file
Creating new tag_uses.txt file...
Creating new quick_strings.txt file...
Traceback (most recent call last):
  File "process_mission_tmps.py", line 64, in <module>
    save_mission_templates(variables,variable_uses,tag_uses,quick_strings)
  File "process_mission_tmps.py", line 38, in save_mission_templates
    file = open(export_dir + "mission_templates.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/mission_templates.txt'
Exporting game menus data...
variables.txt not found. Creating new variables.txt file
variable_uses.txt not found. Creating new variable_uses.txt file
Creating new tag_uses.txt file...
Creating new quick_strings.txt file...
Traceback (most recent call last):
  File "process_game_menus.py", line 47, in <module>
    save_game_menus(variables,variable_uses,tag_uses,quick_strings)
  File "process_game_menus.py", line 22, in save_game_menus
    ofile = open(export_dir + "menus.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/menus.txt'
exporting simple triggers...
variables.txt not found. Creating new variables.txt file
variable_uses.txt not found. Creating new variable_uses.txt file
Creating new tag_uses.txt file...
Creating new quick_strings.txt file...
Traceback (most recent call last):
  File "process_simple_triggers.py", line 24, in <module>
    save_simple_triggers(variables,variable_uses,simple_triggers,tag_uses,quick_strings)
  File "process_simple_triggers.py", line 8, in save_simple_triggers
    file = open(export_dir + "simple_triggers.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/simple_triggers.txt'
exporting triggers...
variables.txt not found. Creating new variables.txt file
variable_uses.txt not found. Creating new variable_uses.txt file
Creating new tag_uses.txt file...
Creating new quick_strings.txt file...
Traceback (most recent call last):
  File "process_dialogs.py", line 199, in <module>
    save_triggers(variables,variable_uses,triggers,tag_uses,quick_strings)
  File "process_dialogs.py", line 47, in save_triggers
    file = open(export_dir + "triggers.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/triggers.txt'
Checking global variable usages...
variables.txt not found. Creating new variables.txt file
variable_uses.txt not found. Creating new variable_uses.txt file
Exporting postfx_params...
Traceback (most recent call last):
  File "process_postfx.py", line 27, in <module>
    write_postfx_params(postfx_params)
  File "process_postfx.py", line 13, in write_postfx_params
    ofile = open(export_dir + "postfx.txt","w")
IOError: [Errno 2] No such file or directory: 'C:/Program Files (x86)/Mount&Blade Warband/Modules/NewNative/postfx.txt'

______________________________

Script processing has ended.
Press any key to exit. . .
I don't know if this is a new problem or a problem that happened to others. If anyone have any ideas why this is happening, tell me.
 
HyperCharge said:
How can I prevent 2 factions away from each other to war ?

For example; England and byzantium goes war. But they are too away to each other. But they don't notice that. So, What determines to open war between factions ? These maybe ?
Code:
 (party_set_slot, "p_castle_10", slot_center_ex_faction, "fac_kingdom_2"), #vaegirs claim nord-held alburq
      (party_set_slot, "p_castle_13", slot_center_ex_faction, "fac_kingdom_4"), #nords claim swadian-held kelredan
      (party_set_slot, "p_castle_15", slot_center_ex_faction, "fac_kingdom_1"), #swadians claim rhodok-held ergelon
      (party_set_slot, "p_castle_46", slot_center_ex_faction, "fac_kingdom_5"), #rhodoks claim sarranid-held weyyah
      (party_set_slot, "p_castle_40", slot_center_ex_faction, "fac_kingdom_6"), #sarranids claim khergit-held uhhun
      (party_set_slot, "p_town_11",   slot_center_ex_faction, "fac_kingdom_3"), #Khergits claim vaegir-held curaw

Plus ↓



I made this to do process with only kingdoms that active in 1300. But it doesn't work. Cities are empty because of somehow this condition is not true.
Code:
#Set the kingdoms
  (faction_set_slot, "fac_kingdom_53", slot_faction_state, sfs_inactive), #multiplayer_faction_ottoman
  (faction_set_slot, "fac_kingdom_33", slot_faction_state, sfs_inactive), #minsk
  (faction_set_slot, "fac_kingdom_34", slot_faction_state, sfs_inactive), #karaman
  (faction_set_slot, "fac_kingdom_35", slot_faction_state, sfs_inactive), #wallachia
  (faction_set_slot, "fac_kingdom_36", slot_faction_state, sfs_inactive), #trebizond
  (faction_set_slot, "fac_kingdom_37", slot_faction_state, sfs_inactive), #dulkadir
  (faction_set_slot, "fac_kingdom_38", slot_faction_state, sfs_inactive), #eretna
  (faction_set_slot, "fac_kingdom_39", slot_faction_state, sfs_inactive), #rodos
  (faction_set_slot, "fac_kingdom_40", slot_faction_state, sfs_inactive), #georgia
  (faction_set_slot, "fac_kingdom_41", slot_faction_state, sfs_inactive), #navarra
  (faction_set_slot, "fac_kingdom_42", slot_faction_state, sfs_inactive), #moldovia
  (faction_set_slot, "fac_kingdom_43", slot_faction_state, sfs_inactive), #albania
  (faction_set_slot, "fac_kingdom_44", slot_faction_state, sfs_inactive), #bosnia
  (faction_set_slot, "fac_kingdom_45", slot_faction_state, sfs_inactive), #moscow
  (faction_set_slot, "fac_kingdom_46", slot_faction_state, sfs_inactive), #florance
  (faction_set_slot, "fac_kingdom_47", slot_faction_state, sfs_inactive), #temur
  (faction_set_slot, "fac_kingdom_48", slot_faction_state, sfs_inactive), #karakoyun
  (faction_set_slot, "fac_kingdom_49", slot_faction_state, sfs_inactive), #crimea
  (faction_set_slot, "fac_kingdom_51", slot_faction_state, sfs_inactive), #naples

  (try_for_range, ":faction_no", kingdoms_begin, kingdoms_end), 
  (faction_slot_eq, ":faction_no", slot_faction_state, sfs_active), #prevent inactive kingdoms to slowdown the game_start loading
        (call_script, "script_faction_recalculate_strength", ":faction_no"),
      (try_end),

(try_for_range, ":kingdom", kingdoms_begin, kingdoms_end),
      (faction_slot_eq, ":faction_no", slot_faction_state, sfs_active),
        (call_script, "script_evaluate_realm_stability", ":kingdom"),
      (try_end),

      (try_for_range, ":cur_kingdom", kingdoms_begin, kingdoms_end),
      (faction_slot_eq, ":faction_no", slot_faction_state, sfs_active),
        (call_script, "script_update_faction_notes", ":cur_kingdom"),
        (store_random_in_range, ":random_no", -60, 0),
        (faction_set_slot, ":faction_no", slot_faction_last_offensive_concluded, ":random_no"),
      (try_end),

# Setting random feast time
      (try_for_range, ":faction_no", kingdoms_begin, kingdoms_end),
      (faction_slot_eq, ":faction_no", slot_faction_state, sfs_active),
        (store_random_in_range, ":last_feast_time", 0, 312), #240 + 72
        (val_mul, ":last_feast_time", -1),
        (faction_set_slot, ":faction_no", slot_faction_last_feast_start_time, ":last_feast_time"),
      (try_end),

...


And how can I prevent "Faction defeated!" menu for inactive kingdoms ?
 
I just scaled my world map down using Blender. (exported obj using Swyter's Cartographer, pressed S in Blender and scaled it down, then export obj and import again through Swyter)

It worked well- the map looks much better and more detailed now that its scaled down. But the textures no longer blend correctly in game, how do I fix this?

gKorDqP.jpg
 
NothingHere said:
So I was trying to make my own mod (NewNative) but when I clicked build_module.bat I got this problem.

this is a very common newbie mistake. Which means most of us saw it when we were trying modding for the first time, so don't feel bad  :mrgreen:

now read this tutorial to learn how to setup your modsys, as your "export_dir" variable is wrong.
:arrow: https://forums.taleworlds.com/index.php/topic,240255.0.html

you should also aim to learn how to read the error messages. They tell you important things, which should help you figure out what you did wrong (and you will see many of them in your future, while you are learning the basics)
 
I have used this trigger (in module_triggers). But people are saying its triggering after 200 ingame days. Anyone know why?


Code:
  (24.0 * 700, 0, ti_once, 
    [
	    (eq, "$test", 0),
		(map_free),
		

	], 
	[

             do thing
		
	]),


My understanding, it should check every 700 days for $test to be 0, if it is then fire the trigger once only but with 0 delay. So why is it firing after 200 days?
 
can someone help me here ? thanks
imado552 said:
i tried doing some stuff on my own but with no success what i'm trying to do is having some special units to recruit in villages i tried duplicating the old recruiting menu and making my own one but with no luck i saw that in the nobles recruiting from towns and castles we used tier 5 troops
Code:
slot_faction_tier_5_troop

so i thought if i can maybe create a new one  like this (if it is possible but i tried...)
Code:
slot_special_troop
but then i didn't know how to assign my own troops to this one and i got many ideas do i need to have them in all of the factions in module script below the tiers like this one here
Code:
......
	  # Cultures:
      (faction_set_slot, "fac_culture_1",  slot_faction_tier_1_troop, "trp_akamatsu_peasent"),
      (faction_set_slot, "fac_culture_1",  slot_faction_tier_2_troop, "trp_akamatsu_skrimisher"),
      (faction_set_slot, "fac_culture_1",  slot_faction_tier_3_troop, "trp_akamatsu_yari_ashigaru"),
      (faction_set_slot, "fac_culture_1",  slot_faction_tier_4_troop, "trp_akamatsu_experienced_yari_ashigaru"),
      (faction_set_slot, "fac_culture_1",  slot_faction_tier_5_troop, "trp_akamatsu_elite_yari_ashigaru"),
      (faction_set_slot, "fac_culture_1",  slot_faction_tier_6_troop, "trp_akamatsu_yari_cavalry"),

      (faction_set_slot, "fac_culture_1",  slot_special_troop, "trp_special_troop"),#### this here is an example

      (faction_set_slot, "fac_culture_1", slot_faction_town_walker_male_troop, "trp_town_walker_1"),
      (faction_set_slot, "fac_culture_1", slot_faction_town_walker_female_troop, "trp_town_walker_2"),
      (faction_set_slot, "fac_culture_1", slot_faction_village_walker_male_troop, "trp_village_walker_1"),
      (faction_set_slot, "fac_culture_1", slot_faction_village_walker_female_troop, "trp_village_walker_2"),
      (faction_set_slot, "fac_culture_1", slot_faction_town_spy_male_troop, "trp_spy_walker_1"),
      (faction_set_slot, "fac_culture_1", slot_faction_town_spy_female_troop, "trp_spy_walker_2"),

      (faction_set_slot, "fac_culture_2",  slot_faction_tier_1_troop, "trp_akizuki_peasent"),
      (faction_set_slot, "fac_culture_2",  slot_faction_tier_2_troop, "trp_akizuki_skrimisher"),
      (faction_set_slot, "fac_culture_2",  slot_faction_tier_3_troop, "trp_akizuki_yari_ashigaru"),
      (faction_set_slot, "fac_culture_2",  slot_faction_tier_4_troop, "trp_akizuki_experienced_yari_ashigaru"),
      (faction_set_slot, "fac_culture_2",  slot_faction_tier_5_troop, "trp_akizuki_elite_yari_ashigaru"),
      (faction_set_slot, "fac_culture_2",  slot_faction_tier_6_troop, "trp_akizuki_yari_cavalry"),
.........
but i'm not sure if it will work so i'm here asking how can i have it working or is there an OSC (open source code)
that have this feature of allowing to recruit special units in villages
and another question how can i make it only for certain villages (if there is something that i can take as an example please do tell me i'll appreciate thanks!)
 
produno said:
I have used this trigger (in module_triggers). But people are saying its triggering after 200 ingame days. Anyone know why?
[...]
I might be wrong and this rule might not apply to regular triggers, but, for example, simple triggers don't count from zero, but rather from a certain random point.

You can always just re-write the trigger to check for the current day.
Like
(store_current_day, ":cur_day"),
(ge, ":cur_day", 700),

HyperCharge said:
How can I prevent 2 factions away from each other to war ?
What determines to open war between factions ?
Many things.
randomly_start_war_peace_new script that is based on complicated npc_decision_checklist_peace_or_war script.
Read these scripts.
Find the place where script_diplomacy_start_war_between_kingdoms is finally called and don't let it happen. The exact preventive code to do this can be written in many ways.
It can be based on particular faction, on distance between factions, on the number of active wars etc.

HyperCharge said:
And how can I prevent "Faction defeated!" menu for inactive kingdoms ?
Same thing. Find this menu, then find the simple trigger or script that calls for this menu and add conditions that will prevent the menu from being called when (neg|faction_slot_eq, ":faction_no", slot_faction_state, sfs_active),

imado552 said:
i tried doing some stuff on my own but with no success what i'm trying to do is having some special units to recruit in villages i tried duplicating the old recruiting menu and making my own one but with no luck i saw that in the nobles recruiting from towns and castles we used tier 5 troops
Write to this guy:
https://forums.taleworlds.com/index.php?action=profile;u=480747
Ask him to forward you my sent messages.
I explained to him how to add new recruitment option several days ago...
 
Tüfekçi Başı said:
Are skins limited in module skins? I added 16. skin and some troops bugged. Is that reason?

I thought the limit was 15. CHeck a mod like Warsword Conquest, they have the max.
 
Leonion said:
Write to this guy:
https://forums.taleworlds.com/index.php?action=profile;u=480747
Ask him to forward you my sent messages.
I explained to him how to add new recruitment option several days ago...
thanks i'll try that!
 
Status
Not open for further replies.
Back
Top Bottom