void Start()
 {
     buttonW     = new moveForward();
     buttonA     = new moveLeft();
     buttonS     = new moveBack();
     buttonD     = new moveRight();
     buttonR     = new UndoCommand();
     buttonSpace = new jumpCommand();
 }
Esempio n. 2
0
 void Start()
 {
     //Bind keys with commands
     buttonB = new DoNothing();
     buttonW = new moveForward();
     buttonS = new moveReverse();
     buttonA = new moveLeft();
     buttonD = new moveRight();
     buttonZ = new undoCommand();
     rb      = GetComponent <Rigidbody>();
 }
Esempio n. 3
0
 void Start()
 {
     //Bind keys with commands
     moveLeft  = new moveLeft();
     moveRight = new moveRight();
     patrolingBehaviorCommands.Add(moveLeft);
     patrolingBehaviorCommands.Add(moveLeft);
     patrolingBehaviorCommands.Add(moveLeft);
     patrolingBehaviorCommands.Add(moveLeft);
     patrolingBehaviorCommands.Add(moveLeft);
     patrolingBehaviorCommands.Add(moveRight);
     patrolingBehaviorCommands.Add(moveRight);
     patrolingBehaviorCommands.Add(moveRight);
     patrolingBehaviorCommands.Add(moveRight);
     patrolingBehaviorCommands.Add(moveRight);
 }