public static void DoReaction <T>(IReact obj) where T : IReact { Rectangle reactRect = obj.ReactRect; isLocked = true; foreach (var item in spriteObjList) { if (item is T && item != obj && !item.IsDeleted) { if ((item as IReact).ReactRect.Intersects(reactRect)) { (item as IReact).DoAction <T>(obj); } } } isLocked = false; }
public void DoAction <T>(IReact obj) { throw new NotImplementedException(); }
public void DoAction <T>(IReact obj) { (obj as SpriteObject).isActive = true; }
public void DoAction <T>(IReact obj) { }