Skip to content

Commit

Permalink
Added isLoggedIn functionality to the GC plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
Imanol Martin committed Oct 15, 2015
1 parent 9619e9d commit d44703e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/social/cocoon-gc/edittime.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@ AddCondition(15, cf_trigger, "On submit achievement success", "Achievements", "O

AddCondition(16, cf_trigger, "On submit achievement fail", "Achievements", "On submit achievement failed", "Triggered if something fails when trying to submit an achievement", "onGCSubmitAchievementFail");

AddCondition(17, cf_none, "Is Logged In", "Social", "Is Logged In", "Checks if the user is already logged in in.", "isLoggedIn");

/**
* Actions
*/
Expand Down
3 changes: 3 additions & 0 deletions src/social/cocoon-gc/runtime.js
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,9 @@ cr.plugins_.ATPGameCenter = function(runtime) {
/**
* Conditions
*/
Cnds.prototype.isLoggedIn = function() {
return this.GCInterface.isLoggedIn();
};
Cnds.prototype.onGCLoginSuccess = function() {
return true;
};
Expand Down

0 comments on commit d44703e

Please sign in to comment.