Skip to content

Instantly share code, notes, and snippets.

View Goncharuk-Nikita's full-sized avatar

Mikita Goncharuk-Nikita

  • Warsaw Poland
View GitHub Profile
using System.Collections.Concurrent;
using System.ComponentModel;
using System.Runtime.CompilerServices;
[AttributeUsage(AttributeTargets.Method)]
public sealed class NotifyPropertyChangedInvocatorAttribute : Attribute
{
public NotifyPropertyChangedInvocatorAttribute()
{
}
private void Method()
{
var wait = new Wait(this);
wait.Execute(5.0F).Done += (i) => DoSomething;
}
private IEnumerator Method()
{
yield return new Wait(this, 5.0F);
private void Method()
{
car wait = new WaitForKeyDown(this);
wait.Execute(KeyCode.Space).Done += (i) => DoSomething();
}
private IEnumerator Method()
{
yield return new WaitForKeyDown(this) { Key = KeyCode.Space };
private void Method()
{
var move = new MoveToPoint(this)
{
Actor = transform,
Target = target,
Speed = 1.0F,
Threshold = 0.05F
};
@Goncharuk-Nikita
Goncharuk-Nikita / Instruction.cs
Last active March 13, 2019 13:10
Instruction
using UnityEngine;
using System;
using IEnumerator = System.Collections.IEnumerator;
public abstract class Instruction : IEnumerator, IInstruction
{
private Instruction current;
object IEnumerator.Current => current;