public void LayoutLinkSet() { _layout = _layoutLink.PuzzleLayout; if (!_layout.HasProperty(_layoutLink.Position, "Health")) { _layout.SetProperty(_layoutLink.Position, "Health", 3); } _layout.PropertySet += PropertyChanged; _health = (int)_layout.GetObjectAt(_layoutLink.Position).Properties["Health"].Value; }
public void LayoutLinkSet() { _layout = _layoutLink.PuzzleLayout; if (!_layout.HasProperty(_layoutLink.Position, "IsLoaded")) { _layout.SetProperty(_layoutLink.Position, "IsLoaded", false); } _layout.PropertySet += PropertyChanged; var isNowLoaded = (bool)_layout.GetObjectAt(_layoutLink.Position).Properties["IsLoaded"].Value; UpdateLoadedState(isNowLoaded); }