The Ahorn part is just a copy-paste from the vanilla entity code, with the "fast" attribute replaced with a "moveSpeed" attribute for more customization. The default value is the "slow" vanilla speed.
In the C# part, I chose to "wrap" the Controller method, since the speed is set in the middle of this routine, and it is 200 lines long. The private targetSpeed attribute is set just after a yield return 0.2f;, so this is how the wrapper knows this value might have to be changed. This limits the number of operations done with reflection.
Closes #72.
The Ahorn part is just a copy-paste from the vanilla entity code, with the "fast" attribute replaced with a "moveSpeed" attribute for more customization. The default value is the "slow" vanilla speed.
In the C# part, I chose to "wrap" the Controller method, since the speed is set in the middle of this routine, and it is 200 lines long. The private
targetSpeed
attribute is set just after ayield return 0.2f;
, so this is how the wrapper knows this value might have to be changed. This limits the number of operations done with reflection.