DragonBones / Tools

DragonBones Tools
MIT License
141 stars 75 forks source link

BUG: converting from version 2.x/3.x #2

Closed bitbay closed 7 years ago

bitbay commented 7 years ago

I tried to convert an animation exported from Flash using the DesignPanel v3.0.1 to the new v5.5 format, but it seems that one of the two is failing:

I attach two images and the two skeletons with their textures/atlases.

This is how it is expected to look like: expected_result ...and this is how it ends up issue

This is exported.zip from DesignPanel 3.0.1, using the command $ db2 -t new -i ./exported -o ./converted i got to this skeleton converted.zip

akdcl commented 7 years ago

Hi, we will fix the bug asap :)

akdcl commented 7 years ago

Hi, the bug has been fixed, you can upgrade the tools.

mobiledevnetwizzy commented 7 years ago

Thank You @akdcl, updating with npm install -g dragonbones-tools to @0.0.31 did it!

mobiledevnetwizzy commented 7 years ago

did this patch/fix landed in the master branch of the repo?


using same input (exported.zip from above) and latest commit i am missing some transform...

armature[0].skin[0].slot[0].display[0].transform === undefined

while the npm version of the converter (@0.0.31) gives for the same input

armature[0].skin[0].slot[0].display[0].transform === { x: 64, y: 64 }
bitbay commented 7 years ago

Our use-case involves a library solution (without the proposed converter web-service), executable inside browser for 'on-the-fly' conversion of dragonbones skeletons from old formats to currently used ones. Have a look at the dirty proof of concept repository and the use case demonstrated here - showcasing the aforementioned error.

Hope it helps to clarify the previous question.


To build the library dragonbones-db2.js simply clone the repo and

$ npm install
$ npm run build-web
akdcl commented 7 years ago

@mobiledevnetwizzy Hi, the bug has been pushed to master branch, is it still has transform bug with 2.x to 5.x?

mobiledevnetwizzy commented 7 years ago

@akdcl aparently yes, but i'm not quite sure because of a clean clone build failing for dragonbones tools.

$ git clone https://github.com/DragonBones/Tools.git && cd Tools
Tools$ npm install
Tools$ npm 
Tools$ npm run build
> dragonbones-tools@0.0.32 build E:\tmp\dragonbones\Tools-clean
> tsc & dbp -t tools

"tsc" is not recognized as an internal or external command,
operable program or batch file.
"dbp" is not recognized as an internal or external command,
operable program or batch file.

Adding the following dependencies to package.json

"dependencies": {
     ...
     "@types/node": "^8.0.47",
     "typescript": "^2.6.1"
   }

i'm left with the dbp -t tools failing.

Cloning and building the repo of @bitbay the result is the same (bug present), but it may have to do with that repo and not the Tools itself.

akdcl commented 7 years ago

@mobiledevnetwizzy if you want to build the tools, you can run command like this:

npm install
npm install typescript --global
tsc

You can read the README.md to find how to build the dragonbones tools.

mobiledevnetwizzy commented 7 years ago

@akdcl with the tsc command it compiles perfectly and gives the correct result. So it must me the web-bundle version of @bitbay that's missing something... Thanks again!