Curation Tutorial: Difference between revisions

From Flashpoint Datahub
Jump to navigation Jump to search
No edit summary
(→‎Finding the Source of a Flash Game: FPFSS > the database search tool)
 
(108 intermediate revisions by 20 users not shown)
Line 1: Line 1:
The following page is a tutorial on how Flashpoint works, and how to curate games.
This page is a basic tutorial on how Flashpoint works and how to curate games for addition to Flashpoint. See the [[Content Patches]] page for information on modifying and adding assets to games already in Flashpoint.
 
Additionally, please read the [[Curation Format]] page for a more detailed explanation on what a curation should look like before submitting.
 
If you would like an overview, check out this '''video tutorial''': https://www.youtube.com/watch?v=Im7tlzhd4fg '''(This video is very outdated, use it as a general introduction to the idea than a full tutorial.)'''


== How Flashpoint Works ==
== How Flashpoint Works ==


Before you curate, it's worth understanding how Flashpoint works, as understanding what exactly Flashpoint does to play games will help you grasp curating later on.
Flashpoint is more than just a program to play files; rather, it's a combination of two programs working in parallel:
* a '''web server''', which hosts game files from an internal or external drive and pretends to be the original Internet source the games ran off of,
* and a '''launcher''', the user interface to select and play games from.
 
Flashpoint itself also comes in two primary versions:
* '''Infinity''', the version that downloads games and animations from a server as you play or view them,
* and '''Ultimate''', the gigantic version with every game and animation included and ready for offline play and viewing.
 
