nerdydrew / Random-Pokemon-Generator

Source code for randompokemon.com
https://randompokemon.com
GNU General Public License v2.0
86 stars 29 forks source link

path not defined #1

Closed DracoMilesX closed 6 years ago

DracoMilesX commented 6 years ago

Trying to set this up locally but it appears the code isn't working and checking the dev console it shows that PATH_TO_SPRITES isn't defined.

Reverting back to an older commit before define usage is working fine.

nerdydrew commented 6 years ago

You need to set it in the setup.js file at the top level directory, as it says in the readme. I updated the sample file accordingly.

DracoMilesX commented 6 years ago

Thanks for the info. For some reason still not working for me. This is how it is currently setup:

/webroot/pkmnrandom /webroot/pkmnrandom/config.js /webroot/pkmnrandom/config.php /webroot/pkmnrandom/sprites/animated /webroot/pkmnrandom/sprites/animated/shiny /webroot/pkmnrandom/etc..

Renamed file names to remove all starting zero's

(Did had to adjust index.php because of the / infront of style.css and several others)

Nginx/PHP7.0

nerdydrew commented 6 years ago

Heh, my bad—I was thinking PHP instead of JavaScript when I updated the sample config. I fixed it to use const now. When in doubt, remember you can always look at the live site, which you can verify works!

And good point on the absolute links. I just fixed them to be relative instead.

DracoMilesX commented 6 years ago

Thank you now it is indeed working except that now ANIMATED is added in the config.js which doesn't match the rest.

nerdydrew commented 6 years ago

Okay, thanks again for that. It should be fixed, for real this time.

DracoMilesX commented 6 years ago

All working now thank you very much:)