• 欢迎访问爱玩吧
  • 如果您觉得本站非常有看点,那么赶紧使用Ctrl+D 收藏爱玩吧

[游戏辅助]疯狂游戏大亨游戏概念设置助手(Mad Games Tycoon)

游戏推荐 aiwanyule 8年前 (2016-10-11) 已收录

游戏辅助:疯狂游戏大亨游戏概念设置助手(Mad Games Tycoon)

版本历史:

1:2016年10月05日 发布1.0版本

2:2016年10月07日 优化配置文件中技术和游戏性数值

软件界面:

[游戏辅助]疯狂游戏大亨游戏概念设置助手(Mad Games Tycoon)

运行环境点击下载:.NET Framework 4 Client Profile

疯狂游戏大亨游戏概念设置助手软件下载1:点击下载

疯狂游戏大亨游戏概念设置助手软件下载2

注意:本段内容须成功“回复本文”后“刷新本页”方可查看!

使用效果:

[游戏辅助]疯狂游戏大亨游戏概念设置助手(Mad Games Tycoon)

源代码:MainWindow.xaml.cs

 

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
/* ----------------------------------------------------------
 * 文件名称:MainWindow.xaml.cs
 *
 * 作者:秦建辉
 *
 * 微信:splashcn
 *
 * 开发环境:
 *      Visual Studio V2015
 *      .NET Framework 4 Client Profile
 *     
 * 版本历史:
 *      V1.0    2016年10月05日
 *              疯狂游戏大亨游戏概念设置助手
------------------------------------------------------------ */
using Com.FirstSolver.Splash;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Media;
namespace Splash
{
    /// <summary>
    /// MainWindow.xaml 的交互逻辑
    /// </summary>
    public partial class MainWindow : Window
    {
        /// <summary>
        /// 程序配置文件名称
        /// </summary>
        public string iniFileName = "Genres.ini";
        /// <summary>
        /// 分割字符集合
        /// </summary>
        public char[] Separator = new char[] { ',' };
        /// <summary>
        /// 游戏类型字典
        /// </summary>
        private Dictionary<string, GameGenre> AllGenreDictionary = new Dictionary<string, GameGenre>();
        public MainWindow()
        {
            InitializeComponent();
        }
        private void Window_Loaded(object sender, RoutedEventArgs e)
        {
            if (System.IO.File.Exists(iniFileName))
            {
                LINQToINI iniFile = new LINQToINI();
                if (iniFile.Load(iniFileName, true, Encoding.Unicode))
                {
                    List<KeyValuePair<string, string>> AllGenreList = new List<KeyValuePair<string, string>>();
                    // 获取分区列表
                    string[] SectionNames = iniFile.GetProfileSectionNames();
                    foreach (string cell in SectionNames)
                    {
                        GameGenre Genre = new GameGenre();
                        AllGenreDictionary.Add(cell, Genre);
                        string[] ResultSet;
                        // 类型全称
                        ResultSet = iniFile.GetProfileString(cell, "FullName");
                        Genre.FullName = ResultSet[0];
                        // 类型显示名称
                        ResultSet = iniFile.GetProfileString(cell, "DisplayName");
                        Genre.DisplayName = ResultSet[0];
                        // 目标客户
                        ResultSet = iniFile.GetProfileString(cell, "Customer");
                        Genre.Customer = ResultSet[0];
                        // 可混搭的游戏类型集合
                        ResultSet = iniFile.GetProfileString(cell, "MinorGenres");
                        Genre.MinorGenres = ResultSet[0].Split(Separator);
                        // 最佳参数
                        ResultSet = iniFile.GetProfileString(cell, "Scheme");
                        Genre.Scheme = ResultSet[0].Split(Separator);
                        // 适合的主题集合
                        ResultSet = iniFile.GetProfileString(cell, "Themes");
                        Genre.Themes = ResultSet[0].Split(Separator);
                        AllGenreList.Add(new KeyValuePair<string, string>(cell, Genre.DisplayName));
                    }
                    // 初始化主类型选择控件
                    KeyValuePair<string, string>[] AllGenres = AllGenreList.ToArray();
                    comboBoxMajorGenreA.ItemsSource = AllGenres;
                    comboBoxMajorGenreB.ItemsSource = AllGenres;
                    comboBoxMajorGenreC.ItemsSource = AllGenres;
                    return;
                }
            }
            // 读取配置文件失败
            MessageBox.Show("读取配置文件失败!程序退出……", "错误", MessageBoxButton.OK, MessageBoxImage.Error);
            Close();
        }
        private void comboBoxMajorGenreA_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            if (comboBoxMajorGenreA.SelectedIndex != -1)
            {
                comboBoxMajorGenreC.SelectedIndex = comboBoxMajorGenreA.SelectedIndex;
                List<KeyValuePair<string, string>> MinorGenreList = new List<KeyValuePair<string, string>>();
                string MajorGenre = comboBoxMajorGenreA.SelectedValue.ToString();
                foreach (string item in AllGenreDictionary[MajorGenre].MinorGenres)
                {
                    MinorGenreList.Add(new KeyValuePair<string, string>(item, AllGenreDictionary[item].DisplayName));
                }
                comboBoxMinorGenreA.ItemsSource = MinorGenreList.ToArray();
                if (comboBoxMinorGenreA.SelectedIndex != -1)
                {
                    RetrieveCommonThemes(MajorGenre, comboBoxMinorGenreA.SelectedValue.ToString());
                }
            }
        }
        private void comboBoxMinorGenreA_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            if (comboBoxMajorGenreA.SelectedIndex != -1 && comboBoxMinorGenreA.SelectedIndex != -1)
            {
                RetrieveCommonThemes(comboBoxMajorGenreA.SelectedValue.ToString(), comboBoxMinorGenreA.SelectedValue.ToString());
            }
        }
        /// <summary>
        /// 选出主类型和子类型公共的主题集合
        /// </summary>
        private void RetrieveCommonThemes(string major, string minor)
        {
            // 获取主类型对应的主题集合
            string[] MajorThemes = AllGenreDictionary[major].Themes;
            // 获取子类型对应的主题集合
            string[] MinorThemes = AllGenreDictionary[minor].Themes;
            // 选出主类型和子类型公共的主题集合
            string[] CommonThemes = (from a in MajorThemes from b in MinorThemes where string.Equals(a, b) select a).ToArray();
            if (CommonThemes != null)
            {
                StringBuilder sb = new StringBuilder();
                foreach (string item in CommonThemes) sb.Append(item + " ");
                sb.Remove(sb.Length - 1, 1);
                textBoxThemes.Text = sb.ToString();
            }
        }
        private void comboBoxMajorGenreB_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            if (comboBoxMajorGenreB.SelectedIndex != -1)
            {
                comboBoxMajorGenreC.SelectedIndex = comboBoxMajorGenreB.SelectedIndex;
                comboBoxFirstTheme.ItemsSource = AllGenreDictionary[comboBoxMajorGenreB.SelectedValue.ToString()].Themes;
            }
        }
        private void buttonMatch_Click(object sender, RoutedEventArgs e)
        {
            // 清空信息
            richTextBoxMinorGenreSecondTheme.Document.Blocks.Clear();
            if (comboBoxMajorGenreB.SelectedIndex != -1)
            {   // 获取主类型对应的主题集合
                string MajorGenre = comboBoxMajorGenreB.SelectedValue.ToString();
                string[] MajorThemes = AllGenreDictionary[MajorGenre].Themes;
                string FirstTheme = comboBoxFirstTheme.Text;
                if (!MajorThemes.Contains(FirstTheme)) return;
                FlowDocument document = richTextBoxMinorGenreSecondTheme.Document;
                foreach (string minorGenre in AllGenreDictionary[MajorGenre].MinorGenres)
                {
                    string[] MinorThemes = AllGenreDictionary[minorGenre].Themes;
                    if (MinorThemes.Contains(FirstTheme))
                    {
                        // 选出主类型和子类型公共的主题集合
                        string[] CommonThemes = (from a in MajorThemes from b in MinorThemes where !string.Equals(a, FirstTheme) && string.Equals(a, b) select a).ToArray();
                        if (CommonThemes != null)
                        {
                            StringBuilder sb = new StringBuilder();
                            foreach (string item in CommonThemes) sb.Append(item + " ");
                            sb.Remove(sb.Length - 1, 1);
                            AppendTextToDocument(AllGenreDictionary[minorGenre].DisplayName, Colors.Red, document);
                            AppendTextToDocument(sb.ToString(), Colors.Blue, document);
                        }
                    }
                }
            }
        }
        private void AppendTextToDocument(string content, Color color, FlowDocument document)
        {
            Run run = new Run(content);
            run.Foreground = new SolidColorBrush(color);
            document.Blocks.Add(new Paragraph(run));
        }
        private void comboBoxMajorGenreC_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            if (comboBoxMajorGenreC.SelectedIndex != -1)
            {
                string MajorGenre = comboBoxMajorGenreC.SelectedValue.ToString();
                // 目标市场
                textBoxCustomer.Text = AllGenreDictionary[MajorGenre].Customer;
                // 游戏玩法|画质
                slider0.Value = int.Parse(AllGenreDictionary[MajorGenre].Scheme[0]);
                // 剧情|游戏时长
                slider1.Value = int.Parse(AllGenreDictionary[MajorGenre].Scheme[1]);
                // 气氛|功能
                slider2.Value = int.Parse(AllGenreDictionary[MajorGenre].Scheme[2]);
                // 游戏深度|新手玩家
                slider3.Value = int.Parse(AllGenreDictionary[MajorGenre].Scheme[3]);
                // 核心玩家|休闲玩家
                slider4.Value = int.Parse(AllGenreDictionary[MajorGenre].Scheme[4]);               
                // 画面
                textBoxGraphics.Text = AllGenreDictionary[MajorGenre].Scheme[5];
                // 音质
                textBoxSound.Text = AllGenreDictionary[MajorGenre].Scheme[6];
                // 技术
                textBoxTechnology.Text = AllGenreDictionary[MajorGenre].Scheme[7];
                // 游戏性
                textBoxControl.Text = AllGenreDictionary[MajorGenre].Scheme[8];
            }
        }
    }
}

爱玩吧 , 版权所有丨如未注明 , 均为原创丨本网站采用BY-NC-SA协议进行授权
转载请注明原文链接:[游戏辅助]疯狂游戏大亨游戏概念设置助手(Mad Games Tycoon)
喜欢 (0)