mirror of
https://github.com/ddnet/ddnet.git
synced 2024-09-21 01:54:19 +00:00
37 lines
890 B
C
37 lines
890 B
C
|
/* (c) Magnus Auvinen. See licence.txt in the root of the distribution for more information. */
|
||
|
/* If you are missing that file, acquire a complete release at teeworlds.com. */
|
||
|
#ifndef ENGINE_FRIENDS_H
|
||
|
#define ENGINE_FRIENDS_H
|
||
|
|
||
|
#include <engine/shared/protocol.h>
|
||
|
|
||
|
#include "kernel.h"
|
||
|
|
||
|
struct CFriendInfo
|
||
|
{
|
||
|
char m_aName[MAX_NAME_LENGTH];
|
||
|
char m_aClan[MAX_CLAN_LENGTH];
|
||
|
};
|
||
|
|
||
|
class IFriends : public IInterface
|
||
|
{
|
||
|
MACRO_INTERFACE("friends", 0)
|
||
|
public:
|
||
|
enum
|
||
|
{
|
||
|
MAX_FRIENDS=128,
|
||
|
};
|
||
|
|
||
|
virtual void Init() = 0;
|
||
|
|
||
|
virtual int NumFriends() const = 0;
|
||
|
virtual const CFriendInfo *GetFriend(int Index) const = 0;
|
||
|
virtual bool IsFriend(const char *pName, const char *pClan) const = 0;
|
||
|
|
||
|
virtual void AddFriend(const char *pName, const char *pClan) = 0;
|
||
|
virtual void RemoveFriend(const char *pName, const char *pClan) = 0;
|
||
|
virtual void RemoveFriend(int Index) = 0;
|
||
|
};
|
||
|
|
||
|
#endif
|