Page MenuHomeFeedback Tracker

Components and component data modding during runtime (modding help) (feature request)
New, NormalPublic

Description

I tried to adjust component data for certain instances, but it wouldn't work.
Is there a way to edit component values for an object?

let's say, I have a playable character.
I can change the stamina regain per second.

I want to change this value while the game is running.

SCR_PlayerController t_PC = SCR_PlayerController.Cast(GetGame().GetPlayerController());
SCR_ChimeraCharacter t_Player = SCR_ChimeraCharacter.Cast(t_PC.GetControlledEntity());
Print(t_Player);
SCR_CharacterStaminaComponent t_Comp_CA = SCR_CharacterStaminaComponent.Cast(t_Player.FindComponent(SCR_CharacterStaminaComponent));

How do I change the character stamina regain per second now?
IS there something I can do to change values and maybe reset the component?

Details

Severity
Feature
Resolution
Open
Reproducibility
N/A
Operating System
Windows 7
Category
General
Additional Information

To summarize, what I want:

  • Edit component values live through scripts
  • Reinitialize components live through scripts

Event Timeline