ActionInstant.xml 4.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495
  1. <Type Name="ActionInstant" FullName="Urho.Actions.ActionInstant">
  2. <TypeSignature Language="C#" Value="public class ActionInstant : Urho.Actions.FiniteTimeAction" />
  3. <TypeSignature Language="ILAsm" Value=".class public auto ansi beforefieldinit ActionInstant extends Urho.Actions.FiniteTimeAction" />
  4. <AssemblyInfo>
  5. <AssemblyName>Urho</AssemblyName>
  6. <AssemblyVersion>1.0.0.0</AssemblyVersion>
  7. </AssemblyInfo>
  8. <Base>
  9. <BaseTypeName>Urho.Actions.FiniteTimeAction</BaseTypeName>
  10. </Base>
  11. <Interfaces />
  12. <Docs>
  13. <summary>Base class for actions that have an immediate effect.</summary>
  14. <remarks>
  15. <para>This is a base class that will invoke the Update method in the <see cref="T:Urho.Actions.ActionState" /> with the value of one as soon as it is executed.   </para>
  16. <para>The following example shows how you would implement an instant:</para>
  17. <code lang="C#"><![CDATA[public class MyInstant : ActionInstant
  18. {
  19. public MyInstant () {}
  20. protected internal override ActionState StartAction(Node target)
  21. {
  22. return new MyInstantState (this, target);
  23. }
  24. public override FiniteTimeAction Reverse ()
  25. {
  26. return (new MyInstantReverse ());
  27. }
  28. }
  29. public class MyInstantState : ActionInstantState
  30. {
  31. public MyInstantState (MyInstant action, Node target)
  32. : base (action, target) {}
  33. public override void Update (float time)]]></code>
  34. <para></para>
  35. <para>In this imaginary action, you there would be an inverse operation called “MyInstantReverse”, which is used to implement the Reverse method in this case.</para>
  36. <para>The “PerformOp” call is the one that does the change, and it will be invoked only once.</para>
  37. </remarks>
  38. </Docs>
  39. <Members>
  40. <Member MemberName=".ctor">
  41. <MemberSignature Language="C#" Value="protected ActionInstant ();" />
  42. <MemberSignature Language="ILAsm" Value=".method familyhidebysig specialname rtspecialname instance void .ctor() cil managed" />
  43. <MemberType>Constructor</MemberType>
  44. <AssemblyInfo>
  45. <AssemblyVersion>1.0.0.0</AssemblyVersion>
  46. </AssemblyInfo>
  47. <Parameters />
  48. <Docs>
  49. <summary>Creates a new instance of the instant action</summary>
  50. <remarks>To be added.</remarks>
  51. </Docs>
  52. </Member>
  53. <Member MemberName="Reverse">
  54. <MemberSignature Language="C#" Value="public override Urho.Actions.FiniteTimeAction Reverse ();" />
  55. <MemberSignature Language="ILAsm" Value=".method public hidebysig virtual instance class Urho.Actions.FiniteTimeAction Reverse() cil managed" />
  56. <MemberType>Method</MemberType>
  57. <AssemblyInfo>
  58. <AssemblyVersion>1.0.0.0</AssemblyVersion>
  59. </AssemblyInfo>
  60. <ReturnValue>
  61. <ReturnType>Urho.Actions.FiniteTimeAction</ReturnType>
  62. </ReturnValue>
  63. <Parameters />
  64. <Docs>
  65. <summary>This method must be overwritten and return the reverse action of your custom action.</summary>
  66. <returns>To be added.</returns>
  67. <remarks>To be added.</remarks>
  68. </Docs>
  69. </Member>
  70. <Member MemberName="StartAction">
  71. <MemberSignature Language="C#" Value="protected override Urho.Actions.ActionState StartAction (Urho.Node target);" />
  72. <MemberSignature Language="ILAsm" Value=".method familyorassemblyhidebysig virtual instance class Urho.Actions.ActionState StartAction(class Urho.Node target) cil managed" />
  73. <MemberType>Method</MemberType>
  74. <AssemblyInfo>
  75. <AssemblyVersion>1.0.0.0</AssemblyVersion>
  76. </AssemblyInfo>
  77. <ReturnValue>
  78. <ReturnType>Urho.Actions.ActionState</ReturnType>
  79. </ReturnValue>
  80. <Parameters>
  81. <Parameter Name="target" Type="Urho.Node" />
  82. </Parameters>
  83. <Docs>
  84. <param name="target">
  85. <para>The new <see cref="T:Urho.Actions.ActionState" /> that encapsulates the state and provides the implementation to perform your action.</para>
  86. </param>
  87. <summary>Creates the action state for this action, called on demand from the framework to start executing the recipe.</summary>
  88. <returns>To be added.</returns>
  89. <remarks>New action that will perform the inverse of this action</remarks>
  90. </Docs>
  91. </Member>
  92. </Members>
  93. </Type>