public void initiate() { if( enemy != null ) { Battle battle = new Battle(player, enemy); battle.start(); } }
public void OnExecuteCommand(Battle.MessageConstants.ExecuteCommandHook hook) { var abilityData = AllPartyManager.Instance.ActiveTimeMaxBattleCharacter.SelectCommandData.AbilityData; abilityData.CommandEventDatabase.ForEach( p => { var components = p.PrefabEventHolder.GetComponents( typeof( I_SetCommandEventParameter ) ); for( int i=0, imax=components.Length; i<imax; i++ ) { (components[i] as I_SetCommandEventParameter).SetCommandEventParameter( p ); } components = p.PrefabEventHolder.GetComponents( typeof( I_OnExecuteCommandHookable ) ); for( int i=0, imax=components.Length; i<imax; i++ ) { (components[i] as I_OnExecuteCommandHookable).OnExecuteCommand( hook ); } }); }
public void OnExecuteCommand(Battle.MessageConstants.ExecuteCommandHook hook) { var selectCommandData = AllPartyManager.Instance.ActiveTimeMaxBattleCharacter.SelectCommandData; selectCommandData.SetTarget( selectCommandData.GetTargetGroupSafe().WeakCharacter ); }