Views: 772,557,451
16 users online:  Aja,  Atari2.0, Bernardo, buggy789, crismemoria,  E-man38,  FPzero, Linen, N450,  PatPatPat, placeholdertest,  RussianMan, Sancles, SMWFan2019,  Telinc1, TheZ - Guests: 193 - Bots: 163Users: 40,572 (1,854 active)
Latest: jirico
Tip: Linear levels aren't necessarily a bad thing. After all, most official Mario levels are fairly linear.Not logged in.
Details for SMWC Preview
Tools - SMWC Preview
File Name: SMWC Preview
Authors: randomdude999
Operating System: Windows, Mac OS X, Linux
Platforms: General
Games: General
Source Available: 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:

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.
Rating: 4.3 (Votes: 8)
Download: Download - 15.53 KiB
Thanks a bunch, its working after applying that patch.
Posted by: Regulous - | Link
That appears to be caused by Cloudflare's anti-urllib measures. Here's a patch that you can apply to python_code/ 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 - | Link
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{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 - | Link
I haven't tested it in 3.7 but looking at the changelog, it should work just fine.
Posted by:  randomdude999 - | Link
Would this also be compatible with the newest version of Python, version 3.7?
Posted by: Alex119098 - | Link
I can't get this to work at all 😧
Posted by: SlameGut - | Link
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:  RPG Hacker - | Link
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 - | Link
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:  RPG Hacker - | Link
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 - | Link
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 - | Link
Did you check developer mode in extensions? That should be the trick.
Posted by: Alex119098 - | Link
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 - | Link
Man, this is such a useful tool. Thanks a lot!
Posted by: Mogu94 - | Link
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 - | Link
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 - | Link
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:
Posted by:  randomdude999 - | Link
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 and in that order. The Preview button doesn't show up on anything at all. What am I doing wrong?
Posted by: IanBoy - | Link
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 - | Link
If this can be made an extension, is there a chance that this could be made a userscript for Greasemonkey?
Posted by: lx5 - | Link

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: 9


Follow Us On

  • YouTube
  • Twitch
  • Twitter


  • Talkhaus
  • SMBX Community
  • GTx0
  • Super Luigi Bros
  • MFGG
  • Gaming Reinvented