Windows
#
IntroductionIf you are using a non-supported or a custom engine, we also provide the Antidote SDK library so you can directly access its validation and watermark methods.
note
Touches are only available for Android and iOS.
#
ConfigurationTo integrate the SDK for Custom Engines in your project:
- Download the latest version of Antidote SDK for Custom Windows Engines.
- Unzip the downloaded file and go to "custom engine" folder.
- You will find the
antidote.dll
library and headers. Include them to your project.
#
ValidationExample:
#
User InformationTo access the Antidote User ID of the user opening the game, you can use the following function:
The returned string is the user ID.
#
Watermarks#
ConfigurationThe watermark handler is automatically instantiated when you reference the Antidote session in the SDK, and will automatically be destructored on shutdown.
The watermark handler needs to be configured before you attempt to render any watermark text. You will need to set the following values:
- text velocity (how quickly the watermark moves on screen)
- update speed (how often the watermark behaviour needs to be updated)
- text width and height
- screen width and height
Assuming your game screen is rendered to a 1920x1080 buffer and your text measures 128x32, you would make the following calls to get everything set up:
Once configured, your engine will need to tell the watermark handler when to update. You will need to know the amount of time in milliseconds that has elapsed since the last call to the watermark handler update. Assuming this time span is a float called delta
you can add the following to your game loop update:
Finally, you will need to add some code to your render function to draw the watermark text. The following call will return a list of text items to be rendered:
#
BehavioursThe following behaviours are supported:
Behaviour | Description |
---|---|
TICKER | Move a single repeated line of text across the screen from right to left, which randomizes vertical position on every update cycle. |
DVD | Bounce a single line of text around the screen. |
MULTILINE_TICKER | Move multiple lines of text across the screen from right to left. |
RANDOM | switch to a different behaviour on every update cycle. |
#
Game EventsEvents can be emitted during gameplay to track once-off events, and the duration of long-running events. These can be viewed on the session recording. To emit an event:
where action
can be one of the following:
Action | Description |
---|---|
start | mark the start of a long-running event (e.g. boss_battle) |
end | mark the end of a long-running event (e.g. boss_battle) |
once | emit a once-off event (e.g. collected_powerup) |