DragonBones / DragonBonesJS

DragonBones TypeScript / JavaScript Runtime
MIT License
746 stars 320 forks source link

Uncaught TypeError: Cannot read property Error via PIXI #118

Closed Darth-Carrotpie closed 4 years ago

Darth-Carrotpie commented 4 years ago

Launched examples. Everything works (except weird position, not scaling into some widgets), but when I swap formats of HelloDragonBones (lines 34/35) to JSON, that are commented there (I assume as an example), I get this error: HelloDragonBones.js:42 Uncaught TypeError: Cannot read property 'resource/mecha_1002_101d_show/mecha_1002_101d_show_ske.json' of undefined at HelloDragonBones._onStart (HelloDragonBones.js:42) at e.<anonymous> (BaseDemo.js:56) at e.a.emit (pixi.min.js:8) at pixi.min.js:8 at t.value (pixi.min.js:8) at e._onComplete (pixi.min.js:8) at pixi.min.js:8 at s (pixi.min.js:8) at e.os.use (pixi.min.js:8) at pixi.min.js:8 Needed that format (JSON), because all of my assets are in it.

Also all demo projects are outdated with depreciated functions from Pixi previous versions.

Darth-Carrotpie commented 4 years ago

found a fix... looks like a syntax error: there was an 's' missing in "_pixiResources": //factory.parseDragonBonesData(this._pixiResource["resource/mecha_1002_101d_show/mecha_1002_101d_show_ske.json"].data);