OLD | NEW |
1 $#include "LuaCocos2dExtensions.h" | 1 $#include "LuaCocos2dExtensions.h" |
2 $#include "physics_nodes/CCPhysicsSprite.h" | 2 $#include "physics_nodes/CCPhysicsSprite.h" |
| 3 $#include "physics_nodes/CCPhysicsNode.h" |
3 $#include "tolua_fix.h" | 4 $#include "tolua_fix.h" |
4 | 5 |
5 $USING_NS_CC; | 6 $USING_NS_CC; |
6 $USING_NS_CC_EXT; | 7 $USING_NS_CC_EXT; |
7 | 8 |
8 $pfile "CCPhysicsSprite.pkg" | 9 class CCPhysicsNode : public CCNode |
| 10 { |
| 11 » b2Body* getB2Body() const; |
| 12 » void setB2Body(b2Body *pBody); |
| 13 » float getPTMRatio() const; |
| 14 » void setPTMRatio(float fPTMRatio); |
| 15 |
| 16 » static CCPhysicsNode* create(); |
| 17 }; |
| 18 |
| 19 class CCPhysicsSprite : public CCSprite |
| 20 { |
| 21 » b2Body* getB2Body() const; |
| 22 » void setB2Body(b2Body *pBody); |
| 23 » float getPTMRatio() const; |
| 24 » void setPTMRatio(float fPTMRatio); |
| 25 |
| 26 » static CCPhysicsSprite* createWithTexture(CCTexture2D *pTexture); |
| 27 » static CCPhysicsSprite* createWithTexture(CCTexture2D *pTexture, CCRect
rect); |
| 28 » static CCPhysicsSprite* createWithSpriteFrame(CCSpriteFrame *pSpriteFram
e); |
| 29 » static CCPhysicsSprite* createWithSpriteFrameName(const char *pszSpriteF
rameName); |
| 30 » static CCPhysicsSprite* create(const char *pszFileName, CCRect rect); |
| 31 » static CCPhysicsSprite* create(const char *pszFileName); |
| 32 » static CCPhysicsSprite* create(); |
| 33 }; |
OLD | NEW |