Re: Question about ancillaries.
Quote:
Originally Posted by Malrubius
The bane of the ancillary system--we can't tell what ancillary a general has gotten, either through a trigger, or as a present from another general.
Hmmmm. What if you assigned every ancillary a unique power of two as a code number (1, 2, 4, 8, 16 . . .), and then had it give an Electability bonus equal to that number? You would then have a finite number of possibilities for the Electability attribute for a possessor of the ancillary.
For instance, say we wanted to check five ancillaries as part of trigger conditions. We assigned them respective powers of two from 2^0 to 2^4. Now, if we want to check whether a general has ancillary #3 (with code number 4), we check if his Electability is equal to 4, 5, 6, 7, 12, 13, 14, 15, 20, 21, 22, 23, 28, 29, 30, or 31. If it's equal to any of those numbers, he has the ancillary; if not, he doesn't. Of course, the number of possibilities will increase exponentially as we increase the number of ancillaries we want to test for, but there's no limit to triggers, so no worries there. We'd just need to make a simple program to generate them.
*adds another notch to his List of Stuff I've Probably Helped EB Out with Without Having to Do a Damned Thing, a list quite a lot longer than the List of Stuff I've Helped EB Out with by Actually Doing Something*
Re: Question about ancillaries.
Any idea what the maximum value of Electability is?
You're going to get into very large numbers very quickly, unless you just do this for a handful of ancillaries. (IOW, don't notch your chickens before they're hatched ~;) )
Re: Question about ancillaries.
if you , after a battle, get teh message that a general died in battle. is that a possible trigger?
could that spawn a "avenger" trait for his son?
Re: Question about ancillaries.
Hmm, I'll have to test and see if that works.
Re: Question about ancillaries.
Quote:
Originally Posted by Malrubius
Any idea what the maximum value of Electability is?
I'll do a quick test.
Quote:
Originally Posted by Malrubius
(IOW, don't notch your chickens before they're hatched ~;) )
That's why I said "Probably".
Edit: I removed all triggers from EDCT, gave Good_Commander (which Flavius Julius starts with in vanilla) the effect of Electability 1000000000, and then added the following triggers:
Code:
;------------------------------------------
Trigger inherited
WhenToTest CharacterTurnEnd
Condition Attribute Electability [gt]= 1000000000
Affects GoodAttacker 20 Chance 100
;------------------------------------------
Trigger inherited
WhenToTest CharacterTurnEnd
Condition Attribute Electability [gt]= 1000000
Affects GoodDefender 20 Chance 100
;------------------------------------------
Trigger inherited
WhenToTest CharacterTurnEnd
Condition Attribute Electability [gt]= 1000
Affects Drink 100 Chance 100
I then started a game and ended my turn. Suddenly, good ol' Flavius was a heroic attacker and defender, but Paralytic. I think we can safely guess that there's not any limit. 1,000,000,000 is good enough for 29-30 ancillaries, in any case.
Of course, there's the slight problem of having to list roughly 500,000,000 possibilities to check for the presence of any given ancillary, but this can be simplified substantially by translating the triggers into ranges. The 29th ancillary, for instance, has a code number of 268,435,456, so (assuming 30 ancillaries) we can just check:
Code:
Condition Attribute Electability [gt]= 268435456
and Attribute Electability [lt]= 536870911
[next trigger]
Condition Attribute Electability [gt]= 805306368
and Attribute Electability [lt]= 1073741823
The number of triggers will then double for each step down, all the way up to the maximum of 536,870,912 for the first ancillary (listing all odd numbers from 1 through 1,073,741,823). Of course, such problems wouldn't really arise if we just selected a few ancillaries we wanted to check for.
Given the Senate's removal, perhaps we could also use SenateStanding and PopularStanding? Or are those used? They would, of course, reduce the burden exponentially.
I can't help but think there must be some way to refine the system. What if we had, for each ancillary with code number N, a hidden trait, which would give -N electability? We could then have a progression of trigger pairs for CharacterTurnEnd that would grant or remove the traits in succession, such that only one pair would be necessary per ancillary. For example, say we have N ancillaries, where any ancillary N gives an Electability bonus of 2^(N−1) = N'. Then we would have a series of triggers such as:
Code:
;------------------------------------------
Trigger AncillaryNGain
WhenToTest CharacterTurnEnd
Condition Attribute Electability [gt]= N'
Affects AncillaryN 1 Chance 100
;------------------------------------------
Trigger AncillaryN−1Gain
WhenToTest CharacterTurnEnd
Condition Attribute Electability [gt]= N'/2
Affects AncillaryN−1 1 Chance 100
. . .
;------------------------------------------
Trigger Ancillary1Gain
WhenToTest CharacterTurnEnd
Condition Attribute Electability [gt]= 1
Affects Ancillary1 1 Chance 100
AncillaryNGain would, of course, give Electability -N' for any N. Now, consider. For the first trigger, what combination of ancillaries could possibly cause an Electability bonus of [gt]= N'? Only one that contains Ancillary N, because all other ancillaries' Electability combined amounts only to N'−1 Electability.
So if the character has the ancillary, he'll gain the AncillaryN trait, which will reduce his Electability by N'. After that's checked, he can only have more than (N−1)' = N'/2 Electability if he has Ancillary N−1. And so on, all the way down to Ancillary 1. Do you follow?
Okay, now after all those triggers, if the player hasn't traded away any ancillaries, Electability will be 0. If he has traded away ancillaries, we can test in exactly the same way as before. If the player traded away Ancillary N, Electability will be at -N' due to the AncillaryN trait, and so we check for that and adjust traits accordingly to account for lost ancillaries.
Finally, as an error-catcher: immediately after all these checks are done, have the game check to be sure Electability is 0. If it's not, have a warning message popup saying "BUG! Save this game and send it to EB at foo@bar.com, or post it on our message boards!"
Re: Question about ancillaries.
Quote:
Originally Posted by Malrubius
Hmm, I'll have to test and see if that works.
would be nice to get: avenger ; this man wants to avenge his fathers death:
+1 command (vs faction..is possible)
Re: Question about ancillaries.
Quote:
Originally Posted by jerby
if you , after a battle, get teh message that a general died in battle. is that a possible trigger?
could that spawn a "avenger" trait for his son?
It is possible, and we'll be looking into these sorts of traits. Probably not for the open beta though.
Thanks for the suggestion! ~:)
Re: Question about ancillaries.
Quote:
Originally Posted by therother
It is possible, and we'll be looking into these sorts of traits. Probably not for the open beta though.
Thanks for the suggestion! ~:)
Oh, great. More work for us. Malrubius is already getting his :whip:
k
Re: Question about ancillaries.
Quote:
Originally Posted by therother
Thanks for the suggestion! ~:)
it was my idea first... :mean:
so the death event for a general being killed in battle is different than the event for dying of old-age/plague/whatever?
Re: Question about ancillaries.
HOLY SMOKES!!!!
Where the hell do you guys learn this stuff? I knew it was complicated, but my God!
You guys either:
(1) Work for dev companies or have done so in the past.
or
(2) Went to school for this stuff?
or
(3) I don't know! Holy Crup!
I would love to learn this, but the mod academy took a dump immediately. That's so damn cool....
Are there any uses for this knowledge other than video games?
Re: Question about ancillaries.
Quote:
Originally Posted by Big_John
it was my idea first... :mean:
Sorry, Big_John! Serves me right for not rereading the thread. :embarassed:
Quote:
so the death event for a general being killed in battle is different than the event for dying of old-age/plague/whatever?
Well, it's different in the sense that it occurs PostBattle rather than on the strategy map.
Re: Question about ancillaries.
Quote:
Originally Posted by therother
Well, it's different in the sense that it occurs PostBattle rather than on the strategy map.
so if you try to give people an "avenger" triat, they won't acquire that at any old death event? it can be tied specifically to the event of a general being killed in battle?
Re: Question about ancillaries.
Yes, PostBattle only occurs after a battle, either autoresolve or battlemap.
Re: Question about ancillaries.
And it also returns the factions that participated, plus various other handy stuff that could be worked in (e.g., the odds―did he die in glorious combat or was he dishonorably/stupidly overwhelmed by numbers alone?).
Re: Question about ancillaries.
Quote:
Originally Posted by Simetrical
And it also returns the factions that participated, plus various other handy stuff that could be worked in (e.g., the odds―did he die in glorious combat or was he dishonorably/stupidly overwhelmed by numbers alone?).
mm.. sounds like you guys could do a lot with that particular event. good stuff.
edit: is there any trait that would make sense to give to a faction leader if several of his generals die dishonorably in combat?
edit2: therother, are you one of the invisble ones??? ~;)
Re: Question about ancillaries.
Quote:
Originally Posted by Big_John
mm.. sounds like you guys could do a lot with that particular event. good stuff.
Yes, the trait system is very flexible;very little of its potential was tapped in RTW. EB will go a long way to correcting that. ~:)
Re: Question about ancillaries.
Quote:
Originally Posted by Big_John
it was my idea first... :mean:
so the death event for a general being killed in battle is different than the event for dying of old-age/plague/whatever?
that might have been teh inspiration for me suggesting..i felt liek my "avenger" was original...whoops..
still feels nice to help~;)
Re: Question about ancillaries.
Quote:
Originally Posted by jerby
that might have been teh inspiration for me suggesting..i felt liek my "avenger" was original...whoops..
still feels nice to help~;)
stealing Ideas are we? jerby,jerby, jerby ~;)
you can say what you want about my wise lynx but at least I was original ~D
~:cheers:
Re: Question about ancillaries.
Although being the mastermind is of course the most important and is the hardest work!
Re: Question about ancillaries.
Quote:
Originally Posted by Big_John
edit2: therother, are you one of the invisble ones??? ~;)
He's the mastermind of our system, yes. The puppetmaster pulling the strings and keeping us all in line. :whip:
Re: Question about ancillaries.
All.. :bow: :bow: :bow: to the great traiter gods... :bow: :bow: :bow: