defold / editor2-issues

DEPRECATED
44 stars 4 forks source link

Failed to load resource sys.load_resource #136

Closed AGulev closed 8 years ago

AGulev commented 8 years ago

I try to run my project in new editor and recive message:

WARNING:SCRIPT: Failed to load resource: /levels/level1.json (-3)

when I try to load json file:

sys.load_resource("/levels/level1.json")

Same code in editor1 works fine

Expected behaviour

json file should be loaded

Actual behaviour

WARNING:SCRIPT: Failed to load resource: /levels/level1.json (-3)

Steps to reproduce

  1. Create folder for custom files "levels"
  2. Add to game project "custom_resources = levels/"
  3. try to load you file by "sys.load_resource("/levels/level1.json")"

    Defold version: 1.2.90 Defold sha: e799db0c48897c3041f912f15cd649ee96ffc39b Platform: Mac OS X 10.12 (x86_64) Java version: 1.8.0_102-b14

ragnard-king commented 8 years ago

Hi @AGulev,

Thanks for the report! Editor2 development is moving quite quickly and we release new versions frequently, and it looks like you are on a version that was released just before we implemented support for custom resources.

Have you tried updating editor2? You should be seeing a popup alerting you that a new version is available.

AGulev commented 8 years ago

Hi, @ragnard-king I have no update popup ( I tryed to restart editor few times (and have no "update" options in menu)

mathiaswking commented 8 years ago

Regarding the popup window, could this be related to https://github.com/defold/editor2-issues/issues/61 ? My popup ended up behind the editor :/

ragnard-king commented 8 years ago

@AGulev If you can launch defold in a terminal, there should be some output on the progress of the updater:

$ ./Defold.app/Contents/MacOS/Defold

Output goes to terminal and editor2.log in your working directory. Could you send editor2.log after the editor has been running for a little while?

AGulev commented 8 years ago

thanks @ragnard-king When I start defold by "open Defold.app/Contents/MacOS/Defold " Defold was updated And yes, after uptade "sys.load_resource" solved

ragnard-king commented 8 years ago

@AGulev Ok, great to hear!

Still slightly confused as to why you didn't receive any updates until now, but will investigate that separately so closing this issue now.