mirror of
https://github.com/Facepunch/Facepunch.Steamworks.git
synced 2025-01-12 06:38:01 +03:00
Overlay
This commit is contained in:
parent
f84aba045c
commit
5b24c8ca01
41
Facepunch.Steamworks/Client.Overlay.cs
Normal file
41
Facepunch.Steamworks/Client.Overlay.cs
Normal file
@ -0,0 +1,41 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
|
||||||
|
namespace Facepunch.Steamworks
|
||||||
|
{
|
||||||
|
public partial class Client : IDisposable
|
||||||
|
{
|
||||||
|
private Overlay _overlay;
|
||||||
|
|
||||||
|
public Overlay Overlay
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
if ( _overlay == null )
|
||||||
|
_overlay = new Overlay { client = this };
|
||||||
|
|
||||||
|
return _overlay;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public class Overlay
|
||||||
|
{
|
||||||
|
internal Client client;
|
||||||
|
|
||||||
|
public void OpenProfile( ulong steamid ) { client._friends.ActivateGameOverlayToUser( "steamid", steamid ); }
|
||||||
|
public void OpenChat( ulong steamid ){ client._friends.ActivateGameOverlayToUser( "chat", steamid ); }
|
||||||
|
public void OpenTrade( ulong steamid ) { client._friends.ActivateGameOverlayToUser( "jointrade", steamid ); }
|
||||||
|
public void OpenStats( ulong steamid ) { client._friends.ActivateGameOverlayToUser( "stats", steamid ); }
|
||||||
|
public void OpenAchievements( ulong steamid ) { client._friends.ActivateGameOverlayToUser( "achievements", steamid ); }
|
||||||
|
|
||||||
|
public void AddFriend( ulong steamid ) { client._friends.ActivateGameOverlayToUser( "friendadd", steamid ); }
|
||||||
|
public void RemoveFriend( ulong steamid ) { client._friends.ActivateGameOverlayToUser( "friendremove", steamid ); }
|
||||||
|
public void AcceptFriendRequest( ulong steamid ) { client._friends.ActivateGameOverlayToUser( "friendrequestaccept", steamid ); }
|
||||||
|
public void IgnoreFriendRequest( ulong steamid ) { client._friends.ActivateGameOverlayToUser( "friendrequestignore", steamid ); }
|
||||||
|
|
||||||
|
public void OpenUrl( string url ) { client._friends.ActivateGameOverlayToWebPage( url ); }
|
||||||
|
}
|
||||||
|
}
|
@ -43,6 +43,7 @@
|
|||||||
<Reference Include="System.Xml" />
|
<Reference Include="System.Xml" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<Compile Include="Client.Overlay.cs" />
|
||||||
<Compile Include="Client.Voice.cs" />
|
<Compile Include="Client.Voice.cs" />
|
||||||
<Compile Include="Client.Auth.cs" />
|
<Compile Include="Client.Auth.cs" />
|
||||||
<Compile Include="Client.cs" />
|
<Compile Include="Client.cs" />
|
||||||
|
Loading…
x
Reference in New Issue
Block a user