How do I use a login php and load the information in C2

  • Hello guys, I have a login php, and i want to load the characters in php that this accounts contains, in contruct 2. How do i this?

    A image for example of what i want to do.

  • To do something like this you will need to create a php API to handle login and database storage. I beleive i have this at my work if you would like a copy premade with an example on using it.

    If you would like to make it yourself you are going to need to use the _POST["Value"] to get input from the ajax plugin in construct 2 that will in return send anything you print our in php back to construct 2

    Want more info or help?

    Send me an email:

  • Could u send me a copy ? i dont have any idea to do this.

  • well assuming that you can construct the PHP (a there are some available scripts to do it), you can construct a request to the C2 game. The browser object will let you access the request string or perhaps more usefully just the parameters you are passing in the string

    for example

    http : //xxx.xx.xxx/game/index.html?player_uid=1000000&token=844682844042&seed=662838

    hope that helps a little

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • yes i want to do this, but in your example, my token never will be the same,

    the guy select your char in PHP, and i set a var called NAME and i want to do that C2 accept this link;

    xxxx.xxx/game/getChar.php?player_name=name (PHP VAR);

    thanks

    if you could; add me in Skype: matheusmwno

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)