简体   繁体   中英

CGRectIntersectsRect for cocos2d Android

I'm currently trying to test for collisions between two CGRects. Usually in Objective C I'd use the CGRectIntersectsRect method, but in Coso2d Android the only method available seems to be CGRect.containsRect which doesn't work as desired. Is there another way this must be done for Android?

I found intersects method in CGRect at github repo use that function to check intersect of two rect.

I also found one issue logged with the same and there is also a solution mention.

下载了包含CGRect.intersects方法的.jar文件的更新版本

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM