class CombatGadgetHelper
{

	public static function SpawnAttack( source : GameObject, radius : Float, attackRecord : Attack_Record, instigator : weak< GameObject > )
	{
		var attack : Attack_GameEffect;
		var attackEffect : EffectInstance;
		var attackContext : AttackInitContext;
		var statMods : array< gameStatModifierData >;
		attackContext.record = attackRecord;
		attackContext.instigator = instigator;
		attackContext.source = source;
		attack = ( ( Attack_GameEffect )( IAttack.Create( attackContext ) ) );
		attackEffect = attack.PrepareAttack( instigator );
		attack.GetStatModList( statMods );
		EffectData.SetFloat( attackEffect.GetSharedData(), GetAllBlackboardDefs().EffectSharedData.radius, radius );
		EffectData.SetVector( attackEffect.GetSharedData(), GetAllBlackboardDefs().EffectSharedData.position, source.GetWorldPosition() );
		EffectData.SetVariant( attackEffect.GetSharedData(), GetAllBlackboardDefs().EffectSharedData.attack, ( ( IAttack )( attack ) ) );
		EffectData.SetVariant( attackEffect.GetSharedData(), GetAllBlackboardDefs().EffectSharedData.attackStatModList, statMods );
		attack.StartAttack();
	}

	public static function SpawnPhysicalImpulse( source : GameObject, radius : Float )
	{
		var effect : EffectInstance;
		effect = GameInstance.GetGameEffectSystem( source.GetGame() ).CreateEffectStatic( 'physicalImpulseSphere', '', source );
		EffectData.SetFloat( effect.GetSharedData(), GetAllBlackboardDefs().EffectSharedData.radius, radius );
		EffectData.SetVector( effect.GetSharedData(), GetAllBlackboardDefs().EffectSharedData.position, source.GetWorldPosition() );
		effect.Run();
	}

}

