Click the arrow to download the file PS3.3.zip (21 KB).
Extract the archive to any convenient place on a local drive. You’ll end up with a directory named PS3.3 containing all the files you need.
Keep a backup of the PS3.3 directory. You’ll need a fresh copy for every new Perlenspiel project.
Email suspected bugs, ideas and comments to bmoriarty [at] wpi [dot] edu.
- Version 3.3.2 (2019.01.27)
- By popular demand, PS.audioFade() has been added to Perlenspiel's Audio API. It allows a currently playing audio channel to be linearly faded up or down, with precise control of the starting volume, ending volume and duration of the effect. An optional callback function can be called when the effect is complete. Refer to the command's API documentation for details.
- Version 3.3.1 (2019.01.22)
- Issues related to the new audio engine have been tracked down and fixed. In particular, PS.audioPlayChannel() now always plays the specified channel from the beginning; that is, it either starts or restarts playback. If PS.audioPlayChannel() is called when the specified channel is already playing as the result of a previous call, the first playback instance will immediately stop, and the channel will start playing again from the beginning. Use PS.audioPause() to pause or unpause a playing channel, and PS.audioStop() to stop a playing channel, or reset a paused channel to its start position without playing it.
- If your project doesn't need to pause or stop sounds, or doesn't require fine-grained control of audio resources, simply use PS.audioPlay() to play your sounds. The new audio engine will automatically optimize the loading and allocation of resources.
- It is customary (and more tidy) to place custom audio files in a dedicated subdirectory. However, if you want to load or play audio files located in the same directory as the game.html file, specify the string "./" in the .path property of the second parameter of PS.audioLoad() and/or PS.audioPlay(). Refer to the API documentation of PS.audioLoad() for complete details.
- The line spacing of this Web site has been slightly increased for improved readability.
- Version 3.3.0 (2018.10.22)
- This major update addresses a number of recent and upcoming changes in the behavior and security of major web browsers, together with issues caused by the emergence of new hardware. It is intended to be backward-compatible with all previous releases of Perlenspiel 3, aside from a few possible (but unlikely) issues with the audio commands (see below). However, to fully utilize the improvements/fixes offered by Version 3.3, Perlenspiel 3 apps made prior to this release must upgrade their game.html file to the version provided in the PS3.3 Devkit.
- A new Audio API call, PS.audioPlayChannel(), allows sound designers finer-grained control over the use of loaded resources.
- All mobile browsers (and soon desktop Chrome) expect users to physically interact with a web page (by touching or clicking on it) before any audio or video will play. This is done to prevent annoying audio or video advertisements from starting up automatically and eating bandwidth. It’s a welcome anti-spam strategy, but it has the unpleasant side effect of preventing legitimate web applications (including all Perlenspiel games) from playing music or sound effects on startup. Perlenspiel 3.3 addresses this problem by eliminating the cover.html file included in earlier versions of the devkit, and displaying the cover.png image on the game.html page instead. Clicking on or touching the cover image provides the interaction required to allow audio to start immediately.
- PS3.3’s revised (and greatly simplified) game.html file allows developers the option to control the color and messaging of the cover image. If no cover.png file is present, a Perlenspiel logo (preloaded within the engine code itself) is displayed instead.
- Before PS3.3. the engine’s 60-ticks-per-second timers were synchronized to the refresh rate of the monitor displaying the browser page. Until recently, nearly all computer monitors ran at a refresh rate of 60Hz, so there were no problems. But the latest gaming monitors run at a variety of refresh rates (including 60, 72, 80, 120, 144, 180 and 240 Hz), which makes the old timers run too fast when run on some (but not all) browsers and operating systems. PS3.3 attempts to dynamically measure the actual refresh rate of the browser running it, and adjust its timers to run at (or near) 60Hz regardless of monitor speed. It works perfectly with Chrome, okay on Firefox (but only because of a well-documented browser bug), and not at all on Microsoft Edge (which flagrantly disregards the HTML5 specification and refreshes at whatever weird, inconsistent rate it wants, because Microsoft).
- Google is spearheading an initiative to encourage all Web sites to abandon the familiar old http:// protocol in favor of the (somewhat) more secure https:// protocol. If Google gets its way, Web browsers will soon begin to question and/or outright reject attempts to connect to http:// servers ... including the server that has been used to support Perlenspiel since 2010. To prevent future inconvenience and breakage, Perlenspiel 3 and its documentation are now hosted on a shiny new server at https://ps3.perlenspiel.net. The old http:// server will continue to exist, but games depending on it will soon begin to fail as Google exerts its mighty will upon the architecture of the Web. Luckily, you can easily futureproof your older PS 3.x games by replacing existing game.html files with the sleek https:// version now provided in the PS3.3 Devkit.
- Numerous small bugs, inefficiencies and bottlenecks in the engine have been addressed. Nevertheless, there will inevitably be issues with this significantly updated release. Please report anything suspicious.
The Fine Print
Perlenspiel is a scheme by Professor Moriarty (bmoriarty [at] wpi [dot] edu).
This web site and the Perlenspiel software are Copyright © 2009- Brian Moriarty.
The Perlenspiel software is provided to you “as is,” and we make no express or implied warranties whatsoever with respect to its functionality, operability, or use, including, without limitation, any implied warranties of merchantability, fitness for a particular purpose, or infringement. We expressly disclaim any liability whatsoever for any direct, indirect, consequential, incidental or special damages, including, without limitation, lost revenues, lost profits, losses resulting from business interruption or loss of data, regardless of the form of action or legal theory under which the liability may be asserted, even if advised of the possibility or likelihood of such damages.
By downloading the software from this page, you agree to the specified terms.
Perlenspiel 3.3 employs James Simpson’s Howler.js library for browser audio management, and Mathias Bynens’ String.fromCodePoint polyfill. Howler.js is Copyright © 2013-2019 by James Simpson and GoldFire Studios, Inc. The String.fromCodePoint polyfill is Copyright © 2014 by Mathias Bynens. Both are used under the terms of the MIT License.
This Web site incorporates Jan Odvárko’s JSColor color-picking widget, which is released for use by open-source projects under the GNU GPL v3 (General Public License, version 3). JSColor is Copyright © 2008– by Jan Odvárko – East Desire.