Difference between revisions of "Server:Faction"

From The Al`Kabor Project Wiki
Jump to navigation Jump to search
Line 1: Line 1:
This article will attempt to explain how faction works server-side to assist with understanding the various modifiers applied to characters between the base values and the ones you experience in-game.
This article will attempt to explain how faction works server-side to assist with understanding the various modifiers applied to characters between the base values and the ones you experience in-game.


In the source code at '''/common/faction.cpp''', faction is calculated in the '''CalculateFaction''' function
In the source code, faction is found in '''/common/faction.h''' and '''/common/faction.cpp'''. Faction is calculated in the '''CalculateFaction''' function, where


<code>character_value += base value + class modifier + race modifier + deity modifier</code>
<code>character_value += base value + class modifier + race modifier + deity modifier</code>


== Faction Ranges ==  
== Faction Value Ranges ==  
{| class="wikitable"
{| class="wikitable"
|-
|-
! From !! To !! Level
! From !! To !! Level
|-
|-
| >= 2000 || - || FACTION_MAX_ALLY
| >= 2000 || - || FACTION_MAX_ALLY = 0
|-
|-
| >= 1100 || - || FACTION_ALLY
| >= 1100 || - || FACTION_ALLY = 1
|-
|-
| >= 750 || <= 1099 || FACTION_WARMLY
| >= 750 || <= 1099 || FACTION_WARMLY = 2
|-
|-
| >= 500 || <= 749 || FACTION_KINDLY
| >= 500 || <= 749 || FACTION_KINDLY = 3
|-
|-
| >= 100 || <= 499 || FACTION_AMIABLY
| >= 100 || <= 499 || FACTION_AMIABLY = 4
|-
|-
| >= 0 || <= 99 || FACTION_INDIFFERENTLY
| >= 0 || <= 99 || FACTION_INDIFFERENTLY = 5
|-
|-
| >= -100 || <= -1 || FACTION_APPREHENSIVELY
| >= -100 || <= -1 || FACTION_APPREHENSIVELY = 6
|-
|-
| >= -500 || <= -101 || FACTION_DUBIOUSLY
| >= -500 || <= -101 || FACTION_DUBIOUSLY = 7
|-
|-
| >= -750 || <= -501 || FACTION_THREATENINGLY
| >= -750 || <= -501 || FACTION_THREATENINGLY = 8
|-
|-
| - || <= -751 || FACTION_SCOWLS
| - || <= -751 || FACTION_SCOWLS = 9
|-
|-
| - || <= -2000 || FACTION_MAX_SCOWLS
| - || <= -2000 || FACTION_MAX_SCOWLS = 10
|}
|}

Revision as of 10:08, 21 November 2024

This article will attempt to explain how faction works server-side to assist with understanding the various modifiers applied to characters between the base values and the ones you experience in-game.

In the source code, faction is found in /common/faction.h and /common/faction.cpp. Faction is calculated in the CalculateFaction function, where

character_value += base value + class modifier + race modifier + deity modifier

Faction Value Ranges

From To Level
>= 2000 - FACTION_MAX_ALLY = 0
>= 1100 - FACTION_ALLY = 1
>= 750 <= 1099 FACTION_WARMLY = 2
>= 500 <= 749 FACTION_KINDLY = 3
>= 100 <= 499 FACTION_AMIABLY = 4
>= 0 <= 99 FACTION_INDIFFERENTLY = 5
>= -100 <= -1 FACTION_APPREHENSIVELY = 6
>= -500 <= -101 FACTION_DUBIOUSLY = 7
>= -750 <= -501 FACTION_THREATENINGLY = 8
- <= -751 FACTION_SCOWLS = 9
- <= -2000 FACTION_MAX_SCOWLS = 10