Commit 3e364673 authored by mercury233's avatar mercury233
parents f2f54c2a c537169b
using System;
using System.IO;
using System.Collections.Generic;
using System.Text;
using System.Diagnostics;
using System.Runtime.InteropServices;
namespace BotWrapper
{
class BotWrapper
{
[DllImport("User32.dll", CharSet = CharSet.Unicode)]
public static extern int MessageBox(IntPtr hWnd, string lpText, string lpCaption, int uType);
static void Main(string[] args)
{
ProcessStartInfo startInfo = new ProcessStartInfo();
startInfo.UseShellExecute = false;
startInfo.WorkingDirectory = Path.GetFullPath("WindBot");
startInfo.FileName = startInfo.WorkingDirectory + "\\WindBot.exe";
if (args.Length == 3)
{
startInfo.CreateNoWindow = true;
startInfo.WindowStyle = ProcessWindowStyle.Hidden;
string arg = args[0].Replace("'","\"");
if (int.Parse(args[1]) == 1)
{
arg += " Hand=1";
}
arg += " Port=" + args[2];
startInfo.Arguments = arg;
}
try
{
Process.Start(startInfo);
}
catch
{
MessageBox((IntPtr)0, "WindBot can't be started!", "WindBot", 0x00000010); // MB_ICONERROR
}
}
}
}
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{0665CA3B-C14F-40EC-ABFB-AD46A695F5A3}</ProjectGuid>
<OutputType>WinExe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>BotWrapper</RootNamespace>
<AssemblyName>Bot</AssemblyName>
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<TargetFrameworkProfile />
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>x86</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>x86</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup>
<StartupObject>BotWrapper.BotWrapper</StartupObject>
</PropertyGroup>
<PropertyGroup>
<ApplicationIcon>WindBot.ico</ApplicationIcon>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="BotWrapper.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<None Include="app.config" />
<None Include="bot.conf">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</None>
</ItemGroup>
<ItemGroup>
<Content Include="WindBot.ico" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>
\ No newline at end of file
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// 有关程序集的一般信息由以下
// 控制。更改这些特性值可修改
// 与程序集关联的信息。
[assembly: AssemblyTitle("BotWrapper")]
[assembly: AssemblyDescription("The Bot.exe wrapper of WindBot.")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("IceYGO")]
[assembly: AssemblyProduct("WindBot")]
[assembly: AssemblyCopyright("Copyright © IceYGO 2017")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
//将 ComVisible 设置为 false 将使此程序集中的类型
//对 COM 组件不可见。 如果需要从 COM 访问此程序集中的类型,
//请将此类型的 ComVisible 特性设置为 true。
[assembly: ComVisible(false)]
// 如果此项目向 COM 公开,则下列 GUID 用于类型库的 ID
[assembly: Guid("0665ca3b-c14f-40ec-abfb-ad46a695f5a3")]
// 程序集的版本信息由下列四个值组成:
//
// 主版本
// 次版本
// 生成号
// 修订号
//
//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值,
// 方法是按如下所示使用“*”: :
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.0"/></startup></configuration>
#bots list
# !name
# command
# description
# flag ( 0x1=SUPPORT_MASTER_RULE_3 , 0x2=SUPPORT_NEW_MASTER_RULE )
!谜之剑士LV4-龙骑星爆
Name=谜之剑士LV4 Deck=Dragunity Dialog=swordsman.zh-CN
龙骑轴星尘龙爆裂体卡组。
3
!谜之剑士LV4-R5
Name=谜之剑士LV4 Deck='Rank V' Dialog=swordsman.zh-CN
5阶超量卡组。
3
!谜之剑士LV4-异热同心武器
Name=谜之剑士LV4 Deck='Zexal Weapons' Dialog=swordsman.zh-CN
神装电光皇卡组。
3
!琪露诺-彩虹
Name=琪露诺 Deck=Rainbow Dialog=cirno.zh-CN
全属性凡骨卡组。
3
!琪露诺-饼蛙
Name=琪露诺 Deck='Toadally Awesome' Dialog=cirno.zh-CN
大师规则三的全盛饼蛙卡组。
1
!复制植物-青眼
Name=复制植物 Deck=Blue-Eyes Dialog=copy.zh-CN
青眼卡组。
3
!复制植物-十二兽
Name=复制植物 Deck=Zoodiac Dialog=copy.zh-CN
大师规则三的十四兽卡组。
1
!尼亚-妖仙兽
Name=尼亚 Deck=Yosenju Dialog=near.zh-CN
妖仙兽卡组。
3
!尼亚-机壳
Name=尼亚 Deck=Qliphort Dialog=near.zh-CN
机壳卡组。
3
!永远之魂-削血
Name=永远之魂 Deck=Burn Dialog=soul.zh-CN
老式削血卡组。
3
!永远之魂-青蛙
Name=永远之魂 Deck=Frog Dialog=soul.zh-CN
老式青蛙卡组。
3
!永远之魂-荷鲁斯
Name=永远之魂 Deck=Horus Dialog=soul.zh-CN
老式龙族卡组。
3
!悠悠
Name=悠悠 Deck=MokeyMokey Dialog=mokey.zh-CN
沙包。
3
!悠悠王
Name=悠悠王 Deck=MokeyMokeyKing Dialog=mokey.zh-CN
大沙包。
3
!试作型机器人1732
Name=试作型机器人1732 Deck=ST1732 Dialog=zh-CN
由三盒ST17和三盒SD32组成的卡组。
2

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 15
VisualStudioVersion = 15.0.26206.0
# Visual Studio 14
VisualStudioVersion = 14.0.25420.1
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WindBot", "WindBot.csproj", "{3E7FAF67-A27D-4A61-B161-93AD4414183E}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "BotWrapper", "BotWrapper\BotWrapper.csproj", "{0665CA3B-C14F-40EC-ABFB-AD46A695F5A3}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
......@@ -21,6 +23,14 @@ Global
{3E7FAF67-A27D-4A61-B161-93AD4414183E}.Release|Any CPU.Build.0 = Release|Any CPU
{3E7FAF67-A27D-4A61-B161-93AD4414183E}.Release|x86.ActiveCfg = Release|x86
{3E7FAF67-A27D-4A61-B161-93AD4414183E}.Release|x86.Build.0 = Release|x86
{0665CA3B-C14F-40EC-ABFB-AD46A695F5A3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{0665CA3B-C14F-40EC-ABFB-AD46A695F5A3}.Debug|Any CPU.Build.0 = Debug|Any CPU
{0665CA3B-C14F-40EC-ABFB-AD46A695F5A3}.Debug|x86.ActiveCfg = Debug|Any CPU
{0665CA3B-C14F-40EC-ABFB-AD46A695F5A3}.Debug|x86.Build.0 = Debug|Any CPU
{0665CA3B-C14F-40EC-ABFB-AD46A695F5A3}.Release|Any CPU.ActiveCfg = Release|Any CPU
{0665CA3B-C14F-40EC-ABFB-AD46A695F5A3}.Release|Any CPU.Build.0 = Release|Any CPU
{0665CA3B-C14F-40EC-ABFB-AD46A695F5A3}.Release|x86.ActiveCfg = Release|Any CPU
{0665CA3B-C14F-40EC-ABFB-AD46A695F5A3}.Release|x86.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment