string_view for tests

This commit is contained in:
halx99 2021-12-28 15:58:56 +08:00
parent 8e8affab5e
commit 367ae2a23c
51 changed files with 1738 additions and 97 deletions

View File

@ -142,11 +142,12 @@ void TestList::deatchTableView() {
CC_SAFE_RELEASE_NULL(_tableView);
}
void TestList::addTest(const std::string& testName, std::function<TestBase*()> callback)
void TestList::addTest(std::string_view testName, std::function<TestBase*()> callback)
{
if (!testName.empty())
{
_childTestNames.emplace_back(StringUtils::format("%d", static_cast<int>(_childTestNames.size() + 1)) + ":" + testName);
_childTestNames.emplace_back(
StringUtils::format("%d:%s", static_cast<int>(_childTestNames.size() + 1), testName.data()));
_testCallbacks.emplace_back(callback);
}
}
@ -282,7 +283,7 @@ ssize_t TestList::numberOfCellsInTableView(TableView *table)
}
//TestSuite
void TestSuite::addTestCase(const std::string& testName, std::function<Scene*()> callback)
void TestSuite::addTestCase(std::string_view testName, std::function<Scene*()> callback)
{
if (!testName.empty() && callback)
{

View File

@ -91,7 +91,7 @@ public:
/**
* You should NEVER call this method, unless you know what you are doing.
*/
void setTestCaseName(const std::string& name) { _testCaseName = name; }
void setTestCaseName(std::string_view name) { _testCaseName = name; }
std::string getTestCaseName() const { return _testCaseName; }
const cocos2d::Label* getSubtitleLable() const { return _subtitleLabel; }
@ -143,7 +143,7 @@ public:
void setTestParent(TestBase* parent) { _parentTest = parent; }
TestBase* getTestParent() { return _parentTest; }
void setTestName(const std::string& testName) { _testName = testName; }
void setTestName(std::string_view testName) { _testName = testName; }
std::string getTestName() const { return _testName; }
protected:
TestBase();
@ -163,7 +163,7 @@ class TestController;
class TestSuite : public TestBase
{
public:
void addTestCase(const std::string& testName, std::function<cocos2d::Scene*()> callback);
void addTestCase(std::string_view testName, std::function<cocos2d::Scene*()> callback);
virtual void restartCurrTest();
virtual void enterNextTest();
@ -190,7 +190,7 @@ public:
TestList();
~TestList();
void addTest(const std::string& testName, std::function<TestBase*()> callback);
void addTest(std::string_view testName, std::function<TestBase*()> callback);
virtual void runThisTest() override;

View File

@ -102,9 +102,9 @@ void Bug14327Layer::editBoxEditingDidEndWithAction(cocos2d::ui::EditBox* editBox
log("editBox %p DidEnd !", editBox);
}
void Bug14327Layer::editBoxTextChanged(cocos2d::ui::EditBox* editBox, const std::string& text)
void Bug14327Layer::editBoxTextChanged(cocos2d::ui::EditBox* editBox, std::string_view text)
{
log("editBox %p TextChanged, text: %s ", editBox, text.c_str());
log("editBox %p TextChanged, text: %s ", editBox, text.data());
}
void Bug14327Layer::editBoxReturn(ui::EditBox* editBox)

View File

@ -42,7 +42,7 @@ public:
virtual void editBoxEditingDidBegin(cocos2d::ui::EditBox* editBox) override;
virtual void editBoxEditingDidEndWithAction(cocos2d::ui::EditBox* editBox, cocos2d::ui::EditBoxDelegate::EditBoxEndAction EditBoxEndAction) override;
virtual void editBoxTextChanged(cocos2d::ui::EditBox* editBox, const std::string& text) override;
virtual void editBoxTextChanged(cocos2d::ui::EditBox* editBox, std::string_view text) override;
virtual void editBoxReturn(cocos2d::ui::EditBox* editBox) override;
protected:

View File

@ -74,10 +74,10 @@ ConsoleCustomCommand::ConsoleCustomCommand()
{
_console = Director::getInstance()->getConsole();
static Console::Command commands[] = {
{"hello", "This is just a user generated command", [](int fd, const std::string& args) {
{"hello", "This is just a user generated command", [](int fd, std::string_view args) {
const char msg[] = "how are you?\nArguments passed: ";
send(fd, msg, sizeof(msg),0);
send(fd, args.c_str(), args.length(),0);
send(fd, args.data(), args.length(),0);
send(fd, "\n",1,0);
}},
};

View File

@ -576,7 +576,7 @@ public:
};
NS_CC_END
static void saveAsBinaryText(const std::string& filename, const std::vector<char>& binary){
static void saveAsBinaryText(std::string_view filename, const std::vector<char>& binary){
auto fs = FileUtils::getInstance();
std::string text(binary.begin(), binary.end());
fs->writeStringToFile(text, filename);
@ -965,10 +965,10 @@ void TestUnicodePath::onEnter()
std::string filename = "测试文件.test";
std::string act;
auto getMsg = [&act](bool b, const std::string& path)-> std::string
auto getMsg = [&act](bool b, std::string_view path)-> std::string
{
char msg[512];
snprintf((char *)msg, 512, "%s for %s path: \"%s\"", b ? "success" : "failed", act.c_str(), path.c_str());
snprintf((char *)msg, 512, "%s for %s path: \"%s\"", b ? "success" : "failed", act.c_str(), path.data());
return std::string(msg);
};
@ -1097,10 +1097,10 @@ void TestIsDirectoryExistAsync::onEnter()
int x = s.width/2, y = s.height/3;
std::string dir;
auto getMsg = [](bool b, const std::string& dir)-> std::string
auto getMsg = [](bool b, std::string_view dir)-> std::string
{
char msg[512];
snprintf((char *)msg, 512, "%s for dir: \"%s\"", b ? "success" : "failed", dir.c_str());
snprintf((char *)msg, 512, "%s for dir: \"%s\"", b ? "success" : "failed", dir.data());
return std::string(msg);
};
@ -1220,9 +1220,11 @@ void TestWriteStringAsync::onEnter()
CCASSERT(success, "Write String to data failed");
writeResult->setString("write success:" + writeDataStr);
FileUtils::getInstance()->getStringFromFile(fullPath, [=](const std::string& value) {
FileUtils::getInstance()->getStringFromFile(fullPath, [=](std::string_view value) {
CCASSERT(!value.empty(), "String should be readable");
readResult->setString("read success: " + value);
std::string strVal = "read success: ";
readResult->setString(strVal.append(value));
});
});
}

View File

@ -80,7 +80,7 @@ FontTests::FontTests()
ADD_TEST_CASE(FontReplacementTest);
}
void FontTest::showFont(const std::string& fontFile)
void FontTest::showFont(std::string_view fontFile)
{
auto s = Director::getInstance()->getWinSize();

View File

@ -33,7 +33,7 @@ DEFINE_TEST_SUITE(FontTests);
class FontTest : public TestCase
{
public:
static FontTest* create(const std::string& fontFile)
static FontTest* create(std::string_view fontFile)
{
auto ret = new FontTest;
if (ret->init())
@ -50,7 +50,7 @@ public:
return ret;
}
void showFont(const std::string& fontFile);
void showFont(std::string_view fontFile);
virtual std::string title() const override;
};

View File

@ -184,13 +184,13 @@ void Material_2DEffects::updateCCTimeUniforms(float)
*/
class EffectAutoBindingResolver : public backend::ProgramState::AutoBindingResolver
{
virtual bool resolveAutoBinding(backend::ProgramState* programState,/* Node* node,*/ const std::string& uniform, const std::string& autoBinding) override;
virtual bool resolveAutoBinding(backend::ProgramState* programState,/* Node* node,*/ std::string_view uniform, std::string_view autoBinding) override;
void callbackRadius(backend::ProgramState* programState, backend::UniformLocation uniform);
void callbackColor(backend::ProgramState* programState, backend::UniformLocation uniform);
};
bool EffectAutoBindingResolver::resolveAutoBinding(backend::ProgramState* programState, /*Node* node,*/ const std::string& uniform, const std::string& autoBinding)
bool EffectAutoBindingResolver::resolveAutoBinding(backend::ProgramState* programState, /*Node* node,*/ std::string_view uniform, std::string_view autoBinding)
{
if (autoBinding.compare("DYNAMIC_RADIUS")==0)
{

View File

@ -80,7 +80,7 @@ MenuLayerMainMenu::MenuLayerMainMenu()
auto item3 = MenuItemLabel::create(labelAtlas, CC_CALLBACK_1(MenuLayerMainMenu::menuCallbackDisabled, this) );
item3->setDisabledColor( Color3B(32,32,64) );
item3->setColor( Color3B(200,200,255) );
CCLOG("test MenuItem Label getString: %s", item3->getString().c_str());
CCLOG("test MenuItem Label getString: %s", item3->getString().data());
// Font Item
auto item4 = MenuItemFont::create("I toggle enable items", [&](Ref *sender) {
_disabledItem->setEnabled(! _disabledItem->isEnabled() );

View File

@ -298,14 +298,14 @@ struct DownloaderTest : public TestCase
downloader->onTaskError = [this](const cocos2d::network::DownloadTask& task,
int errorCode,
int errorCodeInternal,
const std::string& errorStr)
std::string_view errorStr)
{
log("Failed to download : %s, identifier(%s) error code(%d), internal error code(%d) desc(%s)"
, task.requestURL.c_str()
, task.identifier.c_str()
, errorCode
, errorCodeInternal
, errorStr.c_str());
, errorStr.data());
auto view = this->getChildByName(task.identifier);
auto status = (Label*)view->getChildByTag(TAG_STATUS);
status->setString(errorStr.length() ? errorStr : "Download failed.");
@ -350,13 +350,13 @@ struct DownloaderMultiTask : public TestCase
log("downloader task success: %s", task.identifier.c_str());
});
downloader->onTaskError = ([] (const network::DownloadTask& task, int errorCode, int errorCodeInternal, const std::string& errorStr) {
downloader->onTaskError = ([] (const network::DownloadTask& task, int errorCode, int errorCodeInternal, std::string_view errorStr) {
log("downloader task failed : %s, identifier(%s) error code(%d), internal error code(%d) desc(%s)"
, task.requestURL.c_str()
, task.identifier.c_str()
, errorCode
, errorCodeInternal
, errorStr.c_str());
, errorStr.data());
});
}
};

View File

@ -47,7 +47,7 @@ HttpClientTest::HttpClientTest()
auto cafile = FileUtils::getInstance()->fullPathForFilename("cacert.pem");
httpClient->setSSLVerification(cafile);
httpClient->enableCookies(nullptr);
CCLOG("The http cookie will store to: %s", httpClient->getCookieFilename().c_str());
CCLOG("The http cookie will store to: %s", httpClient->getCookieFilename().data());
const int MARGIN = 40;
const int SPACE = 35;

View File

@ -64,7 +64,7 @@ namespace {
{
public:
static TextButton *create(const std::string& text, const std::function<void(TextButton*)> &onTriggered)
static TextButton *create(std::string_view text, const std::function<void(TextButton*)> &onTriggered)
{
auto ret = new TextButton();
@ -246,7 +246,7 @@ bool AudioControlTest::init()
_isStopped = false;
button->setEnabled(false);
AudioEngine::setFinishCallback(_audioID, [&](int id, const std::string& filePath){
AudioEngine::setFinishCallback(_audioID, [&](int id, std::string_view filePath){
log("_audioID(%d), _isStopped:(%d), played over!!!", _audioID, _isStopped);
_playOverLabel->setVisible(true);
@ -527,7 +527,7 @@ bool PlaySimultaneouslyTest::init()
if(audioId != AudioEngine::INVALID_AUDIO_ID){
_playingcount += 1;
AudioEngine::setFinishCallback(audioId, [&](int id, const std::string& filePath){
AudioEngine::setFinishCallback(audioId, [&](int id, std::string_view filePath){
_playingcount -= 1;
if(_playingcount <= 0){
((TextButton*)_playItem)->setEnabled(true);
@ -591,7 +591,7 @@ bool AudioProfileTest::init()
sprintf(show,"audio count:%d",_audioCount);
_showLabel->setString(show);
AudioEngine::setFinishCallback(id, [&](int id, const std::string& filePath){
AudioEngine::setFinishCallback(id, [&](int id, std::string_view filePath){
_audioCount -= 1;
char show[30];
sprintf(show,"audio count:%d",_audioCount);
@ -1155,22 +1155,22 @@ std::string AudioPlayInFinishedCB::subtitle() const
return "After played over, click again, should also hear 3 audios";
}
void AudioPlayInFinishedCB::doPlay(const std::string& filename)
void AudioPlayInFinishedCB::doPlay(std::string_view filename)
{
int playID = AudioEngine::play2d(filename, false, 1);
AudioEngine::setFinishCallback(playID, [this](int finishID, const std::string& file){
AudioEngine::setFinishCallback(playID, [this](int finishID, std::string_view file){
_playList.pop_front();
log("finish music %s",file.c_str());
log("finish music %s",file.data());
if (!_playList.empty()) {
const std::string& name = _playList.front();
std::string_view name = _playList.front();
doPlay(name);
}
});
}
void AudioPlayInFinishedCB::playMusic(const std::string& filename)
void AudioPlayInFinishedCB::playMusic(std::string_view filename)
{
_playList.push_back(filename);
_playList.push_back(std::string{filename});
if (_playList.size() == 1) {
doPlay(filename);
}
@ -1182,7 +1182,7 @@ void AudioUncacheInFinishedCB::onEnter()
AudioEngineTestDemo::onEnter();
int id = AudioEngine::play2d("background.mp3");
AudioEngine::setFinishCallback(id, [](int i, const std::string& str){
AudioEngine::setFinishCallback(id, [](int i, std::string_view str){
AudioEngine::uncacheAll();
});
}

View File

@ -322,8 +322,8 @@ public:
virtual std::string subtitle() const override;
private:
void doPlay(const std::string& filename);
void playMusic(const std::string& filename);
void doPlay(std::string_view filename);
void playMusic(std::string_view filename);
std::list<std::string> _playList;
};

View File

@ -203,12 +203,12 @@ class SpriteInGroupCommand : public Sprite
protected:
GroupCommand _spriteWrapperCommand;
public:
static SpriteInGroupCommand* create(const std::string& filename);
static SpriteInGroupCommand* create(std::string_view filename);
virtual void draw(Renderer *renderer, const Mat4 &transform, uint32_t flags) override;
};
SpriteInGroupCommand* SpriteInGroupCommand::create(const std::string &filename)
SpriteInGroupCommand* SpriteInGroupCommand::create(std::string_view filename)
{
SpriteInGroupCommand* sprite = new SpriteInGroupCommand();
sprite->initWithFile(filename);
@ -682,7 +682,7 @@ void CaptureScreenTest::onCaptured(Ref*)
utils::captureScreen(CC_CALLBACK_2(CaptureScreenTest::afterCaptured, this), _filename);
}
void CaptureScreenTest::afterCaptured(bool succeed, const std::string& outputFile)
void CaptureScreenTest::afterCaptured(bool succeed, std::string_view outputFile)
{
if (succeed)
{

View File

@ -174,7 +174,7 @@ protected:
~CaptureScreenTest();
void onCaptured(cocos2d::Ref*);
void afterCaptured(bool succeed, const std::string& outputFile);
void afterCaptured(bool succeed, std::string_view outputFile);
std::string _filename;
};

View File

@ -1280,7 +1280,7 @@ void NodeNameTest::test(float dt)
{
sprintf(name, "node%d", i);
auto node = parent->getChildByName(name);
log("find child: %s", node->getName().c_str());
log("find child: %s", node->getName().data());
}
// enumerateChildren()

View File

@ -185,7 +185,7 @@ public:
class DemoParticleFromFile : public ParticleDemo
{
public:
static DemoParticleFromFile* create(const std::string& file)
static DemoParticleFromFile* create(std::string_view file)
{
auto ret = new DemoParticleFromFile;
if (ret->init())

View File

@ -100,7 +100,7 @@ void RenderTextureSave::saveImageWithPremultipliedAlpha(cocos2d::Ref* sender)
char png[20];
sprintf(png, "image-pma-%d.png", counter);
auto callback = [&](RenderTexture* rt, const std::string& path)
auto callback = [&](RenderTexture* rt, std::string_view path)
{
auto sprite = Sprite::create(path);
addChild(sprite);
@ -126,7 +126,7 @@ void RenderTextureSave::saveImageWithNonPremultipliedAlpha(cocos2d::Ref *sender)
char png[20];
sprintf(png, "image-no-pma-%d.png", counter);
auto callback = [&](RenderTexture* rt, const std::string& path)
auto callback = [&](RenderTexture* rt, std::string_view path)
{
auto sprite = Sprite::create(path);
addChild(sprite);
@ -790,7 +790,7 @@ Issue16113Test::Issue16113Test()
text->setPosition(winSize.width / 2,winSize.height/2);
text->Node::visit();
target->end();
auto callback = [&](RenderTexture* rt, const std::string& path){
auto callback = [&](RenderTexture* rt, std::string_view path){
rt->release();
};
target->retain();

View File

@ -48,7 +48,7 @@ public:
RenderState::StateBlock::invalidate(cocos2d::RenderState::StateBlock::RS_ALL_ONES);
}
static SkeletonAnimationCullingFix* createWithFile (const std::string& skeletonDataFile, const std::string& atlasFile, float scale = 1)
static SkeletonAnimationCullingFix* createWithFile (std::string_view skeletonDataFile, std::string_view atlasFile, float scale = 1)
{
SkeletonAnimationCullingFix* node = new SkeletonAnimationCullingFix();
spAtlas* atlas = spAtlas_createFromFile(atlasFile.c_str(), 0);
@ -694,7 +694,7 @@ void Scene3DTestScene::createDetailDlg()
Director::getInstance()->getTextureCache()->removeTextureForKey(_snapshotFile);
_osdScene->removeChildByTag(SNAPSHOT_TAG);
_snapshotFile = "CaptureScreenTest.png";
utils::captureScreen([this](bool succeed, const std::string& outputFile)
utils::captureScreen([this](bool succeed, std::string_view outputFile)
{
if (!succeed)
{

View File

@ -554,7 +554,7 @@ void SchedulerSchedulesAndRemove::scheduleAndUnschedule(float /*dt*/)
// TestNode
//
//------------------------------------------------------------------
void TestNode::initWithString(const std::string& str, int priority)
void TestNode::initWithString(std::string_view str, int priority)
{
_string = str;
scheduleUpdateWithPriority(priority);

View File

@ -226,7 +226,7 @@ public:
~TestNode();
void initWithString(const std::string& str, int priority);
void initWithString(std::string_view str, int priority);
virtual void update(float dt) override;
private:
std::string _string;

View File

@ -82,7 +82,7 @@ ShaderNode::~ShaderNode()
{
}
ShaderNode* ShaderNode::shaderNodeWithVertex(const std::string &vert, const std::string& frag)
ShaderNode* ShaderNode::shaderNodeWithVertex(std::string_view vert, std::string_view frag)
{
auto node = new ShaderNode();
node->initWithVertex(vert, frag);
@ -91,7 +91,7 @@ ShaderNode* ShaderNode::shaderNodeWithVertex(const std::string &vert, const std:
return node;
}
bool ShaderNode::initWithVertex(const std::string &vert, const std::string &frag)
bool ShaderNode::initWithVertex(std::string_view vert, const std::string& frag)
{
_vertFileName = vert;
_fragFileName = frag;

View File

@ -76,7 +76,7 @@ class Effect;
class EffectSprite : public Sprite
{
public:
static EffectSprite *create(const std::string& filename) {
static EffectSprite *create(std::string_view filename) {
auto ret = new EffectSprite;
if(ret->initWithFile(filename)) {
ret->autorelease();
@ -392,7 +392,7 @@ class EffectNormalMapped : public Effect
{
public:
CREATE_FUNC(EffectNormalMapped);
static EffectNormalMapped* create(const std::string&normalMapFileName)
static EffectNormalMapped* create(std::string_viewnormalMapFileName)
{
EffectNormalMapped *normalMappedSprite = new EffectNormalMapped();
if (normalMappedSprite->init() && normalMappedSprite->initNormalMap(normalMapFileName))
@ -410,7 +410,7 @@ public:
float getKBump()const{return _kBump;}
protected:
bool init();
bool initNormalMap(const std::string&normalMapFileName);
bool initNormalMap(std::string_viewnormalMapFileName);
virtual void setTarget(EffectSprite* sprite) override;
EffectSprite* _sprite;
Vec3 _lightPos;
@ -424,7 +424,7 @@ bool EffectNormalMapped::init()
_kBump = 2;
return true;
}
bool EffectNormalMapped::initNormalMap(const std::string& normalMapFileName)
bool EffectNormalMapped::initNormalMap(std::string_view normalMapFileName)
{
auto normalMapTexture = Director::getInstance()->getTextureCache()->addImage(normalMapFileName);
SET_TEXTURE(_programState, "u_normalMap", 1, normalMapTexture->getBackendTexture());

View File

@ -148,7 +148,7 @@ public:
uint32_t getFormat() override { return FORMAT; }
void load(const std::string& filePath, SpriteFrameCache& cache) override
void load(std::string_view filePath, SpriteFrameCache& cache) override
{
CCASSERT(!filePath.empty(), "atlas filename should not be nullptr");
@ -199,7 +199,7 @@ public:
addSpriteFramesWithJson(jDoc, texturePath, filePath, cache);
}
void load(const std::string& filePath, Texture2D* texture, SpriteFrameCache& cache) override
void load(std::string_view filePath, Texture2D* texture, SpriteFrameCache& cache) override
{
const auto fullPath = FileUtils::getInstance()->fullPathForFilename(filePath);
rapidjson::Document jDoc;
@ -209,7 +209,7 @@ public:
addSpriteFramesWithJson(jDoc, texture, filePath, cache);
}
void load(const std::string& filePath, const std::string& textureFileName, SpriteFrameCache& cache) override
void load(std::string_view filePath, std::string_view textureFileName, SpriteFrameCache& cache) override
{
CCASSERT(!textureFileName.empty(), "texture name should not be null");
const auto fullPath = FileUtils::getInstance()->fullPathForFilename(filePath);
@ -232,7 +232,7 @@ public:
addSpriteFramesWithJson(jDoc, texture, "by#addSpriteFramesWithFileContent()", cache);
}
void reload(const std::string& filePath, SpriteFrameCache& cache) override
void reload(std::string_view filePath, SpriteFrameCache& cache) override
{
const auto fullPath = FileUtils::getInstance()->fullPathForFilename(filePath);
rapidjson::Document doc;
@ -285,7 +285,7 @@ public:
}
protected:
void addSpriteFramesWithJson(const rapidjson::Document& doc, const std::string& texturePath, const std::string& atlasPath, SpriteFrameCache& cache)
void addSpriteFramesWithJson(const rapidjson::Document& doc, std::string_view texturePath, std::string_view atlasPath, SpriteFrameCache& cache)
{
std::string pixelFormatName;
auto&& metaItr = doc.FindMember("meta");
@ -338,7 +338,7 @@ protected:
}
}
void addSpriteFramesWithJson(const rapidjson::Document& doc, Texture2D* texture, const std::string& atlasPath, SpriteFrameCache& cache)
void addSpriteFramesWithJson(const rapidjson::Document& doc, Texture2D* texture, std::string_view atlasPath, SpriteFrameCache& cache)
{
auto&& framesItr = doc.FindMember("frames");
if (framesItr == doc.MemberEnd())
@ -409,7 +409,7 @@ protected:
CC_SAFE_DELETE(image);
}
void reloadSpriteFramesWithDictionary(const rapidjson::Document& doc, Texture2D* texture, const std::string& atlasPath, SpriteFrameCache& cache)
void reloadSpriteFramesWithDictionary(const rapidjson::Document& doc, Texture2D* texture, std::string_view atlasPath, SpriteFrameCache& cache)
{
auto&& framesItr = doc.FindMember("frames");
if (framesItr == doc.MemberEnd())
@ -484,7 +484,7 @@ SpriteFrameCacheJsonAtlasTest::~SpriteFrameCacheJsonAtlasTest()
cache->deregisterSpriteSheetLoader(GenericJsonArraySpriteSheetLoader::FORMAT);
}
void SpriteFrameCacheJsonAtlasTest::loadSpriteFrames(const std::string& file, cocos2d::backend::PixelFormat expectedFormat)
void SpriteFrameCacheJsonAtlasTest::loadSpriteFrames(std::string_view file, cocos2d::backend::PixelFormat expectedFormat)
{
SpriteFrameCache::getInstance()->addSpriteFramesWithFile(file, GenericJsonArraySpriteSheetLoader::FORMAT);
SpriteFrame* spriteFrame = SpriteFrameCache::getInstance()->getSpriteFrameByName("sprite_frames_test/grossini.png");

View File

@ -91,7 +91,7 @@ public:
~SpriteFrameCacheJsonAtlasTest() override;
private:
void loadSpriteFrames(const std::string& file, cocos2d::backend::PixelFormat expectedFormat);
void loadSpriteFrames(std::string_view file, cocos2d::backend::PixelFormat expectedFormat);
cocos2d::Label* infoLabel;
};

View File

@ -78,7 +78,7 @@ class SpritePolygonTestSlider : public SpritePolygonTestCase
protected:
cocos2d::Label *_epsilonLabel;
int _tagIndex;
cocos2d::Sprite* makeSprite(const std::string& filename, const cocos2d::Vec2& pos);
cocos2d::Sprite* makeSprite(std::string_view filename, const cocos2d::Vec2& pos);
virtual bool init() override;
void initSliders();
virtual void initSprites(){};

View File

@ -3429,7 +3429,7 @@ class MySprite1 : public Sprite
public:
CREATE_FUNC(MySprite1);
MySprite1() {}
static MySprite1* createWithSpriteFrameName(const std::string& spriteFrameName)
static MySprite1* createWithSpriteFrameName(std::string_view spriteFrameName)
{
auto sprite = MySprite1::create();
sprite->setSpriteFrame(spriteFrameName);
@ -3442,7 +3442,7 @@ class MySprite2 : public Sprite
public:
CREATE_FUNC(MySprite2);
MySprite2() {}
static MySprite2* create(const std::string& name)
static MySprite2* create(std::string_view name)
{
auto sprite = MySprite2::create();
sprite ->setTexture(name);

View File

@ -257,7 +257,7 @@ TransitionsTests::TransitionsTests()
}
}
TestLayer1* TestLayer1::create(const std::string& transitionName)
TestLayer1* TestLayer1::create(std::string_view transitionName)
{
auto layer = new TestLayer1(transitionName);
if (layer->init())
@ -273,7 +273,7 @@ TestLayer1* TestLayer1::create(const std::string& transitionName)
return layer;
}
TestLayer1::TestLayer1(const std::string& transitionName)
TestLayer1::TestLayer1(std::string_view transitionName)
{
float x,y;
@ -333,7 +333,7 @@ void TestLayer1::onExit()
log("Scene 1 onExit");
}
TestLayer2* TestLayer2::create(const std::string& transitionName)
TestLayer2* TestLayer2::create(std::string_view transitionName)
{
auto layer = new TestLayer2(transitionName);
if (layer->init())
@ -349,7 +349,7 @@ TestLayer2* TestLayer2::create(const std::string& transitionName)
return layer;
}
TestLayer2::TestLayer2(const std::string& transitionName)
TestLayer2::TestLayer2(std::string_view transitionName)
{
float x,y;

View File

@ -41,9 +41,9 @@ public:
class TestLayer1 : public cocos2d::Layer
{
public:
static TestLayer1* create(const std::string& transitionName);
static TestLayer1* create(std::string_view transitionName);
TestLayer1(const std::string& transitionName);
TestLayer1(std::string_view transitionName);
~TestLayer1();
void step(float dt);
@ -57,9 +57,9 @@ public:
class TestLayer2 : public cocos2d::Layer
{
public:
static TestLayer2* create(const std::string& transitionName);
static TestLayer2* create(std::string_view transitionName);
TestLayer2(const std::string& transitionName);
TestLayer2(std::string_view transitionName);
~TestLayer2();
void step(float dt);

View File

@ -147,10 +147,10 @@ void UIEditBoxTest::editBoxEditingDidEndWithAction(cocos2d::ui::EditBox* editBox
log("editBox %p DidEnd with action %d!", editBox, action);
}
void UIEditBoxTest::editBoxTextChanged(cocos2d::ui::EditBox* editBox, const std::string& text)
void UIEditBoxTest::editBoxTextChanged(cocos2d::ui::EditBox* editBox, std::string_view text)
{
log("editBox %p TextChanged, text: %s ", editBox, text.c_str());
editBox->setText(text.c_str());
log("editBox %p TextChanged, text: %s ", editBox, text.data());
editBox->setText(text.data());
}
void UIEditBoxTest::editBoxReturn(ui::EditBox* editBox)
@ -274,9 +274,9 @@ void UIEditBoxTestToggleVisibility::editBoxEditingDidBegin(cocos2d::ui::EditBox*
log("editBox %p DidBegin !", editBox);
}
void UIEditBoxTestToggleVisibility::editBoxTextChanged(cocos2d::ui::EditBox* editBox, const std::string& text)
void UIEditBoxTestToggleVisibility::editBoxTextChanged(cocos2d::ui::EditBox* editBox, std::string_view text)
{
log("editBox %p TextChanged, text: %s ", editBox, text.c_str());
log("editBox %p TextChanged, text: %s ", editBox, text.data());
}
void UIEditBoxTestToggleVisibility::editBoxReturn(ui::EditBox* editBox)
@ -309,17 +309,17 @@ bool UIEditBoxTestTextHorizontalAlignment::init() {
const auto visibleSize = glview->getVisibleSize();
const auto editBoxSize = Size(visibleSize.width - 100, visibleSize.height * 0.1f);
const auto createEditBox = [this, editBoxSize, visibleOrigin, visibleSize](const std::string& text,
const auto createEditBox = [this, editBoxSize, visibleOrigin, visibleSize](std::string_view text,
const TextHAlignment alignment,
const int position_y) {
ui::EditBox* editbox = ui::EditBox::create(editBoxSize + Size(0,40), ui::Scale9Sprite::create("extensions/green_edit.png"));
editbox->setPosition(Vec2(visibleOrigin.x+visibleSize.width/2-50, (float)position_y));
editbox->setFontColor(Color3B::RED);
editbox->setPlaceHolder(text.c_str());
editbox->setPlaceHolder(text.data());
editbox->setPlaceholderFontColor(Color3B::WHITE);
editbox->setPlaceholderFontSize((int)editBoxSize.height/2);
editbox->setFontSize((int)editBoxSize.height/2);
editbox->setText(text.c_str());
editbox->setText(text.data());
editbox->setTextHorizontalAlignment(alignment);
editbox->setReturnType(ui::EditBox::KeyboardReturnType::DONE);
addChild(editbox);

View File

@ -39,7 +39,7 @@ public:
virtual void editBoxEditingDidBegin(cocos2d::ui::EditBox* editBox)override;
virtual void editBoxEditingDidEndWithAction(cocos2d::ui::EditBox* editBox, cocos2d::ui::EditBoxDelegate::EditBoxEndAction action)override;
virtual void editBoxTextChanged(cocos2d::ui::EditBox* editBox, const std::string& text)override;
virtual void editBoxTextChanged(cocos2d::ui::EditBox* editBox, std::string_view text)override;
virtual void editBoxReturn(cocos2d::ui::EditBox* editBox)override;
@ -59,7 +59,7 @@ public:
virtual bool init() override;
virtual void editBoxEditingDidBegin(cocos2d::ui::EditBox* editBox)override;
virtual void editBoxTextChanged(cocos2d::ui::EditBox* editBox, const std::string& text)override;
virtual void editBoxTextChanged(cocos2d::ui::EditBox* editBox, std::string_view text)override;
virtual void editBoxReturn(cocos2d::ui::EditBox* editBox)override;

View File

@ -292,7 +292,7 @@ void UIRadioButtonTwoGroupsTest::clearRadioButtonGroup(Ref* sender)
}
}
void UIRadioButtonTwoGroupsTest::addLog(const std::string& log)
void UIRadioButtonTwoGroupsTest::addLog(std::string_view log)
{
std::string existingLog = _logConsole->getString();
if(!existingLog.empty())

View File

@ -66,7 +66,7 @@ public:
protected:
void addLog(const std::string& log);
void addLog(std::string_view log);
cocos2d::ui::RadioButtonGroup* _radioButtonGroups[2];
cocos2d::ui::Text* _groupEventLabel;

View File

@ -1720,7 +1720,7 @@ bool UIRichTextXMLExtend::init()
// RichText
_richText = RichText::createWithXML("<span>CloseNormal-tag:<br /><CloseNormal /><br /><br />CloseSelected-tag:<br /><CloseSelected></CloseSelected></span>",
defaults,
[](const std::string& url) {
[](std::string_view url) {
Application::getInstance()->openURL(url);
});
_richText->ignoreContentAdaptWithSize(false);

View File

@ -41,7 +41,7 @@ namespace {
{
public:
static TextButton *create(const std::string& text, const std::function<void(TextButton*)> &onTriggered)
static TextButton *create(std::string_view text, const std::function<void(TextButton*)> &onTriggered)
{
auto ret = new TextButton();

View File

@ -41,7 +41,7 @@ std::string ZipTest::title() const {
}
static void unzipTest(Label *label, const std::string &originFile, const std::string &tmpName, const std::string &zipFile, const std::string& password = "")
static void unzipTest(Label *label, const std::string &originFile, const std::string &tmpName, const std::string &zipFile, std::string_view password = "")
{
auto fu = FileUtils::getInstance();

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,860 @@
11105.png
size: 1409,1409
format: RGBA8888
filter: Linear,Linear
repeat: none
a/zhuj_00001
rotate: true
xy: 384, 206
size: 71, 76
orig: 960, 540
offset: 527, 321
index: -1
a/zhuj_00002
rotate: false
xy: 197, 566
size: 136, 281
orig: 960, 540
offset: 553, 93
index: -1
a/zhuj_00003
rotate: true
xy: 801, 1224
size: 183, 308
orig: 960, 540
offset: 503, 37
index: -1
a/zhuj_00004
rotate: false
xy: 2, 232
size: 187, 308
orig: 960, 540
offset: 499, 35
index: -1
a/zhuj_00005
rotate: true
xy: 492, 1218
size: 189, 307
orig: 960, 540
offset: 496, 33
index: -1
a/zhuj_00006
rotate: false
xy: 2, 542
size: 193, 305
orig: 960, 540
offset: 492, 32
index: -1
a/zhuj_00007
rotate: false
xy: 294, 1104
size: 196, 303
orig: 960, 540
offset: 488, 30
index: -1
a/zhuj_00008
rotate: true
xy: 1111, 1208
size: 199, 295
orig: 960, 540
offset: 484, 29
index: -1
a/zhuj_00009
rotate: true
xy: 1100, 1006
size: 200, 274
orig: 960, 540
offset: 481, 27
index: -1
a/zhuj_00010
rotate: true
xy: 460, 872
size: 197, 257
orig: 960, 540
offset: 479, 27
index: -1
a/zhuj_00011
rotate: false
xy: 477, 620
size: 193, 250
orig: 960, 540
offset: 478, 27
index: -1
a/zhuj_00012
rotate: false
xy: 273, 849
size: 185, 233
orig: 960, 540
offset: 482, 28
index: -1
a/zhuj_00013
rotate: true
xy: 649, 282
size: 160, 213
orig: 960, 540
offset: 492, 31
index: -1
a/zhuj_00014
rotate: true
xy: 864, 293
size: 124, 171
orig: 960, 540
offset: 514, 42
index: -1
a/zhuj_00015
rotate: false
xy: 1326, 879
size: 81, 125
orig: 960, 540
offset: 556, 84
index: -1
body
rotate: false
xy: 2, 1084
size: 290, 323
orig: 302, 323
offset: 12, 0
index: -1
body_back
rotate: true
xy: 929, 419
size: 141, 153
orig: 141, 153
offset: 0, 0
index: -1
canying/s1
rotate: false
xy: 516, 146
size: 125, 142
orig: 125, 142
offset: 0, 0
index: -1
canying/s3
rotate: false
xy: 643, 150
size: 135, 130
orig: 135, 130
offset: 0, 0
index: -1
canying/s4
rotate: true
xy: 292, 9
size: 158, 106
orig: 158, 106
offset: 0, 0
index: -1
canying/s5
rotate: false
xy: 1221, 135
size: 146, 107
orig: 146, 107
offset: 0, 0
index: -1
canying/s6
rotate: true
xy: 516, 7
size: 137, 106
orig: 137, 106
offset: 0, 0
index: -1
eyefire/eyefire_00000
rotate: false
xy: 1326, 851
size: 12, 26
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00001
rotate: false
xy: 1326, 851
size: 12, 26
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00002
rotate: true
xy: 1381, 623
size: 12, 26
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00003
rotate: false
xy: 365, 566
size: 12, 27
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00004
rotate: false
xy: 757, 2
size: 12, 27
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00005
rotate: true
xy: 325, 1091
size: 11, 27
orig: 16, 32
offset: 3, 0
index: -1
eyefire/eyefire_00006
rotate: true
xy: 325, 1091
size: 11, 27
orig: 16, 32
offset: 3, 0
index: -1
eyefire/eyefire_00007
rotate: false
xy: 1376, 1148
size: 11, 27
orig: 16, 32
offset: 3, 0
index: -1
eyefire/eyefire_00008
rotate: true
xy: 777, 1042
size: 12, 28
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00009
rotate: false
xy: 191, 243
size: 12, 28
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00010
rotate: false
xy: 941, 814
size: 12, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00011
rotate: false
xy: 941, 814
size: 12, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00012
rotate: true
xy: 197, 552
size: 12, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00013
rotate: false
xy: 649, 457
size: 12, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00014
rotate: false
xy: 1214, 381
size: 12, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00015
rotate: false
xy: 1368, 349
size: 12, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00016
rotate: false
xy: 757, 31
size: 12, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00017
rotate: true
xy: 864, 210
size: 11, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00018
rotate: false
xy: 349, 193
size: 11, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00019
rotate: true
xy: 901, 793
size: 12, 28
orig: 16, 32
offset: 1, 0
index: -1
eyefire/eyefire_00020
rotate: true
xy: 1180, 34
size: 12, 28
orig: 16, 32
offset: 1, 0
index: -1
eyefire/eyefire_00021
rotate: true
xy: 1180, 34
size: 12, 28
orig: 16, 32
offset: 1, 0
index: -1
eyefire/eyefire_00022
rotate: false
xy: 1381, 593
size: 12, 28
orig: 16, 32
offset: 1, 0
index: -1
eyefire/eyefire_00023
rotate: false
xy: 335, 566
size: 13, 27
orig: 16, 32
offset: 1, 0
index: -1
eyefire/eyefire_00024
rotate: false
xy: 1204, 209
size: 13, 28
orig: 16, 32
offset: 1, 0
index: -1
eyefire/eyefire_00025
rotate: false
xy: 1137, 139
size: 13, 28
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00026
rotate: false
xy: 1137, 139
size: 13, 28
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00027
rotate: true
xy: 294, 1089
size: 13, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00028
rotate: false
xy: 1376, 1177
size: 13, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00029
rotate: false
xy: 762, 1041
size: 13, 28
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00030
rotate: true
xy: 777, 1056
size: 13, 28
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00031
rotate: true
xy: 777, 1056
size: 13, 28
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00032
rotate: false
xy: 350, 566
size: 13, 27
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00033
rotate: false
xy: 1395, 594
size: 12, 27
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00034
rotate: false
xy: 1395, 565
size: 12, 27
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00035
rotate: false
xy: 1381, 564
size: 12, 27
orig: 16, 32
offset: 3, 0
index: -1
eyefire/eyefire_00036
rotate: false
xy: 1381, 564
size: 12, 27
orig: 16, 32
offset: 3, 0
index: -1
eyefire/eyefire_00037
rotate: false
xy: 1391, 1179
size: 11, 27
orig: 16, 32
offset: 3, 0
index: -1
hair_t
rotate: false
xy: 492, 1071
size: 313, 145
orig: 313, 145
offset: 0, 0
index: -1
head
rotate: true
xy: 1269, 380
size: 145, 138
orig: 145, 138
offset: 0, 0
index: -1
head_beard_b
rotate: false
xy: 780, 142
size: 113, 66
orig: 113, 66
offset: 0, 0
index: -1
head_beard_f
rotate: false
xy: 989, 24
size: 96, 95
orig: 96, 95
offset: 0, 0
index: -1
headmouth
rotate: false
xy: 385, 279
size: 86, 55
orig: 86, 55
offset: 0, 0
index: -1
l_arm
rotate: true
xy: 1087, 24
size: 95, 91
orig: 96, 92
offset: 1, 1
index: -1
l_armour
rotate: true
xy: 888, 31
size: 91, 99
orig: 92, 100
offset: 1, 0
index: -1
l_beard
rotate: true
xy: 1018, 121
size: 46, 117
orig: 46, 117
offset: 0, 0
index: -1
l_ear
rotate: true
xy: 864, 419
size: 23, 51
orig: 23, 51
offset: 0, 0
index: -1
l_eye
rotate: false
xy: 285, 224
size: 9, 8
orig: 9, 8
offset: 0, 0
index: -1
l_finger_a
rotate: false
xy: 1180, 48
size: 94, 85
orig: 94, 85
offset: 0, 0
index: -1
l_finger_b
rotate: true
xy: 317, 224
size: 73, 65
orig: 73, 65
offset: 0, 0
index: -1
l_finger_c
rotate: true
xy: 224, 169
size: 63, 59
orig: 63, 59
offset: 0, 0
index: -1
l_finger_d
rotate: true
xy: 1350, 62
size: 71, 49
orig: 71, 49
offset: 0, 0
index: -1
l_hand
rotate: true
xy: 624, 2
size: 117, 76
orig: 118, 76
offset: 0, 0
index: -1
l_leg
rotate: true
xy: 672, 683
size: 160, 227
orig: 160, 227
offset: 0, 0
index: -1
l_upparm
rotate: true
xy: 1092, 851
size: 153, 232
orig: 153, 232
offset: 0, 0
index: -1
lock
rotate: false
xy: 1034, 169
size: 168, 68
orig: 168, 68
offset: 0, 0
index: -1
lock_2
rotate: false
xy: 864, 223
size: 168, 68
orig: 168, 68
offset: 0, 0
index: -1
r_arm
rotate: false
xy: 477, 290
size: 170, 196
orig: 170, 196
offset: 0, 0
index: -1
r_armour_t
rotate: false
xy: 719, 845
size: 234, 187
orig: 234, 187
offset: 0, 0
index: -1
r_armour_u
rotate: true
xy: 477, 488
size: 130, 193
orig: 130, 193
offset: 0, 0
index: -1
r_beard
rotate: true
xy: 925, 562
size: 83, 158
orig: 83, 158
offset: 0, 0
index: -1
r_ear
rotate: true
xy: 779, 43
size: 97, 107
orig: 97, 107
offset: 0, 0
index: -1
r_ear_ringa
rotate: true
xy: 1018, 175
size: 15, 14
orig: 15, 14
offset: 0, 0
index: -1
r_ear_ringb
rotate: false
xy: 901, 807
size: 38, 36
orig: 38, 36
offset: 0, 0
index: -1
r_ear_ringb_s
rotate: false
xy: 719, 1034
size: 41, 35
orig: 41, 35
offset: 0, 0
index: -1
r_ear_s
rotate: false
xy: 238, 234
size: 77, 67
orig: 78, 67
offset: 1, 0
index: -1
r_eye
rotate: true
xy: 1018, 192
size: 29, 14
orig: 30, 14
offset: 1, 0
index: -1
r_eye_hurt
rotate: true
xy: 672, 845
size: 25, 38
orig: 25, 39
offset: 0, 0
index: -1
r_finger_a
rotate: false
xy: 224, 7
size: 66, 160
orig: 66, 161
offset: 0, 1
index: -1
r_finger_b
rotate: true
xy: 1037, 313
size: 97, 175
orig: 98, 176
offset: 0, 0
index: -1
r_finger_c
rotate: true
xy: 1085, 527
size: 108, 210
orig: 109, 211
offset: 0, 1
index: -1
r_finger_d
rotate: true
xy: 1092, 637
size: 78, 226
orig: 78, 226
offset: 0, 0
index: -1
r_hand
rotate: false
xy: 1084, 412
size: 183, 113
orig: 183, 113
offset: 0, 0
index: -1
r_leg
rotate: false
xy: 2, 849
size: 269, 233
orig: 269, 233
offset: 0, 0
index: -1
r_upparm
rotate: false
xy: 807, 1034
size: 291, 188
orig: 291, 188
offset: 0, 0
index: -1
skill/0
rotate: false
xy: 1297, 527
size: 82, 108
orig: 267, 145
offset: 130, 18
index: -1
skill/1
rotate: true
xy: 400, 14
size: 153, 114
orig: 267, 145
offset: 43, 0
index: -1
skill/10
rotate: false
xy: 1276, 48
size: 72, 85
orig: 267, 145
offset: 93, 30
index: -1
skill/11
rotate: false
xy: 702, 62
size: 75, 86
orig: 267, 145
offset: 92, 30
index: -1
skill/12
rotate: false
xy: 1221, 244
size: 145, 134
orig: 267, 145
offset: 56, 11
index: -1
skill/13
rotate: true
xy: 955, 787
size: 245, 135
orig: 267, 145
offset: 11, 10
index: -1
skill/14
rotate: false
xy: 1092, 717
size: 249, 132
orig: 267, 145
offset: 9, 12
index: -1
skill/15
rotate: false
xy: 672, 556
size: 251, 125
orig: 267, 145
offset: 8, 15
index: -1
skill/16
rotate: false
xy: 672, 444
size: 255, 110
orig: 267, 145
offset: 6, 22
index: -1
skill/17
rotate: true
xy: 385, 336
size: 257, 90
orig: 267, 145
offset: 5, 34
index: -1
skill/18
rotate: true
xy: 238, 303
size: 261, 90
orig: 267, 145
offset: 3, 34
index: -1
skill/19
rotate: true
xy: 330, 299
size: 265, 53
orig: 267, 145
offset: 1, 62
index: -1
skill/2
rotate: false
xy: 895, 124
size: 121, 97
orig: 267, 145
offset: 58, 12
index: -1
skill/20
rotate: true
xy: 191, 273
size: 267, 45
orig: 267, 145
offset: 0, 68
index: -1
skill/3
rotate: true
xy: 1320, 637
size: 78, 79
orig: 267, 145
offset: 76, 27
index: -1
skill/4
rotate: true
xy: 285, 171
size: 51, 62
orig: 267, 145
offset: 103, 37
index: -1
skill/5
rotate: false
xy: 1350, 6
size: 55, 54
orig: 267, 145
offset: 103, 38
index: -1
skill/6
rotate: false
xy: 702, 2
size: 53, 58
orig: 267, 145
offset: 103, 38
index: -1
skill/7
rotate: false
xy: 1343, 722
size: 52, 73
orig: 267, 145
offset: 103, 38
index: -1
skill/8
rotate: false
xy: 1343, 797
size: 60, 80
orig: 267, 145
offset: 103, 32
index: -1
skill/9
rotate: true
xy: 780, 210
size: 70, 82
orig: 267, 145
offset: 94, 31
index: -1
skirt_b
rotate: false
xy: 925, 647
size: 165, 138
orig: 165, 138
offset: 0, 0
index: -1
skirt_f
rotate: false
xy: 335, 595
size: 140, 252
orig: 140, 252
offset: 0, 0
index: -1
tail
rotate: true
xy: 2, 4
size: 226, 220
orig: 226, 220
offset: 0, 0
index: -1
tail_b
rotate: false
xy: 1037, 239
size: 182, 72
orig: 182, 72
offset: 0, 0
index: -1

File diff suppressed because one or more lines are too long

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 MiB

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,776 @@
fenrir.png
size: 1128,1128
format: RGBA8888
filter: Linear,Linear
repeat: none
attack/0
rotate: true
xy: 388, 255
size: 27, 32
orig: 154, 63
offset: 127, 18
index: -1
attack/a
rotate: false
xy: 1022, 872
size: 27, 32
orig: 154, 63
offset: 127, 18
index: -1
attack/b
rotate: true
xy: 937, 275
size: 131, 57
orig: 154, 63
offset: 10, 6
index: -1
attack/c
rotate: false
xy: 1017, 502
size: 109, 52
orig: 154, 63
offset: 5, 4
index: -1
attack/d
rotate: false
xy: 1039, 558
size: 77, 46
orig: 154, 63
offset: 0, 0
index: -1
body
rotate: false
xy: 2, 803
size: 290, 323
orig: 302, 323
offset: 12, 0
index: -1
canying/s1
rotate: true
xy: 847, 548
size: 125, 142
orig: 125, 142
offset: 0, 0
index: -1
canying/s3
rotate: false
xy: 431, 255
size: 135, 130
orig: 135, 130
offset: 0, 0
index: -1
canying/s4
rotate: true
xy: 570, 639
size: 158, 106
orig: 158, 106
offset: 0, 0
index: -1
canying/s5
rotate: false
xy: 600, 17
size: 146, 107
orig: 146, 107
offset: 0, 0
index: -1
canying/s6
rotate: true
xy: 548, 799
size: 137, 106
orig: 137, 106
offset: 0, 0
index: -1
eyefire/eyefire_00000
rotate: false
xy: 767, 911
size: 12, 26
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00001
rotate: false
xy: 767, 911
size: 12, 26
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00002
rotate: false
xy: 997, 420
size: 12, 26
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00003
rotate: true
xy: 1088, 782
size: 12, 27
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00004
rotate: false
xy: 721, 691
size: 12, 27
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00005
rotate: true
xy: 1022, 859
size: 11, 27
orig: 16, 32
offset: 3, 0
index: -1
eyefire/eyefire_00006
rotate: true
xy: 1022, 859
size: 11, 27
orig: 16, 32
offset: 3, 0
index: -1
eyefire/eyefire_00007
rotate: false
xy: 953, 18
size: 11, 27
orig: 16, 32
offset: 3, 0
index: -1
eyefire/eyefire_00008
rotate: false
xy: 753, 909
size: 12, 28
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00009
rotate: false
xy: 656, 811
size: 12, 28
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00010
rotate: false
xy: 1114, 471
size: 12, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00011
rotate: false
xy: 1114, 471
size: 12, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00012
rotate: false
xy: 1114, 440
size: 12, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00013
rotate: false
xy: 1114, 409
size: 12, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00014
rotate: false
xy: 230, 284
size: 12, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00015
rotate: false
xy: 244, 284
size: 12, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00016
rotate: false
xy: 258, 284
size: 12, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00017
rotate: false
xy: 996, 262
size: 11, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00018
rotate: false
xy: 827, 504
size: 11, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00019
rotate: false
xy: 997, 448
size: 12, 28
orig: 16, 32
offset: 1, 0
index: -1
eyefire/eyefire_00020
rotate: false
xy: 925, 17
size: 12, 28
orig: 16, 32
offset: 1, 0
index: -1
eyefire/eyefire_00021
rotate: false
xy: 925, 17
size: 12, 28
orig: 16, 32
offset: 1, 0
index: -1
eyefire/eyefire_00022
rotate: false
xy: 939, 17
size: 12, 28
orig: 16, 32
offset: 1, 0
index: -1
eyefire/eyefire_00023
rotate: true
xy: 925, 2
size: 13, 27
orig: 16, 32
offset: 1, 0
index: -1
eyefire/eyefire_00024
rotate: true
xy: 662, 2
size: 13, 28
orig: 16, 32
offset: 1, 0
index: -1
eyefire/eyefire_00025
rotate: true
xy: 692, 2
size: 13, 28
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00026
rotate: true
xy: 692, 2
size: 13, 28
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00027
rotate: true
xy: 600, 2
size: 13, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00028
rotate: true
xy: 631, 2
size: 13, 29
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00029
rotate: true
xy: 136, 10
size: 13, 28
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00030
rotate: true
xy: 680, 380
size: 13, 28
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00031
rotate: true
xy: 680, 380
size: 13, 28
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00032
rotate: false
xy: 1106, 1099
size: 13, 27
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00033
rotate: false
xy: 937, 246
size: 12, 27
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00034
rotate: true
xy: 166, 11
size: 12, 27
orig: 16, 32
offset: 2, 0
index: -1
eyefire/eyefire_00035
rotate: true
xy: 710, 381
size: 12, 27
orig: 16, 32
offset: 3, 0
index: -1
eyefire/eyefire_00036
rotate: true
xy: 710, 381
size: 12, 27
orig: 16, 32
offset: 3, 0
index: -1
eyefire/eyefire_00037
rotate: false
xy: 966, 18
size: 11, 27
orig: 16, 32
offset: 3, 0
index: -1
hair t
rotate: true
xy: 2, 253
size: 313, 145
orig: 313, 145
offset: 0, 0
index: -1
head
rotate: false
xy: 680, 395
size: 145, 138
orig: 145, 138
offset: 0, 0
index: -1
head beard b
rotate: true
xy: 996, 293
size: 113, 66
orig: 113, 66
offset: 0, 0
index: -1
head beard f
rotate: true
xy: 656, 841
size: 96, 95
orig: 96, 95
offset: 0, 0
index: -1
headmouth
rotate: true
xy: 1064, 268
size: 86, 55
orig: 86, 55
offset: 0, 0
index: -1
l arm
rotate: false
xy: 1017, 409
size: 95, 91
orig: 96, 92
offset: 1, 1
index: -1
l armour
rotate: false
xy: 829, 130
size: 91, 99
orig: 92, 100
offset: 1, 0
index: -1
l beard
rotate: false
xy: 991, 556
size: 46, 117
orig: 46, 117
offset: 0, 0
index: -1
l ear
rotate: true
xy: 1009, 135
size: 23, 51
orig: 23, 51
offset: 0, 0
index: -1
l eye
rotate: false
xy: 827, 398
size: 9, 8
orig: 9, 8
offset: 0, 0
index: -1
l finger a
rotate: true
xy: 922, 135
size: 94, 85
orig: 94, 85
offset: 0, 0
index: -1
l finger b
rotate: false
xy: 678, 774
size: 73, 65
orig: 73, 65
offset: 0, 0
index: -1
l finger c
rotate: false
xy: 149, 254
size: 63, 59
orig: 63, 59
offset: 0, 0
index: -1
l finger d
rotate: true
xy: 1009, 160
size: 71, 49
orig: 71, 49
offset: 0, 0
index: -1
l hand
rotate: true
xy: 847, 11
size: 117, 76
orig: 118, 76
offset: 0, 0
index: -1
l leg
rotate: true
xy: 273, 634
size: 160, 227
orig: 160, 227
offset: 0, 0
index: -1
l upparm
rotate: false
xy: 276, 400
size: 153, 232
orig: 153, 232
offset: 0, 0
index: -1
lock
rotate: false
xy: 847, 478
size: 168, 68
orig: 168, 68
offset: 0, 0
index: -1
lock 2
rotate: false
xy: 827, 408
size: 168, 68
orig: 168, 68
offset: 0, 0
index: -1
r arm
rotate: false
xy: 216, 86
size: 170, 196
orig: 170, 196
offset: 0, 0
index: -1
r armour t
rotate: false
xy: 587, 939
size: 234, 187
orig: 234, 187
offset: 0, 0
index: -1
r armour u
rotate: true
xy: 388, 123
size: 130, 193
orig: 130, 193
offset: 0, 0
index: -1
r beard
rotate: false
xy: 753, 235
size: 83, 158
orig: 83, 158
offset: 0, 0
index: -1
r ear
rotate: false
xy: 730, 126
size: 97, 107
orig: 97, 107
offset: 0, 0
index: -1
r ear ringa
rotate: false
xy: 954, 2
size: 15, 14
orig: 15, 14
offset: 0, 0
index: -1
r ear ringb
rotate: false
xy: 1088, 823
size: 38, 36
orig: 38, 36
offset: 0, 0
index: -1
r ear ringb s
rotate: false
xy: 678, 683
size: 41, 35
orig: 41, 35
offset: 0, 0
index: -1
r ear s
rotate: true
xy: 1039, 606
size: 78, 67
orig: 78, 67
offset: 0, 0
index: -1
r eye
rotate: true
xy: 214, 284
size: 29, 14
orig: 30, 14
offset: 1, 0
index: -1
r eye hurt
rotate: true
xy: 1088, 796
size: 25, 38
orig: 25, 39
offset: 0, 0
index: -1
r finger a
rotate: false
xy: 502, 634
size: 66, 160
orig: 66, 161
offset: 0, 1
index: -1
r finger b
rotate: false
xy: 838, 231
size: 97, 175
orig: 98, 176
offset: 0, 0
index: -1
r finger c
rotate: true
xy: 388, 13
size: 108, 210
orig: 109, 211
offset: 0, 1
index: -1
r finger d
rotate: false
xy: 136, 25
size: 78, 226
orig: 78, 226
offset: 0, 0
index: -1
r hand
rotate: false
xy: 568, 262
size: 183, 113
orig: 183, 113
offset: 0, 0
index: -1
r leg
rotate: false
xy: 2, 568
size: 269, 233
orig: 269, 233
offset: 0, 0
index: -1
r upparm
rotate: false
xy: 294, 938
size: 291, 188
orig: 291, 188
offset: 0, 0
index: -1
skill/0
rotate: true
xy: 216, 2
size: 82, 108
orig: 267, 145
offset: 130, 18
index: -1
skill/1
rotate: false
xy: 276, 284
size: 153, 114
orig: 267, 145
offset: 43, 0
index: -1
skill/10
rotate: false
xy: 1002, 48
size: 72, 85
orig: 267, 145
offset: 93, 30
index: -1
skill/11
rotate: false
xy: 925, 47
size: 75, 86
orig: 267, 145
offset: 92, 30
index: -1
skill/12
rotate: false
xy: 583, 126
size: 145, 134
orig: 267, 145
offset: 56, 11
index: -1
skill/13
rotate: true
xy: 431, 387
size: 245, 135
orig: 267, 145
offset: 11, 10
index: -1
skill/14
rotate: true
xy: 2, 2
size: 249, 132
orig: 267, 145
offset: 9, 12
index: -1
skill/15
rotate: true
xy: 149, 315
size: 251, 125
orig: 267, 145
offset: 8, 15
index: -1
skill/16
rotate: true
xy: 568, 377
size: 255, 110
orig: 267, 145
offset: 6, 22
index: -1
skill/17
rotate: false
xy: 753, 675
size: 257, 90
orig: 267, 145
offset: 5, 34
index: -1
skill/18
rotate: false
xy: 753, 767
size: 261, 90
orig: 267, 145
offset: 3, 34
index: -1
skill/19
rotate: true
xy: 1051, 861
size: 265, 53
orig: 267, 145
offset: 1, 62
index: -1
skill/2
rotate: true
xy: 748, 3
size: 121, 97
orig: 267, 145
offset: 58, 12
index: -1
skill/20
rotate: false
xy: 753, 859
size: 267, 45
orig: 267, 145
offset: 0, 68
index: -1
skill/3
rotate: false
xy: 1012, 686
size: 78, 79
orig: 267, 145
offset: 76, 27
index: -1
skill/4
rotate: true
xy: 1064, 356
size: 51, 62
orig: 267, 145
offset: 103, 37
index: -1
skill/5
rotate: false
xy: 1064, 212
size: 55, 54
orig: 267, 145
offset: 103, 38
index: -1
skill/6
rotate: false
xy: 1009, 233
size: 53, 58
orig: 267, 145
offset: 103, 38
index: -1
skill/7
rotate: true
xy: 678, 720
size: 52, 73
orig: 267, 145
offset: 103, 38
index: -1
skill/8
rotate: false
xy: 326, 4
size: 60, 80
orig: 267, 145
offset: 103, 32
index: -1
skill/9
rotate: false
xy: 1016, 775
size: 70, 82
orig: 267, 145
offset: 94, 31
index: -1
skirt b
rotate: false
xy: 680, 535
size: 165, 138
orig: 165, 138
offset: 0, 0
index: -1
skirt f
rotate: true
xy: 294, 796
size: 140, 252
orig: 140, 252
offset: 0, 0
index: -1
tail
rotate: false
xy: 823, 906
size: 226, 220
orig: 226, 220
offset: 0, 0
index: -1

File diff suppressed because one or more lines are too long

Binary file not shown.

After

Width:  |  Height:  |  Size: 857 KiB

Binary file not shown.

Binary file not shown.