This commit is contained in:
cyw
2026-02-13 14:34:15 +08:00
parent 6ed1953e24
commit f36e3f9df2
5206 changed files with 573757 additions and 16 deletions

View File

@@ -0,0 +1,29 @@
#include "Stdafx.h"
#include "AfxDLLx.h"
//////////////////////////////////////////////////////////////////////////
//¾²Ì¬±äÁ¿
static AFX_EXTENSION_MODULE AndroidServiceDLL={NULL,NULL};
//////////////////////////////////////////////////////////////////////////
//DLL Ö÷º¯Êý
extern "C" INT APIENTRY DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID lpReserved)
{
UNREFERENCED_PARAMETER(lpReserved);
if (dwReason==DLL_PROCESS_ATTACH)
{
if (!AfxInitExtensionModule(AndroidServiceDLL, hInstance)) return 0;
new CDynLinkLibrary(AndroidServiceDLL);
}
else if (dwReason==DLL_PROCESS_DETACH)
{
AfxTermExtensionModule(AndroidServiceDLL);
}
return 1;
}
//////////////////////////////////////////////////////////////////////////

View File

@@ -0,0 +1,6 @@
; AndroidService.def : DLL
LIBRARY "AndroidService"
EXPORTS
;

View File

@@ -0,0 +1,121 @@
// Microsoft Visual C++ generated resource script.
//
#include "resource.h"
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "afxres.h"
/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
// 中文(简体,中国) resources
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_CHS)
LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED
#pragma code_page(936)
#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//
1 TEXTINCLUDE
BEGIN
"resource.h\0"
END
2 TEXTINCLUDE
BEGIN
"#include ""afxres.h""\r\n"
"\0"
END
3 TEXTINCLUDE
BEGIN
"#define _AFX_NO_SPLITTER_RESOURCES\r\n"
"#define _AFX_NO_OLE_RESOURCES\r\n"
"#define _AFX_NO_TRACKER_RESOURCES\r\n"
"#define _AFX_NO_PROPERTY_RESOURCES\r\n"
"\r\n"
"#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_CHS)\r\n"
"LANGUAGE 4, 2\r\n"
"#pragma code_page(936)\r\n"
"#include ""res\\AndroidService.rc2"" // 不是由 Microsoft Visual C++ 编辑过的资源\r\n"
"#include ""afxres.rc"" // 标准组件\r\n"
"#endif\r\n"
"\0"
END
#endif // APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Version
//
VS_VERSION_INFO VERSIONINFO
FILEVERSION 6,6,0,3
PRODUCTVERSION 6,6,0,3
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
FILEFLAGS 0x1L
#else
FILEFLAGS 0x0L
#endif
FILEOS 0x4L
FILETYPE 0x2L
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "080403a8"
BEGIN
VALUE "Comments", "科技有限公司"
VALUE "CompanyName", "科技有限公司"
VALUE "FileDescription", "机器人服务组件"
VALUE "FileVersion", "6.6.0.3"
VALUE "InternalName", "AndroidService.dll"
VALUE "LegalCopyright", "深圳市网狐科技有限公司保留所有权利。"
VALUE "OriginalFilename", "AndroidService.dll"
VALUE "ProductName", "机器人服务组件"
VALUE "ProductVersion", "6.6.0.3"
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", 0x804, 936
END
END
#endif // 中文(简体,中国) resources
/////////////////////////////////////////////////////////////////////////////
#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//
#define _AFX_NO_SPLITTER_RESOURCES
#define _AFX_NO_OLE_RESOURCES
#define _AFX_NO_TRACKER_RESOURCES
#define _AFX_NO_PROPERTY_RESOURCES
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_CHS)
LANGUAGE 4, 2
#pragma code_page(936)
#include "res\AndroidService.rc2" // 不是由 Microsoft Visual C++ 编辑过的资源
#include "afxres.rc" // 标准组件
#endif
/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED

View File

