Recent content by zidozido

  1. Modding Q&A [For Quick Questions and Answers]

    Code:
    *** Warband Refined & Enhanced Compiler Kit (W.R.E.C.K.) version 1.0.0 ***
    Please report errors, problems and suggestions at http://lav.lomskih.net/wreck/
    
    Loading module... FAILED.
    MODULE `scripts` ERROR:
    Traceback (most recent call last):
      File "compile.py", line 109, in <module>
        from module_scripts import *
      File "F:\Mount and Blade - Warband\Modules\Alpujarras Wars V.4 test\code\module_scripts.py", line 35539
        ]),
        ^
    SyntaxError: invalid syntax
    
    
    COMPILATION FAILED.
    
    Press any key to continue . . .
    i want to know why every time i add something to module scripts this happens and also get error always in this code
    Code:
    ]
    # modmerger_start version=201 type=2
    try:
        component_name = "scripts"
        var_set = { "scripts" : scripts }
        from modmerger import modmerge
        modmerge(var_set)
    except:
        raise
    # modmerger_end
    always there is an error in the try after i add something new. the code of the mentioned error above :
    Code:
    		(else_try),
    			(party_is_active, ":new_camp"),
    			(str_store_party_name, s4, ":new_camp"),
    			(remove_party, ":new_camp"),
    			(party_template_set_slot, ":bandit_template", slot_party_template_lair_party, 0),
    		(else_try),
    		(try_end),	 	 
    	(try_end),
        ]),

    please explain to me why this error occurs to me all time i usually fixed it by copying the line of code from a backup but now i have no backup so please respond to me and explain why it happens from the first place
  2. Modding Q&A [For Quick Questions and Answers]

    ok i get invalid syntax error every time i almost every time i add something to module scripts so and its always in the last block of code the modmerger so i would like to find a solution rather than reloading backup files here is the code
    Code:
    #JQ COMPANIONS QUICKVIEW
     
    ]
    # modmerger_start version=201 type=2
    try:
        component_name = "scripts"
        var_set = { "scripts" : scripts }
        from modmerger import modmerge
        modmerge(var_set)
    except:
        raise
    # modmerger_end



    so what is the error i keep doing ?
  3. Modding Q&A [For Quick Questions and Answers]

    i want to have something like crusaders in anno domini i created the faction,party templates added a spawn point but they dont appear what should i do or what is messing ?
  4. Modding Q&A [For Quick Questions and Answers]

    hello guys if i want to add a feature any one has a link to a tutorial for learning to code them also i want to add something like crusaders in anno domini mod that rooms around etc are they same as bandits but edit relations only or something different thanks in advance
  5. Modding Q&A [For Quick Questions and Answers]

    i have a small inquiry  to create something like crusaders in anno domini mod you make them as you  make bandits but with editing relations did what i say is right ?
  6. Modding Q&A [For Quick Questions and Answers]

    NPC99 said:
    zidozido said:
    ok my first problem was fixed :smile: now with the second one

    the lords of a new faction who where put on an island cant leave it how or where should i modify to make them embark and disembark

    If you want a feature, search the forums.

    NPC99 said:
    The simplest sailing needs the campaign map to have walkable roads over the seas as this can be used by standard Warband AI as well as the player. Terrain type 7 (ford/bridge) is a walkable water terrain, but it should only be used sparingly at the coasts. Its advantage is that it will properly blend with the land tiles. Its disadvantage is that too many such tiles can lead to map crashes. So for the bulk of your roads at sea, use terrain type 15 (deep ocean).
    If you do nothing more, your sea roads will look like the rest of your oceans and can be walked by both the player and AI units. However, horses riding over or men walking over waves doesn’t look great. To fix that you need a trigger to check the terrain a unit is on and to change its icon to a ship where that terrain type is 7 or 15 and back again when it is not. It needs to cover every type of unit icon.
    That then causes ship icons to appear when troops cross fords or bridges, which also looks silly. So if you want ship icons, you have to get rid of fords over rivers. You can only use bridges and the bridge icons must be placed over land tiles, not terrain type 7.  Provided your land bridge is slightly narrower than the bridge icon it will be hidden, making everything appear normal.



    PS your next problem is that hostile encounters at sea will result in land battles unless you create a sea battle scene, mission template etc.

    thanks but the strange thing that i can embark and disembark but ai lords and villagers cant so what is the file that control this feature i guess the problem isnt with the terrain as i embark and disembark easily
  7. Modding Q&A [For Quick Questions and Answers]

    PitchPL said:
    you need code it.
    oh  :roll: :roll: :roll:
    is there a tutorial which i can follow to learn how ?
  8. Modding Q&A [For Quick Questions and Answers]

    ok my first problem was fixed :smile: now with the second one

    the lords of a new faction who where put on an island cant leave it how or where should i modify to make them embark and disembark
  9. problem with newly added villages

    no i didnt create these scenes by myself and  i dont guess the problem is with ai routes the main problem is that there is no village
  10. problem with newly added villages

    ok i am sure i have done every thing right but they just dont appear here is the code of module_scenes

    Code:
      ("village_199",sf_generate,"none", "none", (0,0),(240,240),-0.5,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeC"),
      ("village_200",sf_generate,"none", "none", (0,0),(240,240),-0.5,"0x00000000200005000008ee3d00007f2800006a9100006095",
        [],[],"outer_terrain_steppeB"),
      ("village_201",sf_generate,"none", "none", (0,0),(240,240),-0.5,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeD"),
      ("village_202",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
         ("village_203",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
      ("village_204",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
      ("village_205",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
        ("village_206",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
    	  ("village_207",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
    	  ("village_208",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
      ("village_209",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
      ("village_210",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
  11. Modding Q&A [For Quick Questions and Answers]

    NPC99 said:
    villages_begin and villages_end are specifically defined in module_constants.py. Remember these are parties, which are just reduced to ID numbers for the engine to use. Any party outside that sequence range will not be treated as a village by any code which uses villages_begin or villages_end.

    Look at your ID_parties.py. A range is just a list running down from top to bottom. Module_constants.py for vanilla Warband includes:

    Code:
    towns_begin = "p_town_1"
    castles_begin = "p_castle_1"
    villages_begin = "p_village_1"
    
    towns_end = castles_begin
    castles_end = villages_begin
    villages_end   = "p_salt_mine"
    ok i checked the range its the same as vanilla warband i checked module_parties and it started with town 1 and ended with saltmine the new villages are decleared before salt mine so they are in range but still i have the error here is the module parties code
    Code:
    ("village_198","Felantix",  icon_village_c|pf_village, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(166.827, 15.5141),[], 211),
    
      ("village_199","Inca",  icon_village_c|pf_village, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(161.325, 26.351),[], 35),
    
      ("village_200","Arta",  icon_village_c|pf_village, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(169.921, 24.2639),[], 100),
    
      ("village_201","Balansat",  icon_village_c|pf_village, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(136.163, -19.7775),[], 40),
    
      ("village_202","Alaior",  icon_village_c|pf_village, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(186.849, 48.8256),[], 96),
      ("village_203","x",  icon_village_c|pf_village, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(195.00000, -138.090000),[], 96),          #[swycartographr] prev. coords: (-71.92, -198.43) #[swycartographr] prev. coords: (-71.17, -196.42) #[swycartographr] prev. coords: (184.1, -152.33) #[swycartographr] prev. coords: (235.5, -132.81) #[swycartographr] prev. coords: (195.3, -145.49) #[swycartographr] prev. coords: (197.68, -145.29) #[swycartographr] prev. coords: (-31.1, -123)
      ("village_204","y",  icon_village_c|pf_village, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(194.100000, -133.000000),[], 96),          #[swycartographr] prev. coords: (-52.71, -229.39) #[swycartographr] prev. coords: (-79.01, -207.42) #[swycartographr] prev. coords: (213.85, -127.1) #[swycartographr] prev. coords: (236.12, -134.69) #[swycartographr] prev. coords: (187.13, -145.84) #[swycartographr] prev. coords: (177.76, -132.42) #[swycartographr] prev. coords: (-31.1, -123)
      ("village_205","m",  icon_village_c|pf_village, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(180.100000, -138.000000),[], 96),          #[swycartographr] prev. coords: (-79, -226.63) #[swycartographr] prev. coords: (-81.21, -203.63) #[swycartographr] prev. coords: (200.13, -129.38) #[swycartographr] prev. coords: (261.25, -148.18) #[swycartographr] prev. coords: (205.12, -138.11) #[swycartographr] prev. coords: (205.07, -136.89) #[swycartographr] prev. coords: (-31.1, -123)
      ("village_206","z",  icon_village_c|pf_village, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(197.100000, -138.000000),[], 96),          #[swycartographr] prev. coords: (-61.53, -217.06) #[swycartographr] prev. coords: (-75.21, -213.64) #[swycartographr] prev. coords: (238.15, -133.74) #[swycartographr] prev. coords: (215.07, -143.46) #[swycartographr] prev. coords: (182.95, -136.49) #[swycartographr] prev. coords: (-31.1, -123)
      ("village_207","a",  icon_village_c|pf_village, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(190.00000, -138.090000),[], 96),          #[swycartographr] prev. coords: (-71.92, -198.43) #[swycartographr] prev. coords: (-71.17, -196.42) #[swycartographr] prev. coords: (184.1, -152.33) #[swycartographr] prev. coords: (235.5, -132.81) #[swycartographr] prev. coords: (195.3, -145.49) #[swycartographr] prev. coords: (197.68, -145.29) #[swycartographr] prev. coords: (-31.1, -123)
      ("village_208","b",  icon_village_c|pf_village, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(191.100000, -133.000000),[], 96),          #[swycartographr] prev. coords: (-52.71, -229.39) #[swycartographr] prev. coords: (-79.01, -207.42) #[swycartographr] prev. coords: (213.85, -127.1) #[swycartographr] prev. coords: (236.12, -134.69) #[swycartographr] prev. coords: (187.13, -145.84) #[swycartographr] prev. coords: (177.76, -132.42) #[swycartographr] prev. coords: (-31.1, -123)
      ("village_209","c",  icon_village_c|pf_village, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(188.100000, -138.000000),[], 96),          #[swycartographr] prev. coords: (-79, -226.63) #[swycartographr] prev. coords: (-81.21, -203.63) #[swycartographr] prev. coords: (200.13, -129.38) #[swycartographr] prev. coords: (261.25, -148.18) #[swycartographr] prev. coords: (205.12, -138.11) #[swycartographr] prev. coords: (205.07, -136.89) #[swycartographr] prev. coords: (-31.1, -123)
      ("village_2010","d",  icon_village_c|pf_village, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(200.100000, -138.000000),[], 96),
    
    
      
      ("salt_mine","Salt_Mine",icon_village_a|pf_disabled|pf_is_static|pf_always_visible|pf_hide_defenders, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(14.2, -31),[]),
      ("four_ways_inn","Four_Ways_Inn",icon_village_a|pf_disabled|pf_is_static|pf_always_visible|pf_hide_defenders, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(4.8, -39.6),[]),
      ("test_scene","test_scene",icon_village_a|pf_disabled|pf_is_static|pf_always_visible|pf_hide_defenders, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(10.8, -19.6),[]),
      #("test_scene","test_scene",icon_village_a|pf_is_static|pf_always_visible|pf_hide_defenders, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(10.8, -19.6),[]),
      ("battlefields","battlefields",pf_disabled|icon_village_a|pf_is_static|pf_always_visible|pf_hide_defenders, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(10.8, -16.6),[]),
      ("dhorak_keep","Dhorak_Keep",icon_town|pf_disabled|pf_is_static|pf_always_visible|pf_no_label|pf_hide_defenders, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(-50,-58),[]),


    module constant :
    Code:
    towns_begin = "p_town_1"
    castles_begin = "p_castle_1"
    villages_begin = "p_village_1"
    
    towns_end = castles_begin
    castles_end = villages_begin
    villages_end   = "p_salt_mine"
    
    walled_centers_begin = towns_begin
    walled_centers_end   = castles_end
    
    centers_begin = towns_begin
    centers_end   = villages_end
    
    training_grounds_begin   = "p_training_ground_1"
    training_grounds_end     = "p_Bridge_1"
    
    scenes_begin = "scn_town_1_center"
    scenes_end = "scn_castle_1_exterior"
    
    spawn_points_begin = "p_zendar"
    spawn_points_end = "p_spawn_points_end"



    module scenes :

    Code:
    ("village_198",sf_generate,"none", "none", (0,0),(240,240),-0.5,"0x000000002000050000060d76000061b90000664000003d79",
        [],[],"outer_terrain_esteppe_mountains_B"),
    
      ("village_199",sf_generate,"none", "none", (0,0),(240,240),-0.5,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeC"),
      ("village_200",sf_generate,"none", "none", (0,0),(240,240),-0.5,"0x00000000200005000008ee3d00007f2800006a9100006095",
        [],[],"outer_terrain_steppeB"),
      ("village_201",sf_generate,"none", "none", (0,0),(240,240),-0.5,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeD"),
      ("village_202",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
         ("village_203",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
      ("village_204",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
      ("village_205",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
        ("village_206",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
    	  ("village_207",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
    	  ("village_208",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
      ("village_209",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
      ("village_210",sf_generate,"none", "none", (0,0),(200,200),-100,"0x000000002000050000059d670000359600004ac200003dcf",
        [],[],"outer_terrain_steppeV"),
    so what is the problem ?
  12. Modding Q&A [For Quick Questions and Answers]

    NPC99 said:
    zidozido said:
    kalarhan said:
    zidozido said:
    so what is the problem ?

    you need to check your actual values, so debug your game by using a savegame file editor or debug messages, and check if you forgot something (like you put the village outside the villages range).
    what do you mean by outside the range ?

    Seriously?

    (try_for_range, ":village_no", villages_begin, villages_end),

    i am so sorry i know i am noob at modding and this question may be the most so here it comes how do i know my range and how do i modify it as i dont see numbers or something that i can modify
  13. Modding Q&A [For Quick Questions and Answers]

    kalarhan said:
    zidozido said:
    so what is the problem ?

    you need to check your actual values, so debug your game by using a savegame file editor or debug messages, and check if you forgot something (like you put the village outside the villages range).
    what do you mean by outside the range ?
  14. Modding Q&A [For Quick Questions and Answers]

    kalarhan said:
    zidozido said:
    sorry for asking the question another time but how to fix the village that when i enter i dont find a village

    check your start-up script that sets the scenes used by a village (via slots)

    Code:
    	  # Villages characters
          (try_for_range, ":village_no", villages_begin, villages_end),
            (store_sub, ":offset", ":village_no", villages_begin),
    
            (store_add, ":exterior_scene_no", "scn_village_1", ":offset"),
            (party_set_slot,":village_no", slot_castle_exterior, ":exterior_scene_no"),
          
            (store_add, ":store_troop_no", "trp_village_1_elder", ":offset"),
            (party_set_slot,":village_no", slot_town_elder, ":store_troop_no"),
            
            (party_set_slot,":village_no", slot_party_type, spt_village),
            (party_set_slot,":village_no", slot_village_raided_by, -1),
          
            (call_script, "script_refresh_village_defenders", ":village_no"),
            (call_script, "script_refresh_village_defenders", ":village_no"),
            (call_script, "script_refresh_village_defenders", ":village_no"),
            (call_script, "script_refresh_village_defenders", ":village_no"),
          (try_end),

    above shows how Native uses slot_castle_exterior to connect a village scene to a village party.


    i found it and its the same surprisingly 
    Code:
    (try_for_range, ":village_no", villages_begin, villages_end),
            (store_sub, ":offset", ":village_no", villages_begin),
    
            (store_add, ":exterior_scene_no", "scn_village_1", ":offset"),
            (party_set_slot,":village_no", slot_castle_exterior, ":exterior_scene_no"),
          
            (store_add, ":store_troop_no", "trp_village_1_elder", ":offset"),
            (party_set_slot,":village_no", slot_town_elder, ":store_troop_no"),
            
            (party_set_slot,":village_no", slot_party_type, spt_village),
            (party_set_slot,":village_no", slot_village_raided_by, -1),
          
            (call_script, "script_refresh_village_defenders", ":village_no"),
            (call_script, "script_refresh_village_defenders", ":village_no"),
            (call_script, "script_refresh_village_defenders", ":village_no"),
            (call_script, "script_refresh_village_defenders", ":village_no"),
          (try_end),
          
          (try_for_range, ":center_no", centers_begin, centers_end),
            (party_set_slot, ":center_no", slot_center_last_spotted_enemy, -1),
            (party_set_slot, ":center_no", slot_center_is_besieged_by, -1),
            (party_set_slot, ":center_no", slot_center_last_taken_by_troop, -1),
          (try_end),

    so what is the problem ?
Back
Top Bottom