示例#1
0
 public static AngleAttack Instance(float angle, int projectileIndex = 0)
 {
     var key = new Tuple<float, int>(angle, projectileIndex);
     AngleAttack ret;
     if (!instances.TryGetValue(key, out ret))
         ret = instances[key] = new AngleAttack(angle, projectileIndex);
     return ret;
 }
示例#2
0
        public static AngleAttack Instance(float angle, int projectileIndex = 0)
        {
            var         key = new Tuple <float, int>(angle, projectileIndex);
            AngleAttack ret;

            if (!instances.TryGetValue(key, out ret))
            {
                ret = instances[key] = new AngleAttack(angle, projectileIndex);
            }
            return(ret);
        }