@@ -0,0 +1,263 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug_Unicode|Win32">
<Configuration>Debug_Unicode</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release_Unicode|Win32">
<Configuration>Release_Unicode</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup Label="Globals">
<ProjectName>机器人服务</ProjectName>
<ProjectGuid>{487AE71A-160E-49E0-A1EF-6D115F6B8A3F}</ProjectGuid>
<SccProjectName />
<SccAuxPath />
<SccLocalPath />
<SccProvider />
<Keyword>MFCDLLProj</Keyword>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release_Unicode|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v120</PlatformToolset>
<UseOfMfc>Dynamic</UseOfMfc>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug_Unicode|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v120</PlatformToolset>
<UseOfMfc>Dynamic</UseOfMfc>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v120</PlatformToolset>
<UseOfMfc>Dynamic</UseOfMfc>
<CharacterSet>MultiByte</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v120</PlatformToolset>
<UseOfMfc>Dynamic</UseOfMfc>
<CharacterSet>MultiByte</CharacterSet>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release_Unicode|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug_Unicode|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup>
<_ProjectFileVersion>12.0.30501.0</_ProjectFileVersion>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<OutDir>Debug\</OutDir>
<IntDir>Debug\</IntDir>
<LinkIncremental>true</LinkIncremental>
<TargetName>ZaJinHuaAndroid</TargetName>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<OutDir>Release\</OutDir>
<IntDir>Release\</IntDir>
<LinkIncremental>false</LinkIncremental>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug_Unicode|Win32'">
<OutDir>$(Configuration)\</OutDir>
<IntDir>$(Configuration)\</IntDir>
<LinkIncremental>true</LinkIncremental>
<TargetName>ZaJinHuaAndroid</TargetName>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release_Unicode|Win32'">
<OutDir>$(Configuration)\</OutDir>
<IntDir>$(Configuration)\</IntDir>
<LinkIncremental>false</LinkIncremental>
<TargetName>ZaJinHuaAndroid</TargetName>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;_WINDOWS;_DEBUG;_AFXEXT;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MinimalRebuild>true</MinimalRebuild>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
<StructMemberAlignment>Default</StructMemberAlignment>
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
<PrecompiledHeader>Use</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
</ClCompile>
<Link>
<OutputFile>../../../../运行/Debug/Ansi/ZaJinHuaAndroid.dll</OutputFile>
<ModuleDefinitionFile>.\AndroidServiceD.def</ModuleDefinitionFile>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
<ImportLibrary />
<TargetMachine>MachineX86</TargetMachine>
</Link>
<Midl>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MkTypLibCompatible>false</MkTypLibCompatible>
</Midl>
<PostBuildEvent>
<Command>
</Command>
</PostBuildEvent>
<ResourceCompile>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<Culture>0x0804</Culture>
<AdditionalIncludeDirectories>$(IntDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ResourceCompile>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<PreprocessorDefinitions>WIN32;_WINDOWS;NDEBUG;_AFXEXT;ANDROID_SERVICE_DLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
<StructMemberAlignment>Default</StructMemberAlignment>
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
<PrecompiledHeader>Use</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
</ClCompile>
<Link>
<OutputFile>../../../../运行/Release/Ansi/ZaJinHuaAndroid.dll</OutputFile>
<ModuleDefinitionFile>.\AndroidService.def</ModuleDefinitionFile>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
<OptimizeReferences>true</OptimizeReferences>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<ImportLibrary />
<TargetMachine>MachineX86</TargetMachine>
</Link>
<Midl>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MkTypLibCompatible>false</MkTypLibCompatible>
</Midl>
<PostBuildEvent>
<Command>
</Command>
</PostBuildEvent>
<ResourceCompile>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<Culture>0x0804</Culture>
<AdditionalIncludeDirectories>$(IntDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ResourceCompile>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug_Unicode|Win32'">
<ClCompile>
<Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;_WINDOWS;_DEBUG;_AFXEXT;_UNICODE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MinimalRebuild>true</MinimalRebuild>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
<StructMemberAlignment>Default</StructMemberAlignment>
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
<PrecompiledHeader>Use</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
</ClCompile>
<Link>
<OutputFile>../../../../运行/Debug/Unicode/ZaJinHuaAndroid.dll</OutputFile>
<ModuleDefinitionFile>.\AndroidServiceD.def</ModuleDefinitionFile>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
<ImportLibrary />
<TargetMachine>MachineX86</TargetMachine>
</Link>
<Midl>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MkTypLibCompatible>false</MkTypLibCompatible>
</Midl>
<PostBuildEvent>
<Command>mkdir ..\..\..\发布组件\服务器组件\Debug\Unicode
copy /y ..\..\..\..\运行\Debug\Unicode\$(TargetFileName) ..\..\..\发布组件\服务器组件\Debug\Unicode\$(TargetFileName)
</Command>
</PostBuildEvent>
<ResourceCompile>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<Culture>0x0804</Culture>
<AdditionalIncludeDirectories>$(IntDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ResourceCompile>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release_Unicode|Win32'">
<ClCompile>
<PreprocessorDefinitions>WIN32;_WINDOWS;NDEBUG;_AFXEXT;ANDROID_SERVICE_DLL;_UNICODE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
<StructMemberAlignment>Default</StructMemberAlignment>
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
<PrecompiledHeader>Use</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
</ClCompile>
<Link>
<OutputFile>../../../../运行/Release/Unicode/ZaJinHuaAndroid.dll</OutputFile>
<ModuleDefinitionFile>.\AndroidService.def</ModuleDefinitionFile>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
<OptimizeReferences>true</OptimizeReferences>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<ImportLibrary />
<TargetMachine>MachineX86</TargetMachine>
</Link>
<Midl>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MkTypLibCompatible>false</MkTypLibCompatible>
</Midl>
<PostBuildEvent>
<Command>mkdir ..\..\..\发布组件\服务器组件\Release\Unicode\
copy /y ..\..\..\..\运行\Release\Unicode\$(TargetFileName) ..\..\..\发布组件\服务器组件\Release\Unicode\$(TargetFileName)
</Command>
</PostBuildEvent>
<ResourceCompile>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<Culture>0x0804</Culture>
<AdditionalIncludeDirectories>$(IntDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ResourceCompile>
</ItemDefinitionGroup>
<ItemGroup>
<ClCompile Include="AndroidService.cpp" />
<ClCompile Include="AndroidServiceManager.cpp" />
<ClCompile Include="AndroidUserItemSink.cpp" />
<ClCompile Include="Stdafx.cpp">
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug_Unicode|Win32'">Create</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release_Unicode|Win32'">Create</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="AndroidServiceManager.h" />
<ClInclude Include="AndroidUserItemSink.h" />
<ClInclude Include="Resource.h" />
<ClInclude Include="Stdafx.h" />
</ItemGroup>
<ItemGroup>
<ResourceCompile Include="AndroidService.rc" />
</ItemGroup>
<ItemGroup>
<None Include="res\AndroidService.rc2" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>

View File

@@ -0,0 +1,55 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="源文件">
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
<Extensions>cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
</Filter>
<Filter Include="头文件">
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
<Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>
</Filter>
<Filter Include="资源文件">
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx</Extensions>
</Filter>
</ItemGroup>
<ItemGroup>
<ClCompile Include="AndroidService.cpp">
<Filter>源文件</Filter>
</ClCompile>
<ClCompile Include="AndroidUserItemSink.cpp">
<Filter>源文件</Filter>
</ClCompile>
<ClCompile Include="Stdafx.cpp">
<Filter>源文件</Filter>
</ClCompile>
<ClCompile Include="AndroidServiceManager.cpp">
<Filter>源文件</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="AndroidUserItemSink.h">
<Filter>头文件</Filter>
</ClInclude>
<ClInclude Include="Resource.h">
<Filter>头文件</Filter>
</ClInclude>
<ClInclude Include="Stdafx.h">
<Filter>头文件</Filter>
</ClInclude>
<ClInclude Include="AndroidServiceManager.h">
<Filter>头文件</Filter>
</ClInclude>
</ItemGroup>
<ItemGroup>
<ResourceCompile Include="AndroidService.rc">
<Filter>资源文件</Filter>
</ResourceCompile>
</ItemGroup>
<ItemGroup>
<None Include="res\AndroidService.rc2">
<Filter>资源文件</Filter>
</None>
</ItemGroup>
</Project>

View File

@@ -0,0 +1,6 @@
; AndroidServiceD.def : DLL
LIBRARY "AndroidServiceD"
EXPORTS
;

View File

@@ -0,0 +1,95 @@
#include "StdAfx.h"
#include "AndroidServiceManager.h"
#include "AndroidUserItemSink.h"
//////////////////////////////////////////////////////////////////////////
//构造函数
CGameServiceManager::CGameServiceManager()
{
}
//析构函数
CGameServiceManager::~CGameServiceManager()
{
}
//接口查询
void * CGameServiceManager::QueryInterface(const IID & Guid, DWORD dwQueryVer)
{
QUERYINTERFACE(IGameServiceManager,Guid,dwQueryVer);
QUERYINTERFACE_IUNKNOWNEX(IGameServiceManager,Guid,dwQueryVer);
return NULL;
}
//创建机器
VOID * CGameServiceManager::CreateAndroidUserItemSink(REFGUID Guid, DWORD dwQueryVer)
{
//变量定义
CAndroidUserItemSink * pAndroidUserItemSink=NULL;
try
{
//建立对象
pAndroidUserItemSink=new CAndroidUserItemSink();
if (pAndroidUserItemSink==NULL) throw TEXT("创建失败");
//查询接口
VOID * pObject=pAndroidUserItemSink->QueryInterface(Guid,dwQueryVer);
if (pObject==NULL) throw TEXT("接口查询失败");
return pObject;
}
catch (...) {}
//删除对象
SafeDelete(pAndroidUserItemSink);
return NULL;
}
//创建游戏桌
VOID * CGameServiceManager::CreateTableFrameSink(REFGUID Guid, DWORD dwQueryVer)
{
return NULL;
}
//创建数据
VOID * CGameServiceManager::CreateGameDataBaseEngineSink(REFGUID Guid, DWORD dwQueryVer)
{
return NULL;
}
//获取属性
bool CGameServiceManager::GetServiceAttrib(tagGameServiceAttrib & GameServiceAttrib)
{
return true;
}
//参数修改
bool CGameServiceManager::RectifyParameter(tagGameServiceOption & GameServiceOption)
{
//效验参数
ASSERT(&GameServiceOption!=NULL);
if (&GameServiceOption==NULL) return false;
//单元积分
GameServiceOption.lCellScore -=__max(1L,GameServiceOption.lCellScore);
//积分下限
GameServiceOption.lMinTableScore=__max(1000L,GameServiceOption.lMinTableScore);
//积分上限
if (GameServiceOption.lRestrictScore!=0L)
{
GameServiceOption.lRestrictScore=__max(GameServiceOption.lRestrictScore,GameServiceOption.lMinTableScore);
}
return true;
}
//////////////////////////////////////////////////////////////////////////
//建立对象
DECLARE_CREATE_MODULE(GameServiceManager)
//////////////////////////////////////////////////////////////////////////

View File

@@ -0,0 +1,46 @@
#ifndef ANDROID_SERVICE_HEAD_FILE
#define ANDROID_SERVICE_HEAD_FILE
#pragma once
#include "Stdafx.h"
//////////////////////////////////////////////////////////////////////////
//游戏服务器管理类
class CGameServiceManager : public IGameServiceManager
{
//函数定义
public:
//构造函数
CGameServiceManager(void);
//析构函数
virtual ~CGameServiceManager(void);
//基础接口
public:
//释放对象
virtual VOID Release() { return; }
//接口查询
virtual VOID * QueryInterface(const IID & Guid, DWORD dwQueryVer);
//创建接口
public:
//创建桌子
virtual VOID * CreateTableFrameSink(REFGUID Guid, DWORD dwQueryVer);
//创建机器
virtual VOID * CreateAndroidUserItemSink(REFGUID Guid, DWORD dwQueryVer);
//创建数据
virtual VOID * CreateGameDataBaseEngineSink(REFGUID Guid, DWORD dwQueryVer);
//参数接口
public:
//组件属性
virtual bool GetServiceAttrib(tagGameServiceAttrib & GameServiceAttrib);
//调整参数
virtual bool RectifyParameter(tagGameServiceOption & GameServiceOption);
};
//////////////////////////////////////////////////////////////////////////
#endif

View File

@@ -0,0 +1,474 @@
#include "Stdafx.h"
#include "AndroidUserItemSink.h"
//////////////////////////////////////////////////////////////////////////
#define TIME_AN_START_GAME 4 //开始时间
#define IDI_READY 100
#define IDI_SHOW_CARD 101
#define IDI_SHOW_CARD2 102
#define IDI_BANKER 105 //机器人存取款
//构造函数
CAndroidUserItemSink::CAndroidUserItemSink()
{
//AllocConsole();
//freopen("CON","wt",stdout);
ZeroMemory(m_bHandCardData,sizeof(m_bHandCardData));
ZeroMemory(m_bSegmentCard,sizeof(m_bSegmentCard));
ZeroMemory(m_bSpecialCardData,sizeof(m_bSpecialCardData));
ZeroMemory(m_bPlayer,sizeof(m_bPlayer));
ZeroMemory(m_bAllUserCardData,sizeof(m_bAllUserCardData));
m_bHandCardCount=0;
static LONG dwRandCount=0L;
srand((unsigned)time(NULL)+dwRandCount++);
m_bWait=false;
m_nRobotPlayMaxCount=2+rand()%3;
m_nRobotPlayCount=0;
m_nAndroidNum=0;
}
//析构函数
CAndroidUserItemSink::~CAndroidUserItemSink()
{
}
//接口查询
void * CAndroidUserItemSink::QueryInterface(REFGUID Guid, DWORD dwQueryVer)
{
QUERYINTERFACE(IAndroidUserItemSink,Guid,dwQueryVer);
QUERYINTERFACE_IUNKNOWNEX(IAndroidUserItemSink,Guid,dwQueryVer);
return NULL;
}
//初始接口
bool CAndroidUserItemSink::Initialization(IUnknownEx * pIUnknownEx)
{
//查询接口
m_pIAndroidUserItem=QUERY_OBJECT_PTR_INTERFACE(pIUnknownEx,IAndroidUserItem);
if (m_pIAndroidUserItem==NULL) return false;
return true;
}
//重置接口
bool CAndroidUserItemSink::RepositionSink()
{
ZeroMemory(m_bHandCardData,sizeof(m_bHandCardData));
ZeroMemory(m_bSegmentCard,sizeof(m_bSegmentCard));
ZeroMemory(m_bSpecialCardData,sizeof(m_bSpecialCardData));
ZeroMemory(m_bPlayer,sizeof(m_bPlayer));
ZeroMemory(m_bAllUserCardData,sizeof(m_bAllUserCardData));
m_bHandCardCount=0;
return true;
}
//时间消息
bool CAndroidUserItemSink::OnEventTimer(UINT nTimerID)
{
switch(nTimerID)
{
case IDI_READY:
{
//发送准备
m_pIAndroidUserItem->SendUserReady(NULL,0);
m_pIAndroidUserItem->KillGameTimer(IDI_READY);
return true;
}
case IDI_SHOW_CARD:
{
ShowCard();
m_pIAndroidUserItem->KillGameTimer(IDI_SHOW_CARD);
return true;
}
case IDI_BANKER:
{
BankOperate(2);
return true;
}
case IDI_SHOW_CARD2:
{
m_nAndroidNum++;
m_pIAndroidUserItem->SetGameTimer(IDI_SHOW_CARD2,1);
return true;
}
}
return false;
}
//游戏消息
bool CAndroidUserItemSink::OnEventGameMessage(WORD wSubCmdID, void * pData, WORD wDataSize)
{
return false;
}
//游戏消息
bool CAndroidUserItemSink::OnEventFrameMessage(WORD wSubCmdID, void * pData, WORD wDataSize)
{
return true;
}
//场景消息
bool CAndroidUserItemSink::OnEventSceneMessage(BYTE cbGameStatus, bool bLookonOther, void * pData, WORD wDataSize)
{
return false;
}
//银行操作
void CAndroidUserItemSink::BankOperate(BYTE cbType)
{
// IServerUserItem *pUserItem = m_pIAndroidUserItem->GetMeUserItem();
// if(pUserItem->GetUserStatus()>=US_SIT)
// {
// if(cbType==1)
// {
// CString strInfo;
// strInfo.Format(TEXT("大厅:状态不对,不执行存取款"));
// NcaTextOut(strInfo);
// return;
// }
// }
//
// //变量定义
// SCORE lRobotScore = pUserItem->GetUserScore();
//
// {
// CString strInfo;
// strInfo.Format(TEXT("[%s] 分数(%I64d)"),pUserItem->GetNickName(),lRobotScore);
//
// if (lRobotScore > m_pIAndroidUserItem->GetAndroidParameter()->lMaxTakeScore)
// {
// CString strInfo1;
// strInfo1.Format(TEXT("满足存款条件(%I64d)"),m_pIAndroidUserItem->GetAndroidParameter()->lMaxTakeScore);
// strInfo+=strInfo1;
//
// NcaTextOut(strInfo);
// }
// else if (lRobotScore < m_pIAndroidUserItem->GetAndroidParameter()->lMinTakeScore)
// {
// CString strInfo1;
// strInfo1.Format(TEXT("满足取款条件(%I64d)"),m_pIAndroidUserItem->GetAndroidParameter()->lMinTakeScore);
// strInfo+=strInfo1;
//
// NcaTextOut(strInfo);
// }
//
// //判断存取
// if (lRobotScore >m_pIAndroidUserItem->GetAndroidParameter()->lMaxTakeScore)
// {
// SCORE lSaveScore=0L;
// lSaveScore = lRobotScore - m_pIAndroidUserItem->GetAndroidParameter()->lMaxTakeScore;
//
// if (lSaveScore > 0)
// {
// lSaveScore += (rand()%(m_pIAndroidUserItem->GetAndroidParameter()->lMaxTakeScore - m_pIAndroidUserItem->GetAndroidParameter()->lMinTakeScore));
// m_pIAndroidUserItem->PerformSaveScore(lSaveScore);
// }
// SCORE lRobotNewScore = pUserItem->GetUserScore();
//
// CString strInfo;
// strInfo.Format(TEXT("[%s] 执行存款:存款前金币(%I64d),存款后金币(%I64d)"),pUserItem->GetNickName(),lRobotScore,lRobotNewScore);
//
// NcaTextOut(strInfo);
// }
// else if (lRobotScore < m_pIAndroidUserItem->GetAndroidParameter()->lMinTakeScore)
// {
// CString strInfo;
// SCORE lScore=m_pIAndroidUserItem->GetAndroidParameter()->lMinTakeScore-lRobotScore;
// if (lScore > 0)
// {
// lScore += (rand()%(m_pIAndroidUserItem->GetAndroidParameter()->lMaxTakeScore - m_pIAndroidUserItem->GetAndroidParameter()->lMinTakeScore));
// m_pIAndroidUserItem->PerformTakeScore(lScore);
// }
//
// SCORE lRobotNewScore = pUserItem->GetUserScore();
// strInfo.Format(TEXT("[%s] 执行取款:取款前金币(%I64d),取款后金币(%I64d)"),pUserItem->GetNickName(),lRobotScore,lRobotNewScore);
//
// NcaTextOut(strInfo);
// }
// }
}
//用户进入
void CAndroidUserItemSink::OnEventUserEnter(IAndroidUserItem * pIAndroidUserItem, bool bLookonUser)
{
return;
}
//用户离开
void CAndroidUserItemSink::OnEventUserLeave(IAndroidUserItem * pIAndroidUserItem, bool bLookonUser)
{
return;
}
//用户积分
void CAndroidUserItemSink::OnEventUserScore(IAndroidUserItem * pIAndroidUserItem, bool bLookonUser)
{
return;
}
//用户状态
void CAndroidUserItemSink::OnEventUserStatus(IAndroidUserItem * pIAndroidUserItem, bool bLookonUser)
{
return;
}
//用户段位
void CAndroidUserItemSink::OnEventUserSegment(IAndroidUserItem * pIAndroidUserItem, bool bLookonUser)
{
return;
}
//游戏开始
bool CAndroidUserItemSink::OnSubSendCard(void * pData, WORD wDataSize)
{
return true;
}
//游戏结束
bool CAndroidUserItemSink::OnSubGameEnd(void * pData, WORD wDataSize)
{
return true;
}
void CAndroidUserItemSink::GetSpecialCard( BYTE CardData[],BYTE CardCount )
{
}
void CAndroidUserItemSink::ShowCard()
{
}
//void CAndroidUserItemSink::ShowCard()
//{
// bool bSpecialCard = false;
// if(m_GameLogic.GetCardType(m_bHandCardData,HAND_CARD_COUNT)!=CT_INVALID)
// {
// //得到所有用户的水数
// BYTE btCardData[52];
// CopyMemory(btCardData,m_bAllUserCardData,sizeof(btCardData));
// LONG lUserDaoShu[GAME_PLAYER];
// ZeroMemory(lUserDaoShu, sizeof(lUserDaoShu));
// WORD wMeChairID = m_pIAndroidUserItem->GetChairID();
// //获得特殊牌型下自己的水数
// GetAllUserDaoShu(btCardData,lUserDaoShu,wMeChairID,true);
// LONG lUserDaoShu1[GAME_PLAYER];
// ZeroMemory(lUserDaoShu1, sizeof(lUserDaoShu1));
// //获得普通牌型下自己的水数
// GetAllUserDaoShu(btCardData,lUserDaoShu1,wMeChairID,false);
// if (lUserDaoShu[wMeChairID] > lUserDaoShu1[wMeChairID])
// bSpecialCard = true;
// else
// bSpecialCard = false;
//
// m_GameLogic.SortCardList(m_bHandCardData,HAND_CARD_COUNT);
// BYTE cbHandCardCount=HAND_CARD_COUNT;
// BYTE cbSegmentCard[3][5];
// ZeroMemory(cbSegmentCard,sizeof(cbSegmentCard));
// tagAnalyseType tagCardType11; //类型及组合
// ZeroMemory(&tagCardType11,sizeof(tagCardType11));
// tagCardType11=m_GameLogic.GetType(m_bHandCardData,cbHandCardCount);
// m_GameLogic.TheBestCard(tagCardType11,m_bHandCardData,cbHandCardCount,cbSegmentCard[0],cbSegmentCard[1],cbSegmentCard[2]);
// if (CT_FIVE_FOUR_ONE<=m_GameLogic.GetCardType(cbSegmentCard[2],5/*,m_GameLogic.btCardSpecialData*/) && lUserDaoShu[wMeChairID] - lUserDaoShu1[wMeChairID] < 10)
// {
// bSpecialCard = false;
// }
// }
//
//
// if(m_GameLogic.GetCardType(m_bHandCardData,HAND_CARD_COUNT/*,m_GameLogic.btCardSpecialData*/)!=CT_INVALID && bSpecialCard == true)
// {
// m_GameLogic.SortCardList(m_bHandCardData,HAND_CARD_COUNT,enAscend);
// GetSpecialCard(m_bHandCardData,HAND_CARD_COUNT);
//
// WORD wType = m_GameLogic.GetSpecialType(m_bHandCardData);
// m_GameLogic.SortSpacialCard(m_bHandCardData,wType);
//
// CMD_C_ShowCard AllSegmentCard ;
// memset(&AllSegmentCard , 0 , sizeof(AllSegmentCard)) ;
// for(int i=0;i<3;i++)
// {
// m_bSegmentCard[0][i]=m_bHandCardData[i];
// }
//
// for(int i=0;i<5;i++)
// {
// m_bSegmentCard[1][i]=m_bHandCardData[3+i];
// }
//
// for(int i=0;i<5;i++)
// {
// m_bSegmentCard[2][i]=m_bHandCardData[8+i];
// }
// m_GameLogic.SortCardList(m_bSegmentCard[0],3);
// m_GameLogic.SortCardList(m_bSegmentCard[1],5);
// m_GameLogic.SortCardList(m_bSegmentCard[2],5);
// CopyMemory(AllSegmentCard.bFrontCard,m_bSegmentCard[0],CountArray(AllSegmentCard.bFrontCard));
// CopyMemory(AllSegmentCard.bMidCard,m_bSegmentCard[1],CountArray(AllSegmentCard.bMidCard));
// CopyMemory(AllSegmentCard.bBackCard,m_bSegmentCard[2],CountArray(AllSegmentCard.bBackCard));
//
// AllSegmentCard.bSpecialType=true;
//
// CopyMemory(m_bSpecialCardData,m_bHandCardData,sizeof(m_bSpecialCardData));
// CopyMemory(AllSegmentCard.btSpecialData,m_bSpecialCardData,sizeof(AllSegmentCard.btSpecialData));
//
// m_pIAndroidUserItem->SendSocketData(SUB_C_SHOWCARD,&AllSegmentCard,sizeof(AllSegmentCard));
//
// }
// else
// {
// m_GameLogic.SortCardList(m_bHandCardData,HAND_CARD_COUNT);
//
// m_bHandCardCount=HAND_CARD_COUNT;
// tagAnalyseType tagCardType; //类型及组合
// ZeroMemory(&tagCardType,sizeof(tagCardType));
// tagCardType=m_GameLogic.GetType(m_bHandCardData,m_bHandCardCount);
// m_GameLogic.TheBestCard(tagCardType,m_bHandCardData,m_bHandCardCount,m_bSegmentCard[0],m_bSegmentCard[1],m_bSegmentCard[2]);
//
// CMD_C_ShowCard AllSegmentCard ;
// memset(&AllSegmentCard , 0 , sizeof(AllSegmentCard)) ;
// CopyMemory(AllSegmentCard.bFrontCard,m_bSegmentCard[0],sizeof(AllSegmentCard.bFrontCard));
// CopyMemory(AllSegmentCard.bMidCard,m_bSegmentCard[1],sizeof(AllSegmentCard.bMidCard));
// CopyMemory(AllSegmentCard.bBackCard,m_bSegmentCard[2],sizeof(AllSegmentCard.bBackCard));
// //乌龙判断
// bool bDragon = false ;
// if((true==m_GameLogic.CompareCard(AllSegmentCard.bFrontCard , AllSegmentCard.bMidCard , 3 , 5 , false)) &&
// (true==m_GameLogic.CompareCard(AllSegmentCard.bMidCard, AllSegmentCard.bBackCard , 5 , 5 , false)))
// bDragon = false ;
// else
// bDragon = true ;
// AllSegmentCard.bDragon=bDragon;
// if(AllSegmentCard.bDragon)
// {
// memset(&AllSegmentCard , 0 , sizeof(AllSegmentCard)) ;
// //恢复扑克
// BYTE bCardCount=HAND_CARD_COUNT;
//
// const BYTE SEARCHE_COUNT = 10 ;
// ASSERT(bCardCount==13) ;
// if(bCardCount!=13) return ;
// BYTE bAllSegmentCardIndex[SEARCHE_COUNT][3][5] ; //分段扑克
//
// BYTE bSegmentScore[SEARCHE_COUNT] ; //分段权重
// BYTE bCardDataIndex[13] = {0,1,2,3,4,5,6,7,8,9,10,11,12} ; //扑克下标
// BYTE bFrontCardType , //前墩类型
// bMidCardType, //中墩类型
// bBackCardType; //后墩类型
// BYTE bCardData[5] ;
// ZeroMemory(bAllSegmentCardIndex , sizeof(bAllSegmentCardIndex)) ;
// ZeroMemory(bSegmentScore , sizeof(bSegmentScore)) ;
//
// srand((unsigned)time( NULL ));
//
// int bSegCount=0 ;
// LONG bSearchCount = 0 ;
// bool bStop = false ;
// while(false==bStop)
// {
// ++bSearchCount ;
// BYTE bCardIndex=0 ; //扑克下标
// //前墩扑克
//
//
// for(BYTE bFrontCard=0 ; bFrontCard<3 ; ++bFrontCard)
// {
// bCardIndex = rand()%(13-bFrontCard) ;
// bAllSegmentCardIndex[bSegCount][0][bFrontCard] = bCardDataIndex[bCardIndex] ;
// bCardData[bFrontCard] = m_bHandCardData[bCardDataIndex[bCardIndex]] ;
// bCardDataIndex[bCardIndex] = bCardDataIndex[13-bFrontCard-1] ;
// }
//
// m_GameLogic.SortCardList(bCardData , 3 , enDescend) ;
// bFrontCardType = m_GameLogic.GetCardType(bCardData , 3/*,m_GameLogic.btCardSpecialData*/) ;
//
// //中墩扑克
// for(BYTE bMidCard=0 ; bMidCard<5 ; ++bMidCard)
// {
// bCardIndex = rand()%(10-bMidCard) ;
// bAllSegmentCardIndex[bSegCount][1][bMidCard] = bCardDataIndex[bCardIndex] ;
// bCardData[bMidCard] = m_bHandCardData[bCardDataIndex[bCardIndex]] ;
// bCardDataIndex[bCardIndex] = bCardDataIndex[10-bMidCard-1] ;
// }
//
// m_GameLogic.SortCardList(bCardData , 5 , enDescend) ;
// bMidCardType = m_GameLogic.GetCardType(bCardData , 5/*,m_GameLogic.btCardSpecialData*/) ;
//
// //后墩扑克
// for(BYTE bBackCard=0 ; bBackCard<5 ; ++bBackCard)
// {
// bAllSegmentCardIndex[bSegCount][2][bBackCard] = bCardDataIndex[bBackCard] ;
// bCardData[bBackCard] = m_bHandCardData[bCardDataIndex[bBackCard]] ;
// }
// m_GameLogic.SortCardList(bCardData , 5 , enDescend) ;
//
//
// bBackCardType = m_GameLogic.GetCardType(bCardData , 5/*,m_GameLogic.btCardSpecialData*/) ;
//
//
// if(bBackCardType>bMidCardType && bMidCardType>bFrontCardType)
// {
// bSegmentScore[bSegCount] = bFrontCardType+bMidCardType+bBackCardType ;
// bSegCount++;
// }
//
// //恢复数据
// for(BYTE i=0 ; i<13 ; ++i)
// bCardDataIndex[i] = i ;
//
// //停止搜索
// if(bSegCount>=SEARCHE_COUNT || bSearchCount>=10000) bStop = true ;
// //搜到一个
// if(true==bStop && 0==bSegCount) bStop = false ;
//
// //搜索不到
// if(bSearchCount>=100000)
// {
// BYTE bIndex=0 ;
// for(BYTE i=0 ; i<3 ; ++i)
// for(BYTE j=0 ; j<5 ; ++j)
// bAllSegmentCardIndex[0][i][j]=bIndex++ ;
// bStop = true ;
// break ;
// }
// }
//
// //最大权重
// BYTE bMaxScore=bSegmentScore[0] ;
// BYTE bIndex=0 ;
// for(BYTE i=0 ; i<bSegCount ; ++i)
// if(bMaxScore<bSegmentScore[i])
// {
// bIndex=i ;
// bMaxScore=bSegmentScore[i] ;
// }
// //设置前墩
// for(int i=0;i<3;i++)
// {
// AllSegmentCard.bFrontCard[i]=m_bHandCardData[bAllSegmentCardIndex[bIndex][0][i]];
// }
// //设置中敦,后敦
// for(int i=0;i<5;i++)
// {
// AllSegmentCard.bMidCard[i]=m_bHandCardData[bAllSegmentCardIndex[bIndex][1][i]];
// AllSegmentCard.bBackCard[i]=m_bHandCardData[bAllSegmentCardIndex[bIndex][2][i]];
// }
// }
// m_GameLogic.SortCardList(AllSegmentCard.bFrontCard,3);
// m_GameLogic.SortCardList(AllSegmentCard.bMidCard,5);
// m_GameLogic.SortCardList(AllSegmentCard.bBackCard,5);
// m_pIAndroidUserItem->SendSocketData(SUB_C_SHOWCARD,&AllSegmentCard,sizeof(AllSegmentCard));
// }
//}
void CAndroidUserItemSink::GetAllUserDaoShu( BYTE btCard[],LONG lUserDaoShu[],WORD wChaiID,bool bSpecial)
{
return ;
}

View File

@@ -0,0 +1,95 @@
#ifndef ANDROID_USER_ITEM_SINK_HEAD_FILE
#define ANDROID_USER_ITEM_SINK_HEAD_FILE
#pragma once
#include "Stdafx.h"
#include "TableFrameSink.h"
//////////////////////////////////////////////////////////////////////////
//机器人类
class CAndroidUserItemSink : public IAndroidUserItemSink
{
//扑克变量
protected:
BYTE m_bHandCardData[HAND_CARD_COUNT]; //机器人手中的牌
BYTE m_bHandCardCount; //牌的数量
BYTE m_bSegmentCard[3][5]; //分段扑克
BYTE m_bSpecialCardData[HAND_CARD_COUNT];//特殊牌的数据
int m_nRobotPlayCount; //机器人玩的局数
int m_nRobotPlayMaxCount; //机器人最多玩的局数
bool m_bPlayer[GAME_PLAYER]; //是否有人
BYTE m_bAllUserCardData[GAME_PLAYER][HAND_CARD_COUNT];
bool m_bWait; //是否有人
TCHAR m_szRoomName[32]; //配置房间
int m_nAndroidNum;
//控件变量
protected:
CGameLogic m_GameLogic; //游戏逻辑
IAndroidUserItem * m_pIAndroidUserItem; //用户接口
//函数定义
public:
//构造函数
CAndroidUserItemSink();
//析构函数
virtual ~CAndroidUserItemSink();
private:
//银行操作
void BankOperate(BYTE cbType);
//基础接口
public:
//释放对象
virtual VOID Release() { }
//是否有效
virtual bool IsValid() { return AfxIsValidAddress(this,sizeof(CAndroidUserItemSink))?true:false; }
//接口查询
virtual void * QueryInterface(const IID & Guid, DWORD dwQueryVer);
//控制接口
public:
//初始接口
virtual bool Initialization(IUnknownEx * pIUnknownEx);
//重置接口
virtual bool RepositionSink();
//游戏事件
public:
//时间消息
virtual bool OnEventTimer(UINT nTimerID);
//游戏消息
virtual bool OnEventGameMessage(WORD wSubCmdID, void * pData, WORD wDataSize);
//游戏消息
virtual bool OnEventFrameMessage(WORD wSubCmdID, void * pData, WORD wDataSize);
//场景消息
virtual bool OnEventSceneMessage(BYTE cbGameStatus, bool bLookonOther, void * pData, WORD wDataSize);
//用户事件
public:
//用户进入
virtual void OnEventUserEnter(IAndroidUserItem * pIAndroidUserItem, bool bLookonUser);
//用户离开
virtual void OnEventUserLeave(IAndroidUserItem * pIAndroidUserItem, bool bLookonUser);
//用户积分
virtual void OnEventUserScore(IAndroidUserItem * pIAndroidUserItem, bool bLookonUser);
//用户状态
virtual void OnEventUserStatus(IAndroidUserItem * pIAndroidUserItem, bool bLookonUser);
//用户段位
virtual void OnEventUserSegment(IAndroidUserItem * pIAndroidUserItem, bool bLookonUser);
protected:
//设置分段
//bool OnSubSetSegment(const void * pBuffer , WORD wDataSize);
//玩家摊牌
//bool OnSubShowCard(const void * pBuffer , WORD wDataSize) ;
//游戏开始
bool OnSubSendCard(void * pData, WORD wDataSize);
//游戏结束
bool OnSubGameEnd(void * pData, WORD wDataSize);
void GetSpecialCard(BYTE CardData[],BYTE CardCount);
void ShowCard();
void GetAllUserDaoShu(BYTE btCard[],LONG lUserDaoShu[],WORD wChaiID,bool bSpecial);
};
//////////////////////////////////////////////////////////////////////////
#endif

View File

@@ -0,0 +1,13 @@
//
// AndroidService.RC2 - Microsoft Visual C++ 不会直接编辑的资源
//
#ifdef APSTUDIO_INVOKED
#error this file is not editable by Microsoft Visual C++
#endif //APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
// 在此处添加手动编辑的资源...
/////////////////////////////////////////////////////////////////////////////

View File

@@ -0,0 +1,16 @@
//{{NO_DEPENDENCIES}}
// Microsoft Visual C++ generated include file.
// Used by AndroidService.RC
//
// 新对象的下一些默认值
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 6000
#define _APS_NEXT_CONTROL_VALUE 6000
#define _APS_NEXT_SYMED_VALUE 6000
#define _APS_NEXT_COMMAND_VALUE 32771
#endif
#endif

View File

@@ -0,0 +1,7 @@
// stdafx.cpp : 只包括标准包含文件的源文件
// AndroidService.pch 将成为预编译头
// stdafx.obj 将包含预编译类型信息
#include "stdafx.h"

View File

@@ -0,0 +1,60 @@
#pragma once
//////////////////////////////////////////////////////////////////////////////////
#ifndef VC_EXTRALEAN
#define VC_EXTRALEAN
#endif
#ifndef WINVER
#define WINVER 0x0501
#endif
#ifndef _WIN32_WINNT
#define _WIN32_WINNT 0x0501
#endif
#ifndef _WIN32_WINDOWS
#define _WIN32_WINDOWS 0x0410
#endif
#ifndef _WIN32_IE
#define _WIN32_IE 0x0400
#endif
#define _ATL_ATTRIBUTES
#define _AFX_ALL_WARNINGS
#define _ATL_CSTRING_EXPLICIT_CONSTRUCTORS
//////////////////////////////////////////////////////////////////////////////////
//MFC 文件
#include <AfxWin.h>
#include <AfxExt.h>
#include <AfxCmn.h>
#include <AfxDisp.h>
//组件头文件
#include "..\消息定义\CMD_Thirteen.h"
//////////////////////////////////////////////////////////////////////////
//系统环境
//平台环境
#include "..\..\..\..\系统模块\服务器组件\游戏服务\GameServiceHead.h"
#ifndef _DEBUG
#ifndef _UNICODE
#pragma comment (lib,"../../../../系统模块/链接库/Ansi/KernelEngine.lib")
#else
#pragma comment (lib,"../../../../系统模块/链接库/Unicode/KernelEngine.lib")
#endif
#else
#ifndef _UNICODE
#pragma comment (lib,"../../../../系统模块/链接库/Ansi/KernelEngineD.lib")
#else
#pragma comment (lib,"../../../../系统模块/链接库/Unicode/KernelEngineD.lib")
#endif
#endif