This repository has been archived by the owner on Sep 21, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 27
Stats (C compatible)
Ahmed Castro edited this page Sep 3, 2018
·
1 revision
void modioGetAllModStats(void* object, ModioFilterCreator filter, void (*callback)(void* object, ModioResponse response, ModioStats mods_stats[], u32 mods_stats_size));
Wrapped by: Stats#getallmodstats
API endpoint used: Get All Mods Stats
Browse all mod stats, can be filtered using the ModioFilterCreator.
Name | Type | Description |
---|---|---|
object | void* |
Context parameter. |
filter | ModioFilterCreator* |
ModioFilterCreator object to be customized. |
callback | void (*callback)(void* object, ModioResponse response, ModioStats mods_stats[], u32 mods_stats_size) |
Function called once the process finished. |
Name | Type | Description |
---|---|---|
object | void* |
Context parameter. |
response | ModioResponse |
ModioResponse object that contains the mod.io response status. |
mods_stats | ModioStats* |
ModioStats array containing the returned mod stats. |
mods_stats_size | u32 |
Mod stats array size. |
void onGetAllModStats(void* object, ModioResponse response, ModioStats mods_stats[], u32 mods_stats_size)
{
if(response.code == 200)
{
//Mod stats retrieved successfully
}
}
[...]
ModioFilterCreator filter;
modioInitFilter(&filter);
modioSetFilterLimit(&filter,3);
modioGetAllModStats(NULL,filter, &onGetAllModStats);
void modioGetModStats(void* object, u32 mod_id, void (*callback)(void* object, ModioResponse response, ModioStats mod));
Wrapped by: Mods#getmodstats
API endpoint used: Get Mod Stats
Get mod stats for the corresponding mod.
Name | Type | Description |
---|---|---|
object | void* |
Context parameter. |
mod_id | u32 |
Mod's unique id. |
callback | void (*callback)(void* object, u32 mod_id, void (*callback)(void* object, ModioResponse response, ModioStats stats) |
Function called once the process finished. |
Name | Type | Description |
---|---|---|
object | void* |
Context parameter. |
response | ModioResponse |
ModioResponse object that contains the mod.io response status. |
stats | ModioStats |
ModioStats object returned. |
void onGetModStats(void* object, ModioResponse response, ModioStats stats)
{
if(response.code == 200)
{
//Mod stats retrieved successfully
}
}
[...]
modioGetModStats(NULL, mod_id, &onGetModStats);
- Home
- Table of Contents
- Getting Started
- SDK Methods
- Creators
- Editors
- Schemas
- modio::Avatar
- modio::Comment
- modio::Dependency
- modio::Download
- modio::Error
- modio::Filehash
- modio::Game
- modio::GameTagOption
- modio::Header
- modio::Icon
- modio::Image
- modio::InstalledMod
- modio::Logo
- modio::Media
- modio::MetadataKVP
- modio::Mod
- modio::ModEvent
- modio::Modfile
- modio::QueuedModDownload
- modio::QueuedModfileUpload
- modio::Rating
- modio::Response
- modio::Stats
- modio::Tag
- modio::User
- Debugging
- Constants
-
C Compatibility
- Methods
- Initialization, Process and Shutdown (C compatible)
- User Authentication (C compatible)
- Mods (C compatible)
- Modfiles (C compatible)
- Media (C compatible)
- Subscriptions (C compatible)
- Events (C compatible)
- Stats (C compatible)
- Tags (C compatible)
- Ratings (C compatible)
- Metadata KVP (C compatible)
- Dependencies (C compatible)
- Comments (C compatible)
- Reports (C compatible)
- Me (C compatible)
- Downloads (C compatible)
- Uploads (C compatible)
- Logs (C compatible)
- External Auth (C compatible)
- Configuration (C compatible)
- Creators
- Editors
- Schemas
- ModioAvatar
- ModioComment
- ModioDependency
- ModioDownload
- ModioError
- ModioFilehash
- ModioGame
- ModioGameTagOption
- ModioHeader
- ModioIcon
- ModioImage
- ModioInstalledMod
- ModioListNode
- ModioLogo
- ModioMedia
- ModioMetadataKVP
- ModioMod
- ModioModEvent
- ModioModfile
- ModioQueuedModDownload
- ModioQueuedModfileUpload
- ModioRating
- ModioResponse
- ModioStats
- ModioTag
- ModioUser
- Methods
- Building