Banner
Views: 713,845,238
Time:
15 users online: Bloody Shadow of The Darkness, Crisisier, DPBOX, Emerald Shell, enan2017, Kiatus, KKevinM, o LadiesMan217, Lemon, o Luigi-San, ModernKiwi, Tobio, Ultima, YoshiGamingHD, Yoshin - Guests: 55 - Bots: 163Users: 37,270 (1,599 active)
Latest: ollai
Not logged in.
Details for SMWC Preview
Tools - SMWC Preview
File Name: SMWC Preview
Added:
Authors: randomdude999
Operating System: Windows, Mac OS X, Linux
Platforms: General
Games: General
Source Included: Yes
Featured: No
Website: Link
Description: This is a Python tool/Chrome extension that adds a "Preview"/"Play" button to SMWC submissions. Install instructions are in README.
Requirements: Google Chrome, Python 3.6+, Zenity if on OSX or Linux. Tested on Windows and Linux. Should also work on OS X, but I don't have a Mac, so I'm not really sure.
Demo video: https://youtu.be/iVYV18Iizig

There is an alternative install method now, you can install with a userscript. This has the advantage that you don't need to install an untrusted extension. Simply install in userscript mode and add the userscript to your browser. Currently not supported on Mac OS X.

If someone knows how to create native dialogs from python on OSX, please tell me.

Edit 1: fix installer (it would error on windows)
Edit 2: fix gen_settings (oh my god i'm bad at this "programming" thing)
Edit 3: fix dialog boxes on non-Windows platforms. Also do some proper testing.
Edit 4: include chrome_ext folder to make loading as unpacked extension easier.
Edit 5: hopefully fix windows again (i should probably create a github repo for this)
Edit 6: Added userscript install. Also created github repo, as promised.
Tags:
Rating: 4.3 (Votes: 8)
Download: Download - 15.53 KiB
232 downloads
Screenshots
Image
Regulous
Thanks a bunch, its working after applying that patch.
Posted by: Regulous -
randomdude999
That appears to be caused by Cloudflare's anti-urllib measures. Here's a patch that you can apply to python_code/common.py to make it use requests, which is a different Python HTTP library that isn't blocked by Cloudflare. If you apply it then remember to also install requests using pip since it isn't included with Python by default.
Posted by: randomdude999 -
Regulous
I'm having issues with this now, whereas I wasn't a couple months ago. After checking the error log I'm wondering if smwc has inadvertently blocked it by trying to prevent scrapers - ie https://dl.smwcentral.net/{item_id}/ works in my browser but according to the error log its giving a urllib.error.HTTPError: HTTP Error 403: Forbidden.
Posted by: Regulous -
randomdude999
I haven't tested it in 3.7 but looking at the changelog, it should work just fine.
Posted by: randomdude999 -
Alex119098
Would this also be compatible with the newest version of Python, version 3.7?
Posted by: Alex119098 -
SlameGut
I can't get this to work at all 😧
Posted by: SlameGut -
RPG Hacker
Amazing! *_*
Thanks a lot. Also send me a PM so that we can arrange when and where I shall kiss your feet. ;)
Posted by: o RPG Hacker -
randomdude999
I'm using Firefox right now, and it's working fine. Sadly i couln't get the extension-based version working, so you will have to use userscript install instead. Someone actually asked me on Discord about userscript install on firefox, so i made some image instructions here.
Posted by: randomdude999 -
RPG Hacker
Pretty amazing script! Something like this is what I've been looking for. Now if someone could somehow make the same thing work in Firefox, I would kiss their feet!
Posted by: o RPG Hacker -
randomdude999
Since there is a command prompt, I assume you installed in userscript mode? If you get as far as a command prompt opening and closing, that already means that most stuff works. If you go to the smwc_preview folder, in there should be a uri_handler folder. Is there a file named "error.log" in there? If there is, please upload it on pastebin and link here.

(I should really update the readme with all the troubleshooting instructions)
Posted by: randomdude999 -
RenkoV2
yeah I did, it doesn't change anything, whenever I click the preview button it just opens a command prompt that instantly closes.
Posted by: RenkoV2 -
Alex119098
Did you check developer mode in extensions? That should be the trick.
Posted by: Alex119098 -
RenkoV2
I can't get it to work, any time I put it on chrome, chrome automatically disables it, also could this work for opera? i mean opera is pretty similar to chrome
Posted by: RenkoV2 -
Mogu94
Man, this is such a useful tool. Thanks a lot!
Posted by: Mogu94 -
randomdude999
When you installed python, did you check the "install py launcher" option? Because that is required. You can try replacing pyw -3 with pythonw and see if that fixes it.
Posted by: randomdude999 -
IanBoy
Got the script working now, but it gives me an error once opening something like a hack or a song saying that a file (pyw) was not found.
Posted by: IanBoy -
randomdude999
What do you mean, updated userscript.js? That file should always stay the same. (besides, i think i renamed it to smwc_preview.user.js anyways)
I made image instructions about how to install the userscript as a tampermonkey script:
https://cdn.discordapp.com/attachments/372700421812256768/373550218693574656/tampermonkey_instructions.zip
Posted by: randomdude999 -
IanBoy
It doesn't give me an updated chrome_ext.crx/userscript.js even though I placed all the things I wanted into the same folder as the program and ran install.py and gen_settings.py in that order. The Preview button doesn't show up on anything at all. What am I doing wrong?
Posted by: IanBoy -
randomdude999
It is a combination of a Chrome extension and a native application. I can't do it with userscripts since I need to send "native messages" and I don't know of any userscript extension that allows that.
Posted by: randomdude999 -
LX5
If this can be made an extension, is there a chance that this could be made a userscript for Greasemonkey?
Posted by: LX5 -

The purpose of this site is not to distribute copyrighted material, but to honor one of our favourite games.

Copyright © 2005 - 2019 - SMW Central
Legal Information - Privacy Policy - Link To Us


Total queries: 31

Menu

Follow Us On

  • Facebook
  • Twitter
  • YouTube

Affiliates

  • Talkhaus
  • SMBX Community
  • GTx0
  • Super Luigi Bros
  • ROMhacking.net
  • MFGG
  • Gaming Reinvented