HeroEngine Forums
Welcome, Guest. Please login or Register for HeroCloud Account.

Author Topic: [Resolved] Character Data  (Read 1673 times)

Tythin4

  • General Accounts
  • *
  • Posts: 39
    • View Profile
[Resolved] Character Data
« on: Nov 14, 11, 04:14:25 PM »

How do you set and save character data such as integers for levels and experience at the time of character creation and gameplay?  I've been searching through the wiki and digging through the coding but for some reason it's not clicking. Can anyone help me or explain it to me? Thanks
« Last Edit: Nov 01, 12, 10:34:25 AM by HE-Cooper »
Logged

HE-Cooper

  • *****
  • Posts: 2221
    • View Profile
Re: Character Data
« Reply #1 on: Nov 14, 11, 04:38:26 PM »

Those sound somewhat like two different questions. But have you started with the Character Data and The Replication tutorial for the game stats side of things?

http://wiki.heroengine.com/wiki/Character_Data_Tutorial
http://wiki.heroengine.com/wiki/Replication
http://wiki.heroengine.com/wiki/Replication_Tutorial

The character data tutorial is now not as perfect as it used to be because it's using all remote calls instead of replication, so you'll see that it recommends the Replication pages as supplemental reading.
Logged

Tythin4

  • General Accounts
  • *
  • Posts: 39
    • View Profile
Re: Character Data
« Reply #2 on: Nov 14, 11, 04:52:17 PM »

Those sound somewhat like two different questions. But have you started with the Character Data and The Replication tutorial for the game stats side of things?

http://wiki.heroengine.com/wiki/Character_Data_Tutorial
http://wiki.heroengine.com/wiki/Replication
http://wiki.heroengine.com/wiki/Replication_Tutorial

The character data tutorial is now not as perfect as it used to be because it's using all remote calls instead of replication, so you'll see that it recommends the Replication pages as supplemental reading.
Yeah, I read through and did those tutorials but I'm having trouble combining the concepts.  I probably should go through the replication wiki page though...
Logged

Tythin4

  • General Accounts
  • *
  • Posts: 39
    • View Profile
Re: Character Data
« Reply #3 on: Nov 14, 11, 11:15:14 PM »

Okay, cam someone walk me through what the basic character creation script does that comes with the world?  I want to be able to fully understand what it does and how it initializes the base stats of the character before I change everyrthing. Also, can someone do that with E_CharacterCreationWindowClassMethods too?
Logged

HE-Cooper

  • *****
  • Posts: 2221
    • View Profile
Re: Character Data
« Reply #4 on: Nov 15, 11, 07:38:11 AM »

Queuing up for an official answer today.
Logged

HE-ALEX

  • General Accounts
  • *
  • Posts: 5
    • View Profile
Re: Character Data
« Reply #5 on: Nov 15, 11, 05:17:23 PM »

When the "Create New" button is clicked on the Character Selection screen a message is sent to the server to create a new character. If the character is allowed to create a character then _CSSCreateCharacter() is called on the $CHARACTERSELECTIONSYSTEM system node. Here is where the new Player Character node is created and associated to the Player Account. When the Player Character node is turned into a root node it is immediatly unloaded. Next the Player Character root node is requested to load. Loading a Root Node is an asynchronous proccess and takes a variable amount of time. After the Player Character node has been loaded the character is sent to the Character Creation Area. When the "Finish" button in the Character Creation screen is pressed the client requests their Player Character's name is changed to what is in the input box. If it succeeds then the client requests travel to the starting area.

Scripts related to this proccess are:
  • _AccountClassMethods
  • _CharacterSelectionClassMethods
  • _PlayerConnectionClassMethods
  • _PlayerAccountClassMethods
  • _GUICSSCharacterSelectionClassMethods
  • E_characterCreatingWindowClassMethods

If you wanted to add additional data to a Player Character node after it's been created, you could override HE_CSSCharacterSelected() on $CHARACTERSELECTIONSYSTEM system node on the server. This will be called from _CSSCharacterSelected() after the Player Character root node has been loaded. Note you will need to check if the data has already been added because _CSSCharacterSelected() will be called every time the character is selected from the Character Selection Screen. You could also implement HE_CSSCreateCharacter() on $CHARACTERSELECTIONSYSTEM system node on the server which would override the behavior of _CSSCreateCharacter() and add any Game Specific data to the Player Character.

If you wanted to change what GUI is used for the character selection screen override HE_CSSInvokeGUI() on $CHARACTERSELECTIONSYSTEM system node on the client. This will be called when the client is activated in the Character Selection area.

The character creation GUI is overridden by HE_CCSInvokeGUI on $CHARACTERCREATIONSYSTEM system node on the client.

Relevant Wiki Articles:
http://wiki.heroengine.com/wiki/$ACCOUNT
http://wiki.heroengine.com/wiki/$CHARACTERSELECTIONSYSTEM
http://wiki.heroengine.com/wiki/$CHARACTERCREATIONSYSTEM
http://wiki.heroengine.com/wiki/Account_Character_Tree
http://wiki.heroengine.com/wiki/Connection_Logic
Logged

Tythin4

  • General Accounts
  • *
  • Posts: 39
    • View Profile
Re: Character Data
« Reply #6 on: Nov 15, 11, 05:20:32 PM »

Thank you very much!
Logged