Jump to content

Havenite Cultural Skills


Simulated Knave

Recommended Posts

On 9/22/2019 at 7:16 PM, Last Tangerine of Navel said:

Not easily, no.  The skill trees are effectively hardcoded.

 

You might be able to get by this, at least for the Royal Haven abilities, but only if you were willing to constantly edit the files.

 

Note, before doing any of this, it's a good idea to make a copy of your game. Then you can always use this copy to keep on playing in case something goes wrong!

 

Go to your scripts folder, and open the file 'QWitemschars.txt'. Find an item that you want one of your soldiers (but not your main character!) to wear, which can simply be done using a text search. Alternatively, find a charm that one of your soldiers is carrying. The stats of this item or charm are contained in the block beginning 'begindefineitem <SomeNumber>'. At the bottom of this block, on a fresh new line at some point before the next begindefineitem, input this:

 

it_stats_to_affect 1 = 70;
it_stats_addition 1 = a;
it_stats_to_affect 2 = 71;
it_stats_addition 2 = b;
it_stats_to_affect 3 = 72;
it_stats_addition 3 = c;

 

where a, b and c are the levels of Haven's Might, Mercy and Command respectively that you want your soldiers to have. Just edit these numbers when you want the abilities to change – and don't forget to leave the skill points free in your training window to compensate!

 

When you next load the game, even though you won't be able to actively see it in their training windows, any soldier wearing this item will now have the required level of the royal abilities!

 

Note that the above code will overwrite all abilities of an item except the one that appears at the very top of its list. Be careful which one you choose!

 

Also, if you are changing equippable items, be aware that some items in the same grouping might also have boosted stats. If your main character or another character you don’t want to have boosted stats is wearing such a related item, you may need to use an additional step.

 

If an item is incorrectly having stats boosted, find this item in the scripts and add the following lines. These should be placed at the end of the item block, as described above:

 

it_stats_to_affect 1 = -1;
it_stats_to_affect 2 = -1;
it_stats_to_affect 3 = -1;

 

Alternatively, to avoid this problem, make the alteration on a charm, instead of an equippable item.

Link to comment
Share on other sites

Importantly for the above code, the natural numbers start at 0, not 1.

 

Just another example of why we really should not be encouraging people to casually mess with the scripts.  The parser is very picky about some things that aren't obvious.  Anyway, I think "get by this" is a pretty generous description of what you're doing here 😛

Link to comment
Share on other sites

I kind of understand why Havenites have no Cultural skills. The story emphasizes that Haven can't conquer a place without local aid, and from a gameplay perspective it adds some decisions about where place your first fort. Still, I hope that there are non-royal cultural skills for Havenites in the next game so that we have more real choices in party building.

Link to comment
Share on other sites

10 hours ago, Last Tangerine of Navel said:

Importantly for the above code, the natural numbers start at 0, not 1.

 

This is a debatable comment, Slarty, even from a mathematical perspective :)

 

The steps I describe above are complete as they stand. To get one level of Haven's Might, set a to 1. For two levels, set a to 2. The numbers in the code and the in-game values directly correspond to one another.

 

There's no -1 for the abilities in this game, Slarty!

Link to comment
Share on other sites

I was musing on this myself as the blank racial tab for Havenites looks off - as though it were unfinished, even though we know otherwise.  It's also inconsistent with the setting for the Empire's own troops to be inferior to vassal troops and, worst of all, it's a missed opportunity for world building.

 

Havenite troops are valueable to the Thirdborn for their strategic value.  They are few in number but able to effect regime change and some (i.e. the ones you recruit) have survived and stayed loyal on the continent without Imperial support for decades.  Even if, for mechanical reasons, they aren't comparable warriors, I wish they had skills reflecting their quality as soldiers.

 

That's why I think giving them strategic skills would be a good balance:

 

Havenite Colonist: +1/+2 random resources every two days.

 

Imperial Garrison: -2%-5% theft risk in current region.

 

And we're shown again and again that even wayward Havenites are impressed by encountering Havenite royalty, even if that only makes them resist the Thirdborn more intensely.  Devoted Havenites like Chief Miranda exhibit increased resolve when you show up, so I'm thinking that could be the grounds for the racial passive of your Havenite companions:

 

Royal Guard: +10 Mental Resist within 6 squares of royalty.

 

Apologies to those who've already read my ramblings on Steam.  This thread was just too pertinent to pass up!

Link to comment
Share on other sites

4 hours ago, Ess-Eschas said:

 

This is a debatable comment, Slarty, even from a mathematical perspective :)

 

The steps I describe above are complete as they stand. To get one level of Haven's Might, set a to 1. For two levels, set a to 2. The numbers in the code and the in-game values directly correspond to one another.

 

There's no -1 for the abilities in this game, Slarty!

 

Sorry, Ess, you are just wrong here.

 

