question

leo-1 avatar image
leo-1 asked

Rule Condition not working with custom tags

In my code I have 3 custom tags attached to the player login, and I'm trying to verify the users login using a rule, but the issue is I cannot specify which custom tag is what e.g

customTag1 = "Foo" customTag2 = "Too" customTag3 = "Goo"

RULE CONDITION CustomTags customTag2 is equal to "Too" run CloudScript "Verify User"

For some reason you're unable to edit the area where it says "string value" to specify which tag I am checking to be the correct ID

CloudScriptAuthenticationPlayStream
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
Neils Shi avatar image
Neils Shi answered

Currently, PlayFab Rule Condition does not support setting specific CustomTags. As a workaround, you can add the judgement for custom tag in the CloudScript function directly. For more info, you can refer to my example code below:

 handlers.CheckCustomTags= function(args,context)
 {
     log.debug(context.playStreamEvent.CustomTags.customTag1);
     log.debug(context.playStreamEvent.CustomTags.customTag2);
     log.debug(context.playStreamEvent.CustomTags.customTag3);
 }
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.