public static string GameStrToSimpleCN(string src) { byte[] utf8bytes = System.Text.Encoding.Default.GetBytes(src); string temp = System.Text.Encoding.GetEncoding(950).GetString(utf8bytes); temp = CFormat.ToSimplified(temp); return(temp); }
public static string load_Item_Defines(string baseFolder) { m_lstDef.Clear(); string allItemDefines = ""; //baseFolder = "F:\\SanOL\\合并防挂成145版本"; string itemHFile = baseFolder + "\\" + Item_H; if (!File.Exists(itemHFile)) { return(allItemDefines); } FileStream _itemHfs = new FileStream(itemHFile, FileMode.Open, FileAccess.Read); StreamReader _itemHReader = new StreamReader(_itemHfs, Encoding.GetEncoding(950)); _itemHReader.BaseStream.Seek(0, SeekOrigin.Begin); _itemHReader.DiscardBufferedData(); _itemHReader.BaseStream.Seek(0, SeekOrigin.Begin); _itemHReader.BaseStream.Position = 0; string strLine = ""; strLine = _itemHReader.ReadLine(); do { strLine = strLine.Split('/')[0]; if (strLine.Contains("#define")) { //ToSimplified item_def item = new item_def(); string _strLine = CFormat.ToSimplified(strLine); string _nameNum = _strLine.Split(new string[] { "item_" }, StringSplitOptions.RemoveEmptyEntries)[1]; string name = _nameNum.Split(' ')[0].Split('\t')[0]; string id = _nameNum.Replace(" ", "").Replace("\t", "").Replace(name, ""); item.name = name; item.id = id; m_lstDef.Add(item); allItemDefines += name + "," + id + ";"; m_lastId = id; } strLine = ""; strLine = _itemHReader.ReadLine(); } while (strLine != null); _itemHReader.Close(); _itemHfs.Close(); return(allItemDefines.Replace("\t", "")); }
public static string GetNameByAcc(string acc) { string name = ""; foreach (var item in m_playersAttrList) { if (acc == item.Account) { name = CFormat.GameStrToSimpleCN(item.Name); break; } } return(name); }
public static AccAttr GetAttrByName(string name) { Nullable <AccAttr> result = null; foreach (var player in m_playersAttrList) { if (CFormat.GameStrToSimpleCN(player.Name) == name) { result = player; break; } } return(result.Value); }
public static int GetIdByName(string name) { int id = 0; foreach (var item in Skill_Defs) { if (item.name == CFormat.ToSimplified(name)) { id = item.id; break; } } return(id); }
public static string GetAccByName(string name) { string acc = ""; foreach (var item in m_playersAttrList) { string _name = CFormat.GameStrToSimpleCN(item.Name); if (_name == name) { acc = item.Account; break; } } return(acc); }
public static string Get_Item_itemHelpStr(string name) { string helpString = ""; baseFolder = "F:\\SanOL\\合并防挂成145版本"; string itemHelperFile = baseFolder + "\\" + Item_helper; if (!File.Exists(itemHelperFile)) { return(helpString); } FileStream _itemHelpfs = new FileStream(itemHelperFile, FileMode.Open, FileAccess.Read); StreamReader _itemHelpReader = new StreamReader(_itemHelpfs, Encoding.GetEncoding(950)); _itemHelpReader.BaseStream.Seek(0, SeekOrigin.Begin); _itemHelpReader.DiscardBufferedData(); _itemHelpReader.BaseStream.Seek(0, SeekOrigin.Begin); _itemHelpReader.BaseStream.Position = 0; string strLine = ""; strLine = _itemHelpReader.ReadLine(); do { string _strLine = CFormat.ToSimplified(strLine); if (_strLine.Contains("item") && _strLine.Contains("=")) { _strLine = _strLine.Replace(" ", "").Replace("\t", ""); string id = _strLine.Split('=')[1].Split(',')[0]; if (id == name) { helpString = _strLine.Split('=')[1].Split(',')[1]; break; } } strLine = ""; strLine = _itemHelpReader.ReadLine(); } while (strLine != null); _itemHelpReader.Close(); _itemHelpfs.Close(); return(helpString); }
private void FillPlayerLstView() { var players = CPlayerCtrl.GetAttrList(); this.lstv_playersInfo.Items.Clear(); foreach (var player in players) { string _acc = CFormat.GameStrToSimpleCN(player.Account); string _name = CFormat.GameStrToSimpleCN(player.Name); ListViewItem lvi = new ListViewItem(); //lvi.ImageIndex = i; //通过与imageList绑定,显示imageList中第i项图标 lvi.Text = _acc.Replace("\t", ""); //lvi.SubItems.Add(_id); lvi.SubItems.Add(_name); this.lstv_playersInfo.Items.Add(lvi); } this.lstv_playersInfo.EndUpdate(); //结束数据处理,UI界面一次性绘制 }
private void btn_AcountFreeze_Click(object sender, EventArgs e) { string acc = CFormat.PureString(txt_AcountName.Text); if (acc == "") { return; } //封号 string log = ""; try { log = CSGHelper.FreezeAccount(acc, 1, "手动封禁!", "GM"); LogHelper.WriteLog(System.AppDomain.CurrentDomain.BaseDirectory, acc + ":" + log, new StackTrace(new StackFrame(true))); btn_AccountReflush_Click(null, null); } catch (Exception ex) { LogHelper.WriteLog(System.AppDomain.CurrentDomain.BaseDirectory, acc + ":" + ex.Message, new StackTrace(new StackFrame(true))); } MessageBox.Show("账户:" + acc + log); }
static public item_attr Get_Attr_ByName(string name, out bool done) { item_attr attr = new item_attr(); attr.code = "item_" + name; baseFolder = "F:\\SanOL\\合并防挂成145版本"; string itemDataFile = baseFolder + "\\" + Item_data; if (!File.Exists(itemDataFile)) { done = false; return(attr); } FileStream _itemDatafs = new FileStream(itemDataFile, FileMode.Open, FileAccess.Read); StreamReader _itemDataReader = new StreamReader(_itemDatafs, Encoding.GetEncoding(950)); _itemDataReader.BaseStream.Seek(0, SeekOrigin.Begin); _itemDataReader.DiscardBufferedData(); _itemDataReader.BaseStream.Seek(0, SeekOrigin.Begin); _itemDataReader.BaseStream.Position = 0; string strLine = ""; strLine = _itemDataReader.ReadLine(); bool get_it = false; do { string _strLine = CFormat.ToSimplified(strLine); _strLine = _strLine.Split('/')[0].Replace("\t", "").Replace(" ", ""); if (get_it && _strLine == "[item]") { break; } if (_strLine.Contains("item_" + name)) { get_it = true; } if (get_it) { string _type = _strLine.Split('=')[0]; if (_type == "code") { attr.code = "item_" + name; } else if (_type == "name") { attr.name = _strLine.Split('=')[1]; } else if (_type == "help_string") { attr.help_string = _strLine.Split('=')[1]; } else if (_type == "type") { attr.type = _strLine.Split('=')[1]; } else if (_type == "super_type") { attr.super_type = _strLine.Split('=')[1]; } else if (_type == "type2") { attr.type2 = _strLine.Split('=')[1]; } else if (_type == "wait_type") { attr.wait_type = _strLine.Split('=')[1]; } else if (_type == "attack_range") { attr.attack_range = _strLine.Split('=')[1]; } else if (_type == "effect_range") { attr.effect_range = _strLine.Split('=')[1]; } else if (_type == "add_attack_power") { attr.add_attack_power = _strLine.Split('=')[1]; } else if (_type == "attack_speed") { attr.attack_speed = _strLine.Split('=')[1]; } else if (_type == "add_weapon_hit") { attr.add_weapon_hit = _strLine.Split('=')[1]; } else if (_type == "add_attr_mind") { attr.add_attr_mind = _strLine.Split('=')[1]; } else if (_type == "add_magic_power") { attr.add_magic_power = _strLine.Split('=')[1]; } else if (_type == "add_attr_con") { attr.add_attr_con = _strLine.Split('=')[1]; } else if (_type == "add_attackx2_ratio") { attr.add_attackx2_ratio = _strLine.Split('=')[1]; } else if (_type == "add_attr_int") { attr.add_attr_int = _strLine.Split('=')[1]; } else if (_type == "add_attr_str") { attr.add_attr_str = _strLine.Split('=')[1]; } else if (_type == "add_attr_dex") { attr.add_attr_dex = _strLine.Split('=')[1]; } else if (_type == "add_hp") { attr.add_hp = _strLine.Split('=')[1]; } else if (_type == "add_mp") { attr.add_mp = _strLine.Split('=')[1]; } else if (_type == "add_attr_leader") { attr.add_attr_leader = _strLine.Split('=')[1]; } else if (_type == "add_defense") { attr.add_defense = _strLine.Split('=')[1]; } else if (_type == "add_weapon_misshit") { attr.add_weapon_misshit = _strLine.Split('=')[1]; } else if (_type == "move") { attr.move = _strLine.Split('=')[1]; } else if (_type == "add_st") { attr.add_st = _strLine.Split('=')[1]; } else if (_type == "add_loyalty") { attr.add_loyalty = _strLine.Split('=')[1]; } else if (_type == "light") { attr.light = _strLine.Split('=')[1]; } else if (_type == "eq_magic_attack_type") { if (attr.eq_magic_attack_type != null && attr.eq_magic_attack_type != "") { attr.eq_magic_attack_type += ";" + _strLine.Split('=')[1]; } else { attr.eq_magic_attack_type = _strLine.Split('=')[1]; } } else if (_type == "limit_level") { attr.limit_level = _strLine.Split('=')[1]; } else if (_type == "weight") { attr.weight = _strLine.Split('=')[1]; } else if (_type == "cost") { attr.cost = _strLine.Split('=')[1]; } else if (_type == "sell") { attr.sell = _strLine.Split('=')[1]; } else if (_type == "cost_level") { attr.cost_level = _strLine.Split('=')[1]; } else if (_type == "icon") { attr.icon = _strLine.Split('=')[1]; } else if (_type == "sfx_hit") { attr.sfx_hit = _strLine.Split('=')[1]; } else if (_type == "sfx_attack") { attr.sfx_attack = _strLine.Split('=')[1]; } else if (_type == "comp_times") { attr.comp_times = _strLine.Split('=')[1]; } else if (_type == "limit_job") { attr.limit_job = _strLine.Split('=')[1]; } else if (_type == "wid") { attr.wid = _strLine.Split('=')[1]; } else if (_type == "sp_effect") { attr.sp_effect = _strLine.Split('=')[1]; } else if (_type == "soul_times") { attr.soul_times = _strLine.Split('=')[1]; } else if (_type == "function") { if (attr.function != null && attr.function != "") { attr.function += ";" + _strLine.Split('=')[1]; } else { attr.function = _strLine.Split('=')[1]; } } else if (_type == "anti_status_ratio") { if (attr.anti_status_ratio != null && attr.anti_status_ratio != "") { attr.anti_status_ratio += ";" + _strLine.Split('=')[1]; } else { attr.anti_status_ratio = _strLine.Split('=')[1]; } } else if (_type == "limit_str") { attr.limit_str = _strLine.Split('=')[1]; } else if (_type == "limit_mind") { attr.limit_mind = _strLine.Split('=')[1]; } else if (_type == "limit_dex") { attr.limit_dex = _strLine.Split('=')[1]; } else if (_type == "limit_int") { attr.limit_int = _strLine.Split('=')[1]; } else if (_type == "limit_leader") { attr.limit_leader = _strLine.Split('=')[1]; } else if (_type == "new_exp") { attr.new_exp = _strLine.Split('=')[1]; } else if (_type == "new_explevel") { attr.new_explevel = _strLine.Split('=')[1]; } else if (_type == "kill") { attr.kill = _strLine.Split('=')[1]; } else if (_type == "drop_id") { attr.drop_id = _strLine.Split('=')[1]; } else if (_type == "use_magic_id") { attr.use_magic_id = _strLine.Split('=')[1]; } else if (_type == "drop_num") { attr.drop_num = _strLine.Split('=')[1]; } else if (_type == "eq_magic_resist") { if (attr.eq_magic_resist != null && attr.eq_magic_resist != "") { attr.eq_magic_resist += ";" + _strLine.Split('=')[1]; } else { attr.eq_magic_resist = _strLine.Split('=')[1]; } } else if (_type == "limit_sex") { attr.limit_sex = _strLine.Split('=')[1]; } else if (_type == "engineer_type") { attr.engineer_type = _strLine.Split('=')[1]; } else if (_type == "duedate_only") { attr.duedate_only = _strLine.Split('=')[1]; } else if (_type == "use_duedate") { attr.use_duedate = _strLine.Split('=')[1]; } else if (_type == "sfx_run") { attr.sfx_run = _strLine.Split('=')[1]; } else if (_type == "sfx_walk") { attr.sfx_walk = _strLine.Split('=')[1]; } else if (_type == "horse_height") { attr.horse_height = _strLine.Split('=')[1]; } else if (_type == "wawa_only") { attr.wawa_only = _strLine.Split('=')[1]; } else if (_type == "no_attack") { attr.no_attack = _strLine.Split('=')[1]; } else if (_type == "other_wid") { attr.other_wid = _strLine.Split('=')[1]; } else if (_type == "use_magic_time") { attr.use_magic_time = _strLine.Split('=')[1]; } else if (_type == "use_magic_level") { attr.use_magic_level = _strLine.Split('=')[1]; } else if (_type == "tp_map_code") { attr.tp_map_code = _strLine.Split('=')[1]; } else if (_type == "tp_pos") { attr.tp_pos = _strLine.Split('=')[1]; } else if (_type == "letto_gold") { attr.letto_gold = _strLine.Split('=')[1]; } else if (_type == "resurrect_soldier") { attr.resurrect_soldier = _strLine.Split('=')[1]; } else if (_type == "recommand_soldier") { attr.recommand_soldier = _strLine.Split('=')[1]; } } strLine = ""; strLine = _itemDataReader.ReadLine(); } while (strLine != null); _itemDataReader.Close(); _itemDatafs.Close(); done = true; return(attr); }
private void FreezeCheck() { //读取loginserverlog,获取非法信息列表 List <Illegal> nameList = GetIllegalList(); int FreezeCount = 0; int IllCount = 0; //更新列表 lstv_GtList.Items.Clear(); foreach (var name in nameList) { //过滤 if (m_FreezeFilterList != null) { bool filter = false; String PureAcount = CFormat.PureString(name.account); foreach (var item in m_FreezeFilterList) { if (PureAcount == item) { filter = true; break; } } if (filter) { continue; } } IllCount++; ListViewItem lvi = new ListViewItem(); lvi.Text = CFormat.PureString(name.account); //lvi.SubItems.Add(_id); lvi.SubItems.Add(CFormat.ToSimplified(CFormat.PureString(name.name))); lvi.SubItems.Add(name.time_str); if (cbx_AutoFreeze.Checked) { string acc = CFormat.PureString(name.account); //封号 try { string log = CSGHelper.FreezeAccount(acc, 1, "非法登录或者使用外挂!", "GM"); lvi.SubItems.Add(log); if (log == "冻结成功") { FreezeCount++; } LogHelper.WriteLog(System.AppDomain.CurrentDomain.BaseDirectory, acc + ":" + log, new StackTrace(new StackFrame(true))); } catch (Exception ex) { LogHelper.WriteLog(System.AppDomain.CurrentDomain.BaseDirectory, acc + ":" + ex.Message, new StackTrace(new StackFrame(true))); } } lstv_GtList.Items.Add(lvi); } lstv_GtList.EndUpdate(); lbl_IllCount.Text = IllCount.ToString(); lbl_FreezeCount.Text = FreezeCount.ToString(); }
public static string load_Skill_Defines(string baseFolder) { string allSkillDefines = ""; Skill_Defs.Clear(); //baseFolder = "F:\\SanOL\\合并防挂成145版本"; string itemHFile = baseFolder + "\\" + "MAGIC.H"; if (!File.Exists(itemHFile)) { return(allSkillDefines); } FileStream _itemHfs = new FileStream(itemHFile, FileMode.Open, FileAccess.Read); StreamReader _itemHReader = new StreamReader(_itemHfs, Encoding.GetEncoding(950)); _itemHReader.BaseStream.Seek(0, SeekOrigin.Begin); _itemHReader.DiscardBufferedData(); _itemHReader.BaseStream.Seek(0, SeekOrigin.Begin); _itemHReader.BaseStream.Position = 0; Skills_Def_Str def; string strLine = ""; strLine = _itemHReader.ReadLine(); do { strLine = strLine.Split('/')[0]; if (strLine.Contains("#define")) { //ToSimplified string _strLine = CFormat.ToSimplified(strLine); string _nameNum = _strLine.Split(new string[] { "magic_" }, StringSplitOptions.RemoveEmptyEntries)[1]; string name = _nameNum.Split(' ')[0].Split('\t')[0]; string id = _nameNum.Replace(" ", "").Replace("\\t", "").Replace(name, ""); allSkillDefines += name + "," + id + ";"; def.name = name; def.id = Int32.Parse(id); Skill_Defs.Add(def); } strLine = ""; strLine = _itemHReader.ReadLine(); } while (strLine != null); _itemHReader.Close(); _itemHfs.Close(); //-------------------------------------------------------------------------------------------------- itemHFile = baseFolder + "\\" + "MAGIC_EXP.H"; if (!File.Exists(itemHFile)) { return(allSkillDefines); } _itemHfs = new FileStream(itemHFile, FileMode.Open, FileAccess.Read); _itemHReader = new StreamReader(_itemHfs, Encoding.GetEncoding(950)); _itemHReader.BaseStream.Seek(0, SeekOrigin.Begin); _itemHReader.DiscardBufferedData(); _itemHReader.BaseStream.Seek(0, SeekOrigin.Begin); _itemHReader.BaseStream.Position = 0; strLine = ""; strLine = _itemHReader.ReadLine(); do { strLine = strLine.Split('/')[0]; if (strLine.Contains("#define")) { //ToSimplified string _strLine = CFormat.ToSimplified(strLine); string _nameNum = _strLine.Split(new string[] { "magic_" }, StringSplitOptions.RemoveEmptyEntries)[1]; string name = _nameNum.Split(' ')[0].Split('\t')[0]; string id = _nameNum.Replace(" ", "").Replace("\\t", "").Replace(name, ""); allSkillDefines += name + "," + id + ";"; def.name = name; def.id = Int32.Parse(id); Skill_Defs.Add(def); } strLine = ""; strLine = _itemHReader.ReadLine(); } while (strLine != null); _itemHReader.Close(); _itemHfs.Close(); return(allSkillDefines.Replace("\t", "")); }
private void btn_bxSend_Click(object sender, EventArgs e) { if (!m_Active) { MessageBox.Show("软件尚未激活! 请联系软件发布人给予激活!"); return; } if (txt_xbAccount.Text != string.Empty) { int xbCount1 = 0; int xbCount2 = 0; int xbCount3 = 0; int xbCount4 = 0; int xbCount5 = 0; int xbCount6 = 0; int xbCount7 = 0; int xbCount8 = 0; int xbCount9 = 0; int xbCount10 = 0; int xbId1 = 1; int xbId2 = 1; int xbId3 = 1; int xbId4 = 1; int xbId5 = 1; int xbId6 = 1; int xbId7 = 1; int xbId8 = 1; int xbId9 = 1; int xbId10 = 1; if (!string.IsNullOrEmpty(txt_xbCount1.Text) || CFormat.isNumberic(txt_xbCount1.Text)) { xbCount1 = Convert.ToInt32(txt_xbCount1.Text); } if (!string.IsNullOrEmpty(txt_xbCount2.Text) || CFormat.isNumberic(txt_xbCount2.Text)) { xbCount2 = Convert.ToInt32(txt_xbCount2.Text); } if (!string.IsNullOrEmpty(txt_xbCount3.Text) || CFormat.isNumberic(txt_xbCount3.Text)) { xbCount3 = Convert.ToInt32(txt_xbCount3.Text); } if (!string.IsNullOrEmpty(txt_xbCount4.Text) || CFormat.isNumberic(txt_xbCount4.Text)) { xbCount4 = Convert.ToInt32(txt_xbCount4.Text); } if (!string.IsNullOrEmpty(txt_xbCount5.Text) || CFormat.isNumberic(txt_xbCount5.Text)) { xbCount5 = Convert.ToInt32(txt_xbCount5.Text); } if (!string.IsNullOrEmpty(txt_xbCount6.Text) || CFormat.isNumberic(txt_xbCount6.Text)) { xbCount6 = Convert.ToInt32(txt_xbCount6.Text); } if (!string.IsNullOrEmpty(txt_xbCount7.Text) || CFormat.isNumberic(txt_xbCount7.Text)) { xbCount7 = Convert.ToInt32(txt_xbCount7.Text); } if (!string.IsNullOrEmpty(txt_xbCount8.Text) || CFormat.isNumberic(txt_xbCount8.Text)) { xbCount8 = Convert.ToInt32(txt_xbCount8.Text); } if (!string.IsNullOrEmpty(txt_xbCount9.Text) || CFormat.isNumberic(txt_xbCount9.Text)) { xbCount9 = Convert.ToInt32(txt_xbCount9.Text); } if (!string.IsNullOrEmpty(txt_xbCount10.Text) || CFormat.isNumberic(txt_xbCount10.Text)) { xbCount10 = Convert.ToInt32(txt_xbCount10.Text); } if (!string.IsNullOrEmpty(txt_xbId1.Text) || CFormat.isNumberic(txt_xbId1.Text)) { xbId1 = Convert.ToInt32(txt_xbId1.Text); if (xbId1 == 0) { xbId1 = 1; xbCount1 = 0; } } if (!string.IsNullOrEmpty(txt_xbId2.Text) || CFormat.isNumberic(txt_xbId2.Text)) { xbId2 = Convert.ToInt32(txt_xbId2.Text); if (xbId2 == 0) { xbId2 = 1; xbCount2 = 0; } } if (!string.IsNullOrEmpty(txt_xbId3.Text) || CFormat.isNumberic(txt_xbId3.Text)) { xbId3 = Convert.ToInt32(txt_xbId3.Text); if (xbId3 == 0) { xbId3 = 1; xbCount3 = 0; } } if (!string.IsNullOrEmpty(txt_xbId4.Text) || CFormat.isNumberic(txt_xbId4.Text)) { xbId4 = Convert.ToInt32(txt_xbId4.Text); if (xbId4 == 0) { xbId4 = 1; xbCount4 = 0; } } if (!string.IsNullOrEmpty(txt_xbId5.Text) || CFormat.isNumberic(txt_xbId5.Text)) { xbId5 = Convert.ToInt32(txt_xbId5.Text); if (xbId5 == 0) { xbId5 = 1; xbCount5 = 0; } } if (!string.IsNullOrEmpty(txt_xbId6.Text) || CFormat.isNumberic(txt_xbId6.Text)) { xbId6 = Convert.ToInt32(txt_xbId6.Text); if (xbId6 == 0) { xbId6 = 1; xbCount6 = 0; } } if (!string.IsNullOrEmpty(txt_xbId7.Text) || CFormat.isNumberic(txt_xbId7.Text)) { xbId7 = Convert.ToInt32(txt_xbId7.Text); if (xbId7 == 0) { xbId7 = 1; xbCount7 = 0; } } if (!string.IsNullOrEmpty(txt_xbId8.Text) || CFormat.isNumberic(txt_xbId8.Text)) { xbId8 = Convert.ToInt32(txt_xbId8.Text); if (xbId8 == 0) { xbId8 = 1; xbCount8 = 0; } } if (!string.IsNullOrEmpty(txt_xbId9.Text) || CFormat.isNumberic(txt_xbId9.Text)) { xbId9 = Convert.ToInt32(txt_xbId9.Text); if (xbId9 == 0) { xbId9 = 1; xbCount9 = 0; } } if (!string.IsNullOrEmpty(txt_xbId10.Text) || CFormat.isNumberic(txt_xbId10.Text)) { xbId10 = Convert.ToInt32(txt_xbId10.Text); if (xbId10 == 0) { xbId10 = 1; xbCount10 = 0; } } string msg = "\n" + "账户:" + txt_xbAccount.Text + "\n" + "角色:" + txt_xbName.Text + "\n" + "代币:" + txt_dbSend.Text + "\n"; if (txt_xbId1.Text != "" && xbCount1 != 0) { msg += "物品:" + txt_xbName1.Text + "\t数量:" + txt_xbCount1.Text + "\t\n"; } if (txt_xbId2.Text != "" && xbCount2 != 0) { msg += "物品:" + txt_xbName2.Text + "\t数量:" + txt_xbCount2.Text + "\t\n"; } if (txt_xbId3.Text != "" && xbCount3 != 0) { msg += "物品:" + txt_xbName3.Text + "\t数量:" + txt_xbCount3.Text + "\t\n"; } if (txt_xbId4.Text != "" && xbCount4 != 0) { msg += "物品:" + txt_xbName4.Text + "\t数量:" + txt_xbCount4.Text + "\t\n"; } if (txt_xbId5.Text != "" && xbCount5 != 0) { msg += "物品:" + txt_xbName5.Text + "\t数量:" + txt_xbCount5.Text + "\t\n"; } if (txt_xbId6.Text != "" && xbCount6 != 0) { msg += "物品:" + txt_xbName6.Text + "\t数量:" + txt_xbCount6.Text + "\t\n"; } if (txt_xbId7.Text != "" && xbCount7 != 0) { msg += "物品:" + txt_xbName7.Text + "\t数量:" + txt_xbCount7.Text + "\t\n"; } if (txt_xbId8.Text != "" && xbCount8 != 0) { msg += "物品:" + txt_xbName8.Text + "\t数量:" + txt_xbCount8.Text + "\t\n"; } if (txt_xbId9.Text != "" && xbCount9 != 0) { msg += "物品:" + txt_xbName9.Text + "\t数量:" + txt_xbCount9.Text + "\t\n"; } if (txt_xbId10.Text != "" && xbCount10 != 0) { msg += "物品:" + txt_xbName10.Text + "\t数量:" + txt_xbCount10.Text + "\t\n"; } msg += "\n确认信息无误?"; DialogResult dr = MessageBox.Show(msg, "对话框标题", MessageBoxButtons.OKCancel, MessageBoxIcon.Question); if (dr != DialogResult.OK) { return; } //确保有效 if ((txt_xbId1.Text == "" || xbCount1 == 0) && (txt_xbId2.Text == "" || xbCount2 == 0) && (txt_xbId3.Text == "" || xbCount3 == 0) && (txt_xbId4.Text == "" || xbCount4 == 0) && (txt_xbId5.Text == "" || xbCount5 == 0)) { } else { string cmd = "INSERT INTO " + txt_sanvtName.Text + @".dbo.vitem (Account,Disable,Card,Login_time,Get_time,SName,CharName,Type," + "DataID1,Number1,DataID2,Number2,DataID3,Number3,DataID4,Number4,DataID5,Number5)" + "values ('" + txt_xbAccount.Text + "',0,CONVERT(varchar(100), GETDATE(), 21),getdate(),getdate(),0,0,0," + xbId1 + "," + xbCount1 + "," + xbId2 + "," + xbCount2 + "," + xbId3 + "," + xbCount3 + "," + xbId4 + "," + xbCount4 + "," + xbId5 + "," + xbCount5 + ")"; string ret = CSGHelper.SqlCommand(cmd); if (ret == "success") { SGExHandle.WriteXbLog(txt_xbAccount.Text + "\t" + txt_xbName.Text + "\t" + txt_xbId1.Text + "\t" + txt_xbName1.Text + "\t" + txt_xbCount1.Text + "\t" + txt_xbId2.Text + "\t" + txt_xbName2.Text + "\t" + txt_xbCount2.Text + "\t" + txt_xbId4.Text + "\t" + txt_xbName3.Text + "\t" + txt_xbCount3.Text + "\t" + txt_xbId5.Text + "\t" + txt_xbName4.Text + "\t" + txt_xbCount4.Text + "\t" + txt_xbId6.Text + "\t" + txt_xbName5.Text + "\t" + txt_xbCount5.Text + "\t"); ListViewItem lvi = new ListViewItem(); lvi.Text = txt_xbAccount.Text; lvi.SubItems.Add(txt_xbName.Text); lvi.SubItems.Add(txt_xbId1.Text); lvi.SubItems.Add(txt_xbName1.Text); lvi.SubItems.Add(txt_xbCount1.Text); lvi.SubItems.Add(txt_xbId2.Text); lvi.SubItems.Add(txt_xbName2.Text); lvi.SubItems.Add(txt_xbCount2.Text); lvi.SubItems.Add(txt_xbId3.Text); lvi.SubItems.Add(txt_xbName3.Text); lvi.SubItems.Add(txt_xbCount3.Text); lvi.SubItems.Add(txt_xbId4.Text); lvi.SubItems.Add(txt_xbName4.Text); lvi.SubItems.Add(txt_xbCount4.Text); lvi.SubItems.Add(txt_xbId5.Text); lvi.SubItems.Add(txt_xbName5.Text); lvi.SubItems.Add(txt_xbCount5.Text); lstv_xblog.Items.Add(lvi); } else { string msg2 = "\n" + "账户:" + txt_xbAccount.Text + "\n" + "角色:" + txt_xbName.Text + "\n"; if (txt_xbId1.Text != "" && xbCount1 != 0) { msg += "物品:" + txt_xbName1.Text + "\t数量:" + txt_xbCount1.Text + "\t\n"; } if (txt_xbId2.Text != "" && xbCount2 != 0) { msg += "物品:" + txt_xbName2.Text + "\t数量:" + txt_xbCount2.Text + "\t\n"; } if (txt_xbId3.Text != "" && xbCount3 != 0) { msg += "物品:" + txt_xbName3.Text + "\t数量:" + txt_xbCount3.Text + "\t\n"; } if (txt_xbId4.Text != "" && xbCount4 != 0) { msg += "物品:" + txt_xbName4.Text + "\t数量:" + txt_xbCount4.Text + "\t\n"; } if (txt_xbId5.Text != "" && xbCount5 != 0) { msg += "物品:" + txt_xbName5.Text + "\t数量:" + txt_xbCount5.Text + "\t\n"; } MessageBox.Show("发送失败,\t\n" + msg2); } } Thread.Sleep(200); if ((txt_xbId6.Text == "" || xbCount6 == 0) && (txt_xbId7.Text == "" || xbCount7 == 0) && (txt_xbId8.Text == "" || xbCount8 == 0) && (txt_xbId9.Text == "" || xbCount9 == 0) && (txt_xbId10.Text == "" || xbCount10 == 0)) { } else { string cmd = "INSERT INTO " + txt_sanvtName.Text + @".dbo.vitem (Account,Disable,Card,Login_time,Get_time,SName,CharName,Type," + "DataID1,Number1,DataID2,Number2,DataID3,Number3,DataID4,Number4,DataID5,Number5)" + "values ('" + txt_xbAccount.Text + "',0,CONVERT(varchar(100), GETDATE(), 21),getdate(),getdate(),0,0,0," + xbId6 + "," + xbCount6 + "," + xbId7 + "," + xbCount7 + "," + xbId8 + "," + xbCount8 + "," + xbId9 + "," + xbCount9 + "," + xbId10 + "," + xbCount10 + ")"; string ret = CSGHelper.SqlCommand(cmd); if (ret == "success") { SGExHandle.WriteXbLog(txt_xbAccount.Text + "\t" + txt_xbName.Text + "\t" + txt_xbId6.Text + "\t" + txt_xbName6.Text + "\t" + txt_xbCount6.Text + "\t" + txt_xbId7.Text + "\t" + txt_xbName7.Text + "\t" + txt_xbCount7.Text + "\t" + txt_xbId8.Text + "\t" + txt_xbName8.Text + "\t" + txt_xbCount8.Text + "\t" + txt_xbId9.Text + "\t" + txt_xbName9.Text + "\t" + txt_xbCount9.Text + "\t" + txt_xbId10.Text + "\t" + txt_xbName10.Text + "\t" + txt_xbCount10.Text + "\t"); ListViewItem lvi = new ListViewItem(); lvi.Text = txt_xbAccount.Text; lvi.SubItems.Add(txt_xbName.Text); lvi.SubItems.Add(txt_xbId6.Text); lvi.SubItems.Add(txt_xbName6.Text); lvi.SubItems.Add(txt_xbCount6.Text); lvi.SubItems.Add(txt_xbId7.Text); lvi.SubItems.Add(txt_xbName7.Text); lvi.SubItems.Add(txt_xbCount7.Text); lvi.SubItems.Add(txt_xbId8.Text); lvi.SubItems.Add(txt_xbName8.Text); lvi.SubItems.Add(txt_xbCount8.Text); lvi.SubItems.Add(txt_xbId9.Text); lvi.SubItems.Add(txt_xbName9.Text); lvi.SubItems.Add(txt_xbCount9.Text); lvi.SubItems.Add(txt_xbId10.Text); lvi.SubItems.Add(txt_xbName10.Text); lvi.SubItems.Add(txt_xbCount10.Text); lstv_xblog.Items.Add(lvi); } else { string msg2 = "\n" + "账户:" + txt_xbAccount.Text + "\n" + "角色:" + txt_xbName.Text + "\n"; if (txt_xbId6.Text != "" && xbCount6 != 0) { msg += "物品:" + txt_xbName6.Text + "\t数量:" + txt_xbCount6.Text + "\t\n"; } if (txt_xbId7.Text != "" && xbCount7 != 0) { msg += "物品:" + txt_xbName7.Text + "\t数量:" + txt_xbCount7.Text + "\t\n"; } if (txt_xbId8.Text != "" && xbCount8 != 0) { msg += "物品:" + txt_xbName8.Text + "\t数量:" + txt_xbCount8.Text + "\t\n"; } if (txt_xbId9.Text != "" && xbCount9 != 0) { msg += "物品:" + txt_xbName9.Text + "\t数量:" + txt_xbCount9.Text + "\t\n"; } if (txt_xbId10.Text != "" && xbCount10 != 0) { msg += "物品:" + txt_xbName10.Text + "\t数量:" + txt_xbCount10.Text + "\t\n"; } MessageBox.Show("发送失败,\t\n" + msg2); } } Thread.Sleep(200); //代币 if (!string.IsNullOrEmpty(txt_dbSend.Text) && CFormat.isNumberic(txt_dbSend.Text)) { int dbCount = Convert.ToInt32(txt_dbSend.Text); if (dbCount > 0) { //虚宝增加 string cmd = "DECLARE @account varchar(21) \n" + "DECLARE @point int \n" + "DECLARE @old_point int \n" + "DECLARE @new_point int \n" + "set @account = '" + txt_xbAccount.Text + "' \n" + "set @point = " + dbCount + " \n" + "Select @old_point=point from dbo.game_acc where account = @account \n" + "SET @new_point = @point + @old_point \n" + "Update dbo.game_acc set point = @new_point where account = @account"; string ret = CSGHelper.SqlCommand(cmd); if (ret == "success") { txt_dbCurr.Text = "" + CSGHelper.SelectAcountPoint(txt_xbAccount.Text); } else { MessageBox.Show("发送代币失败,代币:" + dbCount); } } } if (cbx_xbconf.Text == "新人起步") { m_SGExHandle.SendWorldWords("新人玩家 " + txt_xbName.Text + " 的新手起步已经发放,请到大鸿胪处领取虚宝,欢迎加入大家庭,祝游戏愉快。"); } } else { MessageBox.Show("请核对发放帐号!"); } }
private void btn_bxSend_Click(object sender, EventArgs e) { if (!m_Active) { MessageBox.Show("软件尚未激活! 请联系软件发布人给予激活!"); return; } if (txt_xbAccount.Text != string.Empty) { int xbCount1 = 0; int xbCount2 = 0; int xbCount3 = 0; int xbCount4 = 0; int xbCount5 = 0; int xbCount6 = 0; int xbCount7 = 0; int xbCount8 = 0; int xbCount9 = 0; int xbCount10 = 0; int xbId1 = 1; int xbId2 = 1; int xbId3 = 1; int xbId4 = 1; int xbId5 = 1; int xbId6 = 1; int xbId7 = 1; int xbId8 = 1; int xbId9 = 1; int xbId10 = 1; if (!string.IsNullOrEmpty(txt_xbCount1.Text) || CFormat.isNumberic(txt_xbCount1.Text)) { xbCount1 = Convert.ToInt32(txt_xbCount1.Text); } if (!string.IsNullOrEmpty(txt_xbCount2.Text) || CFormat.isNumberic(txt_xbCount2.Text)) { xbCount2 = Convert.ToInt32(txt_xbCount2.Text); } if (!string.IsNullOrEmpty(txt_xbCount3.Text) || CFormat.isNumberic(txt_xbCount3.Text)) { xbCount3 = Convert.ToInt32(txt_xbCount3.Text); } if (!string.IsNullOrEmpty(txt_xbCount4.Text) || CFormat.isNumberic(txt_xbCount4.Text)) { xbCount4 = Convert.ToInt32(txt_xbCount4.Text); } if (!string.IsNullOrEmpty(txt_xbCount5.Text) || CFormat.isNumberic(txt_xbCount5.Text)) { xbCount5 = Convert.ToInt32(txt_xbCount5.Text); } if (!string.IsNullOrEmpty(txt_xbCount6.Text) || CFormat.isNumberic(txt_xbCount6.Text)) { xbCount6 = Convert.ToInt32(txt_xbCount6.Text); } if (!string.IsNullOrEmpty(txt_xbCount7.Text) || CFormat.isNumberic(txt_xbCount7.Text)) { xbCount7 = Convert.ToInt32(txt_xbCount7.Text); } if (!string.IsNullOrEmpty(txt_xbCount8.Text) || CFormat.isNumberic(txt_xbCount8.Text)) { xbCount8 = Convert.ToInt32(txt_xbCount8.Text); } if (!string.IsNullOrEmpty(txt_xbCount9.Text) || CFormat.isNumberic(txt_xbCount9.Text)) { xbCount9 = Convert.ToInt32(txt_xbCount9.Text); } if (!string.IsNullOrEmpty(txt_xbCount10.Text) || CFormat.isNumberic(txt_xbCount10.Text)) { xbCount10 = Convert.ToInt32(txt_xbCount10.Text); } if (!string.IsNullOrEmpty(txt_xbId1.Text) || CFormat.isNumberic(txt_xbId1.Text)) { xbId1 = Convert.ToInt32(txt_xbId1.Text); if (xbId1 == 0) { xbId1 = 1; xbCount1 = 0; } } if (!string.IsNullOrEmpty(txt_xbId2.Text) || CFormat.isNumberic(txt_xbId2.Text)) { xbId2 = Convert.ToInt32(txt_xbId2.Text); if (xbId2 == 0) { xbId2 = 1; xbCount2 = 0; } } if (!string.IsNullOrEmpty(txt_xbId3.Text) || CFormat.isNumberic(txt_xbId3.Text)) { xbId3 = Convert.ToInt32(txt_xbId3.Text); if (xbId3 == 0) { xbId3 = 1; xbCount3 = 0; } } if (!string.IsNullOrEmpty(txt_xbId4.Text) || CFormat.isNumberic(txt_xbId4.Text)) { xbId4 = Convert.ToInt32(txt_xbId4.Text); if (xbId4 == 0) { xbId4 = 1; xbCount4 = 0; } } if (!string.IsNullOrEmpty(txt_xbId5.Text) || CFormat.isNumberic(txt_xbId5.Text)) { xbId5 = Convert.ToInt32(txt_xbId5.Text); if (xbId5 == 0) { xbId5 = 1; xbCount5 = 0; } } if (!string.IsNullOrEmpty(txt_xbId6.Text) || CFormat.isNumberic(txt_xbId6.Text)) { xbId6 = Convert.ToInt32(txt_xbId6.Text); if (xbId6 == 0) { xbId6 = 1; xbCount6 = 0; } } if (!string.IsNullOrEmpty(txt_xbId7.Text) || CFormat.isNumberic(txt_xbId7.Text)) { xbId7 = Convert.ToInt32(txt_xbId7.Text); if (xbId7 == 0) { xbId7 = 1; xbCount7 = 0; } } if (!string.IsNullOrEmpty(txt_xbId8.Text) || CFormat.isNumberic(txt_xbId8.Text)) { xbId8 = Convert.ToInt32(txt_xbId8.Text); if (xbId8 == 0) { xbId8 = 1; xbCount8 = 0; } } if (!string.IsNullOrEmpty(txt_xbId9.Text) || CFormat.isNumberic(txt_xbId9.Text)) { xbId9 = Convert.ToInt32(txt_xbId9.Text); if (xbId9 == 0) { xbId9 = 1; xbCount9 = 0; } } if (!string.IsNullOrEmpty(txt_xbId10.Text) || CFormat.isNumberic(txt_xbId10.Text)) { xbId10 = Convert.ToInt32(txt_xbId10.Text); if (xbId10 == 0) { xbId10 = 1; xbCount10 = 0; } } string msg = "\n" + "账户:" + txt_xbAccount.Text + "\n" + "角色:" + txt_xbName.Text + "\n" + "代币:" + txt_dbSend.Text + "\n"; if (txt_xbId1.Text != "" && xbCount1 != 0) { msg += "物品:" + txt_xbName1.Text + "\t数量:" + txt_xbCount1.Text + "\t\n"; } if (txt_xbId2.Text != "" && xbCount2 != 0) { msg += "物品:" + txt_xbName2.Text + "\t数量:" + txt_xbCount2.Text + "\t\n"; } if (txt_xbId3.Text != "" && xbCount3 != 0) { msg += "物品:" + txt_xbName3.Text + "\t数量:" + txt_xbCount3.Text + "\t\n"; } if (txt_xbId4.Text != "" && xbCount4 != 0) { msg += "物品:" + txt_xbName4.Text + "\t数量:" + txt_xbCount4.Text + "\t\n"; } if (txt_xbId5.Text != "" && xbCount5 != 0) { msg += "物品:" + txt_xbName5.Text + "\t数量:" + txt_xbCount5.Text + "\t\n"; } if (txt_xbId6.Text != "" && xbCount6 != 0) { msg += "物品:" + txt_xbName6.Text + "\t数量:" + txt_xbCount6.Text + "\t\n"; } if (txt_xbId7.Text != "" && xbCount7 != 0) { msg += "物品:" + txt_xbName7.Text + "\t数量:" + txt_xbCount7.Text + "\t\n"; } if (txt_xbId8.Text != "" && xbCount8 != 0) { msg += "物品:" + txt_xbName8.Text + "\t数量:" + txt_xbCount8.Text + "\t\n"; } if (txt_xbId9.Text != "" && xbCount9 != 0) { msg += "物品:" + txt_xbName9.Text + "\t数量:" + txt_xbCount9.Text + "\t\n"; } if (txt_xbId10.Text != "" && xbCount10 != 0) { msg += "物品:" + txt_xbName10.Text + "\t数量:" + txt_xbCount10.Text + "\t\n"; } msg += "\n确认信息无误?"; DialogResult dr = MessageBox.Show(msg, "对话框标题", MessageBoxButtons.OKCancel, MessageBoxIcon.Question); if (dr != DialogResult.OK) { return; } //确保有效 if ((txt_xbId1.Text == "" || xbCount1 == 0) && (txt_xbId2.Text == "" || xbCount2 == 0) && (txt_xbId3.Text == "" || xbCount3 == 0) && (txt_xbId4.Text == "" || xbCount4 == 0) && (txt_xbId5.Text == "" || xbCount5 == 0)) { } else { bool result = CSGHelper.InsertSanvtItem(txt_xbAccount.Text , (uint)xbId1, (uint)xbCount1, (uint)xbId2, (uint)xbCount2, (uint)xbId3, (uint)xbCount3 , (uint)xbId4, (uint)xbCount4, (uint)xbId5, (uint)xbCount5); if (result) { SGExHandle.WriteXbLog(txt_xbAccount.Text + "\t" + txt_xbName.Text + "\t" + txt_xbId1.Text + "\t" + txt_xbName1.Text + "\t" + txt_xbCount1.Text + "\t" + txt_xbId2.Text + "\t" + txt_xbName2.Text + "\t" + txt_xbCount2.Text + "\t" + txt_xbId4.Text + "\t" + txt_xbName3.Text + "\t" + txt_xbCount3.Text + "\t" + txt_xbId5.Text + "\t" + txt_xbName4.Text + "\t" + txt_xbCount4.Text + "\t" + txt_xbId6.Text + "\t" + txt_xbName5.Text + "\t" + txt_xbCount5.Text + "\t"); ListViewItem lvi = new ListViewItem(); lvi.Text = txt_xbAccount.Text; lvi.SubItems.Add(txt_xbName.Text); lvi.SubItems.Add(txt_xbId1.Text); lvi.SubItems.Add(txt_xbName1.Text); lvi.SubItems.Add(txt_xbCount1.Text); lvi.SubItems.Add(txt_xbId2.Text); lvi.SubItems.Add(txt_xbName2.Text); lvi.SubItems.Add(txt_xbCount2.Text); lvi.SubItems.Add(txt_xbId3.Text); lvi.SubItems.Add(txt_xbName3.Text); lvi.SubItems.Add(txt_xbCount3.Text); lvi.SubItems.Add(txt_xbId4.Text); lvi.SubItems.Add(txt_xbName4.Text); lvi.SubItems.Add(txt_xbCount4.Text); lvi.SubItems.Add(txt_xbId5.Text); lvi.SubItems.Add(txt_xbName5.Text); lvi.SubItems.Add(txt_xbCount5.Text); lstv_xblog.Items.Add(lvi); } else { string msg2 = "\n" + "账户:" + txt_xbAccount.Text + "\n" + "角色:" + txt_xbName.Text + "\n"; if (txt_xbId1.Text != "" && xbCount1 != 0) { msg += "物品:" + txt_xbName1.Text + "\t数量:" + txt_xbCount1.Text + "\t\n"; } if (txt_xbId2.Text != "" && xbCount2 != 0) { msg += "物品:" + txt_xbName2.Text + "\t数量:" + txt_xbCount2.Text + "\t\n"; } if (txt_xbId3.Text != "" && xbCount3 != 0) { msg += "物品:" + txt_xbName3.Text + "\t数量:" + txt_xbCount3.Text + "\t\n"; } if (txt_xbId4.Text != "" && xbCount4 != 0) { msg += "物品:" + txt_xbName4.Text + "\t数量:" + txt_xbCount4.Text + "\t\n"; } if (txt_xbId5.Text != "" && xbCount5 != 0) { msg += "物品:" + txt_xbName5.Text + "\t数量:" + txt_xbCount5.Text + "\t\n"; } MessageBox.Show("发送失败,\t\n" + msg2); } } Thread.Sleep(200); if ((txt_xbId6.Text == "" || xbCount6 == 0) && (txt_xbId7.Text == "" || xbCount7 == 0) && (txt_xbId8.Text == "" || xbCount8 == 0) && (txt_xbId9.Text == "" || xbCount9 == 0) && (txt_xbId10.Text == "" || xbCount10 == 0)) { } else { bool result = CSGHelper.InsertSanvtItem(txt_xbAccount.Text , (uint)xbId6, (uint)xbCount6, (uint)xbId7, (uint)xbCount7, (uint)xbId8, (uint)xbCount8 , (uint)xbId9, (uint)xbCount9, (uint)xbId10, (uint)xbCount10); if (result) { SGExHandle.WriteXbLog(txt_xbAccount.Text + "\t" + txt_xbName.Text + "\t" + txt_xbId6.Text + "\t" + txt_xbName6.Text + "\t" + txt_xbCount6.Text + "\t" + txt_xbId7.Text + "\t" + txt_xbName7.Text + "\t" + txt_xbCount7.Text + "\t" + txt_xbId8.Text + "\t" + txt_xbName8.Text + "\t" + txt_xbCount8.Text + "\t" + txt_xbId9.Text + "\t" + txt_xbName9.Text + "\t" + txt_xbCount9.Text + "\t" + txt_xbId10.Text + "\t" + txt_xbName10.Text + "\t" + txt_xbCount10.Text + "\t"); ListViewItem lvi = new ListViewItem(); lvi.Text = txt_xbAccount.Text; lvi.SubItems.Add(txt_xbName.Text); lvi.SubItems.Add(txt_xbId6.Text); lvi.SubItems.Add(txt_xbName6.Text); lvi.SubItems.Add(txt_xbCount6.Text); lvi.SubItems.Add(txt_xbId7.Text); lvi.SubItems.Add(txt_xbName7.Text); lvi.SubItems.Add(txt_xbCount7.Text); lvi.SubItems.Add(txt_xbId8.Text); lvi.SubItems.Add(txt_xbName8.Text); lvi.SubItems.Add(txt_xbCount8.Text); lvi.SubItems.Add(txt_xbId9.Text); lvi.SubItems.Add(txt_xbName9.Text); lvi.SubItems.Add(txt_xbCount9.Text); lvi.SubItems.Add(txt_xbId10.Text); lvi.SubItems.Add(txt_xbName10.Text); lvi.SubItems.Add(txt_xbCount10.Text); lstv_xblog.Items.Add(lvi); } else { string msg2 = "\n" + "账户:" + txt_xbAccount.Text + "\n" + "角色:" + txt_xbName.Text + "\n"; if (txt_xbId6.Text != "" && xbCount6 != 0) { msg += "物品:" + txt_xbName6.Text + "\t数量:" + txt_xbCount6.Text + "\t\n"; } if (txt_xbId7.Text != "" && xbCount7 != 0) { msg += "物品:" + txt_xbName7.Text + "\t数量:" + txt_xbCount7.Text + "\t\n"; } if (txt_xbId8.Text != "" && xbCount8 != 0) { msg += "物品:" + txt_xbName8.Text + "\t数量:" + txt_xbCount8.Text + "\t\n"; } if (txt_xbId9.Text != "" && xbCount9 != 0) { msg += "物品:" + txt_xbName9.Text + "\t数量:" + txt_xbCount9.Text + "\t\n"; } if (txt_xbId10.Text != "" && xbCount10 != 0) { msg += "物品:" + txt_xbName10.Text + "\t数量:" + txt_xbCount10.Text + "\t\n"; } MessageBox.Show("发送失败,\t\n" + msg2); } } Thread.Sleep(200); //代币 if (!string.IsNullOrEmpty(txt_dbSend.Text) && CFormat.isNumberic(txt_dbSend.Text)) { int dbCount = Convert.ToInt32(txt_dbSend.Text); if (dbCount > 0) { //虚宝增加 bool result = CSGHelper.AddAcountPoint(txt_xbAccount.Text, dbCount); if (result) { txt_dbCurr.Text = "" + CSGHelper.SelectAcountPoint(txt_xbAccount.Text); } else { MessageBox.Show("发送代币失败,代币:" + dbCount); } } } if (cbx_xbconf.Text == "新人起步") { m_SGExHandle.SendWorldWords("新人玩家 " + txt_xbName.Text + " 的新手起步已经发放,请到大鸿胪处领取虚宝,欢迎加入大家庭,祝游戏愉快。"); } } else { MessageBox.Show("请核对发放帐号!"); } }