The numbers I'm talking about are the ones that appear in the parameter names.  You began with it_stats_to_affect 1, not it_stats_to_affect 0.  It's an array and the numeration begins with 0.

Link to comment
Share on other sites

I agree with the zero being the first number. Also other script alteration warnings, you can also affect other things with changes or additions. For example, the next item after the changed one may inherit the changed stats depending on how it was written. Actually several down the list may get the new stats depending on various factors on how they are written.

Link to comment
Share on other sites

2 hours ago, Last Tangerine of Navel said:

Sorry, Ess, you are just wrong here.

 

Without wishing to be deliberately contrary, I don’t think I’ve said anything factually incorrect here. However, do let me know if I’m misunderstanding something.

 

The decision to start numbering the abilities at 1 was a deliberate one. In my experience, the most valuable ability of an item is listed in the first slot, numbered 0, as you say. Since I was going to overwrite three of the four possible abilities of an item, I thought it best to keep that upper slot free. Hence the numbering system I chose.

 

Each item, so far as I can see, must have the it_stats_to_affect array defined. If an item has no ability at all, then the 0-numbered slot is given an ability with a null value of minus one. However, the array is still defined. This means that you can add abilities to the later slots without anything breaking – the remaining three abilities still activate, and everything displays correctly on the screen. Effectively, the game just skips over the null ability.

 

In other words, my suggestion above keeps the most valuable ability of an item, if any, while adding on the three royal abilities. It works as well for items with abilities as for those that have none.

 

If you don’t believe me, check it out!

 

22 minutes ago, ZorroDragonslayer said:

For example, the next item after the changed one may inherit the changed stats depending on how it was written.

 

Indeed that is so. However, in my experience this is only done with items in a particular grouping – say only with the sets of broadswords, or with the sets of plate armour. Players can't naturally wear two sets of plate armour at the same time, or wield two swords. As a result, I was under the impression that such 'leakage' of stats would not be problem. Indeed, it ends up being preferential, since players who upgrade their gear to similar items will still receive the same effects without needing to upgrade the scripts.

 

However, you have reminded me that this might be the problem for the player character, or for other characters that are not intended to have stat increases, since they might unintentionally have boosted stats as well. I'll update my original post to warn about this.

Link to comment
Share on other sites

Could one not just edit some kind of ability into all Havenite units in the base creature definition? Perhaps a small bonus to damage vs. Ukatish/Ahriel/Vol, or a bonus to blessings. It wouldn't be something one could put skill points in, but it WOULD give a reason to keep using Havenite soldiers rather than immediately replacing them with auxiliaries.

 

EDIT: Or just give every Havenite 1 level of Haven's Command for free, I suppose.

Edited by Simulated Knave
Link to comment
Share on other sites

Maybe that was your intention, but you didn't state that; to someone who hadn't touched the scripts previously, they'd have no reason not to conclude that the numbering began at 1.  Additionally, if they happen to edit or import an item with no ability in the 0 slot, but they put abilities in later slots, handling can be inconsistent.

 

