TannerRogalsky / love.js

LÖVE ported to the web using Emscripten
MIT License
491 stars 52 forks source link

Black Screen #72

Open ishaangrewal opened 4 years ago

ishaangrewal commented 4 years ago

I passed my project folder but localhost:8000 in my browser opens a window that just has a black screen in the game area. The title of the game is visible as the title of the window open and it says the resize and fullscreen options along with the emscripten icon is visible too.

LilTimmy420 commented 4 years ago

I have the same issue for my 2nd game (black screen). For the first one everything works great. I'm using love2D version 11.3.

LilTimmy420 commented 4 years ago

@ishaangrewal I found the solution to this problem. This problem is due to the fact that love.js is developed to work with love2D version 0.10.0. If you are using love2D 11.3 to develop your game, you need to make some minor changes to your program. For the setColor() function, v11.3 uses the scale from 0 to 1, while older versions uses the scale from 0 to 255. So all you need to do is to make changes such as setColor(1, 1, 1, 1) to setColor(255, 255, 255, 255). Good luck!