mirror of
https://github.com/Facepunch/sbox-public.git
synced 2026-01-23 05:39:39 -05:00
This commit imports the C# engine code and game files, excluding C++ source code. [Source-Commit: ceb3d758046e50faa6258bc3b658a30c97743268]
42 lines
1.2 KiB
C#
42 lines
1.2 KiB
C#
using System;
|
|
using Sandbox.Twitch;
|
|
|
|
namespace Sandbox
|
|
{
|
|
internal struct StreamBroadcast
|
|
{
|
|
internal StreamBroadcast( TwitchAPI.StreamResponse stream )
|
|
{
|
|
Id = stream.Id;
|
|
UserId = stream.UserId;
|
|
Username = stream.UserLogin;
|
|
DisplayName = stream.UserName;
|
|
GameId = stream.GameId;
|
|
GameName = stream.GameName;
|
|
Type = stream.Type;
|
|
Title = stream.Title;
|
|
ViewerCount = stream.ViewerCount;
|
|
StartedAt = DateTimeOffset.Parse( stream.StartedAt );
|
|
Language = stream.Language;
|
|
ThumbnailUrl = stream.ThumbnailUrl;
|
|
TagIds = stream.TagIds;
|
|
IsMature = stream.IsMature;
|
|
}
|
|
|
|
public string Id { get; internal set; }
|
|
public string UserId { get; internal set; }
|
|
public string Username { get; internal set; }
|
|
public string DisplayName { get; internal set; }
|
|
public string GameId { get; internal set; }
|
|
public string GameName { get; internal set; }
|
|
public string Type { get; internal set; }
|
|
public string Title { get; internal set; }
|
|
public int ViewerCount { get; internal set; }
|
|
public DateTimeOffset StartedAt { get; internal set; }
|
|
public string Language { get; internal set; }
|
|
public string ThumbnailUrl { get; internal set; }
|
|
public string[] TagIds { get; internal set; }
|
|
public bool IsMature { get; internal set; }
|
|
}
|
|
}
|