예제 #1
0
    // Use this for initialization
    void Start()
    {
        TargetSearch();

        baseParameter.moveParameter = new MoveParameter(parent.frontDirection, 5F);

        if (target == null) { state = new MoveState(this); }
        else
        {
            HomingState.Options ops = new HomingState.Options
            {
                level = HomingState.HOMINGLEVEL.Middole,
                time = 180,
                interval = 2
            };
            state = new HomingState(this, target.transform, ops);

        }
        attackParameter.damage = new Damage(30, false, 20, parent.frontDirection, false);
    }
예제 #2
0
    // Use this for initialization
    void Start()
    {
        TargetSearch();

        baseParameter.moveParameter = new MoveParameter(parent.frontDirection, 5F);

        if (target == null)
        {
            state = new MoveState(this);
        }
        else
        {
            HomingState.Options ops = new HomingState.Options
            {
                level    = HomingState.HOMINGLEVEL.Middole,
                time     = 180,
                interval = 2
            };
            state = new HomingState(this, target.transform, ops);
        }
        attackParameter.damage = new Damage(30, false, 20, parent.frontDirection, false);
    }