예제 #1
0
        static public bool checkType(IntPtr l, int p, out Vector2 v)
        {
            float x, y;

            LuaDLL.luaS_checkVector2(l, p, out x, out y);
            v = new Vector2(x, y);
            return(true);
        }
예제 #2
0
        static public bool checkType(IntPtr l, int p, out Vector2 v)
        {
            float x, y;

            if (LuaDLL.luaS_checkVector2(l, p, out x, out y) != 0)
            {
                throw new Exception(string.Format("Invalid vector2 argument at {0}", p));
            }
            v = new Vector2(x, y);
            return(true);
        }