Infinity will download files as you play games that request them, while Ultimate knows the files are already there. Both make the files believe they're being ran on their original source. This has numerous benefits, the two most important being bypassing '''sitelocks''' and supporting '''multi-asset''' games. The [[How Flashpoint Works]] article provides more detail on this topic. Before we understand how Flashpoint handles those cases, though, let's walk through the simplest case possible: curating a single-asset SWF file.
 
== Setting Up Our Software ==
 
To download game files from the Internet, you'll need:
*'''[https://flashpointarchive.org/downloads Flashpoint Infinity]''', version 12 or later; curating in previous versions or Ultimate may run into compatibility problems.
*'''A modern web browser''' such as Chrome or Firefox, which have a built in Network monitor that we can use to find and grab individual SWFs, and sometimes multi-asset titles with low amounts of resources.
*'''cURLsDownloader''', found as a component in the Extras section of the Flashpoint Infinity Installer. This isn't strictly necessary, but it helps immensely; you'll see why later on.
 
Download Flashpoint Infinity, extract it to an internal or external drive, run it via its shortcut in the extracted folder, and make sure that the included games play properly before you continue.
 
== Finding the Source of a Flash Game ==
[[File:SWFAssetInChrome.png|thumb|The SWF for Interactive Buddy in Chrome's network tab; it should look similar on Firefox.]]
'''Be sure to [https://fpfss.unstable.life/web/submissions search FPFSS], check the [[Not Accepted Curations]] page, and search the Curations channels in the [https://discord.gg/kY8r2BbPQ9 Flashpoint Discord server] before settling on a game! Otherwise, you might waste time and effort to save a game that's already been saved.'''
 
As a tutorial, we'll start by curating the simplest type of Flash game: a single SWF file that isn't sitelocked, specifically [https://www.newgrounds.com/portal/view/218014 Interactive Buddy]. You might need to enable Flash in your browser to get it to play (this tutorial won't work if you're using another player such as the Newgrounds Player).
 
* If you're using Chrome or Firefox, press F12 to open the Developer Tools and click on the Network tab. This shows us every asset that loads on the page in real time.
* You can filter miscellaneous types of assets such as Flash files by clicking the Other tab within the Network tab.
* Refresh the page to find that a few assets loaded. The game file has an extension of '''.swf''', and has a type of x-shockwave-flash in the table.
* Once you find the SWF, you can hover over it to see its URL and confirm that it ends in .swf.
* Right-click the asset and select Copy > Copy link address.
 
If you know your game is Flash but still can't get it to work, check the [[Flash Curation]] page for more detailed info on specifically Flash games. If all else fails, ask away in #curator-lounge on our Discord and we'll try to solve the issue together.
 
=== Other Methods for Obtaining Game Source URLs ===
 
If you're having a hard time finding the game's source this way, or just desire a more convenient method, additional options are available.
 
'''Option 1:''' Press Ctrl+U on the page the game is embedded on to open its source HTML file. Press Ctrl+F to open the search bar, then type in ".swf". You'll likely come across a link directly to the game's SWF source file., which you can copy and save for later. '''Be careful of red herring SWFs!''' Use common sense when finding SWFs this way, as some pages may embed multiple SWFs at once, only one of which is the actual game file. Kongregate notoriously embeds a nearly empty SWF named <code>konduit</code> into each game's HTML page instead of the game's source SWF, making it impossible to find the link using this method.
 
'''Option 2:''' Open Developer Tools, but instead of clicking on the Network tab, click on the Elements tab instead. Use Ctrl+F just like with Option 1 to find and copy the link to the game's source file. This is useful when neither of the above options work, especially when attempting to find [[Flash Curation#Flashvars|flashvars]].


See, Flashpoint is more than just a file and a program to play it. Flashpoint's underlying tech is actually a combination of three programs working in parallel - a '''web server''', a '''redirector''' and a '''launcher'''. A web server is what the internet works on; computers around the world run web servers to host you when you visit a website. The entire internet runs on these web servers. When you open a page to, for example, YouTube, your computer is talking to a web server. Flashpoint runs a web server on your local computer. The second component is the '''redirector''', which allows us to change where the web traffic from a particular application goes. And, unless you've never used Flashpoint, you've already used our Flashpoint '''Launcher'''.
=== Wayback Machine ===


These three techs work together in order to, in as basic terms as possible, '''pretend to be the internet'''. See, we need to do a lot of things to preserve Flash (and other kinds of) games:
Sometimes a game will not be available on its original website anymore, either because it was removed from the site or because the site shut down completely. But in many cases, these games can be recovered using the [https://web.archive.org/ Wayback Machine]. See [[Downloading from Wayback]] for more info and tips.


* Pass sitelocks. Some games will only run properly if they can detect they're on the proper internet.
=== Non-Flash Games ===
* Load resources. Some games will try to load resources directly from the internet, and fail if they can't.
* Emulate servers. Some games will try to talk to servers (an example is Happy Wheels loading custom levels). This is impossible to do without a proper server.


You can hack SWFs on a case by case basis if you want, but Flashpoint is a ''preservation project'' - we're trying to keep the games in as an intact state as possible, for historical and practical reasons. For this, we use this technique of pretending to be the internet. A combination of our 'fake' internet and a program designed to redirect our software to talk to this fake internet is our approach; we can keep copies of websites on the local hard drive, and point programs at this 'fake internet' to trick it into believing it's talking to the real internet. Using our fake internet to run web games from is the best approach, thanks to being able to naturally avoid all three of the problems above. With that said, I'm going to outline below, step by step, how it works.
If a context menu that mentions Adobe Flash Player doesn't appear when right clicking the game canvas, it's probably not a Flash game. Don't worry, we got you covered! Try viewing our tutorials specifically tailored for other [[Platforms]] like Shockwave or HTML5.


* Flashpoint starts, alongside our three apps:
== Generating Content Folders with cURLsDownloader ==
** The launcher, for the player to interact with.
** The server, which is hosting our fake internet.
** The redirector, which can point programs at our fake internet.
** (It is also worth noting that our software changes ''proxy settings'' so that we can check all the computer's traffic; we can't redirect if we can't check all traffic for the apps we want to redirect.)
* The player picks a game to launch.
** The launcher starts up the program to play the Flash game (in this case, we'll say it's the Adobe Flash Player Projector - a single window to run an SWF file, hereafter referred to as the ''projector'') and it passes along a web address; this is where we're hosting the game on our fake internet.
** The projector tries to talk to the real internet, but the redirector catches it in the act, and says "hey, use our fake internet instead, it's better and has hot chicks".
** The projector agrees, and uses the fake internet. It says hello to our fake internet and asks for the web address.
** The fake internet looks inside its local files for the web address in question. This is in Flashpoint's "Server/htdocs" directory, with subfolders for web addresses and files further along in more folders.
*** If we're talking about Flashpoint Ultimate, the file will already be there, and it'll pass the file along to the projector.
*** If we're talking about Flashpoint Infinity, our fake internet will check if the file is there, and pass it along if it already is, or download it if it isn't, then pass it along.
** The projector loads the file, and you can play it. Hooray!
*** In the case of a game that has a sitelock, as long as it is on the right address, the fake internet looks no different to it than the real internet. Therefore, if you put it in the exact right spot that it thinks it needs to be, it'll bypass the sitelock without a fuss. It's the same deal with extra resources; as long as the files are on the fake internet where the game expects them to be on the internet, it'll just work.


To summarize, we're hosting a fake internet inside our Flashpoint file directory on our own computer, and using a combination of all the software at hand, the software used to play games by talking to the internet is redirected to our fake internet hosted from our hard drive, and loads games from there.
If you've followed the tutorial up to this point, you should have copied this link to the SWF for Interactive Buddy:


== Setting Up Our Software ==
https://uploads.ungrounded.net/218000/218014_DAbuddy_latest.swf?123
 
Flashpoint calls files from a file directory created from the URL of a game, packaged into a folder called '''content''' for each curation. Instead of creating a content folder manually, though, we can use a tool called cURLsDownloader to do it automatically.
 
* cURLsDownloader should be in your Flashpoint Infinity folder > Utilities > cURLsDownloader (if you have the component downloaded in the Installer.)
* Open cURLsDownloader and paste your game URL into its input.
* Select Option 1 to grab the SWF file.
* cURLsDownloader will automatically download the SWF and create a content folder for Flashpoint, located in its Downloads folder. Use option 1 when finished if it detects a broken filename, which will very likely fix it.
 
We'll come back to this Downloads folder later to move it to its proper place.
 
== Curating with Flashpoint Infinity ==
 
[[File:LaunchCommandMatchesContent.png|thumb|What your curation should look like when you're finished. Note how the Launch Command matches the Content Files. For details on the other fields see the [[Curation_Format#List_of_Metadata_Fields|Curation Format page]] ]]
The expected way to curate is to use the '''Curate Tab''' in Infinity. This needs to be turned on by toggling '''Enable Editing''' in the config menu. First, take a look at our [[Curate Tab|visual Curate Tab guide]]. Next, open the Curate tab, then click the New Curation button to see a list of fields to fill in. These are the most important ones:
*'''Title:''' A game's title distinguishes it from other games. Name it "Interactive Buddy" or "Test Game" or anything you like, it doesn't matter right now.
*'''Platform:''' The framework which the game runs on. This also determines where the game goes inside our database, which is split into several platforms (Flash, Shockwave, Unity, etc). When using Infinity for testing purposes, this isn't massively important, but for SWF files, Flash should be selected for the Platform field.
*'''Application Path:''' This determines what piece of software is used to start up the file we specify. In this case we're using a single, simple SWF, so we'll use the Flash Player Projector; in the current version of Infinity, this is listed as "FPSoftware\Flash\flashplayer_32_sa.exe", and is selected by default.
*'''Launch Command:''' Tells Flashpoint the URL of either the game's source file or the page it is hosted on. Flashpoint looks for this file on the user's storage drive, and runs the file to start the game.
 
To summarize, the Launch Command of a game is most often the URL of its source file. However, '''be extremely careful''' about the beginning of this game's URL; it uses HTTPS instead of HTTP. Flashpoint can't handle using HTTPS, and will download assets from the live Internet instead of from its fake Internet server, which can lead to a game going off the web later and not working in Flashpoint when that happens. To summarize, '''no matter the URL, always use http:// at the beginning of any Launch Command, NO EXCEPTIONS.'''
 
To add the content you generated earlier using cURLsDownloader, click the "Open Folder" button at the bottom of your curation and you should see a "content" folder. Move all of the folders from cURLsDownloader's "Downloads" folder into this "content" folder, and then click the "Refresh Content" button.
 
Take a look at the image to the right to see how your tutorial curation should look. If any field is highlighted in yellow, it's a warning; take another look at your own curation and see what's wrong. Curations of your own should have as much metadata filled in as possible, but the fields mentioned above ensure the game will work in Flashpoint. You can fill in the rest of the fields if you like, but it's not necessary right now.
 
Once you're confident your curation looks good, click the "Run" button next to the "Open Folder" button to test the game and you should see Interactive Buddy pop up.


To actually rip games from the internet, we are gonna need some software. This guide will be purely curating Flash games; if you want to curate something a little more complicated, it'll need more than this guide. This is just meant to show you how Flashpoint works at a base level; you can build on this knowledge later if you need to on other tutorials.
=== Using MAD4FP ===


With that said, you will need some extra software:
MAD4FP (Multi-Asset Downloader for Flashpoint) allows for automatically downloading game assets. It can download content files directly into your curation's content folder and create the proper folder structure automatically. For more information, see [[MAD4FP]].


* Flashpoint Core. This is a version of Flashpoint that only has a handful of games; it's mainly meant for adding, testing and just generally playing around with the platform. You can usually find a link to it [http://bluemaxima.org/flashpoint/downloads/ at the bottom of the Downloads page]. You can use another Flashpoint distribution, like Infinity, but it can be annoyingly easy to break Flashpoint in the middle of this; at least Core can be used as a disposable platform that you can just re-extract if something goes wrong.
=== Using fpcurator ===
* If you're doing simple, one file SWF games, you can make do with a modern version of a browser like Google Chrome. Google Chrome has a built in network monitor that we can use to find and grab individual SWFs, and sometimes multi-asset titles with low amounts of resources.


There are more tools that you can use, but since we're not dealing with multi-asset games yet, we're just gonna work with these two for now. Download Flashpoint Core, extract it to your hard drive, run it via the usual shortcut, and make sure that the included Flash game plays properly before you continue.
fpcurator is inside Infinity's Utilities components and allows for easily creating submissions. The common use is to paste urls that contain the games and press the "Curate" button to have them generated in the default folder for curations; if you are already using Flashpoint, press the "Scan For New Curations" button after that.


== Grabbing Our First Game From The Internet ==
When a game is not multiasset and its website is more compatible with the tool (those can be checked at the utility's "sites" subfolder), your work is usually reduced to applying the proper [[Tags]] and a logo/screenshot.


We're going to start really simple; we're going to curate a game that's a single SWF file, has no sitelock, and is just easy to get along with.
Congrats! You've successfully made a curation. Now let's see how to deal with more complex games.


[https://www.newgrounds.com/portal/view/218014 Here's the link]. Yep, it's Interactive Buddy. We already have it (and you should always check the Game Master List before you curate something) but it works good as a tutorial. If you're using Google Chrome, you might need to enable Flash to get it to play (just clicking on the middle of the screen and clicking 'Enable Flash' in the top left should be enough. It's worth noting that you can't do this tutorial if you have the Newgrounds Player enabled.)
== Sitelocks ==
[[File:AndkonSitelock.png|thumb|The sitelock telling you to go to Andkon Arcade, despite the game already being on Andkon Arcade.]]
Some Flash games will check the domain the game is being hosted on, and "lock" the game from being played if it's not on the correct site, called a sitelock.  


Now, if you're using Google Chrome, press F12, and don't panic at the overwhelming panel that just showed up on the right side of the screen. We only need to focus on a couple of things going on with this. At the very top of this panel, you should see a tab called "Network"; click it. This panel lets us see what is loading on the page in real time as it loads. It should be on 'All' by default, which *might* work, but thankfully, Chrome makes this easy for us by letting us filter files that are 'abnormal' by clicking the "Other" tab on the fourth row down. Once you have the Network tab open and Other highlighted, click the Refresh button on your browser.
This can even occur, though very rarely, on the original site where the game was hosted, as is the case with [http://andkon.com/arcade/adventureaction/monsterslayers/ Monster Slayers]. Click this link and try to play the game; your result will be the image on the right. Ironically, despite the game already being hosted on andkon.com, it'll activate its sitelock and tell you to go to Andkon Arcade. Try to find and download the SWF using the method described in the previous section.


You'll probably see a fair few weird entries there, but if you hover your mouse over each entry on the list, you'll get a full URL of each file as a small tooltip. There's one in particular you're looking for: here's a clue, the URL will have "swf" somewhere close to the end. You can also look at the "Size" column if this is your first time loading the file; it'll probably be a lot bigger than most other things on the page. Once you have this file, right click on it, and click "Open in New Tab". You should be prompted to save the SWF somewhere; do so, somewhere that you remember where it is.
You should find this source URL:


== Moving Our Game Into Flashpoint ==
http://andkon.com/arcade/adventureaction/monsterslayers/monsterslayers.swf


Congrats, you just downloaded your first SWF. There's more to it than this though, don't celebrate yet. Go to where you saved that file, and copy it (right-click in Windows, hopefully you know this by now). Navigate to where you extracted Flashpoint Core, and go into the Server folder, then the htdocs folder.
This sitelock is due to Andkon's main domain changing to "andkon.com", when it used to be "arcade.andkon.com". Therefore, changing the "andkon.com" in the URL to "arcade.andkon.com" will give us a Launch Command that bypasses the sitelock:


Time for a bit of an explanation. This 'htdocs' folder is the root of our fake internet, the very peak of it, and the folders that go down are fake 'websites' that are hosted in Flashpoint when it launches, and for our software to talk to. We need to keep an eye where we paste any files into this folder, so that we can efficiently put our game into Flashpoint later on. With that said, you should already have an 'uploads.ungrounded.net' folder in the htdocs folder. For now, let's go into that folder, then paste the SWF we just downloaded straight in there.
http://arcade.andkon.com/arcade/adventureaction/monsterslayers/monsterslayers.swf


Now we can go back up two directories and launch Flashpoint Core. In Flashpoint Core, you should see, in the bottom left, a "New Game" button that you can click, and get a list of things on the right. There are four things we need to pay attention to at this very moment:
This particular URL uses http:// instead of https://, but '''always make sure the Launch Command uses http://''' regardless.


* The title. We need to be able to tell it apart. Name it "Interactive Buddy" or "Test Game" or anything you like, it doesn't matter at this point.
Try to create a new curation by downloading the SWF from the top URL using cURLsDownloader, and setting the bottom URL as the Launch Command. Use the Curate tab to test your game; Flashpoint should bypass the sitelock and allow you to play Monster Slayers, just like Andkon used to.
* The Platform. This determines what XML this goes into (our database is split into different platforms - Flash, Unity, etc.). For the purpose of using Core for testing purposes, this isn't massively important, but you need to select one for this to work, so just select Flash.
* The Application Path. This determines what piece of software is used to start up the file we specify. In this case we're using a single, simple SWF, so we want to pick out the Flash Player Projector; in the current version of Core, this is listed as "FPSoftware\Flash\flashplayer_32_sa.exe", so pick that.
* The Launch Command.


There's the big one. We need to talk about URLs now. On the normal internet, a URL, for example, will look like this:
It's important to use correct Launch Commands and proper content folders for every curation you make (even if you're curating a non-sitelocked SWF), to ensure that all the game's assets are loaded exactly as they would be on the real Internet, without running into any possible sitelocks on the way (even if the game appears to be playable outside of Flashpoint).


https://uploads.ungrounded.net/218000/218014_DAbuddy_latest.swf?123
== Using cURLsDownloader for Multi-Asset Games ==


This URL is split into a few sections.
Up until now, we've only curated single-asset SWF files. However, many web games were made at a time where downloading one large file was intensive on Internet speeds and took longer than it should. This meant lots of games were split into several, smaller assets so the overall game loaded faster. Whether these games load all of the assets when the game first starts up or intermittently as you play the game depends on how they were programmed, making curation of multi-asset games more difficult than single-assets.


* "https://" < this is what determines what protocol is used. For those of you who don't want an internet lesson, this will pretty much always be a variation of http:// or https://
Let's check out a multi-asset game called [https://www.kongregate.com/games/struma/gateway-ii Gateway II]. Here's the link to the main SWF of the game:
* "uploads.ungrounded.net" < this is a domain; basically a folder that determines where something is on the internet.
https://chat.kongregate.com/gamez/0000/3268/live/gateway_2.swf?kongregate_game_version=1581667106
* "/218000/218014_DAbuddy_latest.swf?123" < this is the rest of the domain; folders leading down to the file, which will load.
Try curating this SWF as described above and testing it in Flashpoint with the Run button. You'll only get to the language select screen before the game freezes once you pick one.  


We need to create a URL inside our fake internet for our Flashpoint Core to load in the same way, so let's put one together, piece by piece.
Select the Logs tab in Flashpoint, then look near the bottom of the log. You should see a line with "200 HTTP/1.1" followed by a directory to the main SWF, followed by one or more lines with "404 HTTP/1.1" followed by directories to additional assets.


The first part is the "https://", however, I need to say this here. Due to a lack of technology capable of doing the job, using a "https://" in the Launch Command will always, '''always''' load files from the real internet instead of from the fake one. This cannot be avoided, this is an easy mistake to make, and it sucks, but it must be noted and checked for. We can end up accidentally loading a game from the internet, seeing it 'working' in Flashpoint, and then have a surprised Pikachu face six months later when the site goes down and suddenly the game doesn't work. To summarize, '''always use http:// at the beginning of a launch command, NO EXCEPTIONS.'''
This means the game was calling for one or more assets that it didn't have offline, making the game freeze because it failed to load a required asset. Thankfully, Flashpoint can handle these assets as long as they're downloaded properly.  


http://
Once again, instead of manually downloading lots of assets, we can use cURLsDownloader to save time and effort.


The second part is our domain. On the real internet, this is almost impossible to visualize; top level domains are talked to via DNS, which redirects you to the correct server. Thanks to the way Flashpoint works, though? It's a lot more simple than that. Our domains are all contained in the first folder of htdocs; all of those folders you saw earlier are domains. In our case, we moved our SWF into the 'uploads.ungrounded.net' folder; so that'll be the next part of our URL.
'''Option 1:''' Download the assets called by the game as you test it in Flashpoint Infinity.
# Click the Copy Text button in the top-right of the Logs tab.
# Paste the results into a text file and remove every line except for ones beginning with "404 HTTP/1.1". Remove that section from each line along with anything before it such as timestamps, then add "http://" to the beginning of each line.
# Save the text file and drag it over cURLsDownloader.
# Wait for cURLsDownloader to finish fetching assets. Use option 1 when finished if it detects broken filenames, which will very likely fix them.
# Move the contents of the Downloads folder in cURLsDownloader to the content folder of your curation.
# Test your game with the Run button. If anything fails to work as it should, look for more lines beginning with "404 HTTP/1.1" in the Logs tab and repeat this process.


http://uploads.ungrounded.net
'''Option 2:''' Download all the assets that the source page of a game loads as you play it on the live Internet (but some assets downloaded won't be part of the game).
# Once again, press F12 to open your browser's Network viewer, then refresh the page.
# Play through your game on the Internet, loading assets as you go.
# When you're confident you've loaded all of the game's assets, click the "All" tab in the Network viewer and right-click on an asset.
# Select Copy > Copy all as cURL (cmd) and paste the results into a text file.
# Save the text file and drag it over cURLsDownloader.
# Wait for cURLsDownloader to finish fetching assets. Use option 1 when finished if it detects broken filenames, which will very likely fix them.
# Open the Downloads folder in cURLsDownloader and determine which folder contains the necessary files to play the game.
# Move the contents of your chosen folder to the content folder of your curation.
# Test your game with the "Run" button.


The third part and beyond are the subfolders inside the domain, and the file on the end. Every time you go into a folder, whether it be the domain or any subfolders in said domain, you should add a slash onto the end, like so:
When testing games, if a game lets you get through more than one level without loading another asset, you'll ''generally'' be okay to assume that there's no more assets to be found, but this is never a guarantee, and you should always test your game in Flashpoint as much as you can.


http://uploads.ungrounded.net/
== Wrapping It Up ==


This tells our fake internet to look inside the uploads.ungrounded.net folder in the htdocs folder for where it needs to go next. If we wanted to go into another folder, we would need to add the folder name on the end of the URL, followed by another slash. For example, if I wanted to go into the "59000" folder? It would look something like this:
Once you're sure you've gotten a game working in Flashpoint, it's time to add the additional parts of any curation. The [[Curation Format]] page tells you how curations are laid out in order to add it to the master build of Flashpoint with as much information as possible. '''You should read the [[Curation Format#List of Metadata Fields|List of Metadata Fields]] section specifically; there are more than a few fields that need to be filled in on each curation this tutorial didn't specifically cover.'''


http://uploads.ungrounded.net/59000/
When you've created a proper curation in the Curate tab, click the "Export" button at the bottom of your curation, which will save a .7z archive of the curation ready to be imported into the master build. Name it something relevant (typically the name of the game), and save it wherever you'll remember it.


In our case, at this moment? We don't want to do that; our SWF that we downloaded and copied in the previous steps is just in uploads.ungrounded.net. When we're in the folder we need to be in to get to our SWF, all that's left is to put the file name on the end of the launch command. So our launch command, assuming you didn't rename the SWF you downloaded before (good behaviour, you'll see why in a bit), your launch command should look like the line below.
Note that your [[Save Data Locations|save data]] for the game will not be included in your curation.


http://uploads.ungrounded.net/218014_DAbuddy_latest.swf
Once you have your .7z ready, follow the instructions below to make sure it gets added to Flashpoint.
{{:Submitting a Curation}}
== See also ==
* [[Flash Curation]]


Once you have your full launch command, paste it into the Launch Command box. Once you have a title, platform, application path and launch command filled in, click the tick in the top right of the edit dialog, and the box containing the title should appear in the games list, in which case you should be able to just double click said box to launch the game. If you do so and see Interactive Buddy after a couple of seconds? Congrats, you did it.
<noinclude>
[[Category:Curation Guides]]
</noinclude>

Latest revision as of 10:33, 2 May 2024

This page is a basic tutorial on how Flashpoint works and how to curate games for addition to Flashpoint. See the Content Patches page for information on modifying and adding assets to games already in Flashpoint.

Additionally, please read the Curation Format page for a more detailed explanation on what a curation should look like before submitting.

If you would like an overview, check out this video tutorial: https://www.youtube.com/watch?v=Im7tlzhd4fg (This video is very outdated, use it as a general introduction to the idea than a full tutorial.)

How Flashpoint Works

Flashpoint is more than just a program to play files; rather, it's a combination of two programs working in parallel:

  • a web server, which hosts game files from an internal or external drive and pretends to be the original Internet source the games ran off of,
  • and a launcher, the user interface to select and play games from.

Flashpoint itself also comes in two primary versions:

  • Infinity, the version that downloads games and animations from a server as you play or view them,
  • and Ultimate, the gigantic version with every game and animation included and ready for offline play and viewing.

Infinity will download files as you play games that request them, while Ultimate knows the files are already there. Both make the files believe they're being ran on their original source. This has numerous benefits, the two most important being bypassing sitelocks and supporting multi-asset games. The How Flashpoint Works article provides more detail on this topic. Before we understand how Flashpoint handles those cases, though, let's walk through the simplest case possible: curating a single-asset SWF file.

Setting Up Our Software

To download game files from the Internet, you'll need:

  • Flashpoint Infinity, version 12 or later; curating in previous versions or Ultimate may run into compatibility problems.
  • A modern web browser such as Chrome or Firefox, which have a built in Network monitor that we can use to find and grab individual SWFs, and sometimes multi-asset titles with low amounts of resources.
  • cURLsDownloader, found as a component in the Extras section of the Flashpoint Infinity Installer. This isn't strictly necessary, but it helps immensely; you'll see why later on.

Download Flashpoint Infinity, extract it to an internal or external drive, run it via its shortcut in the extracted folder, and make sure that the included games play properly before you continue.

Finding the Source of a Flash Game

The SWF for Interactive Buddy in Chrome's network tab; it should look similar on Firefox.

Be sure to search FPFSS, check the Not Accepted Curations page, and search the Curations channels in the Flashpoint Discord server before settling on a game! Otherwise, you might waste time and effort to save a game that's already been saved.

As a tutorial, we'll start by curating the simplest type of Flash game: a single SWF file that isn't sitelocked, specifically Interactive Buddy. You might need to enable Flash in your browser to get it to play (this tutorial won't work if you're using another player such as the Newgrounds Player).

  • If you're using Chrome or Firefox, press F12 to open the Developer Tools and click on the Network tab. This shows us every asset that loads on the page in real time.
  • You can filter miscellaneous types of assets such as Flash files by clicking the Other tab within the Network tab.
  • Refresh the page to find that a few assets loaded. The game file has an extension of .swf, and has a type of x-shockwave-flash in the table.
  • Once you find the SWF, you can hover over it to see its URL and confirm that it ends in .swf.
  • Right-click the asset and select Copy > Copy link address.

If you know your game is Flash but still can't get it to work, check the Flash Curation page for more detailed info on specifically Flash games. If all else fails, ask away in #curator-lounge on our Discord and we'll try to solve the issue together.

Other Methods for Obtaining Game Source URLs

If you're having a hard time finding the game's source this way, or just desire a more convenient method, additional options are available.

Option 1: Press Ctrl+U on the page the game is embedded on to open its source HTML file. Press Ctrl+F to open the search bar, then type in ".swf". You'll likely come across a link directly to the game's SWF source file., which you can copy and save for later. Be careful of red herring SWFs! Use common sense when finding SWFs this way, as some pages may embed multiple SWFs at once, only one of which is the actual game file. Kongregate notoriously embeds a nearly empty SWF named konduit into each game's HTML page instead of the game's source SWF, making it impossible to find the link using this method.

Option 2: Open Developer Tools, but instead of clicking on the Network tab, click on the Elements tab instead. Use Ctrl+F just like with Option 1 to find and copy the link to the game's source file. This is useful when neither of the above options work, especially when attempting to find flashvars.

Wayback Machine

Sometimes a game will not be available on its original website anymore, either because it was removed from the site or because the site shut down completely. But in many cases, these games can be recovered using the Wayback Machine. See Downloading from Wayback for more info and tips.

Non-Flash Games

If a context menu that mentions Adobe Flash Player doesn't appear when right clicking the game canvas, it's probably not a Flash game. Don't worry, we got you covered! Try viewing our tutorials specifically tailored for other Platforms like Shockwave or HTML5.

Generating Content Folders with cURLsDownloader

If you've followed the tutorial up to this point, you should have copied this link to the SWF for Interactive Buddy:

https://uploads.ungrounded.net/218000/218014_DAbuddy_latest.swf?123

Flashpoint calls files from a file directory created from the URL of a game, packaged into a folder called content for each curation. Instead of creating a content folder manually, though, we can use a tool called cURLsDownloader to do it automatically.

  • cURLsDownloader should be in your Flashpoint Infinity folder > Utilities > cURLsDownloader (if you have the component downloaded in the Installer.)
  • Open cURLsDownloader and paste your game URL into its input.
  • Select Option 1 to grab the SWF file.
  • cURLsDownloader will automatically download the SWF and create a content folder for Flashpoint, located in its Downloads folder. Use option 1 when finished if it detects a broken filename, which will very likely fix it.

We'll come back to this Downloads folder later to move it to its proper place.

Curating with Flashpoint Infinity

What your curation should look like when you're finished. Note how the Launch Command matches the Content Files. For details on the other fields see the Curation Format page

The expected way to curate is to use the Curate Tab in Infinity. This needs to be turned on by toggling Enable Editing in the config menu. First, take a look at our visual Curate Tab guide. Next, open the Curate tab, then click the New Curation button to see a list of fields to fill in. These are the most important ones:

  • Title: A game's title distinguishes it from other games. Name it "Interactive Buddy" or "Test Game" or anything you like, it doesn't matter right now.
  • Platform: The framework which the game runs on. This also determines where the game goes inside our database, which is split into several platforms (Flash, Shockwave, Unity, etc). When using Infinity for testing purposes, this isn't massively important, but for SWF files, Flash should be selected for the Platform field.
  • Application Path: This determines what piece of software is used to start up the file we specify. In this case we're using a single, simple SWF, so we'll use the Flash Player Projector; in the current version of Infinity, this is listed as "FPSoftware\Flash\flashplayer_32_sa.exe", and is selected by default.
  • Launch Command: Tells Flashpoint the URL of either the game's source file or the page it is hosted on. Flashpoint looks for this file on the user's storage drive, and runs the file to start the game.

To summarize, the Launch Command of a game is most often the URL of its source file. However, be extremely careful about the beginning of this game's URL; it uses HTTPS instead of HTTP. Flashpoint can't handle using HTTPS, and will download assets from the live Internet instead of from its fake Internet server, which can lead to a game going off the web later and not working in Flashpoint when that happens. To summarize, no matter the URL, always use http:// at the beginning of any Launch Command, NO EXCEPTIONS.

To add the content you generated earlier using cURLsDownloader, click the "Open Folder" button at the bottom of your curation and you should see a "content" folder. Move all of the folders from cURLsDownloader's "Downloads" folder into this "content" folder, and then click the "Refresh Content" button.

Take a look at the image to the right to see how your tutorial curation should look. If any field is highlighted in yellow, it's a warning; take another look at your own curation and see what's wrong. Curations of your own should have as much metadata filled in as possible, but the fields mentioned above ensure the game will work in Flashpoint. You can fill in the rest of the fields if you like, but it's not necessary right now.

Once you're confident your curation looks good, click the "Run" button next to the "Open Folder" button to test the game and you should see Interactive Buddy pop up.

Using MAD4FP

MAD4FP (Multi-Asset Downloader for Flashpoint) allows for automatically downloading game assets. It can download content files directly into your curation's content folder and create the proper folder structure automatically. For more information, see MAD4FP.

Using fpcurator

fpcurator is inside Infinity's Utilities components and allows for easily creating submissions. The common use is to paste urls that contain the games and press the "Curate" button to have them generated in the default folder for curations; if you are already using Flashpoint, press the "Scan For New Curations" button after that.

When a game is not multiasset and its website is more compatible with the tool (those can be checked at the utility's "sites" subfolder), your work is usually reduced to applying the proper Tags and a logo/screenshot.

Congrats! You've successfully made a curation. Now let's see how to deal with more complex games.

Sitelocks

The sitelock telling you to go to Andkon Arcade, despite the game already being on Andkon Arcade.

Some Flash games will check the domain the game is being hosted on, and "lock" the game from being played if it's not on the correct site, called a sitelock.

This can even occur, though very rarely, on the original site where the game was hosted, as is the case with Monster Slayers. Click this link and try to play the game; your result will be the image on the right. Ironically, despite the game already being hosted on andkon.com, it'll activate its sitelock and tell you to go to Andkon Arcade. Try to find and download the SWF using the method described in the previous section.

You should find this source URL:

http://andkon.com/arcade/adventureaction/monsterslayers/monsterslayers.swf

This sitelock is due to Andkon's main domain changing to "andkon.com", when it used to be "arcade.andkon.com". Therefore, changing the "andkon.com" in the URL to "arcade.andkon.com" will give us a Launch Command that bypasses the sitelock:

http://arcade.andkon.com/arcade/adventureaction/monsterslayers/monsterslayers.swf

This particular URL uses http:// instead of https://, but always make sure the Launch Command uses http:// regardless.

Try to create a new curation by downloading the SWF from the top URL using cURLsDownloader, and setting the bottom URL as the Launch Command. Use the Curate tab to test your game; Flashpoint should bypass the sitelock and allow you to play Monster Slayers, just like Andkon used to.

It's important to use correct Launch Commands and proper content folders for every curation you make (even if you're curating a non-sitelocked SWF), to ensure that all the game's assets are loaded exactly as they would be on the real Internet, without running into any possible sitelocks on the way (even if the game appears to be playable outside of Flashpoint).

Using cURLsDownloader for Multi-Asset Games

Up until now, we've only curated single-asset SWF files. However, many web games were made at a time where downloading one large file was intensive on Internet speeds and took longer than it should. This meant lots of games were split into several, smaller assets so the overall game loaded faster. Whether these games load all of the assets when the game first starts up or intermittently as you play the game depends on how they were programmed, making curation of multi-asset games more difficult than single-assets.

Let's check out a multi-asset game called Gateway II. Here's the link to the main SWF of the game:

https://chat.kongregate.com/gamez/0000/3268/live/gateway_2.swf?kongregate_game_version=1581667106

Try curating this SWF as described above and testing it in Flashpoint with the Run button. You'll only get to the language select screen before the game freezes once you pick one.

Select the Logs tab in Flashpoint, then look near the bottom of the log. You should see a line with "200 HTTP/1.1" followed by a directory to the main SWF, followed by one or more lines with "404 HTTP/1.1" followed by directories to additional assets.

This means the game was calling for one or more assets that it didn't have offline, making the game freeze because it failed to load a required asset. Thankfully, Flashpoint can handle these assets as long as they're downloaded properly.

Once again, instead of manually downloading lots of assets, we can use cURLsDownloader to save time and effort.

Option 1: Download the assets called by the game as you test it in Flashpoint Infinity.

  1. Click the Copy Text button in the top-right of the Logs tab.
  2. Paste the results into a text file and remove every line except for ones beginning with "404 HTTP/1.1". Remove that section from each line along with anything before it such as timestamps, then add "http://" to the beginning of each line.
  3. Save the text file and drag it over cURLsDownloader.
  4. Wait for cURLsDownloader to finish fetching assets. Use option 1 when finished if it detects broken filenames, which will very likely fix them.
  5. Move the contents of the Downloads folder in cURLsDownloader to the content folder of your curation.
  6. Test your game with the Run button. If anything fails to work as it should, look for more lines beginning with "404 HTTP/1.1" in the Logs tab and repeat this process.

Option 2: Download all the assets that the source page of a game loads as you play it on the live Internet (but some assets downloaded won't be part of the game).

  1. Once again, press F12 to open your browser's Network viewer, then refresh the page.
  2. Play through your game on the Internet, loading assets as you go.
  3. When you're confident you've loaded all of the game's assets, click the "All" tab in the Network viewer and right-click on an asset.
  4. Select Copy > Copy all as cURL (cmd) and paste the results into a text file.
  5. Save the text file and drag it over cURLsDownloader.
  6. Wait for cURLsDownloader to finish fetching assets. Use option 1 when finished if it detects broken filenames, which will very likely fix them.
  7. Open the Downloads folder in cURLsDownloader and determine which folder contains the necessary files to play the game.
  8. Move the contents of your chosen folder to the content folder of your curation.
  9. Test your game with the "Run" button.

When testing games, if a game lets you get through more than one level without loading another asset, you'll generally be okay to assume that there's no more assets to be found, but this is never a guarantee, and you should always test your game in Flashpoint as much as you can.

Wrapping It Up

Once you're sure you've gotten a game working in Flashpoint, it's time to add the additional parts of any curation. The Curation Format page tells you how curations are laid out in order to add it to the master build of Flashpoint with as much information as possible. You should read the List of Metadata Fields section specifically; there are more than a few fields that need to be filled in on each curation this tutorial didn't specifically cover.

When you've created a proper curation in the Curate tab, click the "Export" button at the bottom of your curation, which will save a .7z archive of the curation ready to be imported into the master build. Name it something relevant (typically the name of the game), and save it wherever you'll remember it.

Note that your save data for the game will not be included in your curation.

Once you have your .7z ready, follow the instructions below to make sure it gets added to Flashpoint.

Submitting a Curation

Submissions are uploaded in the Flashpoint Submission System, which requires you to join our Discord server first. An explanation of how the site works is available here.

If you have any questions, ask in #curators and a Curator will answer them.

After you have uploaded your curation to the website, a Curator will check it. This can take some time, so please be patient. You will be pinged in #fpfss-notifications about whether or not your submission was approved, and if any changes need to be made.

Once your first submission is approved, you'll be given the Trial Curator role. That means you will be able to submit more curations and upload bigger files.

Congratulations! Your submitted game/animation will appear in the next update to Flashpoint.

See also