Beamable SDK
Public Member Functions | Public Attributes | List of all members
Beamable.EasyFeatures.BeamableViewGroup Class Reference

This is a Beamable Component you can add to any GameObject you have to gain access to it's API that:

More...

Inheritance diagram for Beamable.EasyFeatures.BeamableViewGroup:
Inheritance graph
[legend]
Collaboration diagram for Beamable.EasyFeatures.BeamableViewGroup:
Collaboration graph
[legend]

Public Member Functions

void RebuildManagedViews (IEnumerable< IBeamableView > otherViews=null)
 Rebuilds the list of managed IBeamableViews in this BeamableViewGroup's GameObject hierarchy. In cases where you want to have your IBeamableViews be independent of the GameObject hierarchy, you can pass in a list of IBeamableViews to append the views controlled by this group.
 
virtual async void TriggerEnrich ()
 Enrich call that returns void so it can be configured to happen via UnityEngine.Events.UnityActions.
 
virtual async Promise Enrich ()
 Ensures that the AllPlayerContexts match the currently set AllPlayerCodes and that they are BeamContext.OnReady. Then, goes through all ManagedViews and calls either IBeamableView.EnrichWithContext(Beamable.BeamContext) or IBeamableView.EnrichWithContext(Beamable.BeamContext, int) based on IBeamableView.SupportedMode.
 
async Promise EnrichWithPlayerCodes (List< string > newPlayerCodes=null)
 Works the same as Enrich, but calls and awaits RebuildPlayerContexts before enriching. More...
 
async Promise RebuildPlayerContexts (List< string > playerCodes)
 Rebuilds the AllPlayerCodes and AllPlayerContexts codes based on the given playerCodes . More...
 

Public Attributes

BeamContextGroup AllPlayerContexts
 List of all BeamContexts currently being used by this BeamableViewGroup to get it's dependencies from.
 
List< string > AllPlayerCodes
 List of all BeamContext.PlayerCode that are used to identify BeamContexts within Beamable's player-centric SDK.
 
List< IBeamableViewManagedViews
 List of all IBeamableViews that exist as children of the GameObject holding this BeamableViewGroup. If you add/remove IBeamableView components from this hierarchy, call RebuildManagedViews and then Enrich to make sure each IBeamableView sees those changes. You can also simply add IBeamableView views to this list and call Enrich. The Enrich call will see the newly appended views and enrich them accordingly.
 

Detailed Description

This is a Beamable Component you can add to any GameObject you have to gain access to it's API that:

This is meant to provide additive behaviour and work with other MonoBehaviour scripts that implement IBeamableView in the same GameObject hierarchy.

Member Function Documentation

◆ EnrichWithPlayerCodes()

async Promise Beamable.EasyFeatures.BeamableViewGroup.EnrichWithPlayerCodes ( List< string >  newPlayerCodes = null)
inline

Works the same as Enrich, but calls and awaits RebuildPlayerContexts before enriching.

Parameters
newPlayerCodes

◆ RebuildPlayerContexts()

async Promise Beamable.EasyFeatures.BeamableViewGroup.RebuildPlayerContexts ( List< string >  playerCodes)
inline

Rebuilds the AllPlayerCodes and AllPlayerContexts codes based on the given playerCodes .

Parameters
playerCodesNew BeamContext.PlayerCode representing the BeamContext that this View should get it's data from.

The documentation for this class was generated from the following file: