BuddyVariables are custom values attached to any Buddy in a BuddyList.
Namespace: Sfs2X.Entities.VariablesAssembly: SmartFox2 (in SmartFox2.dll) Version: 0.9.14.0
Syntax
| C# |
|---|
public class SFSBuddyVariable : BuddyVariable, UserVariable |
Remarks
They work with the same principle of the User/Room Variables.
The only difference is the logic by which they get propagated to other Users. While RoomVariables are broadcast to all clients in the same Room, BuddyVariables are updated to all Users who have the BuddyVariable owner in their BuddyLists. BuddyVariables support basic data types and nested complex objects:
All variable names starting with a dollar sign ($) will set the BuddyVariable as persistent and make them available at any time whether the owner is online or not.
The only difference is the logic by which they get propagated to other Users. While RoomVariables are broadcast to all clients in the same Room, BuddyVariables are updated to all Users who have the BuddyVariable owner in their BuddyLists. BuddyVariables support basic data types and nested complex objects:
- Null
- Bool
- Int
- Double
- String
- SFSObject
- SFSArray
All variable names starting with a dollar sign ($) will set the BuddyVariable as persistent and make them available at any time whether the owner is online or not.