我必须使用方法:
intersector.isPointInPolygon(Array<Vector2> polygon, Vector2 point);
我应该如何定义这个数组?
ArrayList 也是如此。
我尝试过 Array<Vector2> poly
但我不知道如何将值添加到
有人可以帮我吗?
最佳答案
好的,问题解决了。
我写了Array<Vector2> poly;
而不是Array<Vector2> poly = new Array<Vector>();
并发生NullPointerException。
无论如何,谢谢大家;
关于java - Array<Vector2> 如何定义它?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33456301/