Exemple #1
0
    def closeGame(self, user):
        """Close all of the game channels and tell the users that user is logged off"""
        # Get the channels and close them
        um = UserManager()

        # Get the datastore user 
        u = User.all().filter('FacebookID =', user.FacebookID).get()
        um.logoutUser(u)
        return True
Exemple #2
0
 def loginUserToGame(self, user):
     """The login user to the game with the game channels"""
     # The user manager
     um = UserManager()
     
     # Get the datastore user 
     u = User.all().filter('FacebookID =', user.FacebookID).get()
     
     # Login the user. Send the login data to all of the users
     # and the current login state for the user.
     um.loginUser(u)
     return True