private bool IsCompatibleSystem(IContactSystem system, IContactTrigger ct) { var sysType = system.GetType(); foreach (var ignored in ignoredSystems) { //Debug.Log(sysType + " <b> compare </b> " + ignored + " " + sysType.CheckIsAssignableFrom(ignored) + ":" + ignored.CheckIsAssignableFrom(sysType)); //if (sysType.CheckIsAssignableFrom(ignored)) if (ignored.CheckIsAssignableFrom(sysType)) { return(false); } } //Debug.Log(name + " <> " + (ct as Component).name + " <b>match</b> " + sysType.Name); return(true); }
public ContactEvent(ContactEvent contactEvent) { this.contactSystem = contactEvent.contactSystem; this.contactTrigger = contactEvent.contactTrigger; this.contactType = contactEvent.contactType; }
public ContactEvent(IContactSystem contactSystem, IContactTrigger contacter, ContactType contactType) { this.contactSystem = contactSystem; this.contactTrigger = contacter; this.contactType = contactType; }