コード例 #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);
        }