Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想知道我们如何在 cocos2d 中找到缩放图像的宽度和高度。我尝试了以下方法来查找,但是没有用,
查找宽度:self.spriteimage.position.x * scaleFactor
position.x 不是宽度。要获得宽度,请尝试:
self.spriteimage.contentSize.width * scaleFactor;