Recent posts by Titch on Kongregate

Flag Post

Topic: Technical Support / Level Up Crashing Browser

Originally posted by Ezza205:

this is happening not because of your browser or anything to do with your computer, but it is a fault in the game. Titch (the developer of level up) said it himself that it was a fault in the game. “I’m trying to fix the bug. Since I’m not an Adobe engineer and didn’t design the version of flash that makes my game crash. This isn’t very easy.”, said Titch in the Level Up game description. i suggest just waiting for someone to fix it. i know it is a bit frustrating because now you can’t get the “Have a nice flashback!” badge to complete the pixel pack award but i’m sure it’ll be fixed soon. =)

That’s not entirely true. I can’t future proof my game against changes to Flash or the KongAPI. Especially not when I can’t see how the KongAPI work under the hood. Level Up runs fine of every other site (and in fact on Kong when I turn the API connection off), which suggests the problem is related to how that is coded and not the game.

In short, I’m trying to fix it, but it might not necessarily be my fault. Either way it’s my job to try and do something about it, even if I fail :/ Most signs seem to be pointing to some kind of security violation. But it shouldn’t crash Flash that badly.

 
Flag Post

Topic: Technical Support / The game Level Up problem

Hey, developer…guy thing here. I’m looking in to the problem. Try to fix it as soon as possible. I’ve not looked at the code for like five months and I now have a full time job as an AS3 coder, so I hope you’ll understand why I’m not already all over it already. Hopefully I can sort it out over the weekend.

As far as I can tell the crash seems directly related to Flash 10.1 Since it causes the whole browser to crash for me it’s kinda tricky getting bug reports. Anyway, yeah. Sorry to leave y’all hanging. I only found out about this when the bug reports started flooding on on Thursday night.

 
Flag Post

Topic: Game Programming / Kongregate API Issue (Wrapper Class, Services returns null)

Originally posted by UnknownGuardian:

Maybe this line should be moved before you log with flixel.

API.services.connect();

Which should be moved to right after you define API, like this:

API = event.target.content;
API.services.connect();

That might work…

This is how I had it originally. Back then I couldn’t even work out why it was breaking, because connect would fail and it would STOP THE ENTIRE FUNCTION and I wouldn’t get any more log messages.

Originally posted by hellijerry:

As an aside, is there any reason all flixel games use pixel art? I can’t think of any technical reason, and couldn’t see anything on the website.

Not all Flixel games use pixel art (Paranormal Puzzle Society and the ZP Contest Entry used normal renders) , but the engine is a blit engine rather than a vector based one, so it suits a little better. I think a lot of the current Flixel Developers come from TIGSource, where everyone generally like Pixel art.

 
Flag Post

Topic: Game Programming / Kongregate API Issue (Wrapper Class, Services returns null)

I’m pretty much at my wits end over this. I’ve spent about three days uploading and testing 30+ preview versions of the script, adding extra debug outputs, adding safty checks to make sure the stage reference remains intact. Whilst the API shadow services work fine, when I put the game on Kong the API stubbornly refuses to work in spite of loading into an object just fine.

The code:


public class FlxKong extends Sprite
{
public var API:*;

public function FlxKong()
{
addEventListener(Event.ADDED_TO_STAGE, init);
}

public function init($e:Event):void
{
removeEventListener(Event.ADDED_TO_STAGE, init);
var paramObj:Object = LoaderInfo(root.loaderInfo).parameters;
var api_url:String = paramObj.api_path || “http://www.kongregate.com/flash/API_AS3_Local.swf”;
FlxG.log("API path: “+api_url); //DEBUG
Security.allowDomain(api_url)
//Load the API
var request:URLRequest = new URLRequest(api_url);
var loader:Loader = new Loader();
loader.contentLoaderInfo.addEventListener(Event.COMPLETE, APILoaded);
FlxG.log(”Attempting Loader code Revision 9");
parent.addChild(loader);
loader.load(request);

}

public function APILoaded(event:Event):void
{
var prop:*
FlxG.log(String(event.target));
FlxG.log(String(event.target.content));
API = event.target.content;
FlxG.log("API: " + API);
if (API.services) FlxG.log(“API LOADED!”);
else FlxG.log(“API NOT LOADED!”);
FlxG.log("connected: " + API.connected);
FlxG.log("loaded: " + API.loaded);
FlxG.log(API.stage);
FlxG.log(API.services);
FlxG.log(API.user);
FlxG.log(API.scores);
FlxG.log(API.stats);
API.services.connect();
FlxG.log(“API Connecting”);

}
}


FlxKong is added as a child to the stage on initilize. I have to use a wrapper class on account of using Flixel to drive my game. The debug output is as follows when I put the game on Kong:

API path: http://chat.kongregate.com/flash/API_AS3_1259646166.swf
Attempting Loader code Revision 9
[object LoaderInfo]
[object as3_api]
API: [object as3_api]
API NOT LOADED!
connected: false
loaded: false
[object Stage]
ERROR: NULL GAME LOG MESSAGE
ERROR: NULL GAME LOG MESSAGE
ERROR: NULL GAME LOG MESSAGE
ERROR: NULL GAME LOG MESSAGE

So yeah. In short the game imports the API but every single one of it’s objects return a null. So I can’t connect.