Physics Mass Override

Dear Skydive,

I’ve posted a tutorial on how you can change physics mass during runtime here!

Wiki Link

A new, community-hosted Unreal Engine Wiki - Announcements - Unreal Engine Forums!

Code from tutorial:

void AYourStaticMeshActorClass::SetMassScale(const float& NewScale)
{
	if(!StaticMeshComponent) return;
       //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
	FBodyInstance* BodyInst = StaticMeshComponent->GetBodyInstance();
 
	if(!BodyInst) return;
	//~~~~~~~~~~~~~~~~~~~~~~~~
 
	// New Scale 
	BodyInst->MassScale = NewScale;  
 
	// Trigger Update! 
	BodyInst->UpdateMassProperties();
}