ManiaAPI.TMX
2.0.0-alpha10
This is a prerelease version of ManiaAPI.TMX.
There is a newer prerelease version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package ManiaAPI.TMX --version 2.0.0-alpha10
NuGet\Install-Package ManiaAPI.TMX -Version 2.0.0-alpha10
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="ManiaAPI.TMX" Version="2.0.0-alpha10" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add ManiaAPI.TMX --version 2.0.0-alpha10
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: ManiaAPI.TMX, 2.0.0-alpha10"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install ManiaAPI.TMX as a Cake Addin #addin nuget:?package=ManiaAPI.TMX&version=2.0.0-alpha10&prerelease // Install ManiaAPI.TMX as a Cake Tool #tool nuget:?package=ManiaAPI.TMX&version=2.0.0-alpha10&prerelease
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
ManiaAPI.TMX
Wraps https://tm-exchange.com/ (old TMX).
Setup
using ManiaAPI.TMX;
// Pick one from TMUF, TMNF, Nations, Sunrise, Original
var tmx = new TMX(TmxSite.TMUF);
Get Replays
var replayCollection = await tmx.GetReplaysAsync(new()
{
TrackId = 4808334,
Count = 20
});
foreach (var item in replayCollection.Results)
{
Console.WriteLine(item.ReplayTime);
})
Search Tracks
var trackCollection = await tmx.SearchTracksAsync(new()
{
Name = "wirtual", // tracks that have wirtual in their name
Count = 20
});
foreach (var item in trackCollection.Results)
{
Console.WriteLine(item.TrackName);
})
Search Leaderboards
var leaderboardCollection = await tmx.SearchLeaderboardsAsync(new()
{
Count = 10
});
foreach (var item in leaderboardCollection.Results)
{
Console.WriteLine(item.User.Name);
}
Search Trackpacks
var trackpackCollection = await tmx.SearchTrackpacksAsync(new()
{
Count = 15
});
foreach (var item in trackpackCollection.Results)
{
Console.WriteLine(item.PackName);
}
Search Users
var userCollection = await tmx.SearchUsersAsync(new()
{
InModerators = true,
Count = 10
});
foreach (var item in userCollection.Results)
{
Console.WriteLine(item.Name);
}
Get Replay Gbx
Just the URL:
string url = tmx.GetReplayGbxUrl(replayId: 5032240);
Or request it:
using HttpResponseMessage response = await tmx.GetReplayGbxResponseAsync(replayId: 5032240);
Or use ManiaAPI.TMX.Extensions.Gbx
package to load it into CGameCtnReplayRecord
, either just the header or full Gbx:
using ManiaAPI.TMX.Extensions.Gbx;
// Just the header
Gbx<CGameCtnReplayRecord> gbxReplayHeader = await tmx.GetReplayGbxHeaderAsync(replayId: 5032240);
// Full Gbx
Gbx<CGameCtnReplayRecord> gbxReplay = await tmx.GetReplayGbxAsync(replayId: 5032240);
Get Track Gbx
Just the URL:
string url = tmx.GetTrackGbxUrl(trackId: 4808334);
Or request it:
using HttpResponseMessage response = await tmx.GetTrackGbxResponseAsync(trackId: 4808334);
Or use ManiaAPI.TMX.Extensions.Gbx
package to load it into CGameCtnChallenge
, either just the header or full Gbx:
using ManiaAPI.TMX.Extensions.Gbx;
// Just the header
Gbx<CGameCtnChallenge> gbxMapHeader = await tmx.GetTrackGbxHeaderAsync(trackId: 4808334);
// Full Gbx
Gbx<CGameCtnChallenge> gbxMap = await tmx.GetTrackGbxAsync(trackId: 4808334);
Get Track Thumbnail
Just the URL:
string url = tmx.GetTrackThumbnailUrl(trackId: 4808334);
Or request it:
using HttpResponseMessage response = await tmx.GetTrackThumbnailResponseAsync(trackId: 4808334);
Get Track Image
Just the URL:
string url = tmx.GetTrackImageUrl(trackId: 4808334, imageIndex: 0);
Or request it:
using HttpResponseMessage response = await tmx.GetTrackImageResponseAsync(trackId: 4808334, imageIndex: 0);
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
net8.0
- TmEssentials (>= 2.4.2)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on ManiaAPI.TMX:
Package | Downloads |
---|---|
ManiaAPI.TMX.Extensions.Gbx
Package Description |
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
2.0.0-alpha4 | 156 | 12/23/2023 |
2.0.0-alpha2 | 171 | 11/1/2023 |
2.0.0-alpha10 | 90 | 6/19/2024 |
2.0.0-alpha1 | 167 | 7/5/2023 |
1.0.10 | 208 | 3/6/2024 |
1.0.9 | 251 | 5/7/2023 |
1.0.8 | 420 | 8/30/2022 |
1.0.7 | 459 | 6/3/2022 |
1.0.6 | 430 | 6/3/2022 |
1.0.5 | 434 | 5/7/2022 |
1.0.4 | 418 | 5/7/2022 |
1.0.3 | 416 | 5/7/2022 |
1.0.2 | 444 | 4/12/2022 |
1.0.0 | 459 | 4/8/2022 |