Factions Question

正在查看此主题的用户

ligerteeth

Regular
Hey just a quick question regarding the module system. Is it possible to have only two factions? I'm putting a bit of a fantasy twist on the classic crusades theme and I want there to only be the crusaders and the crusadees if you see what i mean. (Don't worry, not the actual names of the factions :grin: )
O ya and if anyone wants to help me out with one more thing, ive been having a little trouble getting some muskets i made to appear in stores i have already added (troop_add_merchandise,reg(2),itp_type_musket,2) to the triggers file, but it still didn't work.
 
It is perfectly possible. Just remove the other factions from module_factions.py and then go through these steps for each one you did remove (I suggest to comment them out and only one at a time - once the whole thing compiles again, get the next one for savest work):
- Seek the faction id (first entry) in all other module files (use a function like "Find in files" of Notepad++),
- analyse and understand what is done with the instance,
- trimm/modify the piece of code accordingly,
- and proceed to the next instance.

For a start you could try to just remove one of the major factions ("kingdom_5" for example) and deal with all occurences of it in the other modules in just the same way - by removing them. Once you are done, see if it compiles (I rather think that it will not, but he - that is your sole chance for an "easy way" ^^).
Undo your changes and try the same with a minor faction ("manhunters" might be good) - there your chance of success should be considerably higher and if it works - well, you can at least get rid of all but ten factions (five kingdoms plus five cultures... by just removing stuff you will never be able to get a working system in that the number of kingdoms does not equal the number of cultures).

I suggest that you just leave factions that do not even appear in the game alone (such as "dark_knights")... while it will certainly be easiest to remove them, you do not actually gain anything from doing so.
... Of course, seeing that there are factions that do not appear in the game, you might get the idea how to achieve your goal with a lot less work (albeit somewhat more dirty)... ^^
(hint: you will still have to do the first step of those four above)
 
ya thanks it worked i was able to remove them, but the cities that would usually belong to the factions i removed are now neutral, how do I fix this?
 
Well, as all towns have "fac_neutral" as initial value in module_parties.py, you could obviously seek module_triggers.py, module_simple_triggers.py and module_scripts.py for the place at which they get their "true" faction assigned (this should actually be a part of code you just removed... commented out and not simply deleted, I hope ^^) and there assign them one of the remaining ones...
Even more obviously you can try to replace these very initial values in module_parties.py with one of your remaining factions - however, this might cause some oddities around, as probably there is a reason behind initialising the towns with that dummy value and assigning their "true" factions later on. Worth a try it is, though (and easier and quicklier done than the more conservative approach ^^).
 
后退
顶部 底部