Exemplo n.º 1
0
    public void ActionEvent(Action source, GameObject gameObjectParam = null, ActionEventType events = ActionEventType.Compeleted,
                            int intParam = 0, string strParam = null)
    {
        UFOFactory ufofactory = Singleton <UFOFactory> .Instance;

        ufofactory.freeUFO(gameObjectParam);
    }
Exemplo n.º 2
0
 public void ActionEvent(Action source, GameObject gameObjectParam = null, ActionEventType events = ActionEventType.Compeleted,
                         int intParam = 0, string strParam = null)
 {
     if (events == ActionEventType.Started)
     {
         slowFlyAction   = FlyAction.getAction(new Vector3(Random.Range(-1, 1f), Random.Range(-1, 1f)), slowSpeed);
         middleFlyAction = FlyAction.getAction(new Vector3(Random.Range(-1, 1f), Random.Range(-1, 1f)), middleSpeed);
         fastFlyAction   = FlyAction.getAction(new Vector3(Random.Range(-1, 1f), Random.Range(-1, 1f)), fastSpeed);
         this.RunAction(gameObjectParam, source, this);
     }
     else if (events == ActionEventType.Compeleted)
     {
         UFOFactory ufofactory = Singleton <UFOFactory> .Instance;
         ufofactory.freeUFO(gameObjectParam);
     }
 }
Exemplo n.º 3
0
 //move gameObject
 public void hit(GameObject gameObject)
 {
     ufoFactory.freeUFO(gameObject);
     scoreRecorder.addScore(round);
 }