set_faction_prop - ryzom/ryzomcore GitHub Wiki


title: Set Faction Prop description: published: true date: 2023-03-13T00:35:09.883Z tags: editor: markdown dateCreated: 2023-03-13T00:35:06.034Z

setFactionProp

The setFactionProp native AI script function sets a property of the group's faction profile.

There are special factions that are automatically attributed to entities.

  • Player
  • Predator
  • Famous<faction>, where faction is the name of a Ryzom faction with uppercase initials and without underscores (e.g., FamousTribeBeachcombers represents players with a positive fame with the Tribe Beachcombers faction).
  • outpost:<id>:<side>, where id is the outpost alias as an int, and side is either attacker or defender. These factions may see their format change soon and shouldn't be used without prior discussion with the responsible coder. They represent players and squads fighting in an outpost conflict.

Syntax

()setFactionProp(Property: s, Content: s) // setFactionProp_ss_

Arguments

  • Property (string): The property to modify. Valid values for Property are:
    • faction
    • ennemyFaction
    • friendFaction
  • Content (string): A '|' separated list of faction names.

Example

()setFactionProp("ennemyFaction", "Predator|FamousTribeBeachcombers");

This example code sets the enemyFaction property of the group's faction profile to include both the "Predator" faction and the "FamousTribeBeachcombers" faction.

⚠️ **GitHub.com Fallback** ⚠️