Help me understand this faction system

Just downloaded Vega Strike and need help? Have a question but don't know where to start? Ask here.
Post Reply
dandennison84
Star Pilot
Star Pilot
Posts: 7
Joined: Sat Mar 02, 2013 3:23 am

Help me understand this faction system

Post by dandennison84 »

I'm not quite sure how to survive in this game. I'm making Atlantis to Serenity runs trying to build up some money. A guild merchant attacked me so I fought back. I ended up killing 5 merchant_guild and 1 merchant but now pretty much everyone hates me? confed, highborn, homeland-security, hunter, shaper, merchant_guild_citizen, highborn_citizen, shaper_citizen, mechanist_citizen and upgrades (also 1 kill?). Am I not supposed to fight? I attacked no one at any time first and my relations were all 0 or better with everyone except aera and they are starting to like me now that I had that fight?

Can I fix this or do I need to start over or what?
klauss
Elite
Elite
Posts: 7243
Joined: Mon Apr 18, 2005 2:40 pm
Location: LS87, Buenos Aires, República Argentina

Re: Help me understand this faction system

Post by klauss »

You must have attacked some merchant ally to get them to attack you.

Faction relations are a bit tricky right now... they do need to be redesigned. And not exactly who's allied with who, but what needs to be redesigned is how your actions influence them. Remember, the game doesn't know whether it was self-defense or not. Nor should merchants care. The thing that isn't so desirable is that it ripples so uncontrollably to every other faction.

In any case, that won't happen spontaneously, you must have done something to piss them off. Think hard. In the meanwhile, try to appease them by fleeing instead of killing, spamming them with friendly messages, and killing off their enemies (pirates, luddites).
Oíd mortales, el grito sagrado...
Call me "Menes, lord of Cats"
Wing Commander Universe
dandennison84
Star Pilot
Star Pilot
Posts: 7
Joined: Sat Mar 02, 2013 3:23 am

Re: Help me understand this faction system

Post by dandennison84 »

I went back to an older save, but I still see merchants getting mad at me. Could it be random or the cargo I'm carrying? I took a look at the comm_ai.cpp code to see if my talking to them could trigger something since every time I come out of base, I F1 everything in range.

Code: Select all

CommunicatingAI::CommunicatingAI( int ttype,
                                  int stype,
                                  float mood,
                                  float anger,
                                  float appeas,
                                  float moodswingyness,
                                  float randomresp ) : Order( ttype, stype )
    , anger( anger )
    , appease( appeas )
    , moodswingyness( moodswingyness )
    , randomresponse( randomresp )
    , mood( mood )
{
    if (appease > 665 && appease < 667) {
        static float appeas = XMLSupport::parse_float( vs_config->getVariable( "AI", "EaseToAppease", ".5" ) );
        this->appease = appeas;
    }
    if ( (anger > 665 && anger < 667) || (anger > -667 && anger < -665) ) {
        static float ang = XMLSupport::parse_float( vs_config->getVariable( "AI", "EaseToAnger", "-.5" ) );
        this->anger = ang;
    }
    if (moodswingyness > 665 && moodswingyness < 667) {
        static float ang1 = XMLSupport::parse_float( vs_config->getVariable( "AI", "MoodSwingLevel", ".2" ) );
        this->moodswingyness = ang1;
    }
    if (randomresp > 665 && moodswingyness < 667) {
        static float ang2 = XMLSupport::parse_float( vs_config->getVariable( "AI", "RandomResponseRange", ".8" ) );
        this->randomresponse = ang2;
    }
}
The last conditional looks different than the others. All of the others are testing a value equal to 666 (2/3rds of a 1000?) except the last. That isn't a copy/paste kind of error is it? =====> randomresp > 665 && moodswingyness < 667
klauss
Elite
Elite
Posts: 7243
Joined: Mon Apr 18, 2005 2:40 pm
Location: LS87, Buenos Aires, República Argentina

Re: Help me understand this faction system

Post by klauss »

dandennison84 wrote:The last conditional looks different than the others. All of the others are testing a value equal to 666 (2/3rds of a 1000?) except the last. That isn't a copy/paste kind of error is it? =====> randomresp > 665 && moodswingyness < 667
Honestly, I have no idea. I don't know that piece of code. It may be correct, and it may not. I don't think I've seen it misbehave, though, which makes me think it's correct.

Notice, if you try to be friends with everyone, F1-ing everyone, you won't be able to. If you make friends with one faction, their enemies will hate you. You might have pissed merchants by making friends with pirates or something like that - since you're neutral at the very beginning of the game, that particular time is very sensitive to the messages you send (not so much after you play a bit).
Oíd mortales, el grito sagrado...
Call me "Menes, lord of Cats"
Wing Commander Universe
dandennison84
Star Pilot
Star Pilot
Posts: 7
Joined: Sat Mar 02, 2013 3:23 am

Re: Help me understand this faction system

Post by dandennison84 »

Ok, that makes sense. Is there a table that says which factions like which other factions?
klauss
Elite
Elite
Posts: 7243
Joined: Mon Apr 18, 2005 2:40 pm
Location: LS87, Buenos Aires, República Argentina

Re: Help me understand this faction system

Post by klauss »

I'm sure there is ;) (don't know exactly where)
Oíd mortales, el grito sagrado...
Call me "Menes, lord of Cats"
Wing Commander Universe
CLoneWolf
ISO Party Member
ISO Party Member
Posts: 443
Joined: Thu May 01, 2008 5:14 pm

Re: Help me understand this faction system

Post by CLoneWolf »

klauss wrote:I'm sure there is ;) (don't know exactly where)
data/factions.xml looks good ;)
Deus Siddis
Elite
Elite
Posts: 1363
Joined: Sat Aug 04, 2007 3:42 pm

Re: Help me understand this faction system

Post by Deus Siddis »

dandennison84 wrote:Ok, that makes sense. Is there a table that says which factions like which other factions?
Chart. It doesn't show hostile relationships, but basically the major human sub-species are fighting skirmishes with each other, and everyone is fighting the Aera, including Rlaan.

More than half the human factions try to defend the merchants, so messing with them probably has too harsh of consequences. So in hindsight, I think only confederation, security and hunters should be tasked with defending merchants. Or maybe just security and hunters.
Deus Siddis
Elite
Elite
Posts: 1363
Joined: Sat Aug 04, 2007 3:42 pm

Re: Help me understand this faction system

Post by Deus Siddis »

The original poster has stumbled over a serious bug.

My last patch to factions.xml (which has been the status quo for the last couple releases) made these kinds of issues much less problematic. But it did not go far enough. Look at this chart of the faction relations, the arrows go from the protector to the protectee faction--

Image

As you can see most everyone will unite and ruthlessly murder any player who runs a foul of the merchant guild. Also the confederation does the same to anyone who gets into trouble with any of the human sub factions. In addition to being ruthless, this web of interconnectedness defeats the whole advantage of having multiple factions in the first place. The solution is to eliminate these far reaching connections.

The result is that only Homeland Security will hunt down criminals who attack sub factions of the Confederation. The Confederation military won't get involved in petty matters like chasing random criminals; their sole mission is to fight the Aera, a threat to potentially the entire species. Similarly, Homeland Security and the Hunters will be the only factions tasked with defending the Merchants.

So what do you say, Klauss? Should I send in the new factions patch?
klauss
Elite
Elite
Posts: 7243
Joined: Mon Apr 18, 2005 2:40 pm
Location: LS87, Buenos Aires, República Argentina

Re: Help me understand this faction system

Post by klauss »

Deus Siddis wrote:The result is that only Homeland Security will hunt down criminals who attack sub factions of the Confederation. The Confederation military won't get involved in petty matters like chasing random criminals; their sole mission is to fight the Aera, a threat to potentially the entire species. Similarly, Homeland Security and the Hunters will be the only factions tasked with defending the Merchants.

So what do you say, Klauss? Should I send in the new factions patch?
Makes sense. Only security forces should care what happens to allies after all. Same goes for Rlaan security.
Oíd mortales, el grito sagrado...
Call me "Menes, lord of Cats"
Wing Commander Universe
Deus Siddis
Elite
Elite
Posts: 1363
Joined: Sat Aug 04, 2007 3:42 pm

Re: Help me understand this faction system

Post by Deus Siddis »

Alright here is the patch, please commit it as soon as possible so it doesn't fall between the cracks:
factions_patch.zip
klauss wrote:Same goes for Rlaan security.
There doesn't seem to be any such faction in factions.xml.
You do not have the required permissions to view the files attached to this post.
klauss
Elite
Elite
Posts: 7243
Joined: Mon Apr 18, 2005 2:40 pm
Location: LS87, Buenos Aires, República Argentina

Re: Help me understand this faction system

Post by klauss »

Weird. I don't remember the name, but I remember seeing some kind of Rlaan security faction.
Oíd mortales, el grito sagrado...
Call me "Menes, lord of Cats"
Wing Commander Universe
Deus Siddis
Elite
Elite
Posts: 1363
Joined: Sat Aug 04, 2007 3:42 pm

Re: Help me understand this faction system

Post by Deus Siddis »

Well according to the the VS wiki there are quite a lot of unimplemented factions. Mostly Rlaan subfactions and various "uplifted" species.
TBeholder
Elite Venturer
Elite Venturer
Posts: 753
Joined: Sat Apr 15, 2006 2:40 am
Location: chthonic safety

Re: Help me understand this faction system

Post by TBeholder »

Deus Siddis wrote:As you can see most everyone will unite and ruthlessly murder any player who runs a foul of the merchant guild. Also the confederation does the same to anyone who gets into trouble with any of the human sub factions. In addition to being ruthless, this web of interconnectedness defeats the whole advantage of having multiple factions in the first place. The solution is to eliminate these far reaching connections.
Nah, it's cool, as long as it differs from "everyone bands together on X". Only needs increased cowardice factors. :)
Profilng deeper and toning down nonessential ones should be enough. E.g. merchants is protected mostly by Hunter and Confed; Confed loves Purist and Merchant more than LIHW; Hunter acts rather erratic on the boundaries of relation, to simulate "is this one in my contract?" or "is bounty worth the bother?" speread. And so on.
"Two Eyes Good, Eleven Eyes Better." -Michele Carter
Deus Siddis
Elite
Elite
Posts: 1363
Joined: Sat Aug 04, 2007 3:42 pm

Re: Help me understand this faction system

Post by Deus Siddis »

TBeholder wrote:Nah, it's cool, as long as it differs from "everyone bands together on X". Only needs increased cowardice factors. :)
Profilng deeper and toning down nonessential ones should be enough. E.g. merchants is protected mostly by Hunter and Confed; Confed loves Purist and Merchant more than LIHW; Hunter acts rather erratic on the boundaries of relation, to simulate "is this one in my contract?" or "is bounty worth the bother?" speread. And so on.
The engine does not seem to support the kinds of complex functionality you describe. This patch is meant to work with the engine the way it is now for use in v0.5.2.
The Faction Code Redesign thread deals with new features.
Post Reply