(And respectfully, "I'm just going to assume it always makes sense to start the edit at 1" is maybe the least rational thing I've heard you say on here.  Which is a low bar!  You say smart stuff.  But the most valuable ability is not always in slot 0.)

 

In the past, there have been issues with customers reading topics here, making script edits without knowing what they're doing, and then sending frustrated support emails to Spiderweb, often without explaining what they've done.  This is not a situation we want to replicate.

 

While the scripts aren't super dangerous to fool around with as these things go, it is still very easy for someone to make an edit that will make the game reject the file -- or a portion of the file -- without realizing it.  The "stat bleeding" that you thought of and added in an edit just now is another good example of things that can go wrong -- and why "quick edits" to the defs files are not actually as quick and easy as they seem.  (Edits to a zone script are not as risky, for a lot of reasons.)

 

For a savvy user, yes, script edits can be a great way to "get around" certain limits and rectify things a player accidentally missed, etc.  But remember that there are tons of lurkers -- people reading these topics off a google search -- etc.  You're not just talking to the person who posed the question, you're talking to google, too.  This is why I almost never suggest script edits; but if you're going to, clarity is very important.  These little details are not nitpicks.

Link to comment
Share on other sites

7 minutes ago, Simulated Knave said:

Could one not just edit some kind of ability into all Havenite units in the base creature definition? Perhaps a small bonus to damage vs. Ukatish/Ahriel/Vol, or a bonus to blessings. It wouldn't be something one could put skill points in, but it WOULD give a reason to keep using Havenite soldiers rather than immediately replacing them with auxiliaries.

 

Yes, but it will come with big problems.

 

These definitions get inherited and imported into other definitions in ways that are sometimes hardcoded and undocumented.  So you can do this, but you'll also be affecting other things in the game; the exact impact will be difficult to foresee and may or may not be significant.

 

Around player characters in particular, there is a lot of hardcoded stuff.  (This has been true in every game that used any version of this system.)  You can make these edits, but it doesn't always go the way you expect.

 

7 minutes ago, Simulated Knave said:

EDIT: Or just give every Havenite 1 level of Haven's Command for free, I suppose.

 

This, for example, may or may not work.  I'd give it 50-50 odds based on how this has been handled in past games.

Link to comment
Share on other sites

Looking at the itemschars file, I have the sneaking suspicion that even UVA (Ukatish/Vol/Ahriel) PCs are defined as species Havenite in the game scripts.

 

Easy way to test it, fortunately. Just change the HP per level. Will do so and be back shortly with results.

 

EDIT: They are very much NOT (or, if they are, they're not defined as such using the Haven PC entry). I successfully gave a Havenite PC a lot more health without it impacting auxiliaries. This could be fun. Now to figure out how to add passive abilities without breaking everything forever.

 

EDIT 2: It occurs to me that there is always an absolutely simple way to make Havenites unique - give them bonus health. THAT won't break.

 

EDIT 3: Update - you can edit many stats by editing creature adjustments. However, the creature adjustments do not correspond to the item stat increases (understandably). Brute forcing what each adjustment is should be possible, but is likely tricky to test for the stats that don't physically display. Still, it seems very likely that Havenites could have their stats edited so they're uniquely better than the auxiliaries, while the auxiliaries have the neat special abilities to balance it out.

Edited by Simulated Knave
Link to comment
Share on other sites

1 hour ago, The Rural Abjurer said:

And respectfully, "I'm just going to assume it always makes sense to start the edit at 1" is maybe the least rational thing I've heard you say on here.  Which is a low bar!

 

I'm not quite sure what is happening here, but I really do think there's some strange failure of communication going on. This wasn't an arbitrary or spontaneous choice; I came to this decision carefully, after testing my ideas on the game engine. I did my best to try and explain this choice to you, and to explain that the engine does not have problems with my implementation method. Again, I tested this. I wrote a set of instructions that I believe is clear, and requires no additional assumptions or input from the user.

 

Still, it seems that you are unhappy with what I am doing here. I'm sorry.

 

I have had some further ideas that would be a lot neater, and get around the bleeding problem. However, the last thing I want to do is to cause any more problems. To that end, I think it's probably best if I do no more public work on this for the time being. Hopefully that will be acceptable to all concerned.

Link to comment
Share on other sites

The fact that the engine does not have problems with one instance of the method does not mean the method will never cause problems.  And there are specific ways that is a very plausible outcome here.

 

I don't know how I can state this any more clearly.  I'm sorry you don't trust my assessment.  I've spent a lot of time doing things with these defs files over the years.  I've spent a lot of time watching random users take what sounded like a coherent explanation, screw up their files, fail to make a backup, and then complain to Spiderweb.

 

That's all I have to say.

Link to comment
Share on other sites

Guys. Don't fight like this. I'll worry that you're divorcing and I'll have to travel for Christmas.

 

I would point out that now that it is impossible to get the game non-digitally, and that computers have advanced a lot faster than Spiderweb games, fixing your screwed up files is about ten minutes' work. If that. I don't want Jeff getting pointless time-wasting emails that make him worry he coded wrong, but I think the risk is lower than it once was.

 

Anyway, one appears to be able to safely and easily mod the basic twelve stats and health (so long as one remembers to not let them extend into every single unit of that race), suggesting one could make the Vol PCs different from the Ukatish from the Havenites from the Ahriel (and, for that matter, the Prince different from other Havenites), which I will likely do. Fun!

 

Unfortunately I hoped once could edit other statistics the same way, but that seems to not be possible (for example, physical armor is logically stat 22. Doesn't seem to be moddable the same way as the basic twelve, though).

Link to comment
Share on other sites

37 minutes ago, Simulated Knave said:

Anyway, one appears to be able to safely and easily mod the basic twelve stats and health (so long as one remembers to not let them extend into every single unit of that race)

 

This may not be true.

 

The game engine sometimes loads a particular creature def, then alters various things about it, including its name, for that instance.  It doesn't happen with everything but there are cases where creature types get used in unexpected ways like this.  This has happened with PC defs in some previous games.

 

BTW, as far as the "games can be redownloaded" thing goes -- you'd think that would prevent the situation I described, but Spiderweb hasn't released games on physical media in just about a decade, and this has still come up with more recent games.  Yes, people who can't figure that out probably shouldn't be editing game files, which is exactly why we normally put warning labels on this stuff, and tell people to make backups if they do try it.

Link to comment
Share on other sites

This may not be true.

 

Which is why I said "appears."

 

Look, it's certainly possible that editing the basic stats will lead to horrible calamity. But it does seem a little unlikely, not least because all of those stats are edited in various creature definitions, including many of them being edited in the PC definitions. So long as backups are made, disaster can be avoided.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...