Gigantic, avoid the icebergs

Hi all, I’ll now showcase my latest creation, Gigantic.

The key in this game is to avoid the large icebergs, while hitting the small icebergs and survivors.

Passing under an ice-gate doubles your score.

Your final score is calculated based on your in game score and time taken, so it’s best to move fast.

Controls:
Left Arrow: Turn anticlockwise
Right Arrow: Turn clockwise
Up Arrow: accelerate
Down Arrow: decelerate

Play it now: http://ux-soft.com/fb/apps/gigantic/ (Applet, note: hosted on facebook, cannot be played without logging in)

Screenshots:

http://ux-soft.com/fb/apps/gigantic/GiganticSS1.png

http://ux-soft.com/fb/apps/gigantic/GiganticSS2.png

Please provide feedback, thanks! :wink:

You should warn that it’s a facebook game and can’t be played without logging in.

Got 60k points, it was a bit too random to my liking. Either the boat went too quick or it steered too slowly to be based upon skill.

Mike

true; i’ll add that in the topic. thanks for your feedback :slight_smile:

also, if it’s going too quick, use the down arrow to slow down, use the up arrow to accelerate.

Finally! Someone who can explain to me how to put a darn applet on Facebook!! So…how did you do it??

EDIT: The game goes a bit too fast, even with the down arrow pressed.

First step is to get the OAuth dialog presented. This is done on the server side with the following php:


	$app_id = '204109199613610';

	$canvas_page = 'http://apps.facebook.com/gigantic_game/';

	$auth_url = "http://www.facebook.com/dialog/oauth?client_id=" 
	. $app_id . "&redirect_uri=" . urlencode($canvas_page) . "&scope=publish_stream";

	$signed_request = $_REQUEST["signed_request"];

	list($encoded_sig, $payload) = explode('.', $signed_request, 2); 

	$data = json_decode(base64_decode(strtr($payload, '-_', '+/')), true);

if $data[‘user_id’] is empty, the user has not allowed OAuth to authenticate the app, therefore you do this:


if (empty($data["user_id"])) {
die("<script> top.location.href='" . $auth_url . "'</script>");
}

As for embedding the applet, you do the following:


	<applet code="com.uxsoft.gig.Game"
			archive="http://ux-soft.com/fb/apps/gigantic/f.jar?v=akjafsdkajtk"
			style="width:700px;height:500px;margin-left:auto;margin-right:auto;"
			id="pageapplet"
			name="pageapplet">
			You do not seem to have Java enabled. Java must be enabled to play this game.
			<param name="fb_key" value=<?php echo '"' . $token . '"'?> />
	</applet>

If you need anymore help, please ask

Wait…where do I put all this? In the Facebook designated code areas or on my own web server and have an iFrame?

your own web server. link the iframe to the url box provided in app settings.

Thanks. And 1 more thing: is all that PHP necessary? I don’t have PHP installed on my web server, I just want a basic applet on the screen that can be playable by anyone.

you need OAuth to authenticate your app before anyone can use it. However, if you aren’t going to use Facebook API requests, just add the applet code into the iframe and link it to the app.

Alright thanks! :slight_smile:

no problem.