public virtual float EvaluateMagnitude(ref InputBindingCompositeContext context)
 {
     return(-1);
 }
 public abstract object ReadValueAsObject(ref InputBindingCompositeContext context);
 public abstract unsafe void ReadValue(ref InputBindingCompositeContext context, void *buffer, int bufferSize);
 // Avoid having to expose internal modifier.
 internal void CallFinishSetup(ref InputBindingCompositeContext context)
 {
     FinishSetup(ref context);
 }
 /// <summary>
 /// Called after binding resolution for an <see cref="InputActionMap"/> is complete.
 /// </summary>
 /// <remarks>
 /// Some composites do not have predetermine value types. Two examples of this are
 /// <see cref="Composites.OneModifierComposite"/> and <see cref="Composites.TwoModifiersComposite"/>, which
 /// both have a <c>"binding"</c> part that can be bound to arbitrary controls. This means that the
 /// value type of these bindings can only be determined at runtime.
 ///
 /// Overriding this method allows accessing the actual controls bound to each part
 /// at runtime.
 ///
 /// <example>
 /// <code>
 /// [InputControl] public int binding;
 ///
 /// protected override void FinishSetup(ref InputBindingContext context)
 /// {
 ///     // Get all controls bound to the 'binding' part.
 ///     var controls = context.controls
 ///         .Where(x => x.part == binding)
 ///         .Select(x => x.control);
 /// }
 /// </code>
 /// </example>
 /// </remarks>
 protected virtual void FinishSetup(ref InputBindingCompositeContext context)
 {
 }
示例#6
0
 public abstract float EvaluateMagnitude(ref InputBindingCompositeContext context);