Module System Error

Users who are viewing this thread

WolfeyS

Recruit
I followed the module system tutorial, and got as far as the first compilation, then I get this, this seems to prevent me from compiling code to my mod.  If i try to compile any code it just errors out and tells me that nothing is defined.

Im running Warband.




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 map icons...
Creating new tag_uses.txt file...
Creating new quick_strings.txt file...
Exporting faction data...
Exporting item data...
Exporting scene data...
Exporting troops data
Exporting particle data...
Exporting scene props...
Exporting tableau materials data...
Exporting presentations...
Exporting party_template data...
Exporting parties
Exporting quest data...
Exporting info_page data...
Exporting scripts...
Exporting mission_template data...
Exporting game menus data...
WARNING: Usage of unassigned global variable: $g_presentation_marshall_selection
_max_renown_3
WARNING: Usage of unassigned global variable: $g_presentation_marshall_selection
_max_renown_3_troop
WARNING: Usage of unassigned global variable: $g_presentation_marshall_selection
_max_renown_3
WARNING: Usage of unassigned global variable: $g_presentation_marshall_selection
_max_renown_3_troop
exporting simple triggers...
exporting triggers...
exporting dialogs...
Checking global variable usages...
WARNING: Global variable never used: tutorial_1_finished
WARNING: Global variable never used: tutorial_2_finished
WARNING: Global variable never used: tutorial_3_finished
WARNING: Global variable never used: tutorial_4_finished
WARNING: Global variable never used: tutorial_5_finished
WARNING: Global variable never used: g_election_date
WARNING: Global variable never used: g_presentation_lines_to_display_begin
WARNING: Global variable never used: g_presentation_lines_to_display_end
WARNING: Global variable never used: $g_presentation_marshall_selection_max_reno
wn_3
WARNING: Global variable never used: $g_presentation_marshall_selection_max_reno
wn_3_troop
WARNING: Global variable never used: $g_presentation_marshall_selection_max_reno
wn_3
WARNING: Global variable never used: $g_presentation_marshall_selection_max_reno
wn_3_troop
Exporting postfx_params...

______________________________

Script processing has ended.
Press any key to exit. . .


I made a few more tests of mine, when i compile it will restore any deleted files (like item_kinds1) but when i try to change items it just compiles the original
 
These are just warnings that everyone gets (unless you move a copy of Native's--or whatever mod system you are tinkering with--variables.txt file into the folder that you are compiling from), they are not errors.

I see nothing here that should cause issues starting the mod.
 
Put this somewhere in your module_scripts.py. You don't even have to call the script, all it does is say to the compiler that these variables are used.

Code:
    #RPW
	("cf_rpw_fix_native_errors",
	[
	    (eq, "$tutorial_1_finished", 0),
	    (eq, "$tutorial_2_finished", 0),
	    (eq, "$tutorial_3_finished", 0),
	    (eq, "$tutorial_4_finished", 0),
	    (eq, "$tutorial_5_finished", 0),
		(eq, "$g_election_date", 0),
		(eq, "$g_presentation_lines_to_display_begin", 0),
		(eq, "$g_presentation_lines_to_display_end", 0),
		(assign, "$g_presentation_marshall_selection_max_renown_3", 0),
		(assign, "$g_presentation_marshall_selection_max_renown_3_troop", 0),
		(eq, "$g_presentation_marshall_selection_max_renown_3", 1),
		(eq, "$g_presentation_marshall_selection_max_renown_3_troop", 1),
	]),
	#RPW
 
WolfeyS said:
I made a few more tests of mine, when i compile it will restore any deleted files (like item_kinds1) but when i try to change items it just compiles the original
...and you've set up module_info.py correctly? And are compiling into a renamed copy of the Native folder?
 
Might be a problem with "security" if you're running Vista or Win7.

Put the ModuleSystem folder onto your desktop and then try.
 
Caba`drin said:
WolfeyS said:
I made a few more tests of mine, when i compile it will restore any deleted files (like item_kinds1) but when i try to change items it just compiles the original
...and you've set up module_info.py correctly? And are compiling into a renamed copy of the Native folder?

Yes and yes, im running on steam, that shouldn't be a problem, it directs to modules/mod.  I followed everything exact. When i came to part two of the module tutorial it told me that everything i had added (I added it exactly as the tutorial stated, check for syntax and such) "was not defined". I can link that error in a momoent.
 
Sinisterius said:
Might be a problem with "security" if you're running Vista or Win7.

Put the ModuleSystem folder onto your desktop and then try.

Already had done this, thanks for the quick replies though
 
Another post but i may have solved it, if the tutorials are for Mount&Blade, not warband, i was copying what he had exactly, although looking at it now it seems warband has a different code scheme, the compilation problem still laughs at me.

Edit: This seems to have solved both problems, after editting his code to fit warband, it will compile now.
 
Sinisterius said:
Put this somewhere in your module_scripts.py. You don't even have to call the script, all it does is say to the compiler that these variables are used.

Code:
    #RPW
	("cf_rpw_fix_native_errors",
	[
	    (eq, "$tutorial_1_finished", 0),
	    (eq, "$tutorial_2_finished", 0),
	    (eq, "$tutorial_3_finished", 0),
	    (eq, "$tutorial_4_finished", 0),
	    (eq, "$tutorial_5_finished", 0),
		(eq, "$g_election_date", 0),
		(eq, "$g_presentation_lines_to_display_begin", 0),
		(eq, "$g_presentation_lines_to_display_end", 0),
		(assign, "$g_presentation_marshall_selection_max_renown_3", 0),
		(assign, "$g_presentation_marshall_selection_max_renown_3_troop", 0),
		(eq, "$g_presentation_marshall_selection_max_renown_3", 1),
		(eq, "$g_presentation_marshall_selection_max_renown_3_troop", 1),
	]),
	#RPW

there is a post on the forums that tells you where to find the lines that triggers these that you can jut # out, that is what i did
 
I have that same problem as Wolfey. I got exactly the same result at the beginning, then added that script and warnings vanished, but it still says nothing is defined.

module.info should be okay
Code:
# Point export_dir to the folder you will be keeping your module
# Make sure you use forward slashes (/) and NOT backward slashes (\)

export_dir = "C:/Program Files/Steam/SteamApps/common/mountblade warband/Modules/NewModule"
#export_dir = "C:/Program Files/Mount&Blade/Modules/Native/"

Now, no matter what I do nothing changes in game. Build.module.bat doesn't give any errors but still nothing changes and if it gives errors I still can play the game like normal because nothing has changed.

I have Vista so is there something special I have to do to get this working?
 
I think it wasn't that. I had tried to write that line half dozen times and just forgot that slash in the last time.

But I said it wasn't :grin: It seems to work properly now. I removed those "read only" slots from Module_system folder and Warband folders and now it works :cool:

-->off to modding. See ya
 
Back
Top Bottom