Calabanar
Sergeant at Arms

Hi everyone,
I have been working on a personal mod for a while now, despite having basically 0 skill in Python and coding in general.
I managed to get everything working up to a point where I tried incorporating a few new elements, and now it's giving me the following error when compiling:
And this big list when trying to build the module:
I'm just kind of stuck here, which sucks because I added the Perfect Troop Tree Presentation but can't use it since the game crashes, which drastically slows down thebalancing and creation of units. If there is anything I should add to help you help me, I'll gladly oblige.
Edit: I have read "The Ultimate Introduction to Modding", which has greatly helped up to this point.
I have been working on a personal mod for a while now, despite having basically 0 skill in Python and coding in general.
I managed to get everything working up to a point where I tried incorporating a few new elements, and now it's giving me the following error when compiling:
*** 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...C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
DONE.
Loading plugins... DONE.
Checking module syntax... DONE.
Allocating identifiers... DONE.
Compiling module... DONE.
Exporting module... DONE.
COMPILATION SUCCESSFUL.
The following errors were generated during compilation:
unassigned local variable <l.final_price_for_secondary_input[@1224979098644774926]> used by operation store_div in script.process_player_enterprise on line 48
The following notifications were generated during compilation:
local l.unused declared but never used in script.game_get_troop_wage
local l.unused declared but never used in script.debug_variables
local l.unused_2 declared but never used in script.debug_variables
local l.unused declared but never used in script.party_inflict_attrition
Appuyez sur une touche pour continuer...
Please report errors, problems and suggestions at http://lav.lomskih.net/wreck/
Loading module...C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
DONE.
Loading plugins... DONE.
Checking module syntax... DONE.
Allocating identifiers... DONE.
Compiling module... DONE.
Exporting module... DONE.
COMPILATION SUCCESSFUL.
The following errors were generated during compilation:
unassigned local variable <l.final_price_for_secondary_input[@1224979098644774926]> used by operation store_div in script.process_player_enterprise on line 48
The following notifications were generated during compilation:
local l.unused declared but never used in script.game_get_troop_wage
local l.unused declared but never used in script.debug_variables
local l.unused_2 declared but never used in script.debug_variables
local l.unused declared but never used in script.party_inflict_attrition
Appuyez sur une touche pour continuer...
And this big list when trying to build the module:
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Initializing...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Compiling all global variables...
Exporting strings...
Exporting skills...
Exporting tracks...
Exporting animations...
Exporting meshes...
Exporting sounds...
Exporting skins...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting map icons...
Creating new tag_uses.txt file...
Creating new quick_strings.txt file...
Exporting faction data...
Exporting item data...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting scene data...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting troops data
Exporting particle data...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting scene props...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting tableau materials data...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting presentations...
Exporting party_template data...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting parties
Exporting quest data...
Exporting info_page data...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting scripts...
WARNING: Script can fail at operation #69. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #85. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #113. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #121. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #141. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #149. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #157. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #165. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #173. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #181. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #189. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #197. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #205. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #207. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #208. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #216. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #223. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #236. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #244. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #257. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #270. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #278. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #286. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #294. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #302. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #310. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #318. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #326. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #332. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #338. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #353. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #395. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #444. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #572. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #588. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #596. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #604. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #612. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #626. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #640. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #653. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #666. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #679. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #692. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #700. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #708. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #748. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #24. Use cf_ at the beginning of its name: cstm_cf_troop_stats_are_different
WARNING: Script can fail at operation #21. Use cf_ at the beginning of its name: cstm_cf_troop_equipments_are_different
WARNING: Script can fail at operation #10. Use cf_ at the beginning of its name: cstm_cf_troop_has_horse
WARNING: Script can fail at operation #11. Use cf_ at the beginning of its name: cstm_cf_troop_has_bow_or_crossbow
WARNING: Script can fail at operation #19. Use cf_ at the beginning of its name: cstm_cf_item_is_eligible_equipment_option
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting mission_template data...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting game menus data...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
exporting simple triggers...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
exporting triggers...
exporting dialogs...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Checking global variable usages...
WARNING: Global variable never used: cstm_selected_troop
WARNING: Global variable never used: cstm_customise_button
WARNING: Global variable never used: cstm_finalise_button
Imported 25 global variables for saved-game compatability that are not used.
Exporting postfx_params...
______________________________
Script processing has ended.
Press any key to exit. . .
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Initializing...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Compiling all global variables...
Exporting strings...
Exporting skills...
Exporting tracks...
Exporting animations...
Exporting meshes...
Exporting sounds...
Exporting skins...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting map icons...
Creating new tag_uses.txt file...
Creating new quick_strings.txt file...
Exporting faction data...
Exporting item data...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting scene data...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting troops data
Exporting particle data...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting scene props...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting tableau materials data...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting presentations...
Exporting party_template data...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting parties
Exporting quest data...
Exporting info_page data...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting scripts...
WARNING: Script can fail at operation #69. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #85. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #113. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #121. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #141. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #149. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #157. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #165. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #173. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #181. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #189. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #197. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #205. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #207. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #208. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #216. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #223. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #236. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #244. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #257. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #270. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #278. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #286. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #294. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #302. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #310. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #318. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #326. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #332. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #338. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #353. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #395. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #444. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #572. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #588. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #596. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #604. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #612. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #626. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #640. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #653. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #666. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #679. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #692. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #700. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #708. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #748. Use cf_ at the beginning of its name: game_receive_network_message
WARNING: Script can fail at operation #24. Use cf_ at the beginning of its name: cstm_cf_troop_stats_are_different
WARNING: Script can fail at operation #21. Use cf_ at the beginning of its name: cstm_cf_troop_equipments_are_different
WARNING: Script can fail at operation #10. Use cf_ at the beginning of its name: cstm_cf_troop_has_horse
WARNING: Script can fail at operation #11. Use cf_ at the beginning of its name: cstm_cf_troop_has_bow_or_crossbow
WARNING: Script can fail at operation #19. Use cf_ at the beginning of its name: cstm_cf_item_is_eligible_equipment_option
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting mission_template data...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Exporting game menus data...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
exporting simple triggers...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
exporting triggers...
exporting dialogs...
C:\Program Files (x86)\Steam\steamapps\common\MountBlade Warband\Modules\MOD! - UNIT TEST\Source Files\util_scripts.py:84: UserWarning: Error injecting code into: party_give_xp_and_gold
warnings.warn("Error injecting code into: %s" % (cur_directive[1]) )
Checking global variable usages...
WARNING: Global variable never used: cstm_selected_troop
WARNING: Global variable never used: cstm_customise_button
WARNING: Global variable never used: cstm_finalise_button
Imported 25 global variables for saved-game compatability that are not used.
Exporting postfx_params...
______________________________
Script processing has ended.
Press any key to exit. . .
I'm just kind of stuck here, which sucks because I added the Perfect Troop Tree Presentation but can't use it since the game crashes, which drastically slows down thebalancing and creation of units. If there is anything I should add to help you help me, I'll gladly oblige.
Edit: I have read "The Ultimate Introduction to Modding", which has greatly helped up to this point.
Last edited: