A PHP Puzzle

Here’s an amusing little puzzle for those of you visiting my site who also happen to know a little PHP. I came up with this myself, during some short span of time when I wasn’t working on my novel or working at my paying job. Look at the PHP code below and determine what it will write as output. I tested the code on a 5.3 server, but I believe it will produce the same output on more recent versions of PHP.

If you get the right answer, don’t post it in the comments. Instead, post the first name of your favorite actor associated with the answer, and I’ll know you got it. If you can get the answer without running the code or looking at a reference book, then you get extra points. The points aren’t worth any more than the points on Whose Line Is It Anyway?, but they’re yours if you earn them, and you can do whatever you want with them. 🙂

The Puzzle Code

if ((1 == TRUE) && (1 !== TRUE)) {
	$x = 0;
} else {
	$x = 1;
$x.=$x. ((1 . 0) - (3.0));
echo $x;

Thanks for coming by my little corner of the webiverse.

Role-Playing and Writing: the Storytelling Intersection

Hello, friends. This time, we have a guest post from Coyote Kishpaugh, co-author of The Order of the Four Sons series. He will tell us about the connection between role-playing games and writing fiction. As I mentioned last time, when his co-author, Lauren Scharhag, graced us with her guest post on creating fantasy worlds, I received an advance review copy of the first book of the O4S series (book one is out now as of this writing), and I recommend it to anyone who likes fantasy or horror or other forms of speculative fiction. It also has a touch of science fiction, crime and history. I’m looking forward to further journeys in this universe they have jointly created, which has many similarities to our own, but tons of differences too. I hope you’ll give the series a try. Links to book one are in Lauren’s guest post, the link to which is at the bottom of this post.

Before we hear from Coyote about his experience with rpgs and fiction writing, let’s get to know him a bit. I asked him and Lauren both the same set of questions, and they agreed to answer them without consulting each other about their answers. Fun, fun, right? Coyote’s answers are below. A link to Lauren’s answers and her guest post are at the end of this post, so you can easily compare to see how close their answers are. Continue reading “Role-Playing and Writing: the Storytelling Intersection”

JavaScript Animated D6 Dice Roller Code Released to Public Domain

The title says it all. The JavaScript Animated D6 Dice Roller was previously made available under open source licenses, but has now been released to the public domain via a CC0 Public Domain Dedication. If you have the urge to include an animated D6 dice roller in any JavaScript-based game, for any purpose, commercial or non-commercial, then grab a copy of the public domain JavaScript Animated D6 Dice Roller package and let it do the work for you! Okay, you have to install it and write code that makes calls to it, so look for the links to the tutorial and documentation on the download page. Continue reading “JavaScript Animated D6 Dice Roller Code Released to Public Domain”

Phantom’s Bane Online

The Eposic text mini-adventure Phantom’s Bane is back online as part of the Eposic archive. I’m not planning to expand or improve the game, but you’re welcome to leave comments here about it if you like.

Phantom’s Bane is coded entirely with HTML and JavaScript (so make sure you have JavaScript turned on). It uses iframes for asynchronous remote server access as needed. (All of the code could have been stuffed into one huge file, but it seemed better to break it out into manageable modules.)

The use of cookies allows you to save a game in progress. Since four different domains all are hosted on the Eposic web server, you can actually save up to four different characters, one per domain name, if you want. The links to the different domains are listed on the first page of the documentation. If you save the game and want to play it again later, be sure to visit the game on the same domain as the one you were on when you saved it.

Proudly powered by WordPress | Theme: Baskerville 2 by Anders Noren.

Up ↑