playMaker

Author Topic: Photon get player properties  (Read 4605 times)

gozda

  • Junior Playmaker
  • **
  • Posts: 88
Photon get player properties
« on: May 05, 2016, 01:06:46 PM »
Can someone create simple action for get player properties by name?
There is an action get next player... but its difficult to every time when player join in to room search this new player by this action.
thanks

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Photon get player properties
« Reply #1 on: May 05, 2016, 01:14:08 PM »
Hi,

 I'll get on this tomorrow first thing :)

 Bye,

 Jean

gozda

  • Junior Playmaker
  • **
  • Posts: 88
Re: Photon get player properties
« Reply #2 on: May 05, 2016, 01:32:01 PM »
Cool thanks,
also :D on https://hutonggames.fogbugz.com/default.asp?W929 theres no event PHOTON/PLAYER PROPERTIES CHANGED, so maybe someone know if this event have data who changed properties?

And with photon package we dont have Event PHOTON / MAX CCCU REACHED but i am sure for what we can use this event if players are already online.

And another 2 question,
1.if there is way to get information when player trying connect to photon, but ccu reach limit?
2.How to close room? :)
« Last Edit: May 05, 2016, 01:37:10 PM by gozda »

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Photon get player properties
« Reply #3 on: May 06, 2016, 09:24:55 AM »
Hi,

 Ok,

-- There is already an action called PhotonViewGetOwnerProperties which will let you pick custom properties for a given player

-- create a new event "PHOTON / MAX CCCU REACHED" and mark it global, you will get informed when reaching limit. I'll package a new version soon with the inclusion of this event, I am not sure why it got deleted... cause I have all the code implemented to send it.

-- To close a room, all players have to leave, then the room is deleted from the server. However, the new releases fo Photon allows for rooms to persists when empty for a given amount of time, like players, so this is becoming more and more flexible.

Bye,

 Jean

gozda

  • Junior Playmaker
  • **
  • Posts: 88
Re: Photon get player properties
« Reply #4 on: July 19, 2016, 08:37:37 AM »
How to get if player with specified name is in room?

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Photon get player properties
« Reply #5 on: July 21, 2016, 02:56:24 AM »
Hi,

 for this, you need to use the "FriendList" system.

 You make a request with a given list of user id, and Photon Server will call you back with global event "PHOTON / ON FRIENDLIST UPDATED", and then you can use the GetFriendListInfo Action to retrieve a particular user, its online status, whether she/he's in a room and in in a room, the room name.

If you want to update, simply make the request every 20 or 30 seconds, and only put the minimum amount of user id.

Bye,

 Jean

gozda

  • Junior Playmaker
  • **
  • Posts: 88
Re: Photon get player properties
« Reply #6 on: July 27, 2016, 03:45:33 AM »
To get friend list online, player who send action need to be in lobby or he can be in room?
I am trying to get player list in room, but this action "Photon Network Find Friends" just stuck in this action, photon server dont call me back to to global event "PHOTON / ON FRIENDLIST UPDATED"

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Photon get player properties
« Reply #7 on: July 27, 2016, 12:17:52 PM »
Hi,

Friendlist only works in lobby or on master server, basically when not in a room

I'll update the action to check for this

Bye,

Jean