EmptyEpsilon icon indicating copy to clipboard operation
EmptyEpsilon copied to clipboard

[FactionInfo] Expose getter and setter for faction relationships

Open oznogon opened this issue 1 year ago • 0 comments

  • Add conversion functions for EFactionVsFactionState as a parameter and return value

  • Replace the overloaded FactionInfo::getState function with separate getRelationshipWith and getRelationshipBetween functions, and replaces usage of FactionInfo::getState with the equivalent getRelationshipBetween

  • Expose getRelationshipWith to scripting:

    human_navy = getFactionInfo("Human Navy")
    kraylor = getFactionInfo("Kraylor")
    human_kraylor_relationship = kraylor:getRelationshipWith(human_navy) -- returns "enemy"
    
  • Add setRelationshipWith

Towards #530.

oznogon avatar Mar 24 '23 05:03 oznogon