Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function yourManualLogin() //change this to your manual login functiuon
- AIRTOWER.username = this._localLoginServerData.nau;
- AIRTOWER.password = this._localLoginServerData.nal;
- // then
- this._airtower.handleOnLogin = OnLogin;
- AIRTOWER.server.login("w1",this._localLoginServerData.nau,this._localLoginServerData.nal); // encrypted password
- }
- function OnLogin(serverResponse)
- {
- this._airtower.removeListener(this._airtower.HANDLE_LOGIN,this._airtower.handleOnLogin);
- this._airtower.removeListener(this._airtower.HANDLE_LOGIN_EXPIRED,this._airtower.handleExpiredPreactivationLogin,this._airtower);
- this._airtower.server.diconnect();
- var _loc5_ = serverResponse[1].split("|");
- this._airtower.loginObject = {};
- this._airtower.loginObject.loginDataRaw = serverResponse[1];
- this._airtower.loginObject.playerID = _loc5_[0];
- this._airtower.loginObject.swid = _loc5_[1];
- this._airtower.loginObject.username = _loc5_[2];
- this._airtower.loginObject.loginKey = _loc5_[3];
- this._airtower.loginObject.languageApproved = _loc5_[5];
- this._airtower.loginObject.languageRejected = _loc5_[6];
- this._airtower.loginObject.friendsLoginKey = serverResponse[3];
- com.clubpenguin.login.handlers.LoginHandler.LoginKey = _loc5_[3];
- this._airtower.loginObject.confirmationHash = serverResponse[2];
- this._airtower.loginObject.emailAddress = serverResponse[5];
- if (serverResponse[6] != null)
- {
- var _loc3_ = serverResponse[6].split("|");
- this._airtower.loginObject.remaining_hours = _loc3_[0];
- this._airtower.loginObject.trialMax = _loc3_[1];
- this._airtower.loginObject.max_grace_hours = _loc3_[2];
- var _loc6_ = new Object();
- _loc6_.modalBackgroundEnbaled = true;
- _loc6_.blockPuffleNotifications = true;
- _loc6_.hideLoadingDialog = true;
- var _loc4_ = new Object();
- _loc4_.state = this._airtower.FRAME_LABEL_WELCOME;
- _loc4_.trialRemaining = _loc3_[0];
- _loc4_.trialMax = _loc3_[1];
- _loc4_.graceMax = _loc3_[2];
- _loc4_.confirmationHash = this._airtower.loginObject.confirmationHash;
- _loc4_.loginDataRaw = this._airtower.loginObject.loginDataRaw;
- this._shell.sendOpenAS3Module("preactivation",_loc4_,_loc6_);
- flash.external.ExternalInterface.call("showActivationBanner",_loc3_[0]);
- }
- this._shell.playerModel.initMyPlayer(this._airtower.loginObject);
- this._airtower.playerId = this._airtower.loginObject.playerID;
- this._shell.updateWorldPopulations(serverResponse[4]);
- var _loc9_ = new Object();
- _loc9_.type = 15;
- _loc9_.playerSWID = this._airtower.loginObject.swid;
- _loc9_.playerID = this._airtower.loginObject.playerID;
- this._shell.sendPlaydomTracking(_loc9_);
- this._airtower.is_logged_in = true;
- ConnectToWorld();
- }
- function ConnectToWorld () {
- this._shell.connectToWorld = function()
- {
- var _loc1_ = _this._shell.getWorldById(_this._shell.world_id_holder);
- _this._shell.showLoading();
- ConnectToWorldServer(_loc1_.ip,_loc1_.port,_this._shell.connectToWorldResponse);
- }
- var _loc1_ = this._shell.getWorldById(WORLD_ID);
- this._shell.setWorldForConnection(WORLD_ID);
- }
- function ConnectToWorldServer(ip, port, response) {
- this._airtower.isRedemption = false;
- this._airtower.on_world_response = response;
- this._airtower.server.onConnection = com.clubpenguin.util.Delegate.create(this,this.LoginConnection);
- this._airtower.server.onRandomKey = com.clubpenguin.util.Delegate.create(this,this.LoginRandomKey);
- this._airtower.server.onExtensionResponse = com.clubpenguin.util.Delegate.create(this._airtower,this._airtower.onAirtowerResponse);
- this._airtower.server.debug = true;
- var _this = this;
- var _loc1_ = function()
- {
- _this._airtower.joinWorld();
- }
- this._airtower.addListener(this._airtower.HANDLE_LOGIN, _loc1_, this);
- if (this._airtower.server.isConnected)
- {
- this._airtower.server.disconnect();
- }
- this._airtower.server.connect(ip, port);
- }
Add Comment
Please, Sign In to add comment