It seems that you're using an outdated browser. Some things may not work as they should (or don't work at all).
We suggest you upgrade newer and better browser like: Chrome, Firefox, Internet Explorer or Opera

×
avatar
phoeniixz: I have created a forked version of the script to read patterns from files for easier editing. Just edit patterns in patterns.txt file.

https://github.com/phoeniixz/GOG-Flash-Promo-Script
And you seem to have improved the structure of the code significantly as well.

Can you do a pull request? I'll run a couple of test and merge it when I get back.

Might as well keep working from your version if its better.
Woaow, more people working on this script ! That's great ! :D Thank you all for doing this :) I'm curious to see (and use) new version of the script when it will be available !
Post edited March 04, 2015 by Splatsch
avatar
phoeniixz: I have created a forked version of the script to read patterns from files for easier editing. Just edit patterns in patterns.txt file.

https://github.com/phoeniixz/GOG-Flash-Promo-Script
avatar
Magnitus: And you seem to have improved the structure of the code significantly as well.

Can you do a pull request? I'll run a couple of test and merge it when I get back.

Might as well keep working from your version if its better.
I'm quite new to GitHub. I think I have successfully create a pull request!
Post edited March 04, 2015 by phoeniixz
avatar
Splatsch: Is it possible to have an alarm simply for each time a "new" game is on sale ? (I mean a game is replacing the one which was actually on sale)
You can now let it watch for a new game on sale.
https://github.com/phoeniixz/GOG-Flash-Promo-Script
Attachments:
shot.png (45 Kb)
avatar
Splatsch: Is it possible to have an alarm simply for each time a "new" game is on sale ? (I mean a game is replacing the one which was actually on sale)
avatar
phoeniixz: You can now let it watch for a new game on sale.
https://github.com/phoeniixz/GOG-Flash-Promo-Script
:D Wouhou ! Thanks ! *go try it*
avatar
Splatsch: Is it possible to have an alarm simply for each time a "new" game is on sale ? (I mean a game is replacing the one which was actually on sale)
avatar
phoeniixz: You can now let it watch for a new game on sale.
https://github.com/phoeniixz/GOG-Flash-Promo-Script
May I ask you : inside "patterns.txt" : titles are not separated ? (and is the search case sensitive ?)
Post edited March 04, 2015 by Splatsch
avatar
Magnitus: Sure, I'd love to take a look.
Ok. I have been a bit sleep deprived, but I managed to set something up.
Please take a look at https://github.com/gatl/the_napping_gamer.
Tomorrow I can see if I make it a bit more Windows-friendly. I think that only the notification needs changing. But since I don't run Windows, everyone's feedback is welcome.

BTW, I haven't found a clue yet regarding that magic URL. :-)
avatar
phoeniixz: You can now let it watch for a new game on sale.
https://github.com/phoeniixz/GOG-Flash-Promo-Script
avatar
Splatsch: May I ask you : inside "patterns.txt" : titles are not separated ? (and is the search case sensitive ?)
The titles are supposed to be separated by line ending but you didn't see it if you opened with notepad because the file was created on Linux. And the search is case insensitive.
Post edited March 04, 2015 by phoeniixz
avatar
Splatsch: May I ask you : inside "patterns.txt" : titles are not separated ? (and is the search case sensitive ?)
avatar
phoeniixz: The titles are supposed to be separated by line ending but you didn't see it if you opened with notepad because the file was created on Linux. And the search is case insensitive.
Okay thanks :)
avatar
Magnitus: Sure, I'd love to take a look.
avatar
Gede: Ok. I have been a bit sleep deprived, but I managed to set something up.
Please take a look at https://github.com/gatl/the_napping_gamer.
Tomorrow I can see if I make it a bit more Windows-friendly. I think that only the notification needs changing. But since I don't run Windows, everyone's feedback is welcome.

BTW, I haven't found a clue yet regarding that magic URL. :-)
I'm trying it right now !

Edit : Hum, it seems I'll wait for a version a little more "windows friendly" XD
Post edited March 04, 2015 by Splatsch
avatar
Gede: Now that Javascript is much faster than it used to be, it makes sense. Yet, I have not learned it yet.
Javascript is big in the web development world.

If you don't work with a browser a lot, then there are probably more mature alternatives.

Overall, many devs cry a river about it, but it's not a bad language to work with if you are methodical though its sexiest attribute is probably is that it is supported in every browser out there.

avatar
Gede: Here is something I wanted to ask you: how on Earth did you discover that URL to fetch the promo data? I would never have found it! I looked for it in the source code of the front page and I could see no hint of its presence!
Yeah, looking at minified Javascript code is just masochistic.

There is a shortcut: Major browsers at this point (and the venerable Firebug plugin for Firefox) have various dev tools, including a "net" tab that allows you to view requests and responses.

avatar
phoeniixz: You can now let it watch for a new game on sale.
https://github.com/phoeniixz/GOG-Flash-Promo-Script
Boy, you've been busy! I guess I'll able to get back to my Express user library sooner than anticipated.

I'll test it and then merge.

Edit: Done. Thanks for all the great improvements on the script!
Post edited March 04, 2015 by Magnitus
avatar
Splatsch: Okay thanks :)
I'm trying it right now !

Edit : Hum, it seems I'll wait for a version a little more "windows friendly" XD
Done! Please provide some feedback so that I can fix any problem that may come by.

avatar
Magnitus: There is a shortcut: Major browsers at this point (and the venerable Firebug plugin for Firefox) have various dev tools, including a "net" tab that allows you to view requests and responses.
Wow! Look at that! It's so neat! Thanks a lot!
It just shows I still have a lot to learn about web development!
Post edited March 04, 2015 by Gede
Cool, it works now!
Anyway, I've changed the poll time to 30-60 secs as I don't need it that frequent.
Ok, the patterns.txt file with end of line formattings adjusted for Windows caused a problem with Linux (wouldn't match titles properly) so to avoid this issue for Linux users, I removed the patterns.txt file from the project.

Probably not the most satisfying solution, but I need to work on other things and I want the script to work for everyone as quickly as possible.

If you want the script to uniquely match a list of games you are interested in, be sure to create that file in the script's directory and list the titles you want.

It's in the documentation.
Post edited March 04, 2015 by Magnitus
I have created a thread to report any problem someone could find with my script.
http://www.gog.com/forum/general/the_napping_gamer_insomnia_script.

Feedback welcome.
Uh, is it possible to make the script play an audio file, instead of a YT video?
My autoplay is disabled on the site (and I need that option).