Example #1
0
    void Start()
    {
        meshFilter = GetComponent <MeshFilter>();

        monitor.Add(() => IsChildOfCanvas);
        monitor.Add(() => meshFilter.sharedMesh);
        monitor.Add <Material[]>(() => materials, ChangeMonitor.ArrayEvaluator);
    }
Example #2
0
    // Use this for initialization
    void Start()
    {
        monitor = new ChangeMonitor(true);

        monitor.Add(() => MaximumHealth);
        monitor.Add(() => Strength);
        monitor.Add <float>(() => WatchThisGrow, (newValue, priorValue) => newValue > priorValue);
    }