Merlin-dev / Merlin_v1

Mostly stable, no new features will be added due to development of v2
Other
19 stars 19 forks source link

Auto Login feature #5

Closed fabriciorissetto closed 6 years ago

fabriciorissetto commented 6 years ago

Hi guys. I'm trying to implement the "Auto Login Feature" and it seems that others have already tried it so this time I'ill put here every step that I'm getting into so even if I give up, others can continue where I've stopped.

Discovering

Step 1 - Game objects responsible for the "Login" button

The objects involved when you press the "Login" button at the main screen

image

Step 3 - Game objects responsible for the "Enter World" button

These are the objects involved when you press the "Enter World" button (counting that the main character is already selected - e.g. you just have clicked the login and then "Enter Word" without any steps in between):

image

Doing it automatically

Determining automatically the account has logged off

When you got loggedoff the game prints an "a" on the Unity debug output! (developers making our lifes easier 😄 )

You can get when it happens in the HandleLog interceptor that already exists in the Console class: image

Clicking the "Login" automatically

This is the step I'm right now. As you can see in Step 1 the method responsible for the login is the LoginDialog.OnClickLogin().

This class is located inside the dll AlbionOnline\game\Albion-Online_Data\Managed\Assembly-CSharp.dll:

image

What needs to be done is to find a way to get the instance of this class and probably just call the OnClickLogin method would be enough (to click in the "Login" button, then we can

Clicking the "Enter World" automatically

...

klukule commented 6 years ago

Hey, I'l contribute to this and I'l make your work partially pointless:

public static void LoginAccount(string accountEmail, string accountPassword)
{
    LoginDialog loginDialog = UnityEngine.Object.FindObjectsOfType<LoginDialog>().FirstOrDefault<LoginDialog>();
    if (loginDialog != null)
    {
        loginDialog.AccountEmailInput.value = accountEmail;
        loginDialog.AccountPasswordInput.value = accountPassword;
        loginDialog.ParentGui.Connect(loginDialog.ServerNameInput.value, LoginGui.a.k);
    }
}

and the second method to login character is currently obsolete, since I haven't updated my private bot yet :) due to work on v2:

as4.aj().aq().f(characterName);

Have a nice day

fabriciorissetto commented 6 years ago

Dude, this isn't the fist time you respond one of my issues or PR's this way.

Closing the issue, I'll not try to contribute to your project again

"have a nice day"

klukule commented 6 years ago

Really?? well OK... for example, I haven't added that myself because Mostly stable, no new features will be added due to development of v2 which is description of v1 repository...