This or That
This sample project is available on Lens Studio Home Page.
This Sample Project represents a gaming mechanic where the Snapchatter encounters the same question in each round. In each round, they choose one of their friends or any items who they believe is best suited to answer that question. At the end of the game, one winner is determined.
Customizing the Sample Project
This sample project allows you to create a unique game for Snapchatters by modifying assets. To get started go to the Home page in Lens Studio and find the This or That card in the Sample Project section. Click on the project card to download the project.
Select Sorting Mode
The project contains 2 types of sorting - friends and custom items. You can switch between these
modes by turning ON/OFF Friends
and Items
objects under the Scripts [Select only 1 option]
:
Customize items
If you select custom sorting items, and you want to adjust them, select [EDIT_ME] Items Data
objectg and change Items
script input.
You can remove each item or add a new one. For each item you can set its texture, primary and secondary names. Names are optional, and you can leave them empty if you want.
Changing which friends are shown
If you select Friends sorting mode you can to change the Sorting Order: You can use the FriendsComponent to specify the sorting order of your friends and filters for their selection. More information about the FriendsComponent can be found here.


In the input data of the Friends Loader script, you can specify the minimum and maximum number of friends to be selected for the game, and add a fallback texture to be applied to friends who do not have Bitmoji.
Changing the Visual Effect
To create your own design and change visual effect for your project, you can replace or completely remove objects marked as [REMOVE_ME] - doing this will not affect the gameplay mechanics.
To replace or remove it, find the 3D Camera in the Scene Hierarchy, and make your desired changes.
After this, you will see the basic view of the game without any additional effects. →
With Visual Effect | Without Visual Effect |
---|---|
![]() | ![]() |
Changing the Question
Changing the question can be done in two ways:
-
Using the Text components labeled Title [TRY_ME]. Edit the text inside the text component and enable this object.
-
Using image components labeled as Title Image [REPLACE_ME]. To change the question in the Image component, replace its texture with your own.
Depending on which way you choose, remember to turn off the other one by ticking the checkbox.
Make sure you have enabled the same type of components and added the same questions in both the 3D camera and the VFX_FG camera.
Customize Game Settings
Use the input data of the RankingController script to customize the game settings.
Note that you can add different objects to be enabled on the Questions Stage, on the Result Stage, and No Friends Stage in case the user has fewer friends than required for the game (only if you select Friends Sorting).
In the same script, you can specify callbacks that will be triggered when transitioning from one stage of the game to another.
Previewing Your Lens
You’re now ready to preview your Lens experience. To preview your Lens in Snapchat, follow the Pairing to Snapchat guide.