River Connection mod

The code is based on which civ's leader has the TRAIT_RIVER_EXPANSION trait and not on the actual civ. The bit in the XML that names America is just biasing them towards river starts. The important thing is that Washington has TRAIT_RIVER_EXPANSION

To change which trait grants the river connections capability, you'll need to edit the TraitRiverConnection.lua file

Code:
function isRiverExpansion(iPlayer)
  if (hasRiverExpansionTrait[iPlayer] == nil) then
    hasRiverExpansionTrait[iPlayer] = false
	
    for _ in DB.Query("SELECT 1 FROM Leader_Traits WHERE LeaderType=? AND TraitType='[B][COLOR="Red"]TRAIT_RIVER_EXPANSION[/COLOR][/B]'", GameInfo.Leaders[Players[iPlayer]:GetLeaderType()].Type) do
      hasRiverExpansionTrait[iPlayer] = true
    end
  end

  return hasRiverExpansionTrait[iPlayer]
end

or to grant the river connection capability to all civs, just use

Code:
function isRiverExpansion(iPlayer)
  return true
end
 
IIRC it's used in one of the scenarios (Scramble for Africa?) and no it doesn't have a similar effect.

Edit: Search the forums if you want/need more info, as it's effect has been discussed before
 
Thanks!

So America always had the River Expansion trait? Or it was added by the required dll and activated by the mod?

Sorry for being such a newbie in modding.
 
Thanks!

So America always had the River Expansion trait? Or it was added by the required dll and activated by the mod?

Sorry for being such a newbie in modding.
America's trait name in the Game's original XML code is TRAIT_RIVER_EXPANSION.

Quite a few of the actual trait names as used in the XML of the base game aren't quite what you'd expect given the UA they ended up with when the game was released.

I've read that Firaxis was originally going to give America the FasterAlongRivers ability, but they ended up just using the reduced tile-acquire costs.
 
Top Bottom