void RaiseSensorChangedEvent(MazeSensor Sensor) { RoutedEventArgs newEventArgs = new RoutedEventArgs(Maze3DControl.SensorChangedEvent); newEventArgs.Source = Sensor; RaiseEvent(newEventArgs); }
private void Sensor_SensorChanged(object sender, RoutedEventArgs e) { Maze3D.MazeSensor Sensor = (Maze3D.MazeSensor)e.OriginalSource; if (Sensor.IsTriggered) { if (ScriptFSM != null) { ScriptFSM.MatchSensor(Sensor.Name); } } ScriptEditor.ShowWhen(Sensor.Name); }
private void Sensor_SensorChanged(object sender, RoutedEventArgs e) { MazeSensor Sensor = (MazeSensor)sender; RaiseSensorChangedEvent(Sensor); }