Using SDK
Create Ad Surfaces and Branded Object Placements in your Unreal Engine project.
Last updated
Create Ad Surfaces and Branded Object Placements in your Unreal Engine project.
Last updated
Once the Rene SDK is successfully installed and opened, you can start utilizing its features. If you have correctly added the API Credentials generated for your game on the ReneVerse Portal into the ReneVerse API Editor menu in Unreal Engine Editor, you can click Sync Data. Once successfully synced through your API keys with the ReneVerse Portal, you'll see foldouts for Ad Surfaces List and Branded Object List, which you had created and configured on the portal.
When you unfold Ad Surfaces List or Branded Object List, you will see list of ads that you have added trough the portal. Information about them are displayed on their respective cards.
Once you have chosen surface or branded object you want to place, for Ad Surfaces select type you want to place and simply click Add to scene. Actor will be placed in the scene.
Once the any type of Ad Surface has been placed in the scene you can rescale it and place it in a position you would like it to be. You can group surfaces, parent them or ad them as an child actors in scene.
Plane Banner Ads are flat 2D objects you can place on any flat surface. Keep their position and orientation in mind.
Decal Banner Ads use Decal Component to draw 2D ads on your preferred surface.
Same routine can be done with branded objects. Find object placement in the ReneVerse API Editor and click Add to scene.
From there you cans scale actor itself or edit bounds of Target Bounding Box until it fits in your scene. When served, object will fit inside bounding box.
Once served, 3D object will be created and rescaled to fit the bounds you have setup.
Once you have setup ad surfaces and object placements, it is easy to serve them any time during the games runtime.
Serving from blueprint
Simplest way to serve ads in your game is by calling one of functions in ReneAPISubsystem. For batch serving ads in your scene, in case you want to serve all ads you can call:
ServeAllAds - it will serve and populate all ad surface and branded objects in your scene
ServeAdSurfaces - it will serve all ad surfaces in scene
ServeBrandedObjects - it will serve all branded objects in scene
For more control, you can call ServeAd or ServeBrandedObject if you want to serve only one of the ads. Simply pass AdSurfaceId or BrandedObjectPlacementId to it. The rest of the parameters are optional.
If you want to target individual ads and serve them separately, you can always use two options: 1. use ServeAd or ServeBrandedObject functions and target specific ids directly in subsystem; 2. get individual reference of the actor and call ServeAd
Serving ads from c++
In order to use ReneVerseSDK from c++, you will need to include ReneVerseSDK as module in your .Build.cs.
To serve ads from your code, the procedure stays the same as with blueprints. You have access to all methods that you need from blueprints. Simply get ReneAPISubsystem and call one of the corresponding methods that suits your needs.
Another option is to call ServeAd on each individual ad,
To stop serving ads in your scene you can always call StopServingAllAds function in ReneAPISubsystem either from Blueprint or c++.
To enable your player to connect to ReneVerse portal you can call Login function in ReneAPISubsystem from blueprint or c++ and pass their email and password they have provided have entered from login form or other means.
As mentioned before, when syncing data from the editor after entering credentials, ReneVerse folder has been added to your project. It contains data asset and data tables with data for your game ads.
Keep the folder in the root of you Content folder.
Once created from the editor, every Ad Surface or Branded Object have reference to the corresponding data table.
In case that your workflow requires that you need to make some modifications to the one of the blueprints, you can always create your custom blueprint from either BP_BannerAdSurface or BP_BrandedObjectPlacement.
Once you have done that you can select DT_AdSurfaceDataTable for surfaces or DT_BrandedObjDataTable for branded objects and select row with the ID you want to serve there.
In case that the data is missing from actors in your scene or something got corrupted, you can always try one button fix from ReneVerse Editor by clicking on the Cleanup and update ads in scene button.
From the editor it is available to create new or update additional Ad Surfaces and Branded Object Placements like it is from the Portal.
In order to create new Ad Surface or Branded Object Placement you can open ReneVerse Editor window and click Create Ad Surface or Create Branded Object Placement button.
This will open corresponding editor for either Ad Surface or Branded Object. There you can populate required data and by pressing Submit, data ad will be created. After that you will be able to ad it to the scene. NOTE. You will need internet connection for this action to execute.
In order to edit Ad Surface or Branded Object Placement, you can do that, either from ReneVerse Editor or from the Details panel of the selected actor in scene.
From the ReneVerse Editor find either Ad Surface of Branded Object Placement in the corresponding list and click edit button. Same edit window, with already populated data of the selected Ad Surface or Branded Object Placement, will open. Edit and submit data to the API.
To delete Ad Surface or Branded Object, find object in the list in ReneVerse Editor and lick delete button. Confirmation popup will appear and after approving, object will be deleted.
Keep in mind that by deleting Ad Surface or Branded Object, already placed actors with same ID will not work. Process of deletion will also delete all instances of the actor with that ID from currently opened scene.
NOTE. All changes might take couple of seconds to apply when submitted, so wait for confirmation notification to appear after the process is complete to continue with further work.
Once the ads are served, data is being collected for each ad actor you have placed in the scene. To view debug information for each object in scene you can use console command Debug.DrawTrackingData 1. Console can be accessed by clicking ~ key.
Data that will be shown for each ad actor is screen cover percentage and view angle as well as points that are checked for occlusion. This can help you position ads in a way that is most beneficial and check if anything is blocking their line of sight from the player.