12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758 |
- #include "renderer/CCCustomCommand.h"
- NS_CC_BEGIN
- CustomCommand::CustomCommand()
- : func(nullptr)
- {
- _type = RenderCommand::Type::CUSTOM_COMMAND;
- }
- void CustomCommand::init(float depth, const cocos2d::Mat4 &modelViewTransform, uint32_t flags)
- {
- RenderCommand::init(depth, modelViewTransform, flags);
- }
- void CustomCommand::init(float globalOrder)
- {
- _globalOrder = globalOrder;
- }
- CustomCommand::~CustomCommand()
- {
- }
- void CustomCommand::execute()
- {
- if(func)
- {
- func();
- }
- }
- NS_CC_END
|