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

Author Topic: (resolved) read target data?  (Read 1346 times)

Thazager

  • General Accounts
  • *
  • Posts: 1155
  • Never stop learning
    • View Profile
    • Heroes and Villains MMORPG
(resolved) read target data?
« on: Nov 22, 16, 10:09:18 PM »

I was reading data from one character to another. I target another player, I can read the name, level, and other fields (which are string or integer). Upon trying to read a list of string or list of integer, it says size = 0. The list is created when the character enters the game, and data is added as they open a window and add things to the list. This is done automatically when character enters. I can print these lists for each player and they show as a good list. When trying to read the info from the other player, the list size shows as 0 and no values can be seen.

(I believe we had this working at one point in the past, and it was recently noticed that targeting another player no longer shows this info.)

Would I now need to create a list on the reader's side and try to fill it with info from the target? (and if that info is still 0?)
Reading the info from server seems a bit slow from async.
Ideas?
« Last Edit: Nov 23, 16, 11:14:35 PM by Thazager »
Logged

ToY-Krun

  • General Accounts
  • *
  • Posts: 677
  • Support Volunteer
    • View Profile
Re: read target data?
« Reply #1 on: Nov 23, 16, 07:44:22 AM »

This list must be created, and manipulated on the server side, and then replicated to other clients, OR, you'll need to call the server on your "click" and "request" the info from the servers node for that char,  since the other char only exists visually on each client, not the actual data node (other than fields specified to replicate with that chars replication group).   Theres no alternative than those two methods,  having that list replicate would be faster than calling the server, but any changes to that field would have to be dealt with via calling the server and changing the list, also you'd have to consider that the field would be getting replicated to every nearby client every time they come into range of each other.  So in the end, if its a fair enough sized list You probably don't want it being replicated.

Basically, the other chars "info" doesnt exist on other clients unless its forced there via replication, or sent from the server via a call method.

Hope that helps.

Thazager

  • General Accounts
  • *
  • Posts: 1155
  • Never stop learning
    • View Profile
    • Heroes and Villains MMORPG
Re: read target data?
« Reply #2 on: Nov 23, 16, 07:36:19 PM »

Interesting, that must a recent change, as we have a video of it working before. It shows the info (in this case buffs) of the other player being shown with spec picture on the buff line. It was not using replication before. It was just data captured from the player on client, not using the server.

https://www.youtube.com/watch?v=gv4VQXoRJ0w&t=66s

Logged

ToY-Krun

  • General Accounts
  • *
  • Posts: 677
  • Support Volunteer
    • View Profile
Re: read target data?
« Reply #3 on: Nov 23, 16, 07:47:53 PM »

That info was likely being passed via a call to nearby clients with the proper fx to play etc, but it does have to come from the server as there's no communication between clients.  Perhaps you were replicating the buff specs the other player had via a list etc. ?

Thazager

  • General Accounts
  • *
  • Posts: 1155
  • Never stop learning
    • View Profile
    • Heroes and Villains MMORPG
Re: read target data?
« Reply #4 on: Nov 23, 16, 11:14:06 PM »

Ok, thanks.  I went through the server on the click to get the info.

Looking back thru the DOM, I did see the buff list was replicated to client - removed.
Logged