I'm making a game in as3 using flash develop and flash cs5. Everything is object oriented. I was wondering, should I have one "gateway" class that has a property-reference to all instantiations of other classes, and I just pass this gateway class to new objects, so they have access to every class. Like so:
var block:Block = new Block(gateway);
//In the block class:
this.gateway.player.setHealth(100);
//Or:
this.gateway.input.lock();
Is this like a singleton pattern or something? Should I do this?