Closed dekrain closed 8 years ago
I cannot test this because of error:
Tile.js:53:Uncaught RangeError: Tile W not found.
a row's "length" property is 52, but real size is 51
Hmm... I tried to change CRLF to LF, but without effects...
Tile.js:53:Uncaught RangeError: Tile W not found.
That means that there's a Tile in your level W
that isn't defined. Check src/levels.toml.
It's probably because index.js
is encoded in CRLF format, but it should be LF.
Originally in logs are line-end character. I removed it. It's probably CR character. In my Path2D parser I used
code.split(/[\n|\r\n]/)
That'll make no difference, we're using a build system that removes most (if not all) line breaks / carriage returns anyway.
That means that there's a Tile in your level W that isn't defined. Check src/levels.toml.
There's a W
in your tilemap somewhere that's confusing it at runtime not compile-time.
Yes, it's because gulp changed ~~~~\n~~~~
to ~~~~\r\n~~~~
I'm not honestly sure where a string of ~
would appear anyways.
The original problem is "I can't run the game". Just to clarify - can you build and run the game now?
For example, in my src/levels.toml#L10
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~[CR][LF]
gulp changes it to
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\r\n
but expected is
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n
(this message has for convenience been deleted but I see what you mean sorry lol)
Interesting. Out of interest, do you use Windows, @dekrain? I believe the rest of us use Linux/Mac so that's probably why you're getting a linefeed result.
51b79807750fa0f009b9088769045c7e9f50fdc2 should fix your bug @dekrain - merge from master and build again to see if it fixes it.
Yes, I'm using Windows. Thanks for that commit.
Hmm... It seems that new plugin doesn't removes /\\r/
sequence
...Thanks to (maybe) large files for hour delay