The Witcher 3
0 of 0

File information

Last updated

Original upload

Created by

KNG

Uploaded by

KNGR

Virus scan

Safe to use

Tags for this mod

208 comments

  1. JovianStone
    JovianStone
    • supporter
    • 29 kudos
    Locked
    Sticky
    I attempted to make this mod only trigger when actually IN COMBAT....but since my Witcher 3 scripting skills aren't up to snuff, so far I've failed. Honestly, I can't believe this wasn't initially set by the author. Every time I kill a rabbit or slaughter some respawning pigs, I gotta sit through the slow-mo. It lost it's appeal a while ago.



    Edit: What I did end up doing is add a random chance to every instance. So now not instead of only critical hits rolling for chance, everything does. Which also means I can set each one to have their own percentage.



    This is my modified file from:

    MOD\content\scripts\local\KNGCSMCM.ws
     
    Spoiler:  
    Show


    class CKNGCSMCM extends CGameplayEntity{

    private var attackAction : W3Action_Attack;
    private var weaponId: SItemUniqueId;
    private var actorAttacker : CActor;
    private var playerAttacker: CR4Player;
    private var actorVictim : CActor;

    private var dodgeRollSlowMoFactor : float;
    private var evadeStepSlowMoFactor : float;
    private var counterAttackSlowMoFactor : float;
    private var criticalHitSlowMoFactor: float;
    private var dismemberSlowMoFactor: float;

    private vardodgeRollSlowMoChance: Int32;
    private var evadeStepSlowMoChance: Int32;
    private varcounterAttackSlowMoChance: Int32;
    private var criticalHitSlowMoChance: Int32;
    private vardismemberSlowMoChance: Int32;

    private var rolling : string;
    private var evading : string;
    private var counterattack : string;
    private var criticalhit : string;
    private var dismember: string;


    public function Init(optional act : W3DamageAction, optional isCriticalHit : bool, optional isRolling : bool, optional evadeTarget : CActor, optional dismember : bool) {

    CriticalSlowMotionCameraMovementController(isRolling, evadeTarget);
    CriticalSlowMotionCameraCombatController(act, isCriticalHit, dismember);

    }



    private function CriticalSlowMotionCameraMovementController(isRolling : bool, evadeTarget : CActor) {

    if (isRolling) {

    SlowMoController(true, "rolling");

    thePlayer.AddTimer('DeactivateSlowMoCam', 0.3, false);

    } else if (evadeTarget) {

    SlowMoController(true, "evading");

    thePlayer.AddTimer('DeactivateSlowMoCam', 0.2, false);

    }

    }

    private function CriticalSlowMotionCameraCombatController(act : W3DamageAction, isCriticalHit : bool, optional dismember : bool) {

    attackAction = (W3Action_Attack)act;
    weaponId = attackAction.GetWeaponId();
    actorAttacker= (CActor)act.attacker;
    playerAttacker = (CR4Player)act.attacker;
    actorVictim = (CActor)act.victim;



    if( actorVictim == GetWitcherPlayer() && attackAction.IsCountered() && act.DealsPhysicalOrSilverDamage()) {

    SlowMoController(true, "counterattack");

    thePlayer.AddTimer('DeactivateSlowMoCam', 0.4, false);



    }

    if( actorAttacker == GetWitcherPlayer() && act.DealsPhysicalOrSilverDamage() && attackAction.IsCriticalHit()) {

    if ( attackAction.IsActionRanged() || thePlayer.IsWeaponHeld('fist') ) {

    return;

    } else {

    SlowMoController(true, "criticalhit");

    thePlayer.AddTimer('DeactivateSlowMoCam', 0.2, false);

    }

    }

    if (dismember) {

    SlowMoController(true, "dismember");

    thePlayer.AddTimer('DeactivateSlowMoCam', 0.3, false);

    }

    }

    public function RandomFactor() : Int32 {

    var i : Int32;
    var Min : Int32;
    var Max : Int32;
    var Value : Int32;

    i = 0;

    Min = 0;
    Max = 100;

    for(i = 0; i < 1; i+=1) {

    Value = RandRange(Max, Min);

    }

    return Value;

    }

    public function SlowMoController (isActive : bool, optional actionname : string) {


    rolling = "rolling";
    evading = "evading";
    counterattack = "counterattack";
    criticalhit= "criticalhit";
    dismember= "dismember";


    // Set your Slow Motion Chance for the individual actions here -These were also added below in order to trigger

    dodgeRollSlowMoChance = 10;
    evadeStepSlowMoChance = 25;
    counterAttackSlowMoChance = 25;
    criticalHitSlowMoChance = 33;
    dismemberSlowMoChance = 100;

    // Set your Slow Motion Factor for the individual action here

    dodgeRollSlowMoFactor = 0.25f;
    evadeStepSlowMoFactor = 0.25f;
    counterAttackSlowMoFactor = 0.25f;
    criticalHitSlowMoFactor = 0.25f;
    dismemberSlowMoFactor = 0.25;


    if (isActive && actionname == rolling && RandomFactor() < dodgeRollSlowMoChance) {

    theGame.SetTimeScale(dodgeRollSlowMoFactor, theGame.GetTimescaleSource(7), theGame.GetTimescalePriority(7), true);
    }

    if (isActive && actionname == evading && RandomFactor() < evadeStepSlowMoChance) {

    theGame.SetTimeScale(evadeStepSlowMoFactor, theGame.GetTimescaleSource(7), theGame.GetTimescalePriority(7), true);
    }

    if (isActive && actionname == counterattack && RandomFactor() < counterAttackSlowMoChance) {

    theGame.SetTimeScale(counterAttackSlowMoFactor, theGame.GetTimescaleSource(7), theGame.GetTimescalePriority(7), true);
    }

    if (isActive && actionname == criticalhit && RandomFactor() < criticalHitSlowMoChance) {

    theGame.SetTimeScale(criticalHitSlowMoFactor, theGame.GetTimescaleSource(7), theGame.GetTimescalePriority(7), true);
    }

    if (isActive && actionname == dismember && RandomFactor() < dismemberSlowMoChance) {

    theGame.SetTimeScale(dismemberSlowMoFactor, theGame.GetTimescaleSource(7), theGame.GetTimescalePriority(7), true);
    }

    if (!isActive) {

    theGame.RemoveTimeScale(theGame.GetTimescaleSource(7));

    }

    }

    }


    Search "Set your Slow Motion Chance for the individual actions here" to see what I added. You have to add EACH of those to the bottom of the script as well, to each of the individual actions. Like so:

    original:
    if (isActive && actionname == rolling)

    Added Random Chance:
    if (isActive && actionname == rolling && RandomFactor() < dodgeRollSlowMoChance)
  2. CptDihindu
    CptDihindu
    • member
    • 0 kudos
    For those stuck in permanent slow-mo, use the "Immersive Camera" mod. It has slow-motion settings for Critical Hit, Dodge, AARD, and Counterattack. Turn other immersive camera settings to vanilla if you only want slow motion.
  3. Erosion2
    Erosion2
    • member
    • 0 kudos
    Does it compatible with GOTY version?
    1. Antonaros1999
      Antonaros1999
      • member
      • 12 kudos
      It probably is
    2. cbaker19
      cbaker19
      • member
      • 1 kudos
      I have been using with 1.31, no problems. Occasionally I have a few seconds of slo mo while riding Roach outside of combat, but from other comments that is normal. Works great for me.
    3. CptDihindu
      CptDihindu
      • member
      • 0 kudos
      Dude, I cannot exit in slow motion once it's started. Slow motion remains out of the combat too. How to fix that? 
  4. sultan51
    sultan51
    • member
    • 0 kudos
    No support next gen (((
  5. Tangl3
    Tangl3
    • supporter
    • 0 kudos
    For those stuck in permanent slow-mo even after uninstalling the mod, you can do the following to fix it:

    Open your console and type "slow(1)", then press Enter. Worked for me.
    1. N4V4LH4
      N4V4LH4
      • member
      • 0 kudos
      this method solved my problem without having to uninstall the mod, and even better, it made the mod work correctly. (One detail is that I opted for slow(0.9)
      Thank you very much
  6. StoneColdt
    StoneColdt
    • member
    • 0 kudos
    gg
  7. Dvieira1024
    Dvieira1024
    • member
    • 0 kudos
    are there any known conflicts? i keep getting script errors
  8. Stranhed
    Stranhed
    • supporter
    • 0 kudos
    compatible with next gen?
  9. lukaZ09
    lukaZ09
    • member
    • 0 kudos
    Is compatible with 1.32?
  10. Betari
    Betari
    • member
    • 0 kudos
    This mod seems to conflict with Friendly Meditation mod. After installing FM, the slow-mo effect won't disappear after some battles. This can be fixed by rolling with spacebar (direction W/S/A/D + spacebar). Also, i'm trying to change some digit values in script, but does no major effect. Otherwise, this is good mod and was working without any bugs before installing FM.
  11. dirtyksubis
    dirtyksubis
    • supporter
    • 0 kudos
    this is garbage broke my game, cant uninstall