Skip to content

Commit

Permalink
Disable ranged combat modulators in default config
Browse files Browse the repository at this point in the history
  • Loading branch information
szapp committed Mar 5, 2019
1 parent 277c010 commit 53a044c
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions _work/data/Scripts/Content/GFA/config/ranged.d
Expand Up @@ -27,6 +27,12 @@
* recoil, see GFA_GetRecoil() below. All of this is a design choice and can be changed in the functions in this file.
*/
func int GFA_GetDrawForce(var C_Item weapon, var int talent) {

// Default:
return 100; // Remove this line if you want to use this configuration function!
// --- Everything below is ignored ---


var int drawForce;

// Differentiate between bows and crossbows
Expand Down Expand Up @@ -70,6 +76,12 @@ func int GFA_GetDrawForce(var C_Item weapon, var int talent) {
* Note: For Gothic 1, instead of the talent, the dexterity is used (as is default for Gothic 1)
*/
func int GFA_GetAccuracy(var C_Item weapon, var int talent) {

// Default:
return MEMINT_SwitchG1G2(hero.attribute[ATR_DEXTERITY], talent); // Remove this line if you want to use this config!
// --- Everything below is ignored ---


// Here, the 'hit chance' is scaled by draw force, where 'hit chance' is talent (Gothic 2) or dexterity (Gothic 1)
// Draw force = 100% -> accuracy = hit chance
// Draw force = 0% -> accuracy = hit chance * 0.8
Expand Down Expand Up @@ -106,6 +118,12 @@ func int GFA_GetAccuracy(var C_Item weapon, var int talent) {
* aiming time (better draw force), see GFA_GetDrawForce() above.
*/
func int GFA_GetRecoil(var C_Item weapon, var int talent) {

// Default:
return 0; // Remove this line if you want to use this configuration function!
// --- Everything below is ignored ---


// No recoil for bows, since they have longer draw time, see GFA_GetDrawForce() above.
if (weapon.flags & ITEM_BOW) {
return 0;
Expand Down Expand Up @@ -151,6 +169,12 @@ func int GFA_GetRecoil(var C_Item weapon, var int talent) {
*/
func int GFA_GetInitialBaseDamage(var int baseDamage, var int damageType, var C_Item weapon, var int talent,
var int aimingDistance) {

// Default:
return baseDamage; // Remove this line if you want to use this configuration function!
// --- Everything below is ignored ---


// Here the damage is scaled by draw force:
// Draw force = 100% -> baseDamage
// Draw force = 0% -> baseDamage * 0.8
Expand Down

0 comments on commit 53a044c

Please sign in to comment.