Username System

2

Stats

2,665 visits, 3,685 views

Tools

Translations

This tutorial hasn't been translated.

License

This tutorial is licensed under CC BY 4.0. Please refer to the license text if you wish to reuse, share or remix the content contained within this tutorial.

Published on 7 Oct, 2017. Last updated 19 Feb, 2019

Today i'm going to show you how to create a username system for your game!

Tutorial Difficulty:Beginner-Anyone can do it

__________________________________________________________________________________________

Step 1:

So first of all you want to create a textbox or something where the player can put in the username of choice (if you know how to add some styling to the text box you can do it)

__________________________________________________________________________________________

Step 2:

#Now create a global variable and call it something you can remember for later!

Set the variable settings to the following:

Name:(Choose your own)

Type:Text

Inital Value:(Leave Blank)

Description:Used for username storage#

__________________________________________________________________________________________

Step 3:

Now on the same layout as the textbox or whatever you used for input of the players username and on the event sheet of that layout do the following:

Create Condition\Textbox\On text changed

Create Action\System\Set value\Select the variable you made earlier\In the value box put TextBox.Text\</p>

(Change TextBox to whatever you used for input)

_________________________________________________________________________________________

Step 4:To use the username in text do the following:

Create Condition\System\On Start Of Layout\Set text\"Welcome "& SC_Account &" To the Space Connect screen"\</p>

(Change SC_Account to the variable name you used)

__________________________________________________________________________________________

Of course you can do so much more than just set the text to display the username but that's for another tutorial.Anyways if you found this helpful then please share the post with the community and here is a few screenshots from my game to show you what the event sheet looks like and other stuff if you found this tutorial useful share it with other fellow construct 2 members and peace out!

  • 1 Comments

  • Order by
Want to leave a comment? Login or Register an account!