PDA

View Full Version : Add new Agents



madalchemist
12-27-2006, 23:36
Hi to all! I'm a would-be modder and Olmsted from totalwar.com forum said to post here my questions as this is the best place.

I enjoyed very much MTW and RTW, and as soon as I could I made retinues transferrable (and many more minor changes), but one thing I really miss from MTW is the Inquisitor, usable from all factions. And I'm trying to make it recruitable and playable.

I am trying to add the Inquisitor as a playable agent, and I successfully (I mean with these ones modified -even together-, it does not crash) modified the following files, adding appropriate triggers and so on: descr_cursor_action, descr_model_strat, export_descr_ancillaries, export_descr_character_traits, descr_character and descr_campaign_db;

Since there are .tga models for inquisitors of all catholic faction (I suppose that's a feature CA thought to put in) and I wanted to preserve the inquisitor Papal_States agent, I created the "Inquisator" agent; it's totally equal to the Inquisitor (even appropriate triggers and traits) save the fact it must be recruited and it is not spawned.

My descr_cultures modified file makes the game crash by an unknown error.

When I tried to make level_1 catholic church build it, by modifying the "export_descr_buildings", the game crashes and the log show the following error:

** 17:46:00.125 [script.err] [error] Script Error in data/export_descr_buildings.txt, at line 3323, column 15
Unknown agent type specified: inquisator **

So my precise question is: where and how does the game checks whether an agent exists or not?

P.S. descr_character and/or descr_model_strat are the ones I bet on

alpaca
12-28-2006, 01:17
I bet this is still hardcoded... In RTW you couldn't add new agent types, and that is probably still the case.

madalchemist
12-28-2006, 15:08
Damnit!! Hardcoded? :help:

...wait! What if I modify the Inquisitor (the one only papal_sats has) by simply making it available to all faction? That one should be allowed by the game :skull:

When you said "Hardcoded" you meant the fixed agents number are for playable factions only, or "throughout total game agents number"?

:furious3: , I knew it was not so easy!

Edit: Just a question: Hardcoded means you can do nothing at all to mod the game that way (i.e. no one could ever do it in Rome)?

alpaca
12-28-2006, 16:36
Damnit!! Hardcoded? :help:

...wait! What if I modify the Inquisitor (the one only papal_sats has) by simply making it available to all faction? That one should be allowed by the game :skull:

When you said "Hardcoded" you meant the fixed agents number are for playable factions only, or "throughout total game agents number"?

:furious3: , I knew it was not so easy!

Edit: Just a question: Hardcoded means you can do nothing at all to mod the game that way (i.e. no one could ever do it in Rome)?
Hardcoded means it's in the actual program source code (i.e. in the executable) instead of in external, editable files.
And, yes, making the inquisitor available to all factions might work.

serenius4tsd
12-28-2006, 17:12
[QUOTE=madalchemist]** 17:46:00.125 [script.err] [error] Script Error in data/export_descr_buildings.txt, at line 3323, column 15
Unknown agent type specified: inquisator **QUOTE]

Was this the spelling you had in the file? I dunno, but maybe it doesnt work cos its meant to be 'inquisitor'. :inquisitive:

madalchemist
12-28-2006, 18:30
Thanks to all for the advices.

Giving it to all faction might work? I'll work on it!

By the way, "inquisator" was the name of the new agent I created (if you use GoogleDesktop and search, you'll find all the models and images for the "inquisator" unit, both .tga and _info; probably it was supposed to be used AND recruited, as there are the colors of inquisitors in all nations who had it in MTW's appropriate directories).

I tried deleting the "inquisator" and making the inquisitor in its place, but it gives the same error about the inquisitor:

Script Error in data/export_descr_buildings.txt, at line 3323, column 15
Unknown agent type specified: inquisitor

So I believe it was not (only) a spelling mistake. It seems that making it available also make it Unknown (obviously there are dozens of files I must have placed in wrong places, so I'll post my progress here).

Please continue to write your opinion as it's very useful to me.

serenius4tsd
12-28-2006, 19:43
Okay, keep up the good work.

Im wondering though, if we manage to crack this thing, what role will inquisitors play? Will they just be added as another sub denomination of priests? Or could they have something that makes them unique to priests/bishops?

Musashi
12-29-2006, 02:06
You might need to capitalize it (Inquisitor, not inquisitor)

madalchemist
12-29-2006, 15:24
@Musashi: If I made that mistake (which is possible) I'll cut my blood vessels :embarassed: *going to check*

@Serenius: The role I thought for the Inquisitor is the MTW's; very low chance to burn the target (minimum=0%) in general, unless target's piety is high.

However many things must be taken care of, as from what I've seen all not-general units (including all Agents but Priests) have a starting base Piety of 1, and they never change that value.

This way, no matter how low is the base chance, if you menage to get a high-level inquisitor, you can destroy any merchant, princess, diplomat, assassin and spy in a blink.

By the way my progress is this from the last time: I played as the Papal_states giving spawned inquisitors an high chance to appear; after one of them appeared, I started to use him. He is under the Agents list with his correct role written, he can move, he can denounce, and if you fail to denounce you get -1 Piety (same trigger of the Priest when he denounces an heretic). No crashes at all.

(just to be precise, I also tried to play with Rebels and when an heretic or a witch appears, you get them on the agent list etc. etc. like the inquisitor)

So it appears he CAN be used; what's to test is whether he can be recruited or only spawned (not to mention to be used from anyone who isn't the Papal_states).

madalchemist
12-30-2006, 00:37
"00:29:56.640 [script.err] [error] Script Error in data/descr_character.txt, at line 1217, column 1
Too many character types specified in descr_character. The current maximum is 12."

That's what it wrote when I tried to give the Inquisitor to all factions and also the "Inquisator" to all factions.

No need to be a genius to read that the number of characters (agents+generals etc.) is capped to 12.

Either I can give base Inquisitor to all factions or someone else must be deleted (it would really be a mess).

Gonna search where this max 12 is specified, supposing it's not hardcoded.

alpaca
12-31-2006, 14:09
"00:29:56.640 [script.err] [error] Script Error in data/descr_character.txt, at line 1217, column 1
Too many character types specified in descr_character. The current maximum is 12."

That's what it wrote when I tried to give the Inquisitor to all factions and also the "Inquisator" to all factions.

No need to be a genius to read that the number of characters (agents+generals etc.) is capped to 12.

Either I can give base Inquisitor to all factions or someone else must be deleted (it would really be a mess).

Gonna search where this max 12 is specified, supposing it's not hardcoded.
Can save the effort. Such stuff is always hardcoded.

madalchemist
12-31-2006, 19:12
You're right. Found it nowhere in the editable codes.

uanime5
03-23-2007, 19:56
"00:29:56.640 [script.err] [error] Script Error in data/descr_character.txt, at line 1217, column 1
Too many character types specified in descr_character. The current maximum is 12."

That's what it wrote when I tried to give the Inquisitor to all factions and also the "Inquisator" to all factions.

No need to be a genius to read that the number of characters (agents+generals etc.) is capped to 12.

Either I can give base Inquisitor to all factions or someone else must be deleted (it would really be a mess).


Does this mean that if you deleted another agent, such as the diplomat, all factions could produce inquisitors?