static ComponentVariableProperty() { VariableRegisters <T> .Register(_ID_READ_ONLY, GetData, null, GetReadOnlyAccess); VariableRegisters <T> .Register(_ID_READ_WRITE, GetData, GetDataRef, GetReadWriteAccess); VariableRegisters <T> .Register(_ID_OPTIONAL, GetData, GetDataRef); }
static GraphVariableProperty() { var type = typeof(GraphVariableProperty <T>); VariableRegisters <T> .Register(ID, type.Getter("GetData"), null, GetComponentAccess); IEnumerable <ComponentType> GetComponentAccess(ref BlobVariable <T> variable) { return(ComponentType.ReadOnly <CurrentBehaviorTreeComponent>().Yield()); } }
static ScriptableObjectVariableProperty() { VariableRegisters <T> .Register(ID, GetData, GetDataRef); }