🎮
Game Ownership
Verify if users own your game or DLC through TapTap platform integration.
Integrate TapTap features into your PC games with ease
npm install tapsdk-pcimport { TapSdk, EventId, SystemState } from 'tapsdk-pc';
// Check if restart is needed (call before init)
if (TapSdk.restartAppIfNecessary('your_client_id')) {
process.exit(0);
}
// Initialize the SDK
const sdk = new TapSdk('your_public_key');
// Check game ownership
if (!sdk.isGameOwned()) {
console.log('User does not own this game');
process.exit(1);
}
// Poll for events in your game loop
const events = sdk.runCallbacks();
for (const event of events) {
// Handle